Re: RFR (XS) 8076759: AbstractStringBuilder.append(...) should ensure enough capacity for the upcoming trivial append calls

2015-05-05 Thread Roger Riggs
Hi Aleksey, Thanks for checking the rounding alternative. As for the CCC, since the implementation details are in the javadoc then it will be needed either to remove the details or to update them. I'd be inclined to try to remove them since they are there primarily for performance. Thanks,

Re: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError

2015-05-05 Thread Daniel Fuchs
Hi Ivan, On 05/05/15 14:55, Ivan Gerasimov wrote: I converted the SubList into an inner class to make the implementations for AbstractList.SubList and ArrayList.SubList similar. It might be not worth doing so, but I thought it would be easier to maintain those classes, if they have similar

Re: RFR(M): 8078896: Add @modules as needed to the jdk_svc tests

2015-05-05 Thread Yekaterina Kantserova
Alan, Thanks for the review! And for the catch - I'll fix it. // Katja On 05/05/2015 03:30 PM, Alan Bateman wrote: Thanks Katja, this looks good. One thing that we should as part of this is rev the requiredVersion in jdk/test/TEST.ROOT in case people are using older versions of jtreg. I

Re: RFR(M): 8078896: Add @modules as needed to the jdk_svc tests

2015-05-05 Thread Alan Bateman
On 05/05/2015 10:04, Yekaterina Kantserova wrote: Hi, Could I please have a review of this fix. bug: https://bugs.openjdk.java.net/browse/JDK-8078896 webrev: http://cr.openjdk.java.net/~ykantser/8078896 The push will be pushed to jdk9/dev. Thanks Katja, this looks good. One thing that we

Re: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError

2015-05-05 Thread Ivan Gerasimov
On 05.05.2015 13:23, Daniel Fuchs wrote: On 05/05/15 10:58, Ivan Gerasimov wrote: Thank you Daniel for taking look at it! On 05.05.2015 11:14, Daniel Fuchs wrote: Hi Ivan, Have you considered to simply override/change subList(int fromIndex, int toIndex) in SubList and RandomAccessSubList -

Re: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError

