[GR-63220] Make ModuleLayerFeature layer aware #11263
Closed
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.
This PR makes the
RuntimeModuleSupport
and theModuleLayerFeature
layer aware.The
RuntimeModuleSupport
is now anApplicationLayerOnlyImageSingleton
which stores thebootLayer
of the final layer. To ensure all modules are visible, all the modules from the base layer are also included in the finalbootLayer
, using theSharedLayerBootLayerModulesSingleton
.To allow the runtime module access to work properly, the
Module#openPackages
andModule#exportedPackages
are now only finalized in the application layer, using the relocatable constants (via theCrossLayerConstantRegistry
). The field values of all layers are aggregated in theLayeredModuleSingleton
. This allows to addopens
orexports
in extension layers.This PR also adds support for future constants that have a
null
value in the application layer. Instead of an offset, thenull
value (0) is directly written.