comparison src/main/gov/nasa/jpf/jvm/bytecode/INVOKESTATIC.java @ 23:db918c531e6d

streamlined class init, which was a mixed case of registerClass()/initializeClass() and pushRequiredClinits(). Now it is a single initializeClass(ti) method which combines the previous initializeClass(), pushRequiredClinits() and pushClinit() methods. The reason for combining these is the forthcoming replacement of separately locked clinits from different DirectCallStackFrames with a single synthetic frame that calls clinits from nested synchronized blocks. This is required to model hotspot, which does cause deadlocks with concurrent init of classes that cause subclass init during their clinit executions.
author Peter Mehlitz <Peter.C.Mehlitz@nasa.gov>
date Wed, 15 Apr 2015 22:40:21 -0700
parents 61d41facf527
children
comparison
equal deleted inserted replaced
22:cd7880ab73c7 23:db918c531e6d
90 } 90 }
91 91
92 // this can be actually different than (can be a base) 92 // this can be actually different than (can be a base)
93 ClassInfo ciCallee = callee.getClassInfo(); 93 ClassInfo ciCallee = callee.getClassInfo();
94 94
95 if (ciCallee.pushRequiredClinits(ti)) { 95 if (ciCallee.initializeClass(ti)) {
96 // do class initialization before continuing 96 // do class initialization before continuing
97 // note - this returns the next insn in the topmost clinit that just got pushed 97 // note - this returns the next insn in the topmost clinit that just got pushed
98 return ti.getPC(); 98 return ti.getPC();
99 } 99 }
100 100