mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-26 14:24:46 +02:00
8332826: Make hashCode methods in ArraysSupport friendlier
Reviewed-by: redestad, liach
This commit is contained in:
parent
2b4a4b7bd8
commit
3cff588a31
13 changed files with 234 additions and 80 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2000, 2023, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2000, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
|
@ -707,7 +707,7 @@ class Heap$Type$Buffer$RW$
|
|||
}
|
||||
|
||||
public int hashCode() {
|
||||
return ArraysSupport.vectorizedHashCode(hb, ix(position()), remaining(), 1, ArraysSupport.T_BYTE);
|
||||
return ArraysSupport.hashCode(hb, ix(position()), remaining(), 1);
|
||||
}
|
||||
|
||||
#end[byte]
|
||||
|
@ -738,7 +738,7 @@ class Heap$Type$Buffer$RW$
|
|||
}
|
||||
|
||||
public int hashCode() {
|
||||
return ArraysSupport.vectorizedHashCode(hb, ix(position()), remaining(), 1, ArraysSupport.T_CHAR);
|
||||
return ArraysSupport.hashCode(hb, ix(position()), remaining(), 1);
|
||||
}
|
||||
#end[char]
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue