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
8288623: Move Continuation classes out of javaClasses.hpp #9191
8288623: Move Continuation classes out of javaClasses.hpp #9191
Conversation
👋 Welcome back iklam! A progress list of the required criteria for merging this PR into |
Webrevs
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we are about to start to squirrel away parts of javaClasses into new files, I wonder if the discoverability of these functions will be better if we use this naming instead:
javaClasses.hpp
javaClassesContinuation.hpp
javaClassesInvoke.hpp
...
instead of:
javaClasses.hpp
continuationJavaClasses.hpp
invokeJavaClasses.hpp
...
#ifndef SHARE_CLASSFILE_JDK_INTERNAL_VM_STACKCHUNK_INLINE_HPP | ||
#define SHARE_CLASSFILE_JDK_INTERNAL_VM_STACKCHUNK_INLINE_HPP |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This include guard doesn't follow the current naming convention.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This has not been resolved.
The naming of this follows what jvmci did - they have jvmciJavaClasses.hpp/cpp. Discovering continuation* is also something useful. |
I am not in love with either naming convention (the names are too long), but the latter sounds more grammatically correct. Also, as Coleen mentioned, if we choose the former, we need to rename jvmciJavaClasses.hpp as well. The former can be discovered as |
#include "classfile/javaClasses.hpp" | ||
#include "classfile/continuationJavaClasses.hpp" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Include order
#include "oops/stackChunkOop.hpp" | ||
#include "gc/g1/g1BarrierSet.hpp" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Include order
#ifndef SHARE_CLASSFILE_JAVACLASSES_IMPL_HPP | ||
#define SHARE_CLASSFILE_JAVACLASSES_IMPL_HPP |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Convention is to name this:
SHARE_CLASSFILE_JAVACLASSESIMPL_HPP
#include "classfile/javaClassesImpl.hpp" | ||
#include "classfile/javaClasses.hpp" | ||
#include "classfile/continuationJavaClasses.hpp" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Include order
I've talked to Ioi and Coleen about whether |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this split very much. JavaClasses was getting too unwieldy. I'm ambivalent whether continuationJavaClasses.cpp/hpp should go in the runtime directory, so please take Stefan's recommendation and move it there. Tnanks.
@iklam This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be:
You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been no new commits pushed to the ➡️ To integrate this PR with the above commit message to the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I started to add comments to the PR, but then realized it would be easier to just provide a patch with my suggestions. Please take a look at:
https://github.com/stefank/jdk/tree/pr_9191
#include "classfile/javaClasses.hpp" | ||
#include "classfile/continuationJavaClasses.hpp" | ||
#include "oops/access.inline.hpp" | ||
#include "oops/stackChunkOop.hpp" | ||
#include "logging/log.hpp" | ||
#include "oops/access.inline.hpp" | ||
#include "oops/stackChunkOop.inline.hpp" | ||
#include "runtime/continuationJavaClasses.hpp" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The .inline.hpp files should include the corresponding .hpp file as the first included file. This is a fairly recently addition to the style guide, that we did to resolve the compilation problems with circular dependencies between the .inline.hpp files. So, please change this to:
#include "runtime/continuationJavaClasses.hpp"
#include "classfile/javaClasses.hpp"
#include "logging/log.hpp"
#include "oops/access.inline.hpp"
#include "oops/stackChunkOop.inline.hpp"
#ifndef SHARE_CLASSFILE_JDK_INTERNAL_VM_STACKCHUNK_INLINE_HPP | ||
#define SHARE_CLASSFILE_JDK_INTERNAL_VM_STACKCHUNK_INLINE_HPP |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This has not been resolved.
*/ | ||
|
||
#include "precompiled.hpp" | ||
#include "classfile/javaClasses.hpp" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is classfile/javaClasses.hpp included in this file?
#define SHARE_CLASSFILE_CONTINUATIONJAVACLASSES_HPP | ||
|
||
#include "memory/allStatic.hpp" | ||
#include "oops/oop.hpp" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oop isn't used in this function, include oopsHierarchy.hpp instead. This file should also include globalDefinitions.hpp and macros.hpp
#ifndef SHARE_CLASSFILE_CONTINUATIONJAVACLASSES_HPP | ||
#define SHARE_CLASSFILE_CONTINUATIONJAVACLASSES_HPP |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Include guard needs to be updated.
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
spurious newline
@@ -220,159 +218,6 @@ inline void java_lang_Thread::set_jfr_epoch(oop ref, u2 epoch) { | |||
} | |||
#endif // INCLUDE_JFR | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Spurious newline
@@ -0,0 +1,110 @@ | |||
/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file should also move to runtime/
@iklam this pull request can not be integrated into git checkout 8288623-move-continuation-out-of-javaClasses-hpp
git fetch https://git.openjdk.org/jdk master
git merge FETCH_HEAD
# resolve conflicts and follow the instructions given by git merge
git commit -m "Merge master"
git push |
Going to push as commit 64782a7. |
javaClasses.hpp is getting too big - it contains the C++ representation of over 50 Java classes.
The RFE moves the following classes into a new file, continuationJavaClasses.hpp. The naming follows the same pattern as the existing header share/jvmci/jvmciJavaClasses.hpp.
Progress
Issue
Reviewers
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk pull/9191/head:pull/9191
$ git checkout pull/9191
Update a local copy of the PR:
$ git checkout pull/9191
$ git pull https://git.openjdk.org/jdk pull/9191/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 9191
View PR using the GUI difftool:
$ git pr show -t 9191
Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/9191.diff