Hi all, sorry for two posts I did a bit more investigation into this problem.
It seems that this problem loses memory when it relocates the stack, but I'm still not sure exactly why or how. Using a YYINITDEPTH value of 1, in my little test case causes a certain number of bytes to be leaked after yypstate_delete finishes. Using a YYINITDEPTH value of 2, in my little test case causes a certain smaller number of bytes to be leaked. This leads me to suspect (but not by any means to be sure) that the bytes lost are either the bytes initially allocated, and that they are not properly relocated with the newly allocated stack bytes, or alternatively that the bytes lost are the new ones, and that for some reason, when yyps gets deleted, it leaves behind some of its freshly allocated memory. Actually either way it is sliced, malloc gets called, but free never does, beside the call to free the top level yyps pointer, so I see this as a point at least to be further evaluated. If anyone knows what's going on with this, I'd appreciate it, I feel like I'm hitting a wall with regards to my understanding of the architecture of bison and its generated code. Thanks -Brandon
