This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] 19/n: trans-mem: middle end/misc patches (LAST PATCH)


On 11/06/11 12:20, Richard Henderson wrote:
-          if (!computed_goto_p (stmt))
+         if (!computed_goto_p (stmt))
             {
-             tree new_dest = main_block_label (gimple_goto_dest (stmt));
-             gimple_goto_set_dest (stmt, new_dest);
+             label = gimple_goto_dest (stmt);
+             new_label = main_block_label (label);
+             if (new_label != label)
+               gimple_goto_set_dest (stmt, new_label);

What's the reason for this changes? Optimization?

Yes. Rth can elaborate if you deem necessary.

Really? I have no idea what this change achieves. I actually wonder if this is a merge error.

Removing this caused various TM tests failures, which I have yet to fully investigate. I found the original patch by you [rth] (attached). Perhaps you can elaborate as to its original use.


It may be that we need to remove all of the GIMPLE_GOTO, GIMPLE_COND, and GIMPLE_SWITCH hacks in cleanup_dead_labels, but I will wait for a double check by you before touching any more of this.

In the meantime, I will commit the patch sans this GIMPLE_GOTO removal which may still be used. That is, after another round of tests.

Attachment: original-goto-patch
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]