United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-7012081 JSR 292: SA-JDI can't read MH/MT/Indy ConstantPool entries
JDK-7012081 : JSR 292: SA-JDI can't read MH/MT/Indy ConstantPool entries

Details
Type:
Bug
Submit Date:
2011-01-13
Status:
Closed
Updated Date:
2012-02-01
Project Name:
JDK
Resolved Date:
2011-09-30
Component:
hotspot
OS:
generic
Sub-Component:
compiler
CPU:
generic
Priority:
P4
Resolution:
Fixed
Affected Versions:
hs20
Fixed Versions:
hs22 (b02)

Related Reports
Backport:
Backport:

Sub Tasks

Description
SA-JDI throws the following exception when trying to get method locals after attaching to a class with JSR292 constant pool entries:

# ERROR: sun.jvm.hotspot.utilities.AssertionFailure: invalid cp index 5120 248
# ERROR:        at sun.jvm.hotspot.utilities.Assert.that(Assert.java:32)
# ERROR:        at sun.jvm.hotspot.oops.ConstantPool.indexOffset(ConstantPool.java:104)
# ERROR:        at sun.jvm.hotspot.oops.ConstantPool.getIntAt(ConstantPool.java:122)
# ERROR:        at sun.jvm.hotspot.oops.ConstantPool.getNameAndTypeAt(ConstantPool.java:170)
# ERROR:        at sun.jvm.hotspot.oops.ConstantPool.getSignatureRefIndexAt(ConstantPool.java:245)
# ERROR:        at sun.jvm.hotspot.oops.GenerateOopMap.doMethod(GenerateOopMap.java:1733)
# ERROR:        at sun.jvm.hotspot.oops.GenerateOopMap.interp1(GenerateOopMap.java:1383)
# ERROR:        at sun.jvm.hotspot.oops.GenerateOopMap.interpBB(GenerateOopMap.java:802)
# ERROR:        at sun.jvm.hotspot.oops.GenerateOopMap.interpAll(GenerateOopMap.java:1107)
# ERROR:        at sun.jvm.hotspot.oops.GenerateOopMap.doInterpretation(GenerateOopMap.java:980)
# ERROR:        at sun.jvm.hotspot.oops.GenerateOopMap.computeMap(GenerateOopMap.java:2208)
# ERROR:        at sun.jvm.hotspot.interpreter.OopMapForCacheEntry.computeMap(OopMapForCacheEntry.java:80)
# ERROR:        at sun.jvm.hotspot.interpreter.OopMapCacheEntry.fill(OopMapCacheEntry.java:53)
# ERROR:        at sun.jvm.hotspot.oops.Method.getMaskFor(Method.java:239)
# ERROR:        at sun.jvm.hotspot.runtime.InterpretedVFrame.getLocals(InterpretedVFrame.java:53)
# ERROR:        at sun.jvm.hotspot.jdi.StackFrameImpl.getValues(StackFrameImpl.java:189)

                                    

Comments
EVALUATION

SA support code needs to be updated for latest JVM changes.
                                     
2011-03-14
EVALUATION

After updating the SA this test is still failing but I think it's a test bug.  The test is look for a frame named .*INDIFY_SDE_Debuggee.main.* but that doesn't seem to exist.  There is a frame named vm.mlvm.share.sajdi.IndyDebuggee.main(java.lang.String[]) and IndyDebuggee is a subclass of INDIFY_SDE_DebuggeeBase.  This part seems like a test bug.  Is there really a .*INDIFY_SDE_Debuggee.main.* frame somewhere that should show up?  Several of the other tests may have a similar problem.
                                     
2011-06-30
EVALUATION

http://hg.openjdk.java.net/hsx/hotspot-comp/hotspot/rev/6a991dcb52bb
                                     
2011-07-21
EVALUATION

7012081: JSR 292: SA-JDI can't read MH/MT/Indy ConstantPool entries
Reviewed-by: kvn, twisti, jrose

There we a bunch of changes to the constant pool and bytecode classes
which were never reflected in the SA so it would break when looking at
classes using 292 features.  The fix is simply to make the SA code
mirror the JVM code again.  Primarily this was the code dealing with
the size of index values for various bytecodes.  The
generateOopMap.cpp change is purely a formatting change to make it
more regular.  After these changes some of the tests still fail but
this is because of test bugs that will be fixed separately.  Tested
with failing tests including the tmtools and sajdi suites which
exercises the SA extensively.
                                     
2011-07-26
EVALUATION

http://hg.openjdk.java.net/hsx/hotspot-rt/hotspot/rev/6a991dcb52bb
                                     
2011-08-23
EVALUATION

See main CR
                                     
2011-09-12



Hardware and Software, Engineered to Work Together