< prev index next >

src/hotspot/share/opto/graphKit.hpp

Print this page




 325   Node* MaxI(Node* l, Node* r)                { return _gvn.transform(new MaxINode(l, r));       }
 326   Node* MinI(Node* l, Node* r)                { return _gvn.transform(new MinINode(l, r));       }
 327 
 328   Node* LShiftI(Node* l, Node* r)             { return _gvn.transform(new LShiftINode(l, r));    }
 329   Node* RShiftI(Node* l, Node* r)             { return _gvn.transform(new RShiftINode(l, r));    }
 330   Node* URShiftI(Node* l, Node* r)            { return _gvn.transform(new URShiftINode(l, r));   }
 331 
 332   Node* CmpI(Node* l, Node* r)                { return _gvn.transform(new CmpINode(l, r));       }
 333   Node* CmpL(Node* l, Node* r)                { return _gvn.transform(new CmpLNode(l, r));       }
 334   Node* CmpP(Node* l, Node* r)                { return _gvn.transform(new CmpPNode(l, r));       }
 335   Node* Bool(Node* cmp, BoolTest::mask relop) { return _gvn.transform(new BoolNode(cmp, relop)); }
 336 
 337   Node* AddP(Node* b, Node* a, Node* o)       { return _gvn.transform(new AddPNode(b, a, o));    }
 338 
 339   // Convert between int and long, and size_t.
 340   // (See macros ConvI2X, etc., in type.hpp for ConvI2X, etc.)
 341   Node* ConvI2L(Node* offset);
 342   Node* ConvI2UL(Node* offset);
 343   Node* ConvL2I(Node* offset);
 344   // Find out the klass of an object.
 345   Node* load_object_klass(Node* object);
 346   // Find out the length of an array.
 347   Node* load_array_length(Node* array);
 348 
 349 
 350   // Helper function to do a NULL pointer check or ZERO check based on type.
 351   // Throw an exception if a given value is null.
 352   // Return the value cast to not-null.
 353   // Be clever about equivalent dominating null checks.
 354   Node* null_check_common(Node* value, BasicType type,
 355                           bool assert_null = false,
 356                           Node* *null_control = NULL,
 357                           bool speculative = false);
 358   Node* null_check(Node* value, BasicType type = T_OBJECT) {
 359     return null_check_common(value, type, false, NULL, !_gvn.type(value)->speculative_maybe_null());
 360   }
 361   Node* null_check_receiver() {
 362     assert(argument(0)->bottom_type()->isa_ptr(), "must be");
 363     return null_check(argument(0));
 364   }
 365   Node* zero_check_int(Node* value) {


 841   int next_monitor();
 842   Node* insert_mem_bar(int opcode, Node* precedent = NULL);
 843   Node* insert_mem_bar_volatile(int opcode, int alias_idx, Node* precedent = NULL);
 844   // Optional 'precedent' is appended as an extra edge, to force ordering.
 845   FastLockNode* shared_lock(Node* obj);
 846   void shared_unlock(Node* box, Node* obj);
 847 
 848   // helper functions for the fast path/slow path idioms
 849   Node* fast_and_slow(Node* in, const Type *result_type, Node* null_result, IfNode* fast_test, Node* fast_result, address slow_call, const TypeFunc *slow_call_type, Node* slow_arg, Klass* ex_klass, Node* slow_result);
 850 
 851   // Generate an instance-of idiom.  Used by both the instance-of bytecode
 852   // and the reflective instance-of call.
 853   Node* gen_instanceof(Node *subobj, Node* superkls, bool safe_for_replace = false);
 854 
 855   // Generate a check-cast idiom.  Used by both the check-cast bytecode
 856   // and the array-store bytecode
 857   Node* gen_checkcast(Node *subobj, Node* superkls, Node* *failure_control = NULL, bool never_null = false);
 858 
 859   Node* is_always_locked(Node* obj);
 860   Node* is_value_mirror(Node* mirror);
 861   void gen_value_type_guard(Node* obj, int nargs = 0);
 862   Node* gen_null_free_array_check(Node* ary);
 863   Node* gen_flattened_array_test(Node* ary);
 864   Node* gen_value_array_null_guard(Node* ary, Node* val, int nargs, bool safe_for_replace = false);
 865   Node* load_lh_array_tag(Node* kls);
 866   Node* gen_lh_array_test(Node* kls, unsigned int lh_value);
 867 
 868   Node* gen_subtype_check(Node* subklass, Node* superklass) {
 869     MergeMemNode* mem = merged_memory();
 870     Node* ctrl = control();
 871     Node* n = Phase::gen_subtype_check(subklass, superklass, &ctrl, mem, &_gvn);
 872     set_control(ctrl);
 873     return n;
 874   }
 875 
 876   // Exact type check used for predicted calls and casts.
 877   // Rewrites (*casted_receiver) to be casted to the stronger type.
 878   // (Caller is responsible for doing replace_in_map.)
 879   Node* type_check_receiver(Node* receiver, ciKlass* klass, float prob,
 880                             Node* *casted_receiver);
 881   Node* type_check(Node* recv_klass, const TypeKlassPtr* tklass, float prob);




 325   Node* MaxI(Node* l, Node* r)                { return _gvn.transform(new MaxINode(l, r));       }
 326   Node* MinI(Node* l, Node* r)                { return _gvn.transform(new MinINode(l, r));       }
 327 
 328   Node* LShiftI(Node* l, Node* r)             { return _gvn.transform(new LShiftINode(l, r));    }
 329   Node* RShiftI(Node* l, Node* r)             { return _gvn.transform(new RShiftINode(l, r));    }
 330   Node* URShiftI(Node* l, Node* r)            { return _gvn.transform(new URShiftINode(l, r));   }
 331 
 332   Node* CmpI(Node* l, Node* r)                { return _gvn.transform(new CmpINode(l, r));       }
 333   Node* CmpL(Node* l, Node* r)                { return _gvn.transform(new CmpLNode(l, r));       }
 334   Node* CmpP(Node* l, Node* r)                { return _gvn.transform(new CmpPNode(l, r));       }
 335   Node* Bool(Node* cmp, BoolTest::mask relop) { return _gvn.transform(new BoolNode(cmp, relop)); }
 336 
 337   Node* AddP(Node* b, Node* a, Node* o)       { return _gvn.transform(new AddPNode(b, a, o));    }
 338 
 339   // Convert between int and long, and size_t.
 340   // (See macros ConvI2X, etc., in type.hpp for ConvI2X, etc.)
 341   Node* ConvI2L(Node* offset);
 342   Node* ConvI2UL(Node* offset);
 343   Node* ConvL2I(Node* offset);
 344   // Find out the klass of an object.
 345   Node* load_object_klass(Node* object, bool clear_prop_bits = true);
 346   // Find out the length of an array.
 347   Node* load_array_length(Node* array);
 348 
 349 
 350   // Helper function to do a NULL pointer check or ZERO check based on type.
 351   // Throw an exception if a given value is null.
 352   // Return the value cast to not-null.
 353   // Be clever about equivalent dominating null checks.
 354   Node* null_check_common(Node* value, BasicType type,
 355                           bool assert_null = false,
 356                           Node* *null_control = NULL,
 357                           bool speculative = false);
 358   Node* null_check(Node* value, BasicType type = T_OBJECT) {
 359     return null_check_common(value, type, false, NULL, !_gvn.type(value)->speculative_maybe_null());
 360   }
 361   Node* null_check_receiver() {
 362     assert(argument(0)->bottom_type()->isa_ptr(), "must be");
 363     return null_check(argument(0));
 364   }
 365   Node* zero_check_int(Node* value) {


 841   int next_monitor();
 842   Node* insert_mem_bar(int opcode, Node* precedent = NULL);
 843   Node* insert_mem_bar_volatile(int opcode, int alias_idx, Node* precedent = NULL);
 844   // Optional 'precedent' is appended as an extra edge, to force ordering.
 845   FastLockNode* shared_lock(Node* obj);
 846   void shared_unlock(Node* box, Node* obj);
 847 
 848   // helper functions for the fast path/slow path idioms
 849   Node* fast_and_slow(Node* in, const Type *result_type, Node* null_result, IfNode* fast_test, Node* fast_result, address slow_call, const TypeFunc *slow_call_type, Node* slow_arg, Klass* ex_klass, Node* slow_result);
 850 
 851   // Generate an instance-of idiom.  Used by both the instance-of bytecode
 852   // and the reflective instance-of call.
 853   Node* gen_instanceof(Node *subobj, Node* superkls, bool safe_for_replace = false);
 854 
 855   // Generate a check-cast idiom.  Used by both the check-cast bytecode
 856   // and the array-store bytecode
 857   Node* gen_checkcast(Node *subobj, Node* superkls, Node* *failure_control = NULL, bool never_null = false);
 858 
 859   Node* is_always_locked(Node* obj);
 860   Node* is_value_mirror(Node* mirror);

 861   Node* gen_null_free_array_check(Node* ary);
 862   Node* gen_flattened_array_test(Node* ary);
 863   Node* gen_value_array_null_guard(Node* ary, Node* val, int nargs, bool safe_for_replace = false);
 864   Node* load_lh_array_tag(Node* kls);
 865   Node* gen_lh_array_test(Node* kls, unsigned int lh_value);
 866 
 867   Node* gen_subtype_check(Node* subklass, Node* superklass) {
 868     MergeMemNode* mem = merged_memory();
 869     Node* ctrl = control();
 870     Node* n = Phase::gen_subtype_check(subklass, superklass, &ctrl, mem, &_gvn);
 871     set_control(ctrl);
 872     return n;
 873   }
 874 
 875   // Exact type check used for predicted calls and casts.
 876   // Rewrites (*casted_receiver) to be casted to the stronger type.
 877   // (Caller is responsible for doing replace_in_map.)
 878   Node* type_check_receiver(Node* receiver, ciKlass* klass, float prob,
 879                             Node* *casted_receiver);
 880   Node* type_check(Node* recv_klass, const TypeKlassPtr* tklass, float prob);


< prev index next >