Mercurial > hg > truffle
comparison src/share/vm/adlc/formssel.hpp @ 599:0ad1cb407fa1
6805427: adlc compiler may generate incorrect machnode emission code
Reviewed-by: kvn, twisti
author | never |
---|---|
date | Wed, 25 Feb 2009 10:53:14 -0800 |
parents | ad8c8ca4ab0f |
children | dbbe28fc66b5 |
comparison
equal
deleted
inserted
replaced
587:e57b6f22d1f3 | 599:0ad1cb407fa1 |
---|---|
99 FormatRule *_format; // Format for assembly generation | 99 FormatRule *_format; // Format for assembly generation |
100 Peephole *_peephole; // List of peephole rules for instruction | 100 Peephole *_peephole; // List of peephole rules for instruction |
101 const char *_ins_pipe; // Instruction Scheduline description class | 101 const char *_ins_pipe; // Instruction Scheduline description class |
102 | 102 |
103 uint *_uniq_idx; // Indexes of unique operands | 103 uint *_uniq_idx; // Indexes of unique operands |
104 int _uniq_idx_length; // Length of _uniq_idx array | |
104 uint _num_uniq; // Number of unique operands | 105 uint _num_uniq; // Number of unique operands |
105 ComponentList _components; // List of Components matches MachNode's | 106 ComponentList _components; // List of Components matches MachNode's |
106 // operand structure | 107 // operand structure |
107 | 108 |
108 // Public Methods | 109 // Public Methods |
255 | 256 |
256 // Seach through operands to determine operands unique positions. | 257 // Seach through operands to determine operands unique positions. |
257 void set_unique_opnds(); | 258 void set_unique_opnds(); |
258 uint num_unique_opnds() { return _num_uniq; } | 259 uint num_unique_opnds() { return _num_uniq; } |
259 uint unique_opnds_idx(int idx) { | 260 uint unique_opnds_idx(int idx) { |
260 if( _uniq_idx != NULL && idx > 0 ) | 261 if( _uniq_idx != NULL && idx > 0 ) { |
262 assert(idx < _uniq_idx_length, "out of bounds"); | |
261 return _uniq_idx[idx]; | 263 return _uniq_idx[idx]; |
262 else | 264 } else { |
263 return idx; | 265 return idx; |
264 } | 266 } |
267 } | |
265 | 268 |
266 // Operands which are only KILLs aren't part of the input array and | 269 // Operands which are only KILLs aren't part of the input array and |
267 // require special handling in some cases. Their position in this | 270 // require special handling in some cases. Their position in this |
268 // operand list is higher than the number of unique operands. | 271 // operand list is higher than the number of unique operands. |
269 bool is_noninput_operand(uint idx) { | 272 bool is_noninput_operand(uint idx) { |