RFR(L) 8026054: New type profiling points: type of return values at calls

Roland Westrelin roland.westrelin at oracle.com
Tue Oct 8 09:22:13 PDT 2013


Follow up to 8023657: New type profiling points: arguments to call

8023657 introduced TypeStackSlotEntries to keep track of types of arguments. This change adds a couple more similar classes: TypeEntriesAtCall and ReturnTypeEntry which is maybe the confusing part of the change. ReturnTypeEntry keeps track of types of return values, TypeStackSlotEntries of types of arguments. In the next type profiling change, TypeStackSlotEntries will be used for parameter type profiling. TypeEntriesAtCall is ReturnTypeEntry + TypeStackSlotEntries to do the profiling at invokes. The number of cells needed at invokes is kept in TypeEntriesAtCall (to count cells for arguments and return value) and some methods in TypeStackSlotEntries were moved to TypeEntriesAtCall as a consequence.

The output of PrintMethodData is:

17 invokevirtual 3 <TestProfiling.m2(LTestProfiling$C;Ljava/lang/Object;Ljava/lang/Object;)LTestProfiling$C;>
  16  bci: 17   VirtualCallData     count(0) entries(1)
                                    'TestProfiling'(4744 1.00)
                argument types      0: stack(1) 'TestProfiling$C'
                                    1: stack(2) 'TestProfiling$B'
                return type         'TestProfiling$C'


More information about the hotspot-compiler-dev mailing list