You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In this example, the gcc_except_table section for test_nounwind_decl does not contain information about the call (as the declaration is nounwind), but the sections for test_nounwind_call and test_memsetdo contain it.
looks at the attributes of a Function operand of the call. This does not work if the call-site was marked nounwind, or if it's a libcall lowering, e.g. of an intrinsic.
The text was updated successfully, but these errors were encountered:
@efriedma-quic Before I spend time working on this, do you think adding a NoUnwind flag to MachineInstr would make sense?
From poking around a bit, I think the pathway to preserving it would be via CallLoweringInfo -> NodeExtraInfo -> MachineInstr (the last step in ScheduleDAG).
The issue here optimizing the size of the unwind table for functions that contain both nounwind and non-nounwind calls? If we correctly detect the nounwind calls, we can skip adding entries to the table for the relevant basic blocks. (Dropping the nounwind is conservatively correct, but not optimal. And this is completely irrelevant for function definitions marked nounwind.)
I guess it makes sense to mark that on the MachineInstr for the call; EHStreamer::callToNoUnwindFunction is trying to rederive information we should already have.
https://llvm.godbolt.org/z/4hhf36Wf8
In this example, the gcc_except_table section for
test_nounwind_decl
does not contain information about the call (as the declaration is nounwind), but the sections fortest_nounwind_call
andtest_memset
do contain it.This is because
llvm-project/llvm/lib/CodeGen/AsmPrinter/EHStreamer.cpp
Line 157 in de37da8
nounwind
, or if it's a libcall lowering, e.g. of an intrinsic.The text was updated successfully, but these errors were encountered: