Conversation
| if (0 <= var->varNumber && var->varNumber < lvaCount) | ||
| { | ||
| printf("("); | ||
| gtDispLclVar(var->varNumber, false); |
There was a problem hiding this comment.
This is going to lose the formatting of the %10s. I suppose you could use gtGetLclVarName, but then you have to deal with a buffer and size. I guess you could generalize gtDispLclVar to also have an option to pad to an explicit size (I think the padding might be on the wrong side, but at least the columns would line up). It might be worth just merging to unblock dumps before thinking about whether or not to do anything.
There was a problem hiding this comment.
I agree with you on that it won't look great, I just didn't want to block jitdump much longer. I will see if it makes sense to change the buffer to return string directly or do what you are proposing. It is debuggable code so I guess we can afford the simplest return solution.
We are hitting an assert when we want to print a variable name for retBuff as @EgorBo says on #77447 (comment)