diff mbox

Fix a bug that breaks go build

Message ID CAO2gOZWhrQ6TVaTdgHvaxU29s-mssq7VdZ08CdJMpmgDC_MSHg@mail.gmail.com
State New
Headers show

Commit Message

Dehao Chen Sept. 20, 2012, 8:12 p.m. UTC
This patch fixes a bug is in tree-eh.c. IS_UNKNOWN_LOCATION is
mistakenly used, thus
the block info for a call stmt is cleared.

Bootstrapped and gcc regression testing is on-going.

Is it okay for trunk?

Thanks,
Dehao

gcc/ChangeLog:
        tree-eh.c (lower_try_finally_dup_block): Use correct way to
        check unknown location.
diff mbox

Patch

Index: tree-eh.c
===================================================================
--- tree-eh.c   (revision 191494)
+++ tree-eh.c   (working copy)
@@ -883,7 +883,7 @@  lower_try_finally_dup_block (gimple_seq seq, struc
   new_seq = copy_gimple_seq_and_replace_locals (seq);

   for (gsi = gsi_start (new_seq); !gsi_end_p (gsi); gsi_next (&gsi))
-    if (IS_UNKNOWN_LOCATION (gimple_location (gsi_stmt (gsi))))
+    if (gimple_location (gsi_stmt (gsi)) == UNKNOWN_LOCATION)
       gimple_set_location (gsi_stmt (gsi), loc);

   if (outer_state->tf)