Re: RFR: 8242428: JVMTI thread operations should use Thread-Local Handshake

2020-06-24 Thread David Holmes
e know all our testing could be executing only one of the cases. This concerns me but I am not yet sure what to do about it. Thanks, David - Also I tested it on submit repo, then it has execution error (mach5-one-ysuenaga-JDK-8242428-20200624-0054-12034717) due to dependency error. So

Re: RFR(S): 8247533: SA stack walking sometimes fails with sun.jvm.hotspot.debugger.DebuggerException: get_thread_regs failed for a lwp

2020-06-24 Thread Chris Plummer
On 6/24/20 6:53 PM, Yasumasa Suenaga wrote: On 2020/06/25 10:00, Chris Plummer wrote: On 6/24/20 5:17 PM, Yasumasa Suenaga wrote: On 2020/06/25 3:22, Chris Plummer wrote: On 6/24/20 12:01 AM, Yasumasa Suenaga wrote: On 2020/06/24 15:32, Chris Plummer wrote: Hi Yasumasa , I think LinuxAMD64C

Re: RFR(S) 8246019 PerfClassTraceTime slows down VM start-up

2020-06-24 Thread David Holmes
No objections. Thanks, David On 24/06/2020 8:57 am, Ioi Lam wrote: I've updated the patch to include just the fix for class initialization: http://cr.openjdk.java.net/~iklam/jdk16/8246019-avoid-PerfClassTraceTime.v02/ Hopefully this part is non-controversial. We are unlikely to make call_

Re: RFR(S): 8247533: SA stack walking sometimes fails with sun.jvm.hotspot.debugger.DebuggerException: get_thread_regs failed for a lwp

2020-06-24 Thread Yasumasa Suenaga
On 2020/06/25 10:00, Chris Plummer wrote: On 6/24/20 5:17 PM, Yasumasa Suenaga wrote: On 2020/06/25 3:22, Chris Plummer wrote: On 6/24/20 12:01 AM, Yasumasa Suenaga wrote: On 2020/06/24 15:32, Chris Plummer wrote: Hi Yasumasa , I think LinuxAMD64CFrame is used for pstack and what I've been l

Re: RFR(S): 8247533: SA stack walking sometimes fails with sun.jvm.hotspot.debugger.DebuggerException: get_thread_regs failed for a lwp

2020-06-24 Thread Chris Plummer
On 6/24/20 5:17 PM, Yasumasa Suenaga wrote: On 2020/06/25 3:22, Chris Plummer wrote: On 6/24/20 12:01 AM, Yasumasa Suenaga wrote: On 2020/06/24 15:32, Chris Plummer wrote: Hi Yasumasa , I think LinuxAMD64CFrame is used for pstack and what I've been looking at has been jstack, and in particul

Re: RFR(S): 8247533: SA stack walking sometimes fails with sun.jvm.hotspot.debugger.DebuggerException: get_thread_regs failed for a lwp

2020-06-24 Thread Yasumasa Suenaga
On 2020/06/25 3:22, Chris Plummer wrote: On 6/24/20 12:01 AM, Yasumasa Suenaga wrote: On 2020/06/24 15:32, Chris Plummer wrote: Hi Yasumasa , I think LinuxAMD64CFrame is used for pstack and what I've been looking at has been jstack, and in particular AMD64CurrentFrameGuess, which does use "la

Re: RFR (S): 8245129: Enhance jstat gc option output and tests

2020-06-24 Thread Daniil Titov
Hi Paul, The change looks good to me. Thanks! --Daniil On 6/22/20, 8:48 AM, "serviceability-dev on behalf of Hohensee, Paul" wrote: Thanks very much for review, Volker. I'll file a follow-up issue. One more reviewer, please? :) Paul On 6/22/20, 8:10 AM, "serviceability-

Re: 15 RFR(XS): 8165276: Spec states that invoke the premain method in an agent class if it's public but implementation differs

2020-06-24 Thread serguei.spit...@oracle.com
On 6/24/20 12:44, Mandy Chung wrote: On 6/24/20 12:26 PM, serguei.spit...@oracle.com wrote: On 6/24/20 05:25, David Holmes wrote: Ah! The test class SimpleAgent is what is not public. That seems a bug in the test. There are many such tests. We can break some of the existing agents by reje

Re: 15 RFR(XS): 8165276: Spec states that invoke the premain method in an agent class if it's public but implementation differs

2020-06-24 Thread Mandy Chung
On 6/24/20 12:26 PM, serguei.spit...@oracle.com wrote: On 6/24/20 05:25, David Holmes wrote: Ah! The test class SimpleAgent is what is not public. That seems a bug in the test. There are many such tests. We can break some of the existing agents by rejecting non-public agent classes. I'm i

Re: 15 RFR(XS): 8165276: Spec states that invoke the premain method in an agent class if it's public but implementation differs

2020-06-24 Thread serguei.spit...@oracle.com
On 6/24/20 05:25, David Holmes wrote: On 24/06/2020 8:14 pm, Alan Bateman wrote: On 24/06/2020 10:57, David Holmes wrote: But you are ignoring my next statement. If we remove the setAccessible(true) then the premain method will not be accessible as Serguei reported. Exception in thread "ma

Re: RFR(S): 8247533: SA stack walking sometimes fails with sun.jvm.hotspot.debugger.DebuggerException: get_thread_regs failed for a lwp

