Hi Ralf,
I have some questions. http://cr.openjdk.java.net/~simonis/webrevs/2018/8205608/src/jdk.jdwp.agent/share/native/libjdwp/ThreadReferenceImpl.c.frames.html 288 if (length != count) { 289 error = JVMTI_ERROR_INTERNAL; 290 }The above looks as incorrect because it does not account for the startIndex value. Also, if the condition is true then it should skip the loop at the lines 292-303. 292 for (fnum = 0; (fnum < count) && (error == JVMTI_ERROR_NONE); ++fnum) { 293 WITH_LOCAL_REFS(env, 1) { 294 jclass clazz; 295 error = methodClass(frames[fnum].method, &clazz); 296 297 if (error == JVMTI_ERROR_NONE) { 298 FrameID frame = createFrameID(thread, fnum + startIndex); 299 outStream_writeFrameID(out, frame); 300 writeCodeLocation(out, clazz, frames[fnum].method, frames[fnum].location); 301 } 302 } END_WITH_LOCAL_REFS(env); 303 }It seems, there has to be a break in the loop at lines 292-303 above if the condition at the line 297 is not true. Please, find a similarity in the original code lines 303-304: 303 if (error != JVMTI_ERROR_NONE) 304 break; Also, it looks as incorrect to send the packages if the such an error was identified. But this issue exists in the original implementation as well. On 7/5/18 15:37, Chris Plummer wrote: Hi Ralf, +1
The test has to be the TestScaffold based. You can find many examples in the jdk/com/sun/jdi folder. Thanks, Serguei
|
- RFR (S) 8205608: Fix 'frames()' in ThreadRefere... Schmelter, Ralf
- Re: RFR (S) 8205608: Fix 'frames()' in Thr... Thomas Stüfe
- RE: RFR (S) 8205608: Fix 'frames()' in... Schmelter, Ralf
- Re: RFR (S) 8205608: Fix 'frames()... Thomas Stüfe
- Re: RFR (S) 8205608: Fix 'frames()' in Thr... Chris Plummer
- Re: RFR (S) 8205608: Fix 'frames()' in... serguei.spit...@oracle.com
- Re: RFR (S) 8205608: Fix 'frames()... serguei.spit...@oracle.com
- RE: RFR (S) 8205608: Fix 'frames()' in... Schmelter, Ralf
- RE: RFR (S) 8205608: Fix 'frames()... Schmelter, Ralf
- Re: RFR (S) 8205608: Fix 'fram... Chris Plummer
- RE: RFR (S) 8205608: Fix ... Schmelter, Ralf
- Re: RFR (S) 8205608: ... Chris Plummer
- Re: RFR (S) 82056... serguei.spit...@oracle.com
- RE: RFR (S) 82056... Schmelter, Ralf
- Re: RFR (S) 82056... Chris Plummer
- Re: RFR (S) 82056... Chris Plummer