<div><div><div>I just learned about the inreg LLVM parameter attribute, which seems to do this.<div><br></div><div><div><div>declare external</div><div>void @___CxxFrameHandler3(i32* inreg nocapture) nounwind </div><div><br>
</div><div>@EHFuncInfo = global i32 0, align 4</div><div><br></div><div>define void @main() {</div><div> tail call void @___CxxFrameHandler3(i32* @EHFuncInfo)</div><div> ret void</div><div>}</div></div><div><br></div><div>
generates:</div><div><br></div><div><div>_main: # @main</div><div> movl $_EHFuncInfo, %eax</div><div> jmp ____CxxFrameHandler3 # TAILCALL</div></div></div></div><div>
<br></div>-- <br>Joćo Matos<br>
</div></div>