2015-05-05 Thread Ivan Gerasimov
Thanks Louis for looking at this! Removing an element from a sub-sublist is done as: 549 public E remove(int index) { 550 rangeCheck(index); 551 checkForComodification(); 552 E result = AbstractList.this.remove(index + offset); 553

Re: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError

2015-05-05 Thread Martin Buchholz
The problem of deep nesting of sublists was known to previous generations of ArrayList maintainers. We got discouraged because there is no known way to make operations that are O(1) on the full list also O(1) on subsub...sublists. It's especially a performance problem when you use ArrayLists

RFR [9] 8079342: some docs cleanup for CORBA - part 2

2015-05-05 Thread alexander stepanov
Hello, Could you please review the following fix http://cr.openjdk.java.net/~avstepan/8079342/webrev.00/ for https://bugs.openjdk.java.net/browse/JDK-8079342 Just some HTML markup fix for CORBA. Thanks, Alexander

Re: RFR(M): JDK-8059036 : Implement Diagnostic Commands for heap and finalizerinfo

2015-05-05 Thread Peter Levart
Hi Dmitry, Staffan, On 05/05/2015 12:38 PM, Staffan Larsen wrote: Dmitry, I think this should be reviewed on hotspot-gc and core-libs-dev as well considering the changes to Finalizer. I’m a little worried about the potentially very large String that is returned from

Re: RFR [9] 8079342: some docs cleanup for CORBA - part 2

2015-05-05 Thread alexander stepanov
But yes, for 'writeValue' it could be renamed without any thoughts, thanks... On 05.05.2015 18:41, alexander stepanov wrote: Hello Lance, It just seemed to be less hazardous. E.g., method 'readValue' (in ValueHandlerImpl) contains inner variable 'in' and parameter '_in' being documented

Re: RFR [9] 8079342: some docs cleanup for CORBA - part 2

2015-05-05 Thread Lance Andersen
Hi Alexander, Thank you, I guess I am not a fan of _variableName in the public javadocs as it is not something we normally see. Understand less is more, especially with CORBA. On May 5, 2015, at 11:41 AM, alexander stepanov alexander.v.stepa...@oracle.com wrote: Hello Lance, It just

Re: RFR [9] 8079342: some docs cleanup for CORBA - part 2

2015-05-05 Thread Lance Andersen
Hi Alexander, I just started to look at this and have a question: /** * Writes the value to the stream using java semantics. - * @param out The stream to write the value to + * @param _out The stream to write the value to * @param value The value to be written to the stream

Re: RFR [9] 8079342: some docs cleanup for CORBA - part 2

2015-05-05 Thread alexander stepanov
Hello Lance, It just seemed to be less hazardous. E.g., method 'readValue' (in ValueHandlerImpl) contains inner variable 'in' and parameter '_in' being documented (also, '_sender' - 'sender'). But of course the names could be swapped, if desired. I lazily preferred not to touch the code

Re: RFR 8078645: removeIf(filter) in ConcurrentHashMap removes entries for which filter is false

2015-05-05 Thread Martin Buchholz
I'd prefer to go the other way, deleting those trivial methods entirely, utilizing the rarely used .new syntax. Index: ConcurrentSkipListMap.java === RCS file:

Re: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError

2015-05-05 Thread Ivan Gerasimov
Hi Paul On 05.05.2015 19:56, Paul Sandoz wrote: Hi Ivan, ArrayList -- You can simplify SubList with: private final class SubList extends AbstractListE implements RandomAccess { private final SubList parent; private final int offset; int size; // Top level sub-list

Re: RFR [9] 8079342: some docs cleanup for CORBA - part 2

2015-05-05 Thread Lance Andersen
The changes seem reasonable those the comments in ValueBoxGen24 are somewhat cryptic to me at least :-) On May 5, 2015, at 12:30 PM, alexander stepanov alexander.v.stepa...@oracle.com wrote: _variableName in the public javadocs Please see

Re: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError

2015-05-05 Thread Louis Wasserman
Just checking -- IIRC, this will change the semantics of how structural modifications to a subList of a subList will affect the first subList. For example, I believe in the past, removing an element from a subList of a subList would decrease the size of the first subList by 1, but now the first

Re: JDK 9 RFR of Update to RegEx test to use random number library

2015-05-05 Thread Xueming Shen
looks fine. On 5/5/15 2:53 PM, Joseph D. Darcy wrote: Hello, The regression test test/java/util/regex/RegExTest.java has been observed to intermittently fail. As the test uses randomness, I'd like to update to the test to use the random number testing library to better identify the

Re: RFR [9] 8079342: some docs cleanup for CORBA - part 2

2015-05-05 Thread alexander stepanov
_variableName in the public javadocs Please see http://cr.openjdk.java.net/~avstepan/8079342/webrev.00/src/java.corba/share/classes/com/sun/corba/se/impl/io/ValueHandlerImpl.java.udiff.html (please update the page as I didn't prepare a new webrev). Hopefully that do not harm the code...

Re: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError

2015-05-05 Thread Paul Sandoz
Hi Ivan, ArrayList -- You can simplify SubList with: private final class SubList extends AbstractListE implements RandomAccess { private final SubList parent; private final int offset; int size; // Top level sub-list SubList(int offset, int fromIndex, int toIndex) {

Re: RFR (XS) 8076759: AbstractStringBuilder.append(...) should ensure enough capacity for the upcoming trivial append calls

2015-05-05 Thread Aleksey Shipilev
Hi again, Here is a new webrev: http://cr.openjdk.java.net/~shade/8076759/webrev.01/ Pruned the implementation details from expandCapacity Javadoc, and about to submit a CCC for it. Thanks, -Aleksey. On 05.05.2015 16:33, Roger Riggs wrote: Hi Aleksey, Thanks for checking the rounding

Re: RFR: 8077846: improve locking strategy for readConfiguration(), reset(), and initializeGlobalHandlers()

2015-05-05 Thread Mandy Chung
On 5/4/2015 11:52 AM, Daniel Fuchs wrote: On 04/05/15 16:46, Peter Levart wrote: Hi Daniel, Here it is: http://cr.openjdk.java.net/~plevart/misc/LogManager.synchronization/webrev.04/ Looks good for me Peter :-) Hopefully Mandy will like it too! Yes it looks good to me. Thanks to both

RFR: 8079136: Accessing a nested sublist leads to StackOverflowError

2015-05-05 Thread Ivan Gerasimov
Hello! When creating a sublist with List.subList(), it keeps a reference to its parent. Then, when accessing (get(), set(), add(), remove(), etc.) the sublist, it recursively calls the corresponding methods of its parent. This recursion, when deep enough, can cause StackOverflowError. The

Re: RFR 8078645: removeIf(filter) in ConcurrentHashMap removes entries for which filter is false

2015-05-05 Thread Paul Sandoz
On May 4, 2015, at 11:11 PM, Martin Buchholz marti...@google.com wrote: Paul, thanks. Looks good. Test uses some impressive machinery, but I like what we did in jsr166 tck tests for similar sorts of tests: - rename latch to done - rename barrier to threadsStarted - rename map to

Re: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError

2015-05-05 Thread Daniel Fuchs
Hi Ivan, Have you considered to simply override/change subList(int fromIndex, int toIndex) in SubList and RandomAccessSubList - so that 'l'/'parent' points always to the original root list (instead of being a sublist of sublist of sublist)? It seems to me that overriding sublist to create a

Re: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError

2015-05-05 Thread Ivan Gerasimov
Thank you Daniel for taking look at it! On 05.05.2015 11:14, Daniel Fuchs wrote: Hi Ivan, Have you considered to simply override/change subList(int fromIndex, int toIndex) in SubList and RandomAccessSubList - so that 'l'/'parent' points always to the original root list (instead of being a

Re: RFR (XS) 8076759: AbstractStringBuilder.append(...) should ensure enough capacity for the upcoming trivial append calls

2015-05-05 Thread Aleksey Shipilev
Hi Roger, On 05/01/2015 08:19 PM, Roger Riggs wrote: Is there any additional benefit by rounding up the next multiple of 4 or 8. That would avoid a few wasted bytes at the end of the buffer modulo the allocation size. It does not seem to help any further. Tried plus32-round8, as in:

Re: RFR (XS) 8076759: AbstractStringBuilder.append(...) should ensure enough capacity for the upcoming trivial append calls

2015-05-05 Thread Aleksey Shipilev
Thanks for review, Ulf! -Aleksey. On 05/01/2015 05:29 PM, Ulf Zibis wrote: Hi Aleksey, I like this approach and to me the webrev looks good. -Ulf Am 24.04.2015 um 20:05 schrieb Aleksey Shipilev: Hi, This seems to be a simple one-liner fix, but the background is more complicated.

Re: RFR 8078645: removeIf(filter) in ConcurrentHashMap removes entries for which filter is false

2015-05-05 Thread Paul Sandoz
On May 5, 2015, at 7:54 AM, Martin Buchholz marti...@google.com wrote: One query in ConcurrentSkipListMap, we have: 2500 // else use iterator 2501 @SuppressWarnings(unchecked) IteratorMap.EntryObject,E it = 2502

RFR(M): 8078896: Add @modules as needed to the jdk_svc tests

2015-05-05 Thread Yekaterina Kantserova
Hi, Could I please have a review of this fix. bug: https://bugs.openjdk.java.net/browse/JDK-8078896 webrev: http://cr.openjdk.java.net/~ykantser/8078896 The push will be pushed to jdk9/dev. Thanks, Katja Alan's clarification from same change in hotspot (RFR: JDK-8075586: add @modules as

RFR (XS): 8078225: tools/launcher/FXLauncherTest.java fails intermittently (win)

2015-05-05 Thread Kumar Srinivasan
Hello, Please review the simple fix which allows the test to be run in its own vm, there seems to be some issue with the harness running in a concurrent mode specifically on Windows. Thanks Kumar diff --git a/test/tools/launcher/FXLauncherTest.java b/test/tools/launcher/FXLauncherTest.java

Re: RFR(M): 8078896: Add @modules as needed to the jdk_svc tests

2015-05-05 Thread Mandy Chung
On 05/05/2015 02:04 AM, Yekaterina Kantserova wrote: Hi, Could I please have a review of this fix. bug: https://bugs.openjdk.java.net/browse/JDK-8078896 webrev: http://cr.openjdk.java.net/~ykantser/8078896 com.sun.management has been moved to jdk.management module. The patch for

Re: RFR [9] Add blocking bulk read to java.io.InputStream

2015-05-05 Thread Alan Bateman
On 02/05/2015 09:27, Chris Hegarty wrote: : Thanks, this was an editing issue. Removed. I think the javadoc looks quite good now, except may be the first statement Reads some bytes It might be clearer to start with Reads a given number of bytes The subsequent text makes the short

Re: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError

2015-05-05 Thread Daniel Fuchs
On 05/05/15 10:58, Ivan Gerasimov wrote: Thank you Daniel for taking look at it! On 05.05.2015 11:14, Daniel Fuchs wrote: Hi Ivan, Have you considered to simply override/change subList(int fromIndex, int toIndex) in SubList and RandomAccessSubList - so that 'l'/'parent' points always to the

Re: RFR(M): JDK-8059036 : Implement Diagnostic Commands for heap and finalizerinfo

2015-05-05 Thread Staffan Larsen
Dmitry, I think this should be reviewed on hotspot-gc and core-libs-dev as well considering the changes to Finalizer. I’m a little worried about the potentially very large String that is returned from printFinalizationQueue(). A possible different approach would be to write

Re: RFR 8078645: removeIf(filter) in ConcurrentHashMap removes entries for which filter is false

2015-05-05 Thread Doug Lea
On 05/05/2015 05:12 AM, Paul Sandoz wrote: On May 5, 2015, at 7:54 AM, Martin Buchholz marti...@google.com wrote: One query in ConcurrentSkipListMap, we have: 2500 // else use iterator 2501 @SuppressWarnings(unchecked) IteratorMap.EntryObject,E it = 2502

Re: RFR (XS): 8078225: tools/launcher/FXLauncherTest.java fails intermittently (win)

2015-05-05 Thread Joseph D. Darcy
Looks fine Kumar; thanks, -Joe On 5/5/2015 1:37 PM, Kumar Srinivasan wrote: Hello, Please review the simple fix which allows the test to be run in its own vm, there seems to be some issue with the harness running in a concurrent mode specifically on Windows. Thanks Kumar diff --git

JDK 9 RFR of Update to RegEx test to use random number library

2015-05-05 Thread Joseph D. Darcy
Hello, The regression test test/java/util/regex/RegExTest.java has been observed to intermittently fail. As the test uses randomness, I'd like to update to the test to use the random number testing library to better identify the cause of any future failures. Please review the patch