8306482: Remove unused Method AccessFlags

Reviewed-by: dholmes, matsaave
This commit is contained in:
Coleen Phillimore 2023-04-20 19:13:14 +00:00
parent d6cf4aa155
commit afd2501fcc
4 changed files with 0 additions and 27 deletions

View File

@ -2089,8 +2089,6 @@
declare_constant(JVM_ACC_LOOPS_FLAG_INIT) \
declare_constant(JVM_ACC_QUEUED) \
declare_constant(JVM_ACC_NOT_C2_OSR_COMPILABLE) \
declare_constant(JVM_ACC_HAS_LINE_NUMBER_TABLE) \
declare_constant(JVM_ACC_HAS_CHECKED_EXCEPTIONS) \
declare_constant(JVM_ACC_HAS_JSRS) \
declare_constant(JVM_ACC_IS_OLD) \
declare_constant(JVM_ACC_IS_OBSOLETE) \
@ -2099,7 +2097,6 @@
declare_constant(JVM_ACC_HAS_VANILLA_CONSTRUCTOR) \
declare_constant(JVM_ACC_HAS_FINALIZER) \
declare_constant(JVM_ACC_IS_CLONEABLE_FAST) \
declare_constant(JVM_ACC_HAS_LOCAL_VARIABLE_TABLE) \
\
declare_constant(JVM_CONSTANT_Utf8) \
declare_constant(JVM_CONSTANT_Unicode) \

View File

@ -51,8 +51,6 @@ enum {
JVM_ACC_NOT_C2_COMPILABLE = 0x02000000,
JVM_ACC_NOT_C1_COMPILABLE = 0x04000000,
JVM_ACC_NOT_C2_OSR_COMPILABLE = 0x08000000,
JVM_ACC_HAS_LINE_NUMBER_TABLE = 0x00100000,
JVM_ACC_HAS_CHECKED_EXCEPTIONS = 0x00400000,
JVM_ACC_HAS_JSRS = 0x00800000,
JVM_ACC_IS_OLD = 0x00010000, // RedefineClasses() has replaced this method
JVM_ACC_IS_OBSOLETE = 0x00020000, // RedefineClasses() has made method obsolete
@ -68,9 +66,6 @@ enum {
JVM_ACC_HAS_FINAL_METHOD = 0x01000000, // True if klass has final method
JVM_ACC_IS_HIDDEN_CLASS = 0x04000000, // True if klass is hidden
JVM_ACC_IS_VALUE_BASED_CLASS = 0x08000000, // True if klass is marked as a ValueBased class
// Method* flags
JVM_ACC_HAS_LOCAL_VARIABLE_TABLE= 0x00400000,
};
@ -109,8 +104,6 @@ class AccessFlags {
bool is_not_c1_compilable () const { return (_flags & JVM_ACC_NOT_C1_COMPILABLE ) != 0; }
bool is_not_c2_compilable () const { return (_flags & JVM_ACC_NOT_C2_COMPILABLE ) != 0; }
bool is_not_c2_osr_compilable() const { return (_flags & JVM_ACC_NOT_C2_OSR_COMPILABLE ) != 0; }
bool has_linenumber_table () const { return (_flags & JVM_ACC_HAS_LINE_NUMBER_TABLE ) != 0; }
bool has_checked_exceptions () const { return (_flags & JVM_ACC_HAS_CHECKED_EXCEPTIONS ) != 0; }
bool has_jsrs () const { return (_flags & JVM_ACC_HAS_JSRS ) != 0; }
bool is_old () const { return (_flags & JVM_ACC_IS_OLD ) != 0; }
bool is_obsolete () const { return (_flags & JVM_ACC_IS_OBSOLETE ) != 0; }
@ -126,11 +119,6 @@ class AccessFlags {
bool is_hidden_class () const { return (_flags & JVM_ACC_IS_HIDDEN_CLASS ) != 0; }
bool is_value_based_class () const { return (_flags & JVM_ACC_IS_VALUE_BASED_CLASS ) != 0; }
// Method* flags
bool has_localvariable_table () const { return (_flags & JVM_ACC_HAS_LOCAL_VARIABLE_TABLE) != 0; }
void set_has_localvariable_table() { atomic_set_bits(JVM_ACC_HAS_LOCAL_VARIABLE_TABLE); }
void clear_has_localvariable_table() { atomic_clear_bits(JVM_ACC_HAS_LOCAL_VARIABLE_TABLE); }
bool on_stack() const { return (_flags & JVM_ACC_ON_STACK) != 0; }
// get .class file flags
@ -168,8 +156,6 @@ class AccessFlags {
void set_not_c1_compilable() { atomic_set_bits(JVM_ACC_NOT_C1_COMPILABLE); }
void set_not_c2_compilable() { atomic_set_bits(JVM_ACC_NOT_C2_COMPILABLE); }
void set_not_c2_osr_compilable() { atomic_set_bits(JVM_ACC_NOT_C2_OSR_COMPILABLE); }
void set_has_linenumber_table() { atomic_set_bits(JVM_ACC_HAS_LINE_NUMBER_TABLE); }
void set_has_checked_exceptions() { atomic_set_bits(JVM_ACC_HAS_CHECKED_EXCEPTIONS); }
void set_has_jsrs() { atomic_set_bits(JVM_ACC_HAS_JSRS); }
void set_is_old() { atomic_set_bits(JVM_ACC_IS_OLD); }
void set_is_obsolete() { atomic_set_bits(JVM_ACC_IS_OBSOLETE); }

View File

@ -64,8 +64,6 @@ public class AccessFlags implements /* imports */ ClassConstants {
public boolean loopsFlagInit () { return (flags & JVM_ACC_LOOPS_FLAG_INIT ) != 0; }
public boolean queuedForCompilation() { return (flags & JVM_ACC_QUEUED ) != 0; }
public boolean isNotOsrCompilable () { return (flags & JVM_ACC_NOT_OSR_COMPILABLE ) != 0; }
public boolean hasLineNumberTable () { return (flags & JVM_ACC_HAS_LINE_NUMBER_TABLE ) != 0; }
public boolean hasCheckedExceptions() { return (flags & JVM_ACC_HAS_CHECKED_EXCEPTIONS ) != 0; }
public boolean hasJsrs () { return (flags & JVM_ACC_HAS_JSRS ) != 0; }
public boolean isObsolete () { return (flags & JVM_ACC_IS_OBSOLETE ) != 0; }
@ -75,9 +73,6 @@ public class AccessFlags implements /* imports */ ClassConstants {
public boolean hasFinalizer () { return (flags & JVM_ACC_HAS_FINALIZER ) != 0; }
public boolean isCloneable () { return (flags & JVM_ACC_IS_CLONEABLE ) != 0; }
// Klass* and Method* flags
public boolean hasLocalVariableTable() { return (flags & JVM_ACC_HAS_LOCAL_VARIABLE_TABLE ) != 0; }
public void printOn(PrintStream tty) {
// prints only .class flags and not the hotspot internal flags
if (isPublic ()) tty.print("public " );

View File

@ -118,8 +118,6 @@ public interface ClassConstants
// invocation counter machinery. Until it is, we will keep track of methods which
// cannot be on stack replaced in the access flags.
public static final long JVM_ACC_NOT_OSR_COMPILABLE = 0x08000000;
public static final long JVM_ACC_HAS_LINE_NUMBER_TABLE = 0x00100000;
public static final long JVM_ACC_HAS_CHECKED_EXCEPTIONS = 0x00400000;
public static final long JVM_ACC_HAS_JSRS = 0x00800000;
// RedefineClasses() has made method obsolete
public static final long JVM_ACC_IS_OBSOLETE = 0x00010000;
@ -134,9 +132,6 @@ public interface ClassConstants
// True if klass supports the Clonable interface
public static final long JVM_ACC_IS_CLONEABLE = 0x80000000;
// Method* flags
public static final long JVM_ACC_HAS_LOCAL_VARIABLE_TABLE = 0x00200000;
// flags accepted by set_field_flags
public static final long JVM_ACC_FIELD_FLAGS = 0x00008000 | JVM_ACC_WRITTEN_FLAGS;