Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Yes, because the pointers are different at -O.

As there are no guarantees as to the relative placement of auto/stack variables relative to each other, that is perfectly fine.



If the behaviour differs at optimisation levels, would that not suggest that it is not a sane behaviour?


Not in this case, no, not at all.

Finding a different layout for auto variable in the stack frame at different optimization levels is perfectly fine.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: