aboutsummaryrefslogtreecommitdiff
path: root/src/share/vm/opto/node.hpp
diff options
context:
space:
mode:
authorgoetz <none@none>2013-11-14 19:24:59 -0800
committergoetz <none@none>2013-11-14 19:24:59 -0800
commit6721012ec757a98a87931d965d32955c3d96d4c2 (patch)
treecf7907ed7977f452a9cf2f0a2f289f0496b3721c /src/share/vm/opto/node.hpp
parent2184bdf777f239160850d253db3395883b8abba9 (diff)
8003854: PPC64 (part 115): Introduce PostallocExpand that expands nodes after register allocation
Summary: added ability in C2 to expand mach nodes to several mach nodes after register allocation Reviewed-by: kvn
Diffstat (limited to 'src/share/vm/opto/node.hpp')
-rw-r--r--src/share/vm/opto/node.hpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/share/vm/opto/node.hpp b/src/share/vm/opto/node.hpp
index 924db1b37..d380a35f0 100644
--- a/src/share/vm/opto/node.hpp
+++ b/src/share/vm/opto/node.hpp
@@ -357,6 +357,8 @@ protected:
// Reference to the i'th input Node. Error if out of bounds.
Node* in(uint i) const { assert(i < _max, err_msg_res("oob: i=%d, _max=%d", i, _max)); return _in[i]; }
+ // Reference to the i'th input Node. NULL if out of bounds.
+ Node* lookup(uint i) const { return ((i < _max) ? _in[i] : NULL); }
// Reference to the i'th output Node. Error if out of bounds.
// Use this accessor sparingly. We are going trying to use iterators instead.
Node* raw_out(uint i) const { assert(i < _outcnt,"oob"); return _out[i]; }
@@ -384,6 +386,10 @@ protected:
// Set a required input edge, also updates corresponding output edge
void add_req( Node *n ); // Append a NEW required input
+ void add_req( Node *n0, Node *n1 ) {
+ add_req(n0); add_req(n1); }
+ void add_req( Node *n0, Node *n1, Node *n2 ) {
+ add_req(n0); add_req(n1); add_req(n2); }
void add_req_batch( Node* n, uint m ); // Append m NEW required inputs (all n).
void del_req( uint idx ); // Delete required edge & compact
void del_req_ordered( uint idx ); // Delete required edge & compact with preserved order
@@ -1350,7 +1356,7 @@ class Node_List : public Node_Array {
public:
Node_List() : Node_Array(Thread::current()->resource_area()), _cnt(0) {}
Node_List(Arena *a) : Node_Array(a), _cnt(0) {}
- bool contains(Node* n) {
+ bool contains(const Node* n) const {
for (uint e = 0; e < size(); e++) {
if (at(e) == n) return true;
}