Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-7132665

Solaris32AndSolaris64Test.sh needs a better options filter


    • Subcomponent:
    • CPU:
    • OS:


      The following SDK/JDK test:


      has some option filtering logic intended to make
      the test run properly in typical testing configs.

      In general, the test needs to filter out:

      - the '-d32' and '-d64' options because the test itself
        needs to specify those options in particular combinations
      - options that don't work in 32-bit mode
      - options that don't work in 64-bit mode
      - Client VM flavor specifiers because the Client VM is 32-bit
        only currently

      Here is the current logic:

         174 # Get DEBUGGEE flags
         175 DEBUGGEEFLAGS=
         176 filename=$TESTCLASSES/@debuggeeVMOptions
         177 if [ ! -r ${filename} ] ; then
         178 filename=$TESTCLASSES/../@debuggeeVMOptions
         179 fi
         180 # Remove -d32, -d64 if present, and remove -XX:[+-]UseCompressedOops
         181 # if present since it is illegal in 32 bit mode.
         182 if [ -r ${filename} ] ; then
         183 DEBUGGEEFLAGS=`cat ${filename} | sed \
         184 -e 's/-d32//g' \
         185 -e 's/-d64//g' \
         186 -e 's/-XX:.UseCompressedOops//g' \
         187 `
         188 fi

      The current edit logic (lines 184-186) does not use any pattern
      anchoring so all of these edit lines could have unintended effects
      on other options.

      Also, the logic on line 186 is applied to all debuggee configs and
      not just the 32-bit debuggee configs. For the purposes of tolerating
      -XX:[+-]UseCompressedOops, it would probably be better to use the
      '-XX:+IgnoreUnrecognizedVMOptions' option.

      There is no logic to filter out Client VM flavor specifiers. This
      seems to work OK with the current launcher, i.e., '-client -d64'
      launches the 64-bit Server VM. However, '-client-fast -d64' results
      in a failure:

      JDK under test is: /work/shared/baseline_jdks/1.8.0_b22/solaris-x64
      OS is running in amd64 mode
      debugger=32 debugee=32 class=DataModelTest
      /work/shared/baseline_jdks/1.8.0_b22/solaris-x64/bin/java -DHANGINGJAVA_DEB -d32
       -showversion -DEXPECTED=32 -classpath "/work/shared/baseline_jdks/1.8.0_b22/sol
       DataModelTest -connect 'com.sun.jdi.CommandLineLaunch:options=-d32 -client-fast
       -showversion -showversion'
      JVM version:1.8.0-ea
      JDI version: 1.6
      JVM description: Java Debug Interface (Reference Implementation) version 1.6
      Java Debug Wire Protocol (Reference Implementation) version 1.6
      JVM Debug Interface version 1.2
      JVM version 1.8.0-ea (Java HotSpot(TM) Client VM, mixed mode, sharing)
      java version "1.8.0-ea"
      Java(TM) SE Runtime Environment (build 1.8.0-ea-b22)
      Java HotSpot(TM) Client VM (build 23.0-b10-fastdebug, mixed mode)

      sun.arch.data.model is: 32
      Goodbye from DataModelTarg!
      debugger=32 debugee=64 class=DataModelTest
      /work/shared/baseline_jdks/1.8.0_b22/solaris-x64/bin/java -DHANGINGJAVA_DEB -d32
       -showversion -DEXPECTED=64 -classpath "/work/shared/baseline_jdks/1.8.0_b22/sol
       DataModelTest -connect 'com.sun.jdi.CommandLineLaunch:options=-d64 -client-fast
       -showversion -showversion'
      Unrecognized option: -client-fast
      Error: Could not create the Java Virtual Machine.
      Error: A fatal exception has occurred. Program will exit.
      The test failed :-(
      exit status was 1
      java version "1.8.0-ea"
      Java(TM) SE Runtime Environment (build 1.8.0-ea-b22)
      Java HotSpot(TM) Server VM (build 23.0-b10, mixed mode)

      run args: [-connect, com.sun.jdi.CommandLineLaunch:options=-d32 -client-fast -sh
      owversion -showversion, DataModelTarg]
      DataModelTest: passed
      java version "1.8.0-ea"
      Java(TM) SE Runtime Environment (build 1.8.0-ea-b22)
      Java HotSpot(TM) Server VM (build 23.0-b10, mixed mode)

      run args: [-connect, com.sun.jdi.CommandLineLaunch:options=-d64 -client-fast -sh
      owversion -showversion, DataModelTarg]
      VM initialization failed for: /work/shared/baseline_jdks/1.8.0_b22/solaris-x64/j
      re/bin/java -d64 -client-fast -showversion -showversion -Xdebug -Xrunjdwp:transp
      ort=dt_socket,address=frankenputer:53932,suspend=y DataModelTarg

       Target VM failed to initialize.
      Exception in thread "main" java.lang.NullPointerException
              at VMConnection.open(VMConnection.java:196)
              at TestScaffold.connect(TestScaffold.java:632)
              at TestScaffold.startUp(TestScaffold.java:363)
              at TestScaffold.startTo(TestScaffold.java:373)
              at DataModelTest.runTests(DataModelTest.java:79)
              at TestScaffold.startTests(TestScaffold.java:429)
              at DataModelTest.main(DataModelTest.java:72)
      32 to 64 test failed for class=DataModelTest!
      result: Failed. Execution failed: exit code 1

      test result: Failed. Execution failed: exit code 1


          Issue Links



              • Assignee:
                dcubed Daniel Daugherty
              • Votes:
                0 Vote for this issue
                2 Start watching this issue


                • Created: