RFR: 8282365: Optimize divideUnsigned and remainderUnsigned for constants [v18]
Emanuel Peter
epeter at openjdk.org
Tue Aug 22 17:29:49 UTC 2023
On Sat, 19 Aug 2023 08:48:35 GMT, Quan Anh Mai <qamai at openjdk.org> wrote:
>> Quan Anh Mai has updated the pull request incrementally with one additional commit since the last revision:
>>
>> whitespace
>
> I am working with adding more division tests in the java side as you have suggested, I think checking the result with different value ranges of the dividend is necessary, I am thinking of using `Min` and `Max` nodes for this, but there is currently no intrinsics for `Math::min(long, long)` and `Math::max(long, long)`, do you think I should add those to have easier time working on testing this patch?
@merykitty Why do you need the intrinsic for `Math::min/max(long,long)`? I would just write two methods: one that is compiled (maybe add IR rule that checks that division is present in earlier compile phase, but not present later), and another method that is excluded from compilation. Then you can just generate random inputs to the division and compare outputs.
But sure, adding the intrinsics for long min/max is on my list, because I want it to vectorize with SuperWord. So go ahead with it in a separate RFE if you want to use it for testing.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/9947#issuecomment-1688591232
More information about the hotspot-compiler-dev
mailing list