[PATCH v3 1/2] generate EH info for volatile asm statements (PR93981)

Jeff Law law@redhat.com
Thu Nov 12 15:51:53 GMT 2020


On 3/11/20 6:38 PM, J.W. Jagersma via Gcc-patches wrote:
> The following patch extends the generation of exception handling
> information, so that it is possible to catch exceptions thrown from
> volatile asm statements, when -fnon-call-exceptions is enabled.  Parts
> of the gcc code already suggested this should be possible, but it was
> never fully implemented.
>
> Two new test cases are added.  The target-dependent test should pass on
> platforms where throwing from a signal handler is allowed.  The only
> platform I am aware of where that is the case is *-linux-gnu, so it is
> set to XFAIL on all others.
>
> gcc/
> 2020-03-11  Jan W. Jagersma  <jwjagersma@gmail.com>
>
> 	PR inline-asm/93981
> 	* tree-cfg.c (make_edges_bb): Make EH edges for GIMPLE_ASM.
> 	* tree-eh.c (lower_eh_constructs_2): Add case for GIMPLE_ASM.
> 	Assign register output operands to temporaries.
> 	* doc/extend.texi: Document that volatile asms can now throw.
>
> gcc/testsuite/
> 2020-03-11  Jan W. Jagersma  <jwjagersma@gmail.com>
>
> 	PR inline-asm/93981
> 	* g++.target/i386/pr93981.C: New test.
> 	* g++.dg/eh/pr93981.C: New test.

Is this the final version of the patch?  Do we have agreement on the
sematics for output operands, particularly memory operands?  The last
few messages in the March thread lead me to believe that's still not
settled.


Jeff




More information about the Gcc-patches mailing list