This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
[trans-mem] _ITM_abortTransaction not considered as noreturn function
- From: Patrick Marlier <patrick dot marlier at unine dot ch>
- To: Richard Henderson <rth at redhat dot com>
- Cc: Aldy Hernandez <aldyh at redhat dot com>, gcc at gcc dot gnu dot org
- Date: Tue, 15 Feb 2011 09:35:11 +0100
- Subject: [trans-mem] _ITM_abortTransaction not considered as noreturn function
Dear Richard,
When I was looking at this problem of tail call optimization, I have
found that _ITM_abortTransaction was not considered as a 'noreturn'
function. Do you have any reason not doing this? If not, I propose to
add ECF_NORETURN in calls.c:special_function_p().
Also I just want to point out that BUILT_IN_TM_START is missing in this
switch/case but I think I figure out why it is ok to not have it (except
in the case of nested transactions).
Thanks in advance for your time,
Patrick Marlier.
Index: calls.c
===================================================================
--- calls.c (revision 170149)
+++ calls.c (working copy)
@@ -473,9 +473,10 @@
{
switch (DECL_FUNCTION_CODE (fndecl))
{
+ case BUILT_IN_TM_ABORT:
+ flags |= ECF_NORETURN;
case BUILT_IN_TM_COMMIT:
case BUILT_IN_TM_COMMIT_EH:
- case BUILT_IN_TM_ABORT:
case BUILT_IN_TM_IRREVOCABLE:
case BUILT_IN_TM_GETTMCLONE_IRR:
case BUILT_IN_TM_MEMCPY: