RFR(M): 8026253: New type profiling points: sparc support

Christian Thalinger christian.thalinger at oracle.com
Thu Jan 9 12:36:11 PST 2014


src/share/vm/c1/c1_LIRGenerator.cpp:

!   ciKlass* exact = profile_type(md, 0, md->byte_offset_of_slot(data, ret->type_offset()),
!   ciKlass* exact = profile_type(md, md->byte_offset_of_slot(data, ret->type_offset()), 0,

What is this change?

src/cpu/sparc/vm/interp_masm_sparc.cpp:

+         // We're right after the type profile for the last
+         // argument. tmp is the number of cell left in the
+         // CallTypeData/VirtualCallTypeData to reach its end. Non null
+         // if there's a return to profile.
+         assert(ReturnTypeEntry::static_cell_count() < TypeStackSlotEntries::per_arg_count(), "can't move past ret type");
+         sll(tmp1, exact_log2(DataLayout::cell_size), tmp1);
+         add(ImethodDataPtr, tmp1, ImethodDataPtr);

I think “tmp” is referring to “tmp1” and “cell” should be plural, shouldn’t it?

Some comments are missing the final “.”.

Also, I didn’t verify the machine instructions in detail but a quick scan didn’t bring up anything obviously wrong.  I guess you did some testing.

Looks good.

On Jan 9, 2014, at 12:35 AM, Roland Westrelin <roland.westrelin at oracle.com> wrote:

> http://cr.openjdk.java.net/~roland/8026253/webrev.00/
> 
> The main difference with the x86 code is that on sparc, the current profile value is loaded, checked & updated and finally stored rather than checked & updated in place as is done on x86. As a consequence the code is somewhat simpler because concurrent updates to the profile are not possible.
> 
> Roland.



More information about the hotspot-compiler-dev mailing list