示例#1
0
  public LoopsData(final StructuredGraph graph) {
    cfg =
        Debug.scope(
            "ControlFlowGraph",
            new Callable<ControlFlowGraph>() {

              @Override
              public ControlFlowGraph call() throws Exception {
                return ControlFlowGraph.compute(graph, true, true, true, true);
              }
            });
    for (Loop lirLoop : cfg.getLoops()) {
      LoopEx ex = new LoopEx(lirLoop, this);
      lirLoopToEx.put(lirLoop, ex);
      loopBeginToEx.put(ex.loopBegin(), ex);
    }
  }
示例#2
0
 public Collection<LoopEx> loops() {
   return lirLoopToEx.values();
 }
示例#3
0
 public LoopEx loop(LoopBeginNode loopBegin) {
   return loopBeginToEx.get(loopBegin);
 }
示例#4
0
 public LoopEx loop(Loop lirLoop) {
   return lirLoopToEx.get(lirLoop);
 }