RFR(S): 8056124 Hotspot should use PICL interface to get cacheline size on SPARC

Vladimir Kozlov vladimir.kozlov at oracle.com
Thu Sep 4 23:17:35 UTC 2014

Put "{" at the end of previous line:

+   static int get_cache_line_sizes(picl_nodehdl_t nodeh, void *result)
+   {

Next checks (and for L2) are not obvious. Please, add comment.

cpu_cache_sizes._L1_data != PROP_INCONSISTENT && 
core_cache_sizes._L1_data != PROP_INCONSISTENT

The value could be 0, a number, PROP_INCONSISTENT and PROP_MISSING.
So you rely on the fact that call back function 
get_int_property_and_ensure_consistency() will not be called when
class name does not match and the value stays 0. And only one class name 
"cpu" or "core" will be match.

May be add an assert that resulted _L1_data and _L2 >= 0.


On 9/4/14 3:27 PM, Igor Veresov wrote:
> Hi guys,
> Sorry for the noise, but I didn’t try the change on Fujitsu and it didn’t work.
> Fujitsu has cache line under a “core” class instead of the “cpu” class on Sun/Oracle, so I have to try both.
> Webrev: http://cr.openjdk.java.net/~iveresov/8056124/webrev.01/
> Thanks!
> igor

More information about the hotspot-compiler-dev mailing list