Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions src/hotspot/share/classfile/vmIntrinsics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -336,8 +336,6 @@ bool vmIntrinsics::disabled_by_jvm_flags(vmIntrinsics::ID id) {
case vmIntrinsics::_updateByteBufferCRC32:
if (!UseCRC32Intrinsics) return true;
break;
case vmIntrinsics::_makePrivateBuffer:
case vmIntrinsics::_finishPrivateBuffer:
case vmIntrinsics::_getReference:
case vmIntrinsics::_getBoolean:
case vmIntrinsics::_getByte:
Expand All @@ -347,7 +345,6 @@ bool vmIntrinsics::disabled_by_jvm_flags(vmIntrinsics::ID id) {
case vmIntrinsics::_getLong:
case vmIntrinsics::_getFloat:
case vmIntrinsics::_getDouble:
case vmIntrinsics::_getValue:
case vmIntrinsics::_getFlatValue:
case vmIntrinsics::_putReference:
case vmIntrinsics::_putBoolean:
Expand All @@ -358,7 +355,6 @@ bool vmIntrinsics::disabled_by_jvm_flags(vmIntrinsics::ID id) {
case vmIntrinsics::_putLong:
case vmIntrinsics::_putFloat:
case vmIntrinsics::_putDouble:
case vmIntrinsics::_putValue:
case vmIntrinsics::_putFlatValue:
case vmIntrinsics::_getReferenceVolatile:
case vmIntrinsics::_getBooleanVolatile:
Expand Down
10 changes: 0 additions & 10 deletions src/hotspot/share/classfile/vmIntrinsics.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -736,8 +736,6 @@ class methodHandle;
do_signature(putFloat_signature, "(Ljava/lang/Object;JF)V") \
do_signature(getDouble_signature, "(Ljava/lang/Object;J)D") \
do_signature(putDouble_signature, "(Ljava/lang/Object;JD)V") \
do_signature(getValue_signature, "(Ljava/lang/Object;JLjava/lang/Class;)Ljava/lang/Object;") \
do_signature(putValue_signature, "(Ljava/lang/Object;JLjava/lang/Class;Ljava/lang/Object;)V") \
do_signature(getFlatValue_signature, "(Ljava/lang/Object;JILjava/lang/Class;)Ljava/lang/Object;") \
do_signature(putFlatValue_signature, "(Ljava/lang/Object;JILjava/lang/Class;Ljava/lang/Object;)V") \
\
Expand All @@ -750,10 +748,7 @@ class methodHandle;
do_name(getLong_name,"getLong") do_name(putLong_name,"putLong") \
do_name(getFloat_name,"getFloat") do_name(putFloat_name,"putFloat") \
do_name(getDouble_name,"getDouble") do_name(putDouble_name,"putDouble") \
do_name(getValue_name,"getValue") do_name(putValue_name,"putValue") \
do_name(getFlatValue_name,"getFlatValue") do_name(putFlatValue_name,"putFlatValue") \
do_name(makePrivateBuffer_name,"makePrivateBuffer") \
do_name(finishPrivateBuffer_name,"finishPrivateBuffer") \
\
do_intrinsic(_getReference, jdk_internal_misc_Unsafe, getReference_name, getReference_signature, F_RN) \
do_intrinsic(_getBoolean, jdk_internal_misc_Unsafe, getBoolean_name, getBoolean_signature, F_RN) \
Expand All @@ -764,7 +759,6 @@ class methodHandle;
do_intrinsic(_getLong, jdk_internal_misc_Unsafe, getLong_name, getLong_signature, F_RN) \
do_intrinsic(_getFloat, jdk_internal_misc_Unsafe, getFloat_name, getFloat_signature, F_RN) \
do_intrinsic(_getDouble, jdk_internal_misc_Unsafe, getDouble_name, getDouble_signature, F_RN) \
do_intrinsic(_getValue, jdk_internal_misc_Unsafe, getValue_name, getValue_signature, F_RN) \
do_intrinsic(_getFlatValue, jdk_internal_misc_Unsafe, getFlatValue_name, getFlatValue_signature, F_RN) \
do_intrinsic(_putReference, jdk_internal_misc_Unsafe, putReference_name, putReference_signature, F_RN) \
do_intrinsic(_putBoolean, jdk_internal_misc_Unsafe, putBoolean_name, putBoolean_signature, F_RN) \
Expand All @@ -775,12 +769,8 @@ class methodHandle;
do_intrinsic(_putLong, jdk_internal_misc_Unsafe, putLong_name, putLong_signature, F_RN) \
do_intrinsic(_putFloat, jdk_internal_misc_Unsafe, putFloat_name, putFloat_signature, F_RN) \
do_intrinsic(_putDouble, jdk_internal_misc_Unsafe, putDouble_name, putDouble_signature, F_RN) \
do_intrinsic(_putValue, jdk_internal_misc_Unsafe, putValue_name, putValue_signature, F_RN) \
do_intrinsic(_putFlatValue, jdk_internal_misc_Unsafe, putFlatValue_name, putFlatValue_signature, F_RN) \
\
do_intrinsic(_makePrivateBuffer, jdk_internal_misc_Unsafe, makePrivateBuffer_name, object_object_signature, F_RN) \
do_intrinsic(_finishPrivateBuffer, jdk_internal_misc_Unsafe, finishPrivateBuffer_name, object_object_signature, F_RN) \
\
do_name(getReferenceVolatile_name,"getReferenceVolatile") do_name(putReferenceVolatile_name,"putReferenceVolatile") \
do_name(getBooleanVolatile_name,"getBooleanVolatile") do_name(putBooleanVolatile_name,"putBooleanVolatile") \
do_name(getByteVolatile_name,"getByteVolatile") do_name(putByteVolatile_name,"putByteVolatile") \
Expand Down
4 changes: 0 additions & 4 deletions src/hotspot/share/opto/c2compiler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -653,8 +653,6 @@ bool C2Compiler::is_intrinsic_supported(vmIntrinsics::ID id) {
case vmIntrinsics::_getCharsStringU:
case vmIntrinsics::_getCharStringU:
case vmIntrinsics::_putCharStringU:
case vmIntrinsics::_makePrivateBuffer:
case vmIntrinsics::_finishPrivateBuffer:
case vmIntrinsics::_getReference:
case vmIntrinsics::_getBoolean:
case vmIntrinsics::_getByte:
Expand All @@ -664,7 +662,6 @@ bool C2Compiler::is_intrinsic_supported(vmIntrinsics::ID id) {
case vmIntrinsics::_getLong:
case vmIntrinsics::_getFloat:
case vmIntrinsics::_getDouble:
case vmIntrinsics::_getValue:
case vmIntrinsics::_getFlatValue:
case vmIntrinsics::_putReference:
case vmIntrinsics::_putBoolean:
Expand All @@ -675,7 +672,6 @@ bool C2Compiler::is_intrinsic_supported(vmIntrinsics::ID id) {
case vmIntrinsics::_putLong:
case vmIntrinsics::_putFloat:
case vmIntrinsics::_putDouble:
case vmIntrinsics::_putValue:
case vmIntrinsics::_putFlatValue:
case vmIntrinsics::_getReferenceVolatile:
case vmIntrinsics::_getBooleanVolatile:
Expand Down
20 changes: 2 additions & 18 deletions src/hotspot/share/opto/doCall.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ static bool arg_can_be_larval(ciMethod* callee, int arg_idx) {
}

switch (callee->intrinsic_id()) {
case vmIntrinsicID::_finishPrivateBuffer:
case vmIntrinsicID::_putBoolean:
case vmIntrinsicID::_putBooleanOpaque:
case vmIntrinsicID::_putBooleanRelease:
Expand Down Expand Up @@ -140,7 +139,6 @@ static bool arg_can_be_larval(ciMethod* callee, int arg_idx) {
case vmIntrinsicID::_putReferenceOpaque:
case vmIntrinsicID::_putReferenceRelease:
case vmIntrinsicID::_putReferenceVolatile:
case vmIntrinsicID::_putValue:
return true;
default:
return false;
Expand Down Expand Up @@ -206,21 +204,7 @@ CallGenerator* Compile::call_generator(ciMethod* callee, int vtable_index, bool
// methods. If these methods are replaced with specialized code,
// then we return it as the inlined version of the call.
CallGenerator* cg_intrinsic = nullptr;
if (callee->intrinsic_id() == vmIntrinsics::_makePrivateBuffer || callee->intrinsic_id() == vmIntrinsics::_finishPrivateBuffer) {
// These methods must be inlined so that we don't have larval value objects crossing method
// boundaries
assert(!call_does_dispatch, "callee should not be virtual %s", callee->name()->as_utf8());
CallGenerator* cg = find_intrinsic(callee, call_does_dispatch);

if (cg == nullptr) {
// This is probably because the intrinsics is disabled from the command line
char reason[256];
jio_snprintf(reason, sizeof(reason), "cannot find an intrinsics for %s", callee->name()->as_utf8());
C->record_method_not_compilable(reason);
return nullptr;
}
return cg;
} else if (allow_inline && allow_intrinsics) {
if (allow_inline && allow_intrinsics) {
CallGenerator* cg = find_intrinsic(callee, call_does_dispatch);
if (cg != nullptr) {
if (cg->is_predicated()) {
Expand Down Expand Up @@ -876,7 +860,7 @@ void Parse::do_call() {
record_profiled_return_for_speculation();
}

if (!rtype->is_void() && cg->method()->intrinsic_id() != vmIntrinsicID::_makePrivateBuffer) {
if (!rtype->is_void()) {
Node* retnode = peek();
const Type* rettype = gvn().type(retnode);
if (rettype->is_inlinetypeptr() && !retnode->is_InlineType()) {
Expand Down
9 changes: 1 addition & 8 deletions src/hotspot/share/opto/graphKit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3528,14 +3528,7 @@ Node* GraphKit::gen_checkcast(Node* obj, Node* superklass, Node* *failure_contro
const TypeKlassPtr* klass_ptr_type = _gvn.type(superklass)->is_klassptr();
const Type* obj_type = _gvn.type(obj);
if (obj_type->is_inlinetypeptr() && !obj_type->maybe_null() && klass_ptr_type->klass_is_exact() && obj_type->inline_klass() == klass_ptr_type->exact_klass(true)) {
// Special case: larval inline objects must not be scalarized. They are also generally not
// allowed to participate in most operations except as the first operand of putfield, or as an
// argument to a constructor invocation with it being a receiver, Unsafe::putXXX with it being
// the first argument, or Unsafe::finishPrivateBuffer. This allows us to aggressively scalarize
// value objects in all other places. This special case comes from the limitation of the Java
// language, Unsafe::makePrivateBuffer returns an Object that is checkcast-ed to the concrete
// value type. We must do this first because C->static_subtype_check may do nothing when
// StressReflectiveCode is set.
// TODO remnant to support old makePrivateBuffer generic cast, we can probably remove this now
return obj;
}

Expand Down
Loading