Hi Daniil,
Not sure, I fully understand the fix. So, let's start from some questions. Why the DefaultClassPrepareEventListener is needed? Is it not enough to filter out the other threads in the ClassPrepareEventListener.eventReceived() method ? 243 eventHandler.startListening(); 244 // Add a listener to handle class prepared events fired by other ( e.g. compiler) threads. 245 // The listener should be added after the event listener is started to ensure that it called before 246 // the default event listener that handles unexpected events. 247 eventHandler.addListener(new DefaultClassPrepareEventListener()); It is still not clear why the default listener is added after the listening is started but not before. If the default listener is really needed then could you, please, split the lines above and L129, L160 to make a little bit shorter? I'd also suggest to replace "class prepared events" at L244 with "ClassPrepare event" or "class prepare event". There is also an unneeded space in the "( e.g. compiler)".Thanks, Serguei On 7/17/18 01:20, Daniil Titov wrote: Please review the change that fix the JDI test when running with Graal. The problem here is that the test verifies that a class prepare event is generated when the target VM loads a specific test class, but with Graal turned on additional class prepare events are generated by the compiler threads. The test doesn't expect them and fails. The fix ensures that additional class prepare events are ignored by the test and properly handled. Bug: https://bugs.openjdk.java.net/browse/JDK-8204695 Webrev: http://cr.openjdk.java.net/~dtitov/8204695/webrev.01/ Thanks! --Daniil |
- RFR 8204695: [Graal] vmTestbase/nsk/jdi/ClassPr... Daniil Titov
- Re: RFR 8204695: [Graal] vmTestbase/nsk/jd... serguei.spit...@oracle.com
- Re: RFR 8204695: [Graal] vmTestbase/ns... Daniil Titov
- Re: RFR 8204695: [Graal] vmTestbas... serguei.spit...@oracle.com
- Re: RFR 8204695: [Graal] vmTes... Daniil Titov
- Re: RFR 8204695: [Graal] vmTes... Daniil Titov
- Re: RFR 8204695: [Graal] ... serguei.spit...@oracle.com
- Re: RFR 8204695: [Gra... Daniil Titov
- Re: RFR 8204695: ... serguei.spit...@oracle.com
- Re: RFR 8204695: ... Chris Plummer
- Re: RFR 8204695: ... Daniil Titov
- Re: RFR 8204695: [Graal] ... Chris Plummer