Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8003421

NPG: Move oops out of InstanceKlass into mirror


    • Type: Enhancement
    • Status: Closed
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: hs25
    • Fix Version/s: hs25
    • Component/s: hotspot
    • Subcomponent:
    • Resolved In Build:



        After permgen removal, the only oops that need to be walked in class metadata are in InstanceKlass besides mirrors are protection_domain, signers, init_lock. If these fields are moved to the mirror there is no increase in overall footprint. Also these fields can be card marked when modified because mirrors generally get promoted to tenured early, so that young collections don't need to look at these in our metadata (only mirrors).

        This would be supportive of MVM because the mirror and these fields cannot be shared between classes so if the InstanceKlass is shared, these things are kept separately in an array indexed by task id. If these things were in the mirror, we'd only have to worry about the mirror in this array. The init_lock had to be virtualized in the MVM prototype. We had extra code that would lock the per-task information as an oop, so this would also be supportive of that.

        In javaClasses.hpp there is a mechanism for injecting fields into our known Java objects, so I don't think this is difficult.


            Issue Links



                • Assignee:
                  coleenp Coleen Phillimore
                  coleenp Coleen Phillimore
                • Votes:
                  0 Vote for this issue
                  4 Start watching this issue


                  • Created: