comparison graal/GraalCompiler/src/com/sun/c1x/lir/LIRDebugInfo.java @ 2707:7ed72769d51a

exception handling related changes: * changed blockPredecessors to list of Instructions, instead of Blocks * removed explicit predecessor management in BlockBegin, now using predecessors from Graph structure * replaced generated LIR exception entries with exception dispatch chains in IR * added Unwind and ExceptionDispatch instructions * removed ExceptionEntry flag in BlockBegin and all code depending on it * removed exceptionHandler list from Instruction, replaced by exception Edge on Invoke and Throw * replaced list of ExceptionHandlers with single exception edge in debug info misc: * changed GraphvizPrinter layout (smaller ports on large nodes) * removed defunct run config
author Lukas Stadler <lukas.stadler@jku.at>
date Wed, 18 May 2011 18:09:20 +0200
parents 16b9a8b5ad39
children a0dd2b907806
comparison
equal deleted inserted replaced
2677:0ea5f12e873a 2707:7ed72769d51a
29 import com.sun.c1x.value.*; 29 import com.sun.c1x.value.*;
30 import com.sun.cri.ci.*; 30 import com.sun.cri.ci.*;
31 31
32 /** 32 /**
33 * This class represents debugging and deoptimization information attached to a LIR instruction. 33 * This class represents debugging and deoptimization information attached to a LIR instruction.
34 *
35 * @author Marcelo Cintra
36 * @author Thomas Wuerthinger
37 * @author Ben L. Titzer
38 */ 34 */
39 public class LIRDebugInfo { 35 public class LIRDebugInfo {
40 36
41 public abstract static class ValueLocator { 37 public abstract static class ValueLocator {
42 public abstract CiValue getLocation(Value value); 38 public abstract CiValue getLocation(Value value);
43 } 39 }
44 40
45 public final FrameState state; 41 public final FrameState state;
46 public final List<ExceptionHandler> exceptionHandlers; 42 public final BlockBegin exceptionEdge;
47 public CiDebugInfo debugInfo; 43 public CiDebugInfo debugInfo;
48 44
49 public LIRDebugInfo(FrameState state, List<ExceptionHandler> exceptionHandlers) { 45 public LIRDebugInfo(FrameState state, BlockBegin exceptionEdge) {
50 assert state != null; 46 assert state != null;
51 this.state = state; 47 this.state = state;
52 this.exceptionHandlers = exceptionHandlers; 48 this.exceptionEdge = exceptionEdge;
53 } 49 }
54 50
55 private LIRDebugInfo(LIRDebugInfo info) { 51 private LIRDebugInfo(LIRDebugInfo info) {
56 this.state = info.state; 52 this.state = info.state;
57 53 this.exceptionEdge = info.exceptionEdge;
58 // deep copy of exception handlers
59 if (info.exceptionHandlers != null) {
60 this.exceptionHandlers = new ArrayList<ExceptionHandler>(info.exceptionHandlers.size());
61 for (ExceptionHandler h : info.exceptionHandlers) {
62 this.exceptionHandlers.add(new ExceptionHandler(h));
63 }
64 } else {
65 this.exceptionHandlers = null;
66 }
67 } 54 }
68 55
69 public LIRDebugInfo copy() { 56 public LIRDebugInfo copy() {
70 return new LIRDebugInfo(this); 57 return new LIRDebugInfo(this);
71 } 58 }