Re: RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Michael Haupt
Hi Claes, Paul, Andrej, thank you very much for your reviews. I've added lazy initialisation. This is the change I'm going to push: http://cr.openjdk.java.net/~mhaupt/8160717/webrev.02/ Best, Michael > Am 06.07.2016 um 16:31 schrieb Claes Redestad : > > > > On 2016-07-06 16:05, Paul Sandoz

Re: RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Claes Redestad
On 2016-07-06 16:05, Paul Sandoz wrote: On 6 Jul 2016, at 13:31, Claes Redestad wrote: On 2016-07-06 12:45, Paul Sandoz wrote: On 6 Jul 2016, at 12:04, Michael Haupt wrote: Hi Paul, thanks for your comments. Lazy initialisation of the PerfCounter is good, as is the warning suppress

Re: RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Paul Sandoz
> On 6 Jul 2016, at 13:31, Claes Redestad wrote: > > > > On 2016-07-06 12:45, Paul Sandoz wrote: >> >>> On 6 Jul 2016, at 12:04, Michael Haupt wrote: >>> >>> Hi Paul, >>> >>> thanks for your comments. >>> >>> Lazy initialisation of the PerfCounter is good, as is the warning >>> suppressi

Re: RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Paul Sandoz
> On 6 Jul 2016, at 14:32, Michael Haupt wrote: > > Hi Paul, > >> Am 06.07.2016 um 12:45 schrieb Paul Sandoz > >: >>> What do you mean with "differentiate between the two cases"? Assuming it's >>> Error/Exception vs. BytecodeGenerationException, here's the curren

Re: RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Michael Haupt
Hi Claes, > Am 06.07.2016 um 13:31 schrieb Claes Redestad : >>> I'll let Claes comment on the broader PerfCounter question, as he suggested >>> using them. I think PerfCounter is a convenient abstraction for what we >>> want to achieve, but the way it's used here may smell a bit abusive. >>> >>

Re: RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Michael Haupt
Hi Paul, > Am 06.07.2016 um 12:45 schrieb Paul Sandoz : >> What do you mean with "differentiate between the two cases"? Assuming it's >> Error/Exception vs. BytecodeGenerationException, here's the current >> rationale. There are cases when it makes sense to fall back to LFI, e.g., >> when, as h

Re: RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Claes Redestad
On 2016-07-06 12:45, Paul Sandoz wrote: On 6 Jul 2016, at 12:04, Michael Haupt wrote: Hi Paul, thanks for your comments. Lazy initialisation of the PerfCounter is good, as is the warning suppression. I'll let Claes comment on the broader PerfCounter question, as he suggested using them.

Re: RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Paul Sandoz
> On 6 Jul 2016, at 12:04, Michael Haupt wrote: > > Hi Paul, > > thanks for your comments. > > Lazy initialisation of the PerfCounter is good, as is the warning suppression. > > I'll let Claes comment on the broader PerfCounter question, as he suggested > using them. I think PerfCounter is a

Re: RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Michael Haupt
Hi Paul, thanks for your comments. Lazy initialisation of the PerfCounter is good, as is the warning suppression. I'll let Claes comment on the broader PerfCounter question, as he suggested using them. I think PerfCounter is a convenient abstraction for what we want to achieve, but the way it'

Re: RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Paul Sandoz
> On 6 Jul 2016, at 10:43, Michael Haupt wrote: > > Hi Andrej, > > thanks for your remarks; see below for a comment. > > In addition, I need an upper-case Review, please. I am concerned that PerfCounter will introduce more dependencies and overhead to startup. Notice for other usages PerfCo

Re: RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Michael Haupt
Hi Andrej, thanks for your remarks; see below for a comment. In addition, I need an upper-case Review, please. > Am 06.07.2016 um 10:25 schrieb Andrej Golovnin : > 767 static final long serialVersionUID = -1L; // no serialisation > > Just because you set serialVersionUID to -1L, it does

Re: RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Andrej Golovnin
Hi Michael, src/java.base/share/classes/java/lang/invoke/InvokerBytecodeGenerator.java The class BytecodeGenerationException should be final. 767 static final long serialVersionUID = -1L; // no serialisation Just because you set serialVersionUID to -1L, it does not mean that it is not s

RFR(S): 8160717: MethodHandles.loop() does not check for excessive signature

2016-07-06 Thread Michael Haupt
Dear all, please review this fix. Bug: https://bugs.openjdk.java.net/browse/JDK-8160717 Webrev: http://cr.openjdk.java.net/~mhaupt/8160717/webrev.00/ The fix captures failures during bytec