Bug 27389 - [4.2 Regression] java: verify_flow_info fails
Summary: [4.2 Regression] java: verify_flow_info fails
Status: RESOLVED DUPLICATE of bug 26447
Alias: None
Product: gcc
Classification: Unclassified
Component: tree-optimization (show other bugs)
Version: 4.2.0
: P3 blocker
Target Milestone: 4.2.0
Assignee: Not yet assigned to anyone
URL:
Keywords: EH, ice-on-valid-code
Depends on:
Blocks: 26447
  Show dependency treegraph
 
Reported: 2006-05-02 14:53 UTC by Richard Biener
Modified: 2006-05-02 17:32 UTC (History)
6 users (show)

See Also:
Host:
Target: x86_64-*-linux-gnu, ia64-*-linux-gnu
Build:
Known to work:
Known to fail:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Richard Biener 2006-05-02 14:53:37 UTC
Testcase:

import javax.xml.stream.XMLStreamException;
import javax.xml.stream.XMLStreamWriter;
public class StAXWriter
{
  XMLStreamWriter writer;
  int indent = 0;
  public void writeEnd(boolean wasEmpty)
  {
    try
      {
        indent -= 2;
        for (int i = 0; i < indent; i++)
          writer.writeCharacters(" ");
      }
    catch (XMLStreamException xmlse)
      {
      }
  }
};

 /abuild/rguenther/obj2/gcc/jc1 StAXWriter.java -fhash-synchronization -fno-use-divide-subroutine -fuse-boehm-gc -fnon-call-exceptions -fkeep-inline-functions -quiet -dumpbase StAXWriter.java -mtune=generic -auxbase-strip /dev/null -g -O2 -Wno-deprecated -version -fomit-frame-pointer -fclasspath= -fbootclasspath=/abuild/rguenther/obj/x86_64-unknown-linux-gnu/libjava/classpath/lib -fencoding=UTF-8 -fbootstrap-classes -fjni -findirect-dispatch -fno-indirect-classes -fPIC -fdump-tree-pre-details -o /dev/null
GNU Java version 4.2.0 20060501 (experimental) (x86_64-unknown-linux-gnu)
        compiled by GNU C version 3.3.3 (SuSE Linux).
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
Class path starts here:
    ./
    /abuild/rguenther/obj/x86_64-unknown-linux-gnu/libjava/classpath/lib/ (system)
StAXWriter.java: In class 'StAXWriter':
StAXWriter.java: In method 'StAXWriter.writeEnd(boolean)':
StAXWriter.java:8: error: control flow in the middle of basic block 3
StAXWriter.java:8: internal compiler error: verify_flow_info failed
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
Comment 1 Richard Biener 2006-05-02 14:56:58 UTC
Happens at the point PRE calls cleanup_tree_cfg after purging dead eh edges.

Found partial redundancy for expression *VH.52 (VH.57)
Created value VH.86 for *D.934_6
Inserted pretmp.60_42 = D.1001_27 in predecessor 14
Created phi prephitmp.61_20 = PHI <storetmp.59_51(17), pretmp.60_42(14)>; in block 4
Replaced *D.934_6 with prephitmp.61_20 in D.936_22 = *D.934_6;
  Removed EH side effects.
Removing basic block 18
;; basic block 18, loop depth 0, count 0
;; prev block 5, next block 6
;; pred:
;; succ:       16 [100.0%]  (fallthru)
<L10>:;
goto <bb 16> (<L6>);


Merging blocks 3 and 17
Merging blocks 4 and 5


(gdb) call debug_bb_n (3)
;; basic block 3, loop depth 0, count 0
;; prev block 2, next block 4
;; pred:       2 [100.0%]  (fallthru,exec)
;; succ:       4 [100.0%]  (fallthru)
<bb 3>:
D.938_17 = D.935_10 + -2;
#   SMT.37_56 = V_MAY_DEF <SMT.37_53>;
#   SMT.41_57 = V_MAY_DEF <SMT.41_54>;
*D.934_6 = D.938_17;
#   VUSE <SMT.37_56>;
#   VUSE <SMT.41_57>;
storetmp.59_51 = *D.934_6;


the store ends the BB, flow info fails to verify at the load.  No EH info
in the block, cfg_cleanup merged it with BB 17 (which is empty).
Comment 2 Bryce McKinlay 2006-05-02 15:33:38 UTC
I could not reproduce the bootstrap failure on x86-64 as of revision 113466.

The test case does fail, however, when built with -findirect-dispatch.

Looks like a dupe of bug 26447 ?
Comment 3 Bryce McKinlay 2006-05-02 17:32:46 UTC

*** This bug has been marked as a duplicate of 26447 ***