mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-24 04:54:40 +02:00
8136820: Generate better code for some Unsafe addressing patterns
Reshape address computation to move invariant part out of loops Reviewed-by: kvn
This commit is contained in:
parent
4af470b866
commit
f8abd0e843
4 changed files with 79 additions and 37 deletions
|
@ -3055,6 +3055,9 @@ bool SWPointer::offset_plus_k(Node* n, bool negate) {
|
|||
}
|
||||
}
|
||||
if (invariant(n)) {
|
||||
if (opc == Op_ConvI2L) {
|
||||
n = n->in(1);
|
||||
}
|
||||
_negate_invar = negate;
|
||||
_invar = n;
|
||||
NOT_PRODUCT(_tracer.offset_plus_k_10(n, _invar, _negate_invar, _offset);)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue