comparison graal/com.oracle.graal.printer/src/com/oracle/graal/printer/HexCodeFile.java @ 14906:f3a5036cc13c

javadoc fixes javadoc has become stricter in jdk8
author Bernhard Urban <bernhard.urban@jku.at>
date Mon, 31 Mar 2014 20:51:09 +0200
parents a6fda38d8484
children cd9404a8216b
comparison
equal deleted inserted replaced
14905:b7afc71535d3 14906:f3a5036cc13c
32 import com.oracle.graal.api.code.CompilationResult.JumpTable; 32 import com.oracle.graal.api.code.CompilationResult.JumpTable;
33 33
34 /** 34 /**
35 * A HexCodeFile is a textual format for representing a chunk of machine code along with extra 35 * A HexCodeFile is a textual format for representing a chunk of machine code along with extra
36 * information that can be used to enhance a disassembly of the code. 36 * information that can be used to enhance a disassembly of the code.
37 * 37 *
38 * A pseudo grammar for a HexCodeFile is given below. 38 * A pseudo grammar for a HexCodeFile is given below.
39 * 39 *
40 * <pre> 40 * <pre>
41 * HexCodeFile ::= Platform Delim HexCode Delim (OptionalSection Delim)* 41 * HexCodeFile ::= Platform Delim HexCode Delim (OptionalSection Delim)*
42 * 42 *
43 * OptionalSection ::= Comment | OperandComment | JumpTable | LookupTable 43 * OptionalSection ::= Comment | OperandComment | JumpTable | LookupTable
44 * 44 *
54 * 54 *
55 * LookupTable ::= "LookupTable" Position NPairs KeySize OffsetSize 55 * LookupTable ::= "LookupTable" Position NPairs KeySize OffsetSize
56 * 56 *
57 * Position, EntrySize, Low, High, NPairs KeySize OffsetSize ::= int 57 * Position, EntrySize, Low, High, NPairs KeySize OffsetSize ::= int
58 * 58 *
59 * Delim := "<||@" 59 * Delim := "&lt;||@"
60 * </pre> 60 * </pre>
61 * 61 *
62 * There must be exactly one HexCode and Platform part in a HexCodeFile. The length of HexDigits 62 * There must be exactly one HexCode and Platform part in a HexCodeFile. The length of HexDigits
63 * must be even as each pair of digits represents a single byte. 63 * must be even as each pair of digits represents a single byte.
64 * <p> 64 * <p>
65 * Below is an example of a valid Code input: 65 * Below is an example of a valid Code input:
66 * 66 *
67 * <pre> 67 * <pre>
68 * 68 *
69 * Platform AMD64 64 <||@ 69 * Platform AMD64 64 &lt;||@
70 * HexCode 0 e8000000009090904883ec084889842410d0ffff48893c24e800000000488b3c24488bf0e8000000004883c408c3 <||@ 70 * HexCode 0 e8000000009090904883ec084889842410d0ffff48893c24e800000000488b3c24488bf0e8000000004883c408c3 &lt;||@
71 * Comment 24 frame-ref-map: +0 {0} 71 * Comment 24 frame-ref-map: +0 {0}
72 * at java.lang.String.toLowerCase(String.java:2496) [bci: 1] 72 * at java.lang.String.toLowerCase(String.java:2496) [bci: 1]
73 * |0 73 * |0
74 * locals: |stack:0:a 74 * locals: |stack:0:a
75 * stack: |stack:0:a 75 * stack: |stack:0:a
76 * <||@ 76 * &lt;||@
77 * OperandComment 24 {java.util.Locale.getDefault()} <||@ 77 * OperandComment 24 {java.util.Locale.getDefault()} &lt;||@
78 * Comment 36 frame-ref-map: +0 {0} 78 * Comment 36 frame-ref-map: +0 {0}
79 * at java.lang.String.toLowerCase(String.java:2496) [bci: 4] 79 * at java.lang.String.toLowerCase(String.java:2496) [bci: 4]
80 * |0 80 * |0
81 * locals: |stack:0:a 81 * locals: |stack:0:a
82 * <||@ 82 * &lt;||@
83 * OperandComment 36 {java.lang.String.toLowerCase(Locale)} <||@ 83 * OperandComment 36 {java.lang.String.toLowerCase(Locale)} lt;||@
84 * 84 *
85 * </pre> 85 * </pre>
86 */ 86 */
87 public class HexCodeFile { 87 public class HexCodeFile {
88 88
89 public static final String NEW_LINE = CodeUtil.NEW_LINE; 89 public static final String NEW_LINE = CodeUtil.NEW_LINE;
207 list.add(encodeString(comment)); 207 list.add(encodeString(comment));
208 } 208 }
209 209
210 /** 210 /**
211 * Sets an operand comment for a given position. 211 * Sets an operand comment for a given position.
212 * 212 *
213 * @return the previous operand comment for {@code pos} 213 * @return the previous operand comment for {@code pos}
214 */ 214 */
215 public String addOperandComment(int pos, String comment) { 215 public String addOperandComment(int pos, String comment) {
216 return operandComments.put(pos, encodeString(comment)); 216 return operandComments.put(pos, encodeString(comment));
217 } 217 }