8336466: C2: Parser incorrectly/unnecessarily checks for clinits
Reviewed-by: kvn, thartmann
This commit is contained in:
parent
b703be9cf6
commit
5d965f36d3
src/hotspot/share/opto
@ -1601,10 +1601,8 @@ AllocateNode::AllocateNode(Compile* C, const TypeFunc *atype,
|
||||
|
||||
void AllocateNode::compute_MemBar_redundancy(ciMethod* initializer)
|
||||
{
|
||||
assert(initializer != nullptr &&
|
||||
initializer->is_initializer() &&
|
||||
!initializer->is_static(),
|
||||
"unexpected initializer method");
|
||||
assert(initializer != nullptr && initializer->is_object_initializer(),
|
||||
"unexpected initializer method");
|
||||
BCEscapeAnalyzer* analyzer = initializer->get_bcea();
|
||||
if (analyzer == nullptr) {
|
||||
return;
|
||||
|
@ -1013,7 +1013,7 @@ void Parse::do_exits() {
|
||||
// such unusual early publications. But no barrier is needed on
|
||||
// exceptional returns, since they cannot publish normally.
|
||||
//
|
||||
if (method()->is_initializer() &&
|
||||
if (method()->is_object_initializer() &&
|
||||
(wrote_final() ||
|
||||
(AlwaysSafeConstructors && wrote_fields()) ||
|
||||
(support_IRIW_for_not_multiple_copy_atomic_cpu && wrote_volatile()))) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user