[master] Integrated: Fix CDS LotsOfClasses tests on 32-bit

Thomas Stuefe stuefe at openjdk.java.net
Fri Feb 4 11:02:42 UTC 2022


On Fri, 4 Feb 2022 08:23:30 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:

> 68fbdb32af390762a01380b277a3ae30f864fdb4 introduced class pointer reduction to 22-bit. Since that change, `CompressedKlassPointers::encode_not_null` validates the given Klass* - checks that it can be properly encoded with 22 bits. That means `CompressedKlassPointers::encode_not_null` should only be called if UseCompressedClassPointers is true (so, only but unconditionally on 64-bit).
> 
> Note that this asserts just puts our nose onto the question of what to do with Klass pointers on 32-bit. If we need to encode them into a smaller type, we need to find a way to do so for 32-bit too. There are several possibilities, ranging from introducing a class space (or class-space-like feature) for 32-bit too, allocating them wherever like today, but with a larger alignment, up to something completely different. But that is out of scope for this tiny fix.

This pull request has now been integrated.

Changeset: cf682984
Author:    Thomas Stuefe <stuefe at openjdk.org>
URL:       https://git.openjdk.java.net/lilliput/commit/cf682984f696da5c23c1ae69e8c85101425f3be8
Stats:     5 lines in 1 file changed: 4 ins; 0 del; 1 mod

Fix CDS LotsOfClasses tests on 32-bit

Reviewed-by: rkennke

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

PR: https://git.openjdk.java.net/lilliput/pull/38


More information about the lilliput-dev mailing list