mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 15:24:43 +02:00
8046936: JEP 270: Reserved Stack Areas for Critical Sections
Reviewed-by: acorn, dcubed
This commit is contained in:
parent
f6440f7fb1
commit
ef800bd53f
69 changed files with 987 additions and 64 deletions
|
@ -946,6 +946,7 @@ public:
|
|||
_method_HotSpotIntrinsicCandidate,
|
||||
_jdk_internal_vm_annotation_Contended,
|
||||
_field_Stable,
|
||||
_jdk_internal_vm_annotation_ReservedStackAccess,
|
||||
_annotation_LIMIT
|
||||
};
|
||||
const Location _location;
|
||||
|
@ -2016,6 +2017,11 @@ AnnotationCollector::annotation_index(const ClassLoaderData* loader_data,
|
|||
}
|
||||
return _jdk_internal_vm_annotation_Contended;
|
||||
}
|
||||
case vmSymbols::VM_SYMBOL_ENUM_NAME(jdk_internal_vm_annotation_ReservedStackAccess_signature): {
|
||||
if (_location != _in_method) break; // only allow for methods
|
||||
if (RestrictReservedStack && !privileged) break; // honor privileges
|
||||
return _jdk_internal_vm_annotation_ReservedStackAccess;
|
||||
}
|
||||
default: {
|
||||
break;
|
||||
}
|
||||
|
@ -2051,6 +2057,8 @@ void MethodAnnotationCollector::apply_to(methodHandle m) {
|
|||
m->set_hidden(true);
|
||||
if (has_annotation(_method_HotSpotIntrinsicCandidate) && !m->is_synthetic())
|
||||
m->set_intrinsic_candidate(true);
|
||||
if (has_annotation(_jdk_internal_vm_annotation_ReservedStackAccess))
|
||||
m->set_has_reserved_stack_access(true);
|
||||
}
|
||||
|
||||
void ClassFileParser::ClassAnnotationCollector::apply_to(InstanceKlass* ik) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue