Ejemplo n.º 1
0
#define SHARK_PRODUCT_FLAG_STRUCT(type, name, value, doc) { #type, XSTR(name), &name, NOT_PRODUCT_ARG(doc) "{Shark product}", DEFAULT },
#define SHARK_PD_PRODUCT_FLAG_STRUCT(type, name, doc)     { #type, XSTR(name), &name, NOT_PRODUCT_ARG(doc) "{Shark pd product}", DEFAULT },
#define SHARK_DIAGNOSTIC_FLAG_STRUCT(type, name, value, doc) { #type, XSTR(name), &name, NOT_PRODUCT_ARG(doc) "{Shark diagnostic}", DEFAULT },
#ifdef PRODUCT
  #define SHARK_DEVELOP_FLAG_STRUCT(type, name, value, doc) /* flag is constant */
  #define SHARK_PD_DEVELOP_FLAG_STRUCT(type, name, doc)     /* flag is constant */
  #define SHARK_NOTPRODUCT_FLAG_STRUCT(type, name, value, doc)
#else
  #define SHARK_DEVELOP_FLAG_STRUCT(type, name, value, doc) { #type, XSTR(name), &name, doc, "{Shark}", DEFAULT },
  #define SHARK_PD_DEVELOP_FLAG_STRUCT(type, name, doc)     { #type, XSTR(name), &name, doc, "{Shark pd}", DEFAULT },
  #define SHARK_NOTPRODUCT_FLAG_STRUCT(type, name, value, doc) { #type, XSTR(name), &name, doc, "{Shark notproduct}", DEFAULT },
#endif

static Flag flagTable[] = {
 RUNTIME_FLAGS(RUNTIME_DEVELOP_FLAG_STRUCT, RUNTIME_PD_DEVELOP_FLAG_STRUCT, RUNTIME_PRODUCT_FLAG_STRUCT, RUNTIME_PD_PRODUCT_FLAG_STRUCT, RUNTIME_DIAGNOSTIC_FLAG_STRUCT, RUNTIME_EXPERIMENTAL_FLAG_STRUCT, RUNTIME_NOTPRODUCT_FLAG_STRUCT, RUNTIME_MANAGEABLE_FLAG_STRUCT, RUNTIME_PRODUCT_RW_FLAG_STRUCT, RUNTIME_LP64_PRODUCT_FLAG_STRUCT)
 RUNTIME_OS_FLAGS(RUNTIME_DEVELOP_FLAG_STRUCT, RUNTIME_PD_DEVELOP_FLAG_STRUCT, RUNTIME_PRODUCT_FLAG_STRUCT, RUNTIME_PD_PRODUCT_FLAG_STRUCT, RUNTIME_DIAGNOSTIC_FLAG_STRUCT, RUNTIME_NOTPRODUCT_FLAG_STRUCT)
#if INCLUDE_ALL_GCS
 G1_FLAGS(RUNTIME_DEVELOP_FLAG_STRUCT, RUNTIME_PD_DEVELOP_FLAG_STRUCT, RUNTIME_PRODUCT_FLAG_STRUCT, RUNTIME_PD_PRODUCT_FLAG_STRUCT, RUNTIME_DIAGNOSTIC_FLAG_STRUCT, RUNTIME_EXPERIMENTAL_FLAG_STRUCT, RUNTIME_NOTPRODUCT_FLAG_STRUCT, RUNTIME_MANAGEABLE_FLAG_STRUCT, RUNTIME_PRODUCT_RW_FLAG_STRUCT)
#endif // INCLUDE_ALL_GCS
#ifdef COMPILER1
 C1_FLAGS(C1_DEVELOP_FLAG_STRUCT, C1_PD_DEVELOP_FLAG_STRUCT, C1_PRODUCT_FLAG_STRUCT, C1_PD_PRODUCT_FLAG_STRUCT, C1_NOTPRODUCT_FLAG_STRUCT)
#endif
#ifdef GRAAL
 GRAAL_FLAGS(GRAAL_DEVELOP_FLAG_STRUCT, GRAAL_PD_DEVELOP_FLAG_STRUCT, GRAAL_PRODUCT_FLAG_STRUCT, GRAAL_PD_PRODUCT_FLAG_STRUCT, GRAAL_NOTPRODUCT_FLAG_STRUCT)
#endif
#ifdef COMPILER2
 C2_FLAGS(C2_DEVELOP_FLAG_STRUCT, C2_PD_DEVELOP_FLAG_STRUCT, C2_PRODUCT_FLAG_STRUCT, C2_PD_PRODUCT_FLAG_STRUCT, C2_DIAGNOSTIC_FLAG_STRUCT, C2_EXPERIMENTAL_FLAG_STRUCT, C2_NOTPRODUCT_FLAG_STRUCT)
#endif
#ifdef SHARK
 SHARK_FLAGS(SHARK_DEVELOP_FLAG_STRUCT, SHARK_PD_DEVELOP_FLAG_STRUCT, SHARK_PRODUCT_FLAG_STRUCT, SHARK_PD_PRODUCT_FLAG_STRUCT, SHARK_DIAGNOSTIC_FLAG_STRUCT, SHARK_NOTPRODUCT_FLAG_STRUCT)
Ejemplo n.º 2
0
// Check the ranges of all flags that have them
void CommandLineFlagRangeList::init(void) {

    _ranges = new (ResourceObj::C_HEAP, mtInternal) GrowableArray<CommandLineFlagRange*>(INITIAL_RANGES_SIZE, true);

    emit_range_no(NULL RUNTIME_FLAGS(EMIT_RANGE_DEVELOPER_FLAG,
                                     EMIT_RANGE_PD_DEVELOPER_FLAG,
                                     EMIT_RANGE_PRODUCT_FLAG,
                                     EMIT_RANGE_PD_PRODUCT_FLAG,
                                     EMIT_RANGE_DIAGNOSTIC_FLAG,
                                     EMIT_RANGE_EXPERIMENTAL_FLAG,
                                     EMIT_RANGE_NOTPRODUCT_FLAG,
                                     EMIT_RANGE_MANAGEABLE_FLAG,
                                     EMIT_RANGE_PRODUCT_RW_FLAG,
                                     EMIT_RANGE_LP64_PRODUCT_FLAG,
                                     EMIT_RANGE_CHECK,
                                     IGNORE_CONSTRAINT) );

    EMIT_RANGES_FOR_GLOBALS_EXT

    emit_range_no(NULL ARCH_FLAGS(EMIT_RANGE_DEVELOPER_FLAG,
                                  EMIT_RANGE_PRODUCT_FLAG,
                                  EMIT_RANGE_DIAGNOSTIC_FLAG,
                                  EMIT_RANGE_EXPERIMENTAL_FLAG,
                                  EMIT_RANGE_NOTPRODUCT_FLAG,
                                  EMIT_RANGE_CHECK,
                                  IGNORE_CONSTRAINT));

#if INCLUDE_JVMCI
    emit_range_no(NULL JVMCI_FLAGS(EMIT_RANGE_DEVELOPER_FLAG,
                                   EMIT_RANGE_PD_DEVELOPER_FLAG,
                                   EMIT_RANGE_PRODUCT_FLAG,
                                   EMIT_RANGE_PD_PRODUCT_FLAG,
                                   EMIT_RANGE_DIAGNOSTIC_FLAG,
                                   EMIT_RANGE_EXPERIMENTAL_FLAG,
                                   EMIT_RANGE_NOTPRODUCT_FLAG,
                                   EMIT_RANGE_CHECK,
                                   IGNORE_CONSTRAINT));
#endif // INCLUDE_JVMCI

#ifdef COMPILER1
    emit_range_no(NULL C1_FLAGS(EMIT_RANGE_DEVELOPER_FLAG,
                                EMIT_RANGE_PD_DEVELOPER_FLAG,
                                EMIT_RANGE_PRODUCT_FLAG,
                                EMIT_RANGE_PD_PRODUCT_FLAG,
                                EMIT_RANGE_DIAGNOSTIC_FLAG,
                                EMIT_RANGE_NOTPRODUCT_FLAG,
                                EMIT_RANGE_CHECK,
                                IGNORE_CONSTRAINT));
#endif // COMPILER1

#ifdef COMPILER2
    emit_range_no(NULL C2_FLAGS(EMIT_RANGE_DEVELOPER_FLAG,
                                EMIT_RANGE_PD_DEVELOPER_FLAG,
                                EMIT_RANGE_PRODUCT_FLAG,
                                EMIT_RANGE_PD_PRODUCT_FLAG,
                                EMIT_RANGE_DIAGNOSTIC_FLAG,
                                EMIT_RANGE_EXPERIMENTAL_FLAG,
                                EMIT_RANGE_NOTPRODUCT_FLAG,
                                EMIT_RANGE_CHECK,
                                IGNORE_CONSTRAINT));
#endif // COMPILER2

#if INCLUDE_ALL_GCS
    emit_range_no(NULL G1_FLAGS(EMIT_RANGE_DEVELOPER_FLAG,
                                EMIT_RANGE_PD_DEVELOPER_FLAG,
                                EMIT_RANGE_PRODUCT_FLAG,
                                EMIT_RANGE_PD_PRODUCT_FLAG,
                                EMIT_RANGE_DIAGNOSTIC_FLAG,
                                EMIT_RANGE_EXPERIMENTAL_FLAG,
                                EMIT_RANGE_NOTPRODUCT_FLAG,
                                EMIT_RANGE_MANAGEABLE_FLAG,
                                EMIT_RANGE_PRODUCT_RW_FLAG,
                                EMIT_RANGE_CHECK,
                                IGNORE_CONSTRAINT));
#endif // INCLUDE_ALL_GCS
}
Ejemplo n.º 3
0
    { #type, XSTR(name), &name JVM_FLAG_KIND("(always)") },

#else

#define RUNTIME_PRODUCT_FLAG_STRUCT(type, name, value, doc) \
    { #type, XSTR(name), &name },

#define RUNTIME_DEVELOP_FLAG_STRUCT(type, name, value, doc) // do nothing

#define RUNTIME_ALWAYS_FLAG_STRUCT(type, name, value, doc) // do nothing

#endif

PRODUCT_CONST static JVMFlag flagTable[] = {
 RUNTIME_FLAGS(RUNTIME_DEVELOP_FLAG_STRUCT,
               RUNTIME_PRODUCT_FLAG_STRUCT,
               RUNTIME_ALWAYS_FLAG_STRUCT)
 {0, NULL, NULL}
};

PRODUCT_CONST JVMFlag* Globals::find_flag(char* name) {
  PRODUCT_CONST JVMFlag* flag;

  for (flag = &flagTable[0]; flag->name; flag++) {
    if (jvm_strcmp(flag->name, name) == 0) {
      return flag;
    }
  }
  return NULL;
}
Ejemplo n.º 4
0
#define ARCH_NOTPRODUCT_FLAG_STRUCT(     type, name, value, doc) { #type, XSTR(name), (void*) &name, NOT_PRODUCT_ARG(doc) Flag::Flags(Flag::DEFAULT | Flag::KIND_ARCH | Flag::KIND_NOT_PRODUCT) },

#define SHARK_PRODUCT_FLAG_STRUCT(       type, name, value, doc) { #type, XSTR(name), &name,         NOT_PRODUCT_ARG(doc) Flag::Flags(Flag::DEFAULT | Flag::KIND_SHARK | Flag::KIND_PRODUCT) },
#define SHARK_PD_PRODUCT_FLAG_STRUCT(    type, name,        doc) { #type, XSTR(name), &name,         NOT_PRODUCT_ARG(doc) Flag::Flags(Flag::DEFAULT | Flag::KIND_SHARK | Flag::KIND_PRODUCT | Flag::KIND_PLATFORM_DEPENDENT) },
#define SHARK_DIAGNOSTIC_FLAG_STRUCT(    type, name, value, doc) { #type, XSTR(name), &name,         NOT_PRODUCT_ARG(doc) Flag::Flags(Flag::DEFAULT | Flag::KIND_SHARK | Flag::KIND_DIAGNOSTIC) },
#define SHARK_DEVELOP_FLAG_STRUCT(       type, name, value, doc) { #type, XSTR(name), (void*) &name, NOT_PRODUCT_ARG(doc) Flag::Flags(Flag::DEFAULT | Flag::KIND_SHARK | Flag::KIND_DEVELOP) },
#define SHARK_PD_DEVELOP_FLAG_STRUCT(    type, name,        doc) { #type, XSTR(name), (void*) &name, NOT_PRODUCT_ARG(doc) Flag::Flags(Flag::DEFAULT | Flag::KIND_SHARK | Flag::KIND_DEVELOP | Flag::KIND_PLATFORM_DEPENDENT) },
#define SHARK_NOTPRODUCT_FLAG_STRUCT(    type, name, value, doc) { #type, XSTR(name), (void*) &name, NOT_PRODUCT_ARG(doc) Flag::Flags(Flag::DEFAULT | Flag::KIND_SHARK | Flag::KIND_NOT_PRODUCT) },

static Flag flagTable[] = {
 RUNTIME_FLAGS(RUNTIME_DEVELOP_FLAG_STRUCT, \
               RUNTIME_PD_DEVELOP_FLAG_STRUCT, \
               RUNTIME_PRODUCT_FLAG_STRUCT, \
               RUNTIME_PD_PRODUCT_FLAG_STRUCT, \
               RUNTIME_DIAGNOSTIC_FLAG_STRUCT, \
               RUNTIME_EXPERIMENTAL_FLAG_STRUCT, \
               RUNTIME_NOTPRODUCT_FLAG_STRUCT, \
               RUNTIME_MANAGEABLE_FLAG_STRUCT, \
               RUNTIME_PRODUCT_RW_FLAG_STRUCT, \
               RUNTIME_LP64_PRODUCT_FLAG_STRUCT, \
               IGNORE_RANGE, \
               IGNORE_CONSTRAINT)
 RUNTIME_OS_FLAGS(RUNTIME_DEVELOP_FLAG_STRUCT, \
                  RUNTIME_PD_DEVELOP_FLAG_STRUCT, \
                  RUNTIME_PRODUCT_FLAG_STRUCT, \
                  RUNTIME_PD_PRODUCT_FLAG_STRUCT, \
                  RUNTIME_DIAGNOSTIC_FLAG_STRUCT, \
                  RUNTIME_NOTPRODUCT_FLAG_STRUCT, \
                  IGNORE_RANGE, \
                  IGNORE_CONSTRAINT)
#if INCLUDE_ALL_GCS
 G1_FLAGS(RUNTIME_DEVELOP_FLAG_STRUCT, \