RFR: 8276453: Undefined behavior in C1 LIR_OprDesc causes SEGV in fastdebug build [v6]

Man Cao manc at openjdk.java.net
Thu Nov 11 08:38:38 UTC 2021


On Thu, 11 Nov 2021 04:33:57 GMT, Dean Long <dlong at openjdk.org> wrote:

>> Man Cao has updated the pull request incrementally with two additional commits since the last revision:
>> 
>>  - Use nullOpr() or {} instead of LIR_Opr()
>>  - Revert the renaming from LIR_OprDesc to LIR_Opr to minimize patch size
>
> src/hotspot/cpu/arm/c1_LIRGenerator_arm.cpp line 367:
> 
>> 365: 
>> 366: void LIRGenerator::CardTableBarrierSet_post_barrier_helper(LIR_Opr addr, LIR_Const* card_table_base) {
>> 367:   assert(addr->is_register(), "must be a register at this point");
> 
> The above rename seems unnecessary.

It is actually necessary. Due to `typedef LIR_Opr LIR_OprDesc;`, `LIR_OprDesc*` is equivalent to `LIR_Opr*`, which breaks build.

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

PR: https://git.openjdk.java.net/jdk/pull/6221


More information about the hotspot-compiler-dev mailing list