[code-reflection] RFR: Regression: compiler SPI does not work with exploded build [v2]
Maurizio Cimadamore
mcimadamore at openjdk.org
Fri Nov 22 12:17:11 UTC 2024
> The recent refactoring from compiler plugin to simple SPI introduced a regression.
> With compiler plugins, the code-reflection extension was effectively loaded in two steps:
> * if the code reflection module was not available in the boot layer, then an attempt was made to load it from a fresh layer created on the fly
> * otherwise, plugins were searched in the boot layer (like for any other regular plugin)
>
> When running in exploded mode, incubating modules are part of the boot layer, so they are loaded normally (w/o the need of an extra layer).
> Unfortunately, the recent refactoring from plugin to SPI removed the second kind of lookup, meaning that now javac will no longer look for an extension in the boot layer.
>
> The solution is simple: javac should look in the fresh layer if it has created one (meaning the incubating module is not part of the boot layer); otherwise, it should just look for the extension in the boot layer.
Maurizio Cimadamore has updated the pull request incrementally with one additional commit since the last revision:
Improve reliability of module layer lookup
-------------
Changes:
- all: https://git.openjdk.org/babylon/pull/278/files
- new: https://git.openjdk.org/babylon/pull/278/files/af8e4160..87da6699
Webrevs:
- full: https://webrevs.openjdk.org/?repo=babylon&pr=278&range=01
- incr: https://webrevs.openjdk.org/?repo=babylon&pr=278&range=00-01
Stats: 33 lines in 2 files changed: 21 ins; 5 del; 7 mod
Patch: https://git.openjdk.org/babylon/pull/278.diff
Fetch: git fetch https://git.openjdk.org/babylon.git pull/278/head:pull/278
PR: https://git.openjdk.org/babylon/pull/278
More information about the babylon-dev
mailing list