--- old/src/share/vm/opto/callGenerator.cpp 2017-07-10 18:11:16.082614330 +0200 +++ new/src/share/vm/opto/callGenerator.cpp 2017-07-10 18:11:11.229636067 +0200 @@ -496,11 +496,12 @@ if (return_type->is_valuetype() && return_type != C->env()->___Value_klass()) { if (result->is_ValueType()) { + ValueTypeNode* vt = result->as_ValueType(); if (!call->tf()->returns_value_type_as_fields()) { - result = result->as_ValueType()->allocate(&kit); + result = vt->allocate(&kit); + result = C->initial_gvn()->transform(new ValueTypePtrNode(vt, result, C)); } else { // Return of multiple values (the fields of a value type) - ValueTypeNode* vt = result->as_ValueType(); vt->replace_call_results(call, C); } } else {