2020-06-24 Thread Chris Plummer
On 6/24/20 12:01 AM, Yasumasa Suenaga wrote: On 2020/06/24 15:32, Chris Plummer wrote: Hi Yasumasa , I think LinuxAMD64CFrame is used for pstack and what I've been looking at has been jstack, and in particular AMD64CurrentFrameGuess, which does use "last java frame". I'm not sure why LinuxAMD

Re: RFR(M): 8244383: jhsdb/HeapDumpTestWithActiveProcess.java fails with "AssertionFailure: illegal bci"

2020-06-24 Thread Daniel D. Daugherty
On 6/23/20 11:04 PM, Chris Plummer wrote: On 6/23/20 7:07 PM, Daniel D. Daugherty wrote: Just one more comment on this part: >    L220: System.out.println("CurrentFrameGuess: choosing interpreter frame: sp = " + >    L221: spFound + ", fpFound = " + fp + ", pc

Re: 15 RFR(XS): 8165276: Spec states that invoke the premain method in an agent class if it's public but implementation differs

2020-06-24 Thread David Holmes
On 24/06/2020 8:14 pm, Alan Bateman wrote: On 24/06/2020 10:57, David Holmes wrote: But you are ignoring my next statement. If we remove the setAccessible(true) then the premain method will not be accessible as Serguei reported. Exception in thread "main" java.lang.IllegalAccessException: c

Re: 15 RFR(XS): 8165276: Spec states that invoke the premain method in an agent class if it's public but implementation differs

2020-06-24 Thread Alan Bateman
On 24/06/2020 10:57, David Holmes wrote: But you are ignoring my next statement. If we remove the setAccessible(true) then the premain method will not be accessible as Serguei reported. Exception in thread "main" java.lang.IllegalAccessException: class sun.instrument.InstrumentationImpl   (

Re: 15 RFR(XS): 8165276: Spec states that invoke the premain method in an agent class if it's public but implementation differs

2020-06-24 Thread David Holmes
On 24/06/2020 7:43 pm, Alan Bateman wrote: On 24/06/2020 10:26, David Holmes wrote: If we call setAccessible(true) then canAccess will return true. Sure but the bug fix will remove the setAccessible(true) so canAccess will do what he wants without needing to catch the exception. This is of c

Re: 15 RFR(XS): 8165276: Spec states that invoke the premain method in an agent class if it's public but implementation differs

2020-06-24 Thread Alan Bateman
On 24/06/2020 10:26, David Holmes wrote: If we call setAccessible(true) then canAccess will return true. Sure but the bug fix will remove the setAccessible(true) so canAccess will do what he wants without needing to catch the exception. This is of course all a side show to the important issue

Re: 15 RFR(XS): 8165276: Spec states that invoke the premain method in an agent class if it's public but implementation differs

2020-06-24 Thread Alan Bateman
On 24/06/2020 10:22, David Holmes wrote: The other way around. The setAccessible has been there long before the module system existed, to allow a non-public premain. As a side-effect when the module system came along it also disabled some module access check (I'm not sure exactly what). This

Re: 15 RFR(XS): 8165276: Spec states that invoke the premain method in an agent class if it's public but implementation differs

2020-06-24 Thread David Holmes
On 24/06/2020 5:33 pm, Alan Bateman wrote: On 24/06/2020 07:55, serguei.spit...@oracle.com wrote: Thank you for the example. Yes, I'm working on a helpful message and was thinking to use the Reflection method:  IllegalAccessException newIllegalAccessException(Class currentClass,  

Re: 15 RFR(XS): 8165276: Spec states that invoke the premain method in an agent class if it's public but implementation differs

2020-06-24 Thread David Holmes
On 24/06/2020 4:22 pm, Alan Bateman wrote: On 24/06/2020 06:50, David Holmes wrote: It sounds like the use of setAccessible was hiding the need to disable some module related access checks. This will have a much bigger compatibility problem if agents with a public premain suddenly stop wo

Re: 15 RFR(XS): 8165276: Spec states that invoke the premain method in an agent class if it's public but implementation differs

2020-06-24 Thread David Holmes
On 24/06/2020 4:24 pm, serguei.spit...@oracle.com wrote: Hi David, On 6/23/20 22:50, David Holmes wrote: Hi Serguei, On 24/06/2020 3:37 pm, serguei.spit...@oracle.com wrote: Hi Larry, Thank you for looking at this! On 6/23/20 21:32, Laurence Cable wrote: should we not consider some form o

Re: 15 RFR(XS): 8165276: Spec states that invoke the premain method in an agent class if it's public but implementation differs

2020-06-24 Thread Alan Bateman
On 24/06/2020 07:55, serguei.spit...@oracle.com wrote: Thank you for the example. Yes, I'm working on a helpful message and was thinking to use the Reflection method:  IllegalAccessException newIllegalAccessException(Class currentClass,                          Class m

Re: RFR(S): 8247533: SA stack walking sometimes fails with sun.jvm.hotspot.debugger.DebuggerException: get_thread_regs failed for a lwp

2020-06-24 Thread Yasumasa Suenaga
On 2020/06/24 15:32, Chris Plummer wrote: Hi Yasumasa , I think LinuxAMD64CFrame is used for pstack and what I've been looking at has been jstack, and in particular AMD64CurrentFrameGuess, which does use "last java frame". I'm not sure why LinuxAMD64CFrame does not look at "last java frame". M