RFR: 8325438: Add exhaustive tests for Math.round intrinsics [v10]
Andrew Haley
aph at openjdk.org
Tue Apr 9 08:12:11 UTC 2024
On Thu, 4 Apr 2024 13:44:34 GMT, Hamlin Li <mli at openjdk.org> wrote:
>> HI,
>> Can you have a look at this patch adding some tests for Math.round instrinsics?
>> Thanks!
>>
>> ### FYI:
>> During the development of RoundVF/RoundF, we faced the issues which were only spotted by running test exhaustively against 32/64 bits range of int/long.
>> It's helpful to add these exhaustive tests in jdk for future possible usage, rather than build it everytime when needed.
>> Of course, we need to put it in `manual` mode, so it's not run when `-automatic` jtreg option is specified which I guess is the mode CI used, please correct me if I'm assume incorrectly.
>
> Hamlin Li has updated the pull request incrementally with one additional commit since the last revision:
>
> use java library code of Math.round as golden value
test/hotspot/jtreg/compiler/vectorization/TestRoundVectorFloatRandom.java line 64:
> 62:
> 63: int golden_round(float a) {
> 64: // below code is copied from java.base/share/classes/java/lang/Math.java
Suggestion:
static int golden_round(float a) {
// below code is copied from java.base/share/classes/java/lang/Math.java
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/17753#discussion_r1557173877
More information about the hotspot-compiler-dev
mailing list