Share via


The maximum number of stack frames supported by Visual Studio has be exceeded.

Question

Friday, June 10, 2016 3:17 PM

I'm trying to debug  a postmortem dump file.  Looks like there is some stupid infinite recursion going on, but I can't see the source of the problem because VS2015 and VS2013 will not look beyond 4972 frames (got that number by going to the command window and typing in Debug.ListCallStack).

Is there a way to increase this value?

Thanks,

A

I don't mind someone marking a post as "Proposed as answer", but DO NOT mark it as "Answered". If I am the OP, I will decide if a post actually answers my post or not. Thank you.

All replies (4)

Friday, June 10, 2016 4:35 PM | 1 vote

Not that I am aware of, but IIRC you have windbg.exe installed (Debugging Tools for Windows).
If it is a native dump would try this debugger. Claims it has max-num of 0xffff

0:000> kb 0x20000
Requested number of stack frames (0x20000) is too large! The maximum number is 0xffff.
                ^ Range error in 'kb 0x20000'

With kind regards


Friday, June 10, 2016 4:48 PM

Yeah, I'm attempting to use WinDbg.  Very difficult to navigate through.  All I can really get from it is that the stack frame I want is 13253 down.  Trying to get other information from WinDbg is almost impossible.

A

I don't mind someone marking a post as "Proposed as answer", but DO NOT mark it as "Answered". If I am the OP, I will decide if a post actually answers my post or not. Thank you.


Friday, June 10, 2016 5:27 PM | 1 vote

Yes it has its pitfalls. Best results are achieved, when Symbol Path(s), Executable Image Path(s), Source Path(s) are set.
https://msdn.microsoft.com/en-us/library/windows/hardware/hh439335(v=vs.85).aspx
https://msdn.microsoft.com/en-us/library/windows/hardware/ff556911(v=vs.85).aspx

Do not forget checking the Reload (or do a manual .reload):


If all is set right - and you got lucky - a click on stack-number may open src (provided you have the right pdbs, modules, src).

But in reality it is a little bit more messy ...
Besides, you already did a

!analyze -v

With kind regards


Thursday, February 1, 2018 6:17 AM

I know i'm late for years but recursion you said about very often relate with public and private vars in a code.

For example, you declare private field _test and write public property Test for it:

private TestClass _test;

public TestClass Test
{
  get
  {
    return this.Test;
  }
  set
  {
    this.Test= value;
  }
}

As you may be seen, property has set the property Test, this is mistake. And in some cases, for example during deserialization you will get that error.

Hope i'll help somebody.