RFR: 8266950: Remove vestigial support for non-strict floating-point execution [v2]
Vladimir Ivanov
vlivanov at openjdk.java.net
Sat May 22 13:51:57 UTC 2021
On Tue, 18 May 2021 04:26:00 GMT, David Holmes <dholmes at openjdk.org> wrote:
>> As part of JEP 306, the vestiges of HotSpot support for non-strict floating-point execution can be removed. All methods implicitly have strictfp semantics so the explicit checks for is_strict() can be replaced by true and the code reformulated accordingly.
>>
>> There are still some names that include "strict" that could potentially be renamed to remove it, but the fact we have to have strict fp semantics is still important on some platforms, so the names help reinforce that IMO.
>>
>> Testing: tiers 1-3
>>
>> Thanks,
>> David
>
> David Holmes has updated the pull request incrementally with one additional commit since the last revision:
>
> lir_div_strictfp and lir_mul_strictfp
Thanks, Jie.
I think there's `result->is_double_fpu()` check missing in `FpuStackAllocator::handle_op2`:
case lir_mul:
case lir_div: {
assert(op2->tmp1_opr()->is_fpu_register(), "strict operations need temporary fpu stack slot");
insert_free_if_dead(op2->tmp1_opr());
assert(sim()->stack_size() <= 7, "at least one stack slot must be free");
// fall-through: continue with the normal handling of lir_mul and lir_div
}
The code should be guarded by `result->is_double_fpu()` since special handling (additional temp operand) is needed only for `mul`/`div` on doubles.
src/hotspot/share/c1/c1_GraphBuilder.cpp line 1126:
> 1124: Value y = pop(type);
> 1125: Value x = pop(type);
> 1126: Value res = new ArithmeticOp(code, x, y,state_before);
Please, put a space before `state_before`.
-------------
PR: https://git.openjdk.java.net/jdk/pull/3991
More information about the hotspot-runtime-dev
mailing list