Add OpenJDK internals doc#70
Open
johanvos wants to merge 1 commit into
Open
Conversation
… to either a jimage or exploded modules
jperedadnr
reviewed
Jan 6, 2026
|
|
||
| ## Create the Java Virtual Machine (JVM) | ||
|
|
||
| The JVM is created by invoking JNI_CreateJavaVM. In the HelloWorld demo that is explained [here](helloworld.md) |
Contributor
There was a problem hiding this comment.
s/JNI_CreateJavaVM/JNI_CreateJavaVM
| ## Create the Java Virtual Machine (JVM) | ||
|
|
||
| The JVM is created by invoking JNI_CreateJavaVM. In the HelloWorld demo that is explained [here](helloworld.md) | ||
| this made done in the `main.c` file: |
Contributor
There was a problem hiding this comment.
"... that is explained here this made done in the ..." has no sense.
Maybe:
"... that is explained here, this is done in the ..."
| Inside the `create_vm` function, a call is done to `Arguments::init_system_properties()` which will invoke `os::init_system_properties_values()` which will invoke `os::set_boot_path`, which is defined in [runtime/os.cpp](https://github.com/openjdk/mobile/src/hotspot/share/runtime/os.cpp). | ||
| In this function, `Arguments::set_boot_class_path` will be invoked with the detected location of the modules. | ||
| The detection of the modules happens in 2 phases: | ||
| 1. If there is a file located at `<JAVA_HOME>lib/modules`, that one is considered to be the jimage containing all boot modules. |
Contributor
There was a problem hiding this comment.
s/<JAVA_HOME>lib/modules/<JAVA_HOME>/lib/modules (missing slash)
KolbyML
approved these changes
Jan 6, 2026
KolbyML
left a comment
There was a problem hiding this comment.
Over all this looks good, I hope information about AoT gets added to the documentation soon as well 😁
Comment on lines
+31
to
+32
| 1. If there is a file located at `<JAVA_HOME>lib/modules`, that one is considered to be the jimage containing all boot modules. | ||
| 2. Otherwise, if there is a directory at `<JAVA_HOME>/modules/java.base`, that one is set as the boot_class_path |
There was a problem hiding this comment.
maybe we should clarify the difference between exploaded and non-exploaded modules, if we want this to be more begineer friendly, should be fine either way though
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Create a new documentation, explaining where the bootclasspath is set to either a jimage or exploded modules