[master] RFR: Load Klass from header, C1/x86 implementation [v7]
Andrew Haley
aph at openjdk.java.net
Fri Dec 3 13:29:48 UTC 2021
On Fri, 3 Dec 2021 09:52:52 GMT, Roman Kennke <rkennke at openjdk.org> wrote:
>> This implements loading the Klass* from object header (instead of dedicated Klass* field) in C1 generated code. It introduces a new C1 LIR opcode (LoadKlass) and related CodeStub for the slow-path runtime-call.
>>
>> The original implementation was brittle in that it emits the decode_klass() whenever it encounters a load that is T_ADDRESS and from klass_offset_in_bytes() (e.g. 4 or 8). Lucky that we did not seem to emit any unrelated such loads. This new implementation uses a dedicated C1 op instead, and expands this to the corresponding load of the header word, and call into slow-path upon fast-path-failure, in the LIR assembler.
>>
>> Testing:
>> - [x] tier1 (x86_64,x86_32)
>> - [x] tier2 (x86_64,x86_32)
>> - [x] tier3 (x86_64,x86_32)
>> - [ ] tier4 (x86_64,x86_32)
>
> Roman Kennke has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 36 commits:
>
> - Merge remote-tracking branch 'origin/klass-from-header-c1' into klass-from-header-c1
> - Merge remote-tracking branch 'upstream/master' into klass-from-header-c1
> - Increase code size estimate
> - Merge branch 'master' into klass-from-header-c1
> - Merge remote-tracking branch 'jdk-upstream/master' into klass-from-header-c1
> - Merge remote-tracking branch 'upstream/master' into klass-from-header-c1
> - Basic arm implementation
> - Basic s390 implementation
> - Basic ppc implementation
> - Use long jump
> - ... and 26 more: https://git.openjdk.java.net/lilliput/compare/4390f5f0...6b24f6c6
This all looks reasonable and straightforward.
-------------
PR: https://git.openjdk.java.net/lilliput/pull/20
More information about the lilliput-dev
mailing list