mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-26 06:14:49 +02:00
7081933: Use zeroing elimination optimization for large array
Don't zero new typeArray during runtime call if the allocation is followed by arraycopy into it. Reviewed-by: twisti
This commit is contained in:
parent
95c56a472b
commit
47e357e16f
13 changed files with 97 additions and 11 deletions
|
@ -2359,10 +2359,10 @@ class StubGenerator: public StubCodeGenerator {
|
|||
for (int off = 0; off < 64; off += 16) {
|
||||
if (use_prefetch && (off & 31) == 0) {
|
||||
if (ArraycopySrcPrefetchDistance > 0) {
|
||||
__ prefetch(from, ArraycopySrcPrefetchDistance, Assembler::severalReads);
|
||||
__ prefetch(from, ArraycopySrcPrefetchDistance+off, Assembler::severalReads);
|
||||
}
|
||||
if (ArraycopyDstPrefetchDistance > 0) {
|
||||
__ prefetch(to, ArraycopyDstPrefetchDistance, Assembler::severalWritesAndPossiblyReads);
|
||||
__ prefetch(to, ArraycopyDstPrefetchDistance+off, Assembler::severalWritesAndPossiblyReads);
|
||||
}
|
||||
}
|
||||
__ ldx(from, off+0, O4);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue