mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 23:04:50 +02:00
8003553: NPG: metaspace objects should be zeroed in constructors
Zero metadata in constructors, not in allocation (and some in constructors) Reviewed-by: jmasa, sspitsyn
This commit is contained in:
parent
4cdcd6dc13
commit
addd95f165
13 changed files with 111 additions and 97 deletions
|
@ -77,20 +77,14 @@ Method* Method::allocate(ClassLoaderData* loader_data,
|
|||
return new (loader_data, size, false, THREAD) Method(cm, access_flags, size);
|
||||
}
|
||||
|
||||
Method::Method(ConstMethod* xconst,
|
||||
AccessFlags access_flags, int size) {
|
||||
Method::Method(ConstMethod* xconst, AccessFlags access_flags, int size) {
|
||||
No_Safepoint_Verifier no_safepoint;
|
||||
set_constMethod(xconst);
|
||||
set_access_flags(access_flags);
|
||||
set_method_size(size);
|
||||
set_name_index(0);
|
||||
set_signature_index(0);
|
||||
#ifdef CC_INTERP
|
||||
set_result_index(T_VOID);
|
||||
#endif
|
||||
set_constants(NULL);
|
||||
set_max_stack(0);
|
||||
set_max_locals(0);
|
||||
set_intrinsic_id(vmIntrinsics::_none);
|
||||
set_jfr_towrite(false);
|
||||
set_method_data(NULL);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue