RFR: 8330174: Protection zone for easier detection of accidental zero-nKlass use [v4]

Thomas Stuefe stuefe at openjdk.org
Wed Jan 22 18:42:48 UTC 2025


On Wed, 22 Jan 2025 17:31:10 GMT, Andrew Haley <aph at openjdk.org> wrote:

>> Thomas Stuefe has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   fix test
>
> src/hotspot/share/cds/metaspaceShared.cpp line 1373:
> 
>> 1371: static constexpr uint64_t protzone_tag       = 0x50524F545A4F4E45ULL; // "PROTZONE"
>> 1372: static constexpr uint64_t protzone_tag_start = 0x2D3E2D3E50524F54ULL; // "->->PROT"
>> 1373: static constexpr uint64_t protzone_tag_end   = 0x50524F543C2D3C2DULL; // "PROT<-<-"
> 
> Is this endianness dependent?

I don't think so. We only read archives created on the same architecture. The only thing that could change would be the page size.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/23190#discussion_r1925798765


More information about the hotspot-dev mailing list