RFR: 8314684: Add overview docs to loaderConstraints.cpp [v3]

David Holmes dholmes at openjdk.org
Wed Aug 23 03:10:47 UTC 2023


On Tue, 22 Aug 2023 22:07:47 GMT, Ioi Lam <iklam at openjdk.org> wrote:

>> I added some documentation to make it easier to understand loaderConstraints.cpp. Please review and check if my description is actually correct. Thanks!
>
> Ioi Lam has updated the pull request incrementally with two additional commits since the last revision:
> 
>  - added references to source code
>  - added info about ConstraintSet

Thanks for the update.

Looks good - very useful.

src/hotspot/share/classfile/loaderConstraints.cpp line 84:

> 82: // Otherwise if both LoaderConstraints have different values for _klass, a LinkageError is thrown.
> 83: //
> 84: // Otherwise the two LoaderConstraints are merged into one.

So I looked in `LoaderConstraintTable::add_entry` to see how this algorithm applied and I could not figure out what condition is actually left (regarding `pp1` and `pp2`) when we get to the merge case at L396 ???

-------------

Marked as reviewed by dholmes (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/15372#pullrequestreview-1590636220
PR Review Comment: https://git.openjdk.org/jdk/pull/15372#discussion_r1302377529


More information about the hotspot-runtime-dev mailing list