benchmark unaligned memory access
Aleksey Shipilev
aleksey.shipilev at oracle.com
Wed Mar 4 17:40:32 UTC 2015
Hi YC,
These questions belong to StackOverflow, please ask it there. This list
is for JMH development, not benchmark reviews.
On 04.03.2015 13:24, YC Huang wrote:
> Hi, I'm trying to benchmark what's the cost between aligned/unaligned
> memory access,but my test-case doesn't show there's obvious
> performance difference when running on my laptop(Pentium 6200).
Did you consider the performance difference is not "obvious", if you
can't replicate it easily? ;) All in all, you are trying to follow up on
a very thin phenomena, and probably the infrastructure costs dominate
the read performance.
> Am I doing something wrong in the Test?
The test looks OK, except for Unsafe instance might reside in "static
*final*" field.
-Aleksey.
More information about the jmh-dev
mailing list