On 11/04/11 08:26, Michael Matz wrote: > Hi, > > On Thu, 3 Nov 2011, Aldy Hernandez wrote: > >> +/* GIMPLE_EH_ELSE must be the sole contents of >> + a GIMPLE_TRY_FINALLY node. For all normal exits from the try block, >> + we N_BODY is run; for all exception exits from the try block, > > s/we // Fixed > >> +++ gcc/calls.c (.../branches/transactional-memory) (revision 180773) >> @@ -496,7 +496,60 @@ emit_call_1 (rtx funexp, tree fntree ATT >> static int >> special_function_p (const_tree fndecl, int flags) >> { >> + case BUILT_IN_TM_IRREVOCABLE: >> + case BUILT_IN_TM_GETTMCLONE_IRR: >> + case BUILT_IN_TM_MEMCPY: >> + case BUILT_IN_TM_MEMMOVE: >> + case BUILT_IN_TM_MEMSET: > > Whitespace. Fixed > >> @@ -1751,6 +1787,8 @@ walk_gimple_stmt (gimple_stmt_iterator * >> gcc_assert (tree_ret == NULL); >> >> /* Re-read stmt in case the callback changed it. */ >> + if (wi&& wi->removed_stmt) >> + return NULL; >> stmt = gsi_stmt (*gsi); > > Comment belongs to the stmt assignment, not to the new if/return. Fixed > >> @@ -3085,6 +3153,8 @@ get_call_expr_in (tree t) >> t = TREE_OPERAND (t, 1); >> if (TREE_CODE (t) == WITH_SIZE_EXPR) >> t = TREE_OPERAND (t, 0); >> + if (TREE_CODE (t) == VIEW_CONVERT_EXPR) >> + t = TREE_OPERAND (t, 0); >> if (TREE_CODE (t) == CALL_EXPR) >> return t; > > The function get_call_expr_in is unused in our compiler (and you don't > introduce a new use), so instead of amending it, just remove it. Fixed in previous patch. >> + GF_CALL_NOINLINE = 1<< 8, > This flag is only used by the new accessors gimple_call_noinline_p and > gimple_call_set_noinline_p. The latter is used in > trans-mem.c:ipa_tm_insert_gettmclone_call, but marked as hack. The flag > isn't tested anywhere (i.e. no calls to gimple_call_noinline_p). Hence > this whole thing is unused, presumably the hack was transformed into a > real solution :) So, don't add the flag or the accessors, and remove the > call from trans-mem.c. Excellent catch! Thanks so much. Fixed. The attached patch has been bootstrapped and regtested on x86-64 Linux. Committing to branch.