8336297: C2: Fix -Wzero-as-null-pointer-constant warnings in derived Node ctors
Reviewed-by: kvn, jwaters
This commit is contained in:
parent
9dfcd75ec4
commit
ab27acab0b
@ -1209,7 +1209,7 @@ Node* GraphKit::load_array_length(Node* array) {
|
||||
Node *alen;
|
||||
if (alloc == nullptr) {
|
||||
Node *r_adr = basic_plus_adr(array, arrayOopDesc::length_offset_in_bytes());
|
||||
alen = _gvn.transform( new LoadRangeNode(0, immutable_memory(), r_adr, TypeInt::POS));
|
||||
alen = _gvn.transform( new LoadRangeNode(nullptr, immutable_memory(), r_adr, TypeInt::POS));
|
||||
} else {
|
||||
alen = array_ideal_length(alloc, _gvn.type(array)->is_oopptr(), false);
|
||||
}
|
||||
@ -2385,7 +2385,7 @@ Node* GraphKit::precision_rounding(Node* n) {
|
||||
if (Matcher::strict_fp_requires_explicit_rounding) {
|
||||
#ifdef IA32
|
||||
if (UseSSE == 0) {
|
||||
return _gvn.transform(new RoundFloatNode(0, n));
|
||||
return _gvn.transform(new RoundFloatNode(nullptr, n));
|
||||
}
|
||||
#else
|
||||
Unimplemented();
|
||||
@ -2399,7 +2399,7 @@ Node* GraphKit::dprecision_rounding(Node *n) {
|
||||
if (Matcher::strict_fp_requires_explicit_rounding) {
|
||||
#ifdef IA32
|
||||
if (UseSSE < 2) {
|
||||
return _gvn.transform(new RoundDoubleNode(0, n));
|
||||
return _gvn.transform(new RoundDoubleNode(nullptr, n));
|
||||
}
|
||||
#else
|
||||
Unimplemented();
|
||||
@ -3489,7 +3489,7 @@ FastLockNode* GraphKit::shared_lock(Node* obj) {
|
||||
box = _gvn.transform(box);
|
||||
Node* mem = reset_memory();
|
||||
|
||||
FastLockNode * flock = _gvn.transform(new FastLockNode(0, obj, box) )->as_FastLock();
|
||||
FastLockNode * flock = _gvn.transform(new FastLockNode(nullptr, obj, box) )->as_FastLock();
|
||||
|
||||
// Add monitor to debug info for the slow path. If we block inside the
|
||||
// slow path and de-opt, we need the monitor hanging around
|
||||
|
@ -2138,12 +2138,12 @@ bool LibraryCallKit::inline_number_methods(vmIntrinsics::ID id) {
|
||||
case vmIntrinsics::_numberOfTrailingZeros_l: n = new CountTrailingZerosLNode(arg); break;
|
||||
case vmIntrinsics::_bitCount_i: n = new PopCountINode( arg); break;
|
||||
case vmIntrinsics::_bitCount_l: n = new PopCountLNode( arg); break;
|
||||
case vmIntrinsics::_reverseBytes_c: n = new ReverseBytesUSNode(0, arg); break;
|
||||
case vmIntrinsics::_reverseBytes_s: n = new ReverseBytesSNode( 0, arg); break;
|
||||
case vmIntrinsics::_reverseBytes_i: n = new ReverseBytesINode( 0, arg); break;
|
||||
case vmIntrinsics::_reverseBytes_l: n = new ReverseBytesLNode( 0, arg); break;
|
||||
case vmIntrinsics::_reverse_i: n = new ReverseINode(0, arg); break;
|
||||
case vmIntrinsics::_reverse_l: n = new ReverseLNode(0, arg); break;
|
||||
case vmIntrinsics::_reverseBytes_c: n = new ReverseBytesUSNode(nullptr, arg); break;
|
||||
case vmIntrinsics::_reverseBytes_s: n = new ReverseBytesSNode( nullptr, arg); break;
|
||||
case vmIntrinsics::_reverseBytes_i: n = new ReverseBytesINode( nullptr, arg); break;
|
||||
case vmIntrinsics::_reverseBytes_l: n = new ReverseBytesLNode( nullptr, arg); break;
|
||||
case vmIntrinsics::_reverse_i: n = new ReverseINode(nullptr, arg); break;
|
||||
case vmIntrinsics::_reverse_l: n = new ReverseLNode(nullptr, arg); break;
|
||||
default: fatal_unexpected_iid(id); break;
|
||||
}
|
||||
set_result(_gvn.transform(n));
|
||||
|
@ -2591,7 +2591,7 @@ Node *LoopLimitNode::Ideal(PhaseGVN *phase, bool can_reshape) {
|
||||
Node* stride_m = phase->intcon(stride_con - (stride_con > 0 ? 1 : -1));
|
||||
Node *range = phase->transform(new SubINode(in(Limit), in(Init)));
|
||||
Node *bias = phase->transform(new AddINode(range, stride_m));
|
||||
Node *trip = phase->transform(new DivINode(0, bias, in(Stride)));
|
||||
Node *trip = phase->transform(new DivINode(nullptr, bias, in(Stride)));
|
||||
Node *span = phase->transform(new MulINode(trip, in(Stride)));
|
||||
return new AddINode(span, in(Init)); // exact limit
|
||||
}
|
||||
@ -2620,7 +2620,7 @@ Node *LoopLimitNode::Ideal(PhaseGVN *phase, bool can_reshape) {
|
||||
Node* neg_stride = phase->longcon(-stride_con);
|
||||
span = phase->transform(new AndLNode(bias, neg_stride));
|
||||
} else {
|
||||
Node *trip = phase->transform(new DivLNode(0, bias, stride));
|
||||
Node *trip = phase->transform(new DivLNode(nullptr, bias, stride));
|
||||
span = phase->transform(new MulLNode(trip, stride));
|
||||
}
|
||||
// Convert back to int
|
||||
|
@ -251,7 +251,7 @@ void Parse::load_interpreter_state(Node* osr_buf) {
|
||||
|
||||
// Build a bogus FastLockNode (no code will be generated) and push the
|
||||
// monitor into our debug info.
|
||||
const FastLockNode *flock = _gvn.transform(new FastLockNode( 0, lock_object, box ))->as_FastLock();
|
||||
const FastLockNode *flock = _gvn.transform(new FastLockNode( nullptr, lock_object, box ))->as_FastLock();
|
||||
map()->push_monitor(flock);
|
||||
|
||||
// If the lock is our method synchronization lock, tuck it away in
|
||||
|
@ -2233,7 +2233,7 @@ void Parse::do_one_bytecode() {
|
||||
case Bytecodes::_fdiv:
|
||||
b = pop();
|
||||
a = pop();
|
||||
c = _gvn.transform( new DivFNode(0,a,b) );
|
||||
c = _gvn.transform( new DivFNode(nullptr,a,b) );
|
||||
d = precision_rounding(c);
|
||||
push( d );
|
||||
break;
|
||||
@ -2243,7 +2243,7 @@ void Parse::do_one_bytecode() {
|
||||
// Generate a ModF node.
|
||||
b = pop();
|
||||
a = pop();
|
||||
c = _gvn.transform( new ModFNode(0,a,b) );
|
||||
c = _gvn.transform( new ModFNode(nullptr,a,b) );
|
||||
d = precision_rounding(c);
|
||||
push( d );
|
||||
}
|
||||
@ -2294,7 +2294,7 @@ void Parse::do_one_bytecode() {
|
||||
a = pop_pair();
|
||||
b = _gvn.transform( new ConvD2FNode(a));
|
||||
// This breaks _227_mtrt (speed & correctness) and _222_mpegaudio (speed)
|
||||
//b = _gvn.transform(new RoundFloatNode(0, b) );
|
||||
//b = _gvn.transform(new RoundFloatNode(nullptr, b) );
|
||||
push( b );
|
||||
break;
|
||||
|
||||
@ -2360,7 +2360,7 @@ void Parse::do_one_bytecode() {
|
||||
case Bytecodes::_ddiv:
|
||||
b = pop_pair();
|
||||
a = pop_pair();
|
||||
c = _gvn.transform( new DivDNode(0,a,b) );
|
||||
c = _gvn.transform( new DivDNode(nullptr,a,b) );
|
||||
d = dprecision_rounding(c);
|
||||
push_pair( d );
|
||||
break;
|
||||
@ -2378,7 +2378,7 @@ void Parse::do_one_bytecode() {
|
||||
a = pop_pair();
|
||||
// a % b
|
||||
|
||||
c = _gvn.transform( new ModDNode(0,a,b) );
|
||||
c = _gvn.transform( new ModDNode(nullptr,a,b) );
|
||||
d = dprecision_rounding(c);
|
||||
push_pair( d );
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user