<div dir="ltr">I'm doing a lot of experiments with GDC, and I'm noticing that leaf functions are still generating a stack frame and doing pointless work...<div style><br></div><div style>int leaf() pure nothrow</div>
<div style>{</div><div style>  return 0;</div><div style>}</div><div style><br></div><div style>compile with -frelease -finline -O3, etc</div><div style><br></div><div style>I expect 2 opcodes, load immediate and return, but I get a whole pointless function including memory access O_O</div>
<div style><br></div><div style>Any ideas? Is this normal?</div></div>