-
Enhancement
-
Resolution: Fixed
-
P3
-
repo-valhalla
When C1 compiles the following code
inline class Point {int x, ..... }
class Holder { Point point; }
int x = holder.point.x
it first allocates a temporary Point object, copy the value of holder.point.x to the temp object, and then read x from the temp object. This should be simplified into a single load instruction
x = ((int*)(holder))[offset of point.x];
inline class Point {int x, ..... }
class Holder { Point point; }
int x = holder.point.x
it first allocates a temporary Point object, copy the value of holder.point.x to the temp object, and then read x from the temp object. This should be simplified into a single load instruction
x = ((int*)(holder))[offset of point.x];
- relates to
-
JDK-8260283 [lworld] C1's EliminateFieldAccess optimization fails with "wrong types"
-
- Resolved
-