Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move com.ibm.jvm classes to named module openj9.jvm #58

Merged
merged 1 commit into from Sep 21, 2017

Conversation

JasonFengJ9
Copy link
Member

Move com.ibm.jvm classes to named module openj9.jvm

1 Added jcl/src/openj9.jvm, and module-info.java, moved exports clause
exports com.ibm.jvm; from java.base to openj9.jvm;
2. Moved jcl/src/java.base/share/classes/com/ibm/jvm/* to
jcl/src/openj9.jvm/share/classes/com/ibm/jvm/;
3. To work with existing JVM during compilation: added removeexport and
deletion of java.base/com.ibm.jvm within j9modules.xml;
4. Updated jpp_configuration.xml and others.

Reviewer: @pshipton
FYI: @DanHeidinga @keithc-ca

Signed-off-by: Jason Feng fengj@ca.ibm.com

*******************************************************************************/
module openj9.jvm {
exports com.ibm.jvm;
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please convert to Unix line-ends for this file.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated.

1 Added jcl/src/openj9.jvm, and module-info.java, moved exports clause
exports com.ibm.jvm; from java.base to openj9.jvm;
2. Moved jcl/src/java.base/share/classes/com/ibm/jvm/* to
jcl/src/openj9.jvm/share/classes/com/ibm/jvm/;
3. To work with existing JVM during compilation: added removeexport and
deletion of java.base/com.ibm.jvm within j9modules.xml;
4. Updated jpp_configuration.xml and others.

Signed-off-by: Jason Feng <fengj@ca.ibm.com>
@genie-openj9
Copy link

Can one of the admins verify this patch?

1 similar comment
@genie-openj9
Copy link

Can one of the admins verify this patch?

@pshipton pshipton merged commit e1be844 into eclipse-openj9:master Sep 21, 2017
@JasonFengJ9 JasonFengJ9 deleted the openj9jvm branch April 26, 2018 19:53
tajila added a commit to tajila/openj9 that referenced this pull request May 12, 2020
Spec change:
VT must use Qsignatures in methodrefs, fields and now classrefs. This
means that when we are resolving classrefs we need to handle cases where
there is no signature (just name) and where there is a Qsignature. This
change has been made in the resolve classref code.

The rest of the changes are test related. Since there is no support for
VT with methodhandles, the method handles still look for 'L' signatures.
So as a work around the test generates a wrapper (generic) function that
accepts 'L' signatures and calls the real function with the 'Q'
signatures. The test cases call the generic version which then redirects
to the specific version.

For example:

```
  public static java.lang.Object makeValueGeneric(java.lang.Object,
java.lang.Object) throws java.lang.Exception;
    descriptor: (Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
    flags: (0x0009) ACC_PUBLIC, ACC_STATIC
    Code:
      stack=2, locals=2, args_size=2
         0: aload_0
         1: checkcast     eclipse-openj9#58                 // class "QPoint2D;"
         4: aload_1
         5: checkcast     eclipse-openj9#58                 // class "QPoint2D;"
         8: invokestatic  eclipse-openj9#60                 // Method
makeValue:(QPoint2D;QPoint2D;)QFlattenedLine2D;
        11: areturn
```

This need for the generic wrapper has always been there but it is more
important now since VTs are only ever using Q signatures.

The increased usage of generic wrappers has exposed some bugs. Below is
a summary:
- Since MHs are not being used to directly call the make function we
cannot rely on the asType conversions the MHs would normally do, so the
types have to be exact in order to pass the checkcast test. Ie. use
longs instead of int, etc.
- The makeGeneric generator code was missing breaks in the case
statements
- VT return signatures were using 'L' instead of 'Q' signatures

A follow on PR will be created to address the new behaviour for
checkcast.



Signed-off-by: Tobi Ajila <atobia@ca.ibm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants