8330159: [C2] Remove or clarify Compile::init_start
Reviewed-by: chagedorn, dlong
This commit is contained in:
parent
9e0ccb8bbd
commit
7db4d46c39
@ -754,14 +754,14 @@ Compile::Compile( ciEnv* ci_env, ciMethod* target, int osr_bci,
|
|||||||
init_tf(TypeFunc::make(domain, range));
|
init_tf(TypeFunc::make(domain, range));
|
||||||
StartNode* s = new StartOSRNode(root(), domain);
|
StartNode* s = new StartOSRNode(root(), domain);
|
||||||
initial_gvn()->set_type_bottom(s);
|
initial_gvn()->set_type_bottom(s);
|
||||||
init_start(s);
|
verify_start(s);
|
||||||
cg = CallGenerator::for_osr(method(), entry_bci());
|
cg = CallGenerator::for_osr(method(), entry_bci());
|
||||||
} else {
|
} else {
|
||||||
// Normal case.
|
// Normal case.
|
||||||
init_tf(TypeFunc::make(method()));
|
init_tf(TypeFunc::make(method()));
|
||||||
StartNode* s = new StartNode(root(), tf()->domain());
|
StartNode* s = new StartNode(root(), tf()->domain());
|
||||||
initial_gvn()->set_type_bottom(s);
|
initial_gvn()->set_type_bottom(s);
|
||||||
init_start(s);
|
verify_start(s);
|
||||||
if (method()->intrinsic_id() == vmIntrinsics::_Reference_get) {
|
if (method()->intrinsic_id() == vmIntrinsics::_Reference_get) {
|
||||||
// With java.lang.ref.reference.get() we must go through the
|
// With java.lang.ref.reference.get() we must go through the
|
||||||
// intrinsic - even when get() is the root
|
// intrinsic - even when get() is the root
|
||||||
@ -1105,13 +1105,12 @@ void Compile::Init(bool aliasing) {
|
|||||||
probe_alias_cache(nullptr)->_index = AliasIdxTop;
|
probe_alias_cache(nullptr)->_index = AliasIdxTop;
|
||||||
}
|
}
|
||||||
|
|
||||||
//---------------------------init_start----------------------------------------
|
#ifdef ASSERT
|
||||||
// Install the StartNode on this compile object.
|
// Verify that the current StartNode is valid.
|
||||||
void Compile::init_start(StartNode* s) {
|
void Compile::verify_start(StartNode* s) const {
|
||||||
if (failing())
|
assert(failing() || s == start(), "should be StartNode");
|
||||||
return; // already failing
|
|
||||||
assert(s == start(), "");
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return the 'StartNode'. We must not have a pending failure, since the ideal graph
|
* Return the 'StartNode'. We must not have a pending failure, since the ideal graph
|
||||||
|
@ -864,7 +864,7 @@ private:
|
|||||||
RootNode* root() const { return _root; }
|
RootNode* root() const { return _root; }
|
||||||
void set_root(RootNode* r) { _root = r; }
|
void set_root(RootNode* r) { _root = r; }
|
||||||
StartNode* start() const; // (Derived from root.)
|
StartNode* start() const; // (Derived from root.)
|
||||||
void init_start(StartNode* s);
|
void verify_start(StartNode* s) const NOT_DEBUG_RETURN;
|
||||||
Node* immutable_memory();
|
Node* immutable_memory();
|
||||||
|
|
||||||
Node* recent_alloc_ctl() const { return _recent_alloc_ctl; }
|
Node* recent_alloc_ctl() const { return _recent_alloc_ctl; }
|
||||||
|
@ -261,7 +261,7 @@ void GraphKit::gen_stub(address C_function,
|
|||||||
frameptr(),
|
frameptr(),
|
||||||
returnadr());
|
returnadr());
|
||||||
root()->add_req(_gvn.transform(to_exc)); // bind to root to keep live
|
root()->add_req(_gvn.transform(to_exc)); // bind to root to keep live
|
||||||
C->init_start(start);
|
C->verify_start(start);
|
||||||
|
|
||||||
//-----------------------------
|
//-----------------------------
|
||||||
// If this is a normal subroutine return, issue the return and be done.
|
// If this is a normal subroutine return, issue the return and be done.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user