8342707: Prepare Gatherers for graduation from Preview
Reviewed-by: alanb, liach
This commit is contained in:
parent
889f906235
commit
ef0dc2518e
@ -24,7 +24,6 @@
|
|||||||
*/
|
*/
|
||||||
package java.util.stream;
|
package java.util.stream;
|
||||||
|
|
||||||
import jdk.internal.javac.PreviewFeature;
|
|
||||||
import jdk.internal.vm.annotation.ForceInline;
|
import jdk.internal.vm.annotation.ForceInline;
|
||||||
|
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
@ -195,9 +194,8 @@ import java.util.function.Supplier;
|
|||||||
* @param <A> the potentially mutable state type of the gatherer operation
|
* @param <A> the potentially mutable state type of the gatherer operation
|
||||||
* (often hidden as an implementation detail)
|
* (often hidden as an implementation detail)
|
||||||
* @param <R> the type of output elements from the gatherer operation
|
* @param <R> the type of output elements from the gatherer operation
|
||||||
* @since 22
|
* @since 24
|
||||||
*/
|
*/
|
||||||
@PreviewFeature(feature = PreviewFeature.Feature.STREAM_GATHERERS)
|
|
||||||
public interface Gatherer<T, A, R> {
|
public interface Gatherer<T, A, R> {
|
||||||
/**
|
/**
|
||||||
* A function that produces an instance of the intermediate state used for
|
* A function that produces an instance of the intermediate state used for
|
||||||
@ -481,10 +479,9 @@ public interface Gatherer<T, A, R> {
|
|||||||
* A Downstream object is the next stage in a pipeline of operations,
|
* A Downstream object is the next stage in a pipeline of operations,
|
||||||
* to which elements can be sent.
|
* to which elements can be sent.
|
||||||
* @param <T> the type of elements this downstream accepts
|
* @param <T> the type of elements this downstream accepts
|
||||||
* @since 22
|
* @since 24
|
||||||
*/
|
*/
|
||||||
@FunctionalInterface
|
@FunctionalInterface
|
||||||
@PreviewFeature(feature = PreviewFeature.Feature.STREAM_GATHERERS)
|
|
||||||
interface Downstream<T> {
|
interface Downstream<T> {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -524,10 +521,9 @@ public interface Gatherer<T, A, R> {
|
|||||||
* @param <A> the type of state used by this integrator
|
* @param <A> the type of state used by this integrator
|
||||||
* @param <T> the type of elements this integrator consumes
|
* @param <T> the type of elements this integrator consumes
|
||||||
* @param <R> the type of results this integrator can produce
|
* @param <R> the type of results this integrator can produce
|
||||||
* @since 22
|
* @since 24
|
||||||
*/
|
*/
|
||||||
@FunctionalInterface
|
@FunctionalInterface
|
||||||
@PreviewFeature(feature = PreviewFeature.Feature.STREAM_GATHERERS)
|
|
||||||
interface Integrator<A, T, R> {
|
interface Integrator<A, T, R> {
|
||||||
/**
|
/**
|
||||||
* Performs an action given: the current state, the next element, and
|
* Performs an action given: the current state, the next element, and
|
||||||
@ -584,10 +580,9 @@ public interface Gatherer<T, A, R> {
|
|||||||
* @param <A> the type of state used by this integrator
|
* @param <A> the type of state used by this integrator
|
||||||
* @param <T> the type of elements this greedy integrator receives
|
* @param <T> the type of elements this greedy integrator receives
|
||||||
* @param <R> the type of results this greedy integrator can produce
|
* @param <R> the type of results this greedy integrator can produce
|
||||||
* @since 22
|
* @since 24
|
||||||
*/
|
*/
|
||||||
@FunctionalInterface
|
@FunctionalInterface
|
||||||
@PreviewFeature(feature = PreviewFeature.Feature.STREAM_GATHERERS)
|
|
||||||
interface Greedy<A, T, R> extends Integrator<A, T, R> { }
|
interface Greedy<A, T, R> extends Integrator<A, T, R> { }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -45,7 +45,7 @@ import java.util.stream.Gatherer.Integrator;
|
|||||||
* The performance-critical code below contains some more complicated encodings:
|
* The performance-critical code below contains some more complicated encodings:
|
||||||
* therefore, make sure to run benchmarks to verify changes to prevent regressions.
|
* therefore, make sure to run benchmarks to verify changes to prevent regressions.
|
||||||
*
|
*
|
||||||
* @since 22
|
* @since 24
|
||||||
*/
|
*/
|
||||||
final class GathererOp<T, A, R> extends ReferencePipeline<T, R> {
|
final class GathererOp<T, A, R> extends ReferencePipeline<T, R> {
|
||||||
@SuppressWarnings("unchecked")
|
@SuppressWarnings("unchecked")
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -25,7 +25,6 @@
|
|||||||
package java.util.stream;
|
package java.util.stream;
|
||||||
|
|
||||||
import jdk.internal.access.SharedSecrets;
|
import jdk.internal.access.SharedSecrets;
|
||||||
import jdk.internal.javac.PreviewFeature;
|
|
||||||
import jdk.internal.vm.annotation.ForceInline;
|
import jdk.internal.vm.annotation.ForceInline;
|
||||||
|
|
||||||
import java.util.ArrayDeque;
|
import java.util.ArrayDeque;
|
||||||
@ -48,9 +47,8 @@ import java.util.stream.Gatherer.Downstream;
|
|||||||
* operations, such as windowing functions, folding functions,
|
* operations, such as windowing functions, folding functions,
|
||||||
* transforming elements concurrently, etc.
|
* transforming elements concurrently, etc.
|
||||||
*
|
*
|
||||||
* @since 22
|
* @since 24
|
||||||
*/
|
*/
|
||||||
@PreviewFeature(feature = PreviewFeature.Feature.STREAM_GATHERERS)
|
|
||||||
public final class Gatherers {
|
public final class Gatherers {
|
||||||
private Gatherers() { } // This class is not intended to be instantiated
|
private Gatherers() { } // This class is not intended to be instantiated
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2012, 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2012, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -24,8 +24,6 @@
|
|||||||
*/
|
*/
|
||||||
package java.util.stream;
|
package java.util.stream;
|
||||||
|
|
||||||
import jdk.internal.javac.PreviewFeature;
|
|
||||||
|
|
||||||
import java.nio.file.Files;
|
import java.nio.file.Files;
|
||||||
import java.nio.file.Path;
|
import java.nio.file.Path;
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
@ -1096,9 +1094,8 @@ public interface Stream<T> extends BaseStream<T, Stream<T>> {
|
|||||||
* @param <R> The element type of the new stream
|
* @param <R> The element type of the new stream
|
||||||
* @param gatherer a gatherer
|
* @param gatherer a gatherer
|
||||||
* @return the new stream
|
* @return the new stream
|
||||||
* @since 22
|
* @since 24
|
||||||
*/
|
*/
|
||||||
@PreviewFeature(feature = PreviewFeature.Feature.STREAM_GATHERERS)
|
|
||||||
default <R> Stream<R> gather(Gatherer<? super T, ?, R> gatherer) {
|
default <R> Stream<R> gather(Gatherer<? super T, ?, R> gatherer) {
|
||||||
return StreamSupport.stream(spliterator(), isParallel())
|
return StreamSupport.stream(spliterator(), isParallel())
|
||||||
.gather(gatherer)
|
.gather(gatherer)
|
||||||
|
@ -76,7 +76,6 @@ public @interface PreviewFeature {
|
|||||||
STRUCTURED_CONCURRENCY,
|
STRUCTURED_CONCURRENCY,
|
||||||
@JEP(number=466, title="ClassFile API", status="Second Preview")
|
@JEP(number=466, title="ClassFile API", status="Second Preview")
|
||||||
CLASSFILE_API,
|
CLASSFILE_API,
|
||||||
@JEP(number=473, title="Stream Gatherers", status="Second Preview")
|
|
||||||
STREAM_GATHERERS,
|
STREAM_GATHERERS,
|
||||||
@JEP(number=476, title="Module Import Declarations", status="Preview")
|
@JEP(number=476, title="Module Import Declarations", status="Preview")
|
||||||
MODULE_IMPORTS,
|
MODULE_IMPORTS,
|
||||||
|
@ -35,7 +35,6 @@ import static org.junit.jupiter.api.Assumptions.*;
|
|||||||
/**
|
/**
|
||||||
* @test
|
* @test
|
||||||
* @summary Testing public API of Gatherer
|
* @summary Testing public API of Gatherer
|
||||||
* @enablePreview
|
|
||||||
* @run junit GathererAPITest
|
* @run junit GathererAPITest
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -32,7 +32,6 @@ import static org.junit.jupiter.api.Assumptions.*;
|
|||||||
* @test
|
* @test
|
||||||
* @bug 8328316
|
* @bug 8328316
|
||||||
* @summary Testing Gatherer behavior under short circuiting
|
* @summary Testing Gatherer behavior under short circuiting
|
||||||
* @enablePreview
|
|
||||||
* @run junit GathererShortCircuitTest
|
* @run junit GathererShortCircuitTest
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -37,7 +37,6 @@ import static org.junit.jupiter.api.Assumptions.*;
|
|||||||
/**
|
/**
|
||||||
* @test
|
* @test
|
||||||
* @summary Testing the Gatherer contract
|
* @summary Testing the Gatherer contract
|
||||||
* @enablePreview
|
|
||||||
* @library /lib/testlibrary/bootlib
|
* @library /lib/testlibrary/bootlib
|
||||||
* @build java.base/java.util.stream.DefaultMethodStreams
|
* @build java.base/java.util.stream.DefaultMethodStreams
|
||||||
* @run junit GathererTest
|
* @run junit GathererTest
|
||||||
|
@ -34,7 +34,6 @@ import static org.junit.jupiter.api.Assumptions.*;
|
|||||||
/**
|
/**
|
||||||
* @test
|
* @test
|
||||||
* @summary Tests the API and contract of Gatherers.fold
|
* @summary Tests the API and contract of Gatherers.fold
|
||||||
* @enablePreview
|
|
||||||
* @run junit GatherersFoldTest
|
* @run junit GatherersFoldTest
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -38,7 +38,6 @@ import static org.junit.jupiter.api.Assumptions.*;
|
|||||||
/**
|
/**
|
||||||
* @test
|
* @test
|
||||||
* @summary Tests the API and contract of Gatherers.mapConcurrent
|
* @summary Tests the API and contract of Gatherers.mapConcurrent
|
||||||
* @enablePreview
|
|
||||||
* @run junit GatherersMapConcurrentTest
|
* @run junit GatherersMapConcurrentTest
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -35,7 +35,6 @@ import static org.junit.jupiter.api.Assumptions.*;
|
|||||||
/**
|
/**
|
||||||
* @test
|
* @test
|
||||||
* @summary Tests the API and contract of Gatherers.scan
|
* @summary Tests the API and contract of Gatherers.scan
|
||||||
* @enablePreview
|
|
||||||
* @run junit GatherersScanTest
|
* @run junit GatherersScanTest
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -36,7 +36,6 @@ import static org.junit.jupiter.api.Assumptions.*;
|
|||||||
/**
|
/**
|
||||||
* @test
|
* @test
|
||||||
* @summary Tests the API and contract of Gatherers.windowFixed
|
* @summary Tests the API and contract of Gatherers.windowFixed
|
||||||
* @enablePreview
|
|
||||||
* @run junit GatherersWindowFixedTest
|
* @run junit GatherersWindowFixedTest
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -36,7 +36,6 @@ import static org.junit.jupiter.api.Assumptions.*;
|
|||||||
/**
|
/**
|
||||||
* @test
|
* @test
|
||||||
* @summary Tests the API and contract of Gatherers.windowSliding
|
* @summary Tests the API and contract of Gatherers.windowSliding
|
||||||
* @enablePreview
|
|
||||||
* @run junit GatherersWindowSlidingTest
|
* @run junit GatherersWindowSlidingTest
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -49,7 +49,7 @@ import static org.openjdk.bench.java.util.stream.ops.ref.BenchmarkGathererImpls.
|
|||||||
@BenchmarkMode(Mode.Throughput)
|
@BenchmarkMode(Mode.Throughput)
|
||||||
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Fork(jvmArgs = "--enable-preview", value = 1)
|
@Fork(value = 1)
|
||||||
@OutputTimeUnit(TimeUnit.SECONDS)
|
@OutputTimeUnit(TimeUnit.SECONDS)
|
||||||
@State(Scope.Thread)
|
@State(Scope.Thread)
|
||||||
public class GatherFMRPar {
|
public class GatherFMRPar {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -49,7 +49,7 @@ import static org.openjdk.bench.java.util.stream.ops.ref.BenchmarkGathererImpls.
|
|||||||
@BenchmarkMode(Mode.Throughput)
|
@BenchmarkMode(Mode.Throughput)
|
||||||
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Fork(jvmArgs = "--enable-preview", value = 1)
|
@Fork(value = 1)
|
||||||
@OutputTimeUnit(TimeUnit.SECONDS)
|
@OutputTimeUnit(TimeUnit.SECONDS)
|
||||||
@State(Scope.Thread)
|
@State(Scope.Thread)
|
||||||
public class GatherFMRSeq {
|
public class GatherFMRSeq {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -48,7 +48,7 @@ import static org.openjdk.bench.java.util.stream.ops.ref.BenchmarkGathererImpls.
|
|||||||
@BenchmarkMode(Mode.Throughput)
|
@BenchmarkMode(Mode.Throughput)
|
||||||
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Fork(jvmArgs = "--enable-preview", value = 1)
|
@Fork(value = 1)
|
||||||
@OutputTimeUnit(TimeUnit.SECONDS)
|
@OutputTimeUnit(TimeUnit.SECONDS)
|
||||||
@State(Scope.Thread)
|
@State(Scope.Thread)
|
||||||
public class GatherFlatMapInfinitySeq {
|
public class GatherFlatMapInfinitySeq {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -48,7 +48,7 @@ import static org.openjdk.bench.java.util.stream.ops.ref.BenchmarkGathererImpls.
|
|||||||
@BenchmarkMode(Mode.Throughput)
|
@BenchmarkMode(Mode.Throughput)
|
||||||
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Fork(jvmArgs = "--enable-preview", value = 1)
|
@Fork(value = 1)
|
||||||
@OutputTimeUnit(TimeUnit.SECONDS)
|
@OutputTimeUnit(TimeUnit.SECONDS)
|
||||||
@State(Scope.Thread)
|
@State(Scope.Thread)
|
||||||
public class GatherFlatMapSeq {
|
public class GatherFlatMapSeq {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -48,7 +48,7 @@ import static org.openjdk.bench.java.util.stream.ops.ref.BenchmarkGathererImpls.
|
|||||||
@BenchmarkMode(Mode.Throughput)
|
@BenchmarkMode(Mode.Throughput)
|
||||||
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Fork(jvmArgs = "--enable-preview", value = 1)
|
@Fork(value = 1)
|
||||||
@OutputTimeUnit(TimeUnit.SECONDS)
|
@OutputTimeUnit(TimeUnit.SECONDS)
|
||||||
@State(Scope.Thread)
|
@State(Scope.Thread)
|
||||||
public class GatherMapPar {
|
public class GatherMapPar {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -48,7 +48,7 @@ import static org.openjdk.bench.java.util.stream.ops.ref.BenchmarkGathererImpls.
|
|||||||
@BenchmarkMode(Mode.Throughput)
|
@BenchmarkMode(Mode.Throughput)
|
||||||
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Fork(jvmArgs = "--enable-preview", value = 1)
|
@Fork(value = 1)
|
||||||
@OutputTimeUnit(TimeUnit.SECONDS)
|
@OutputTimeUnit(TimeUnit.SECONDS)
|
||||||
@State(Scope.Thread)
|
@State(Scope.Thread)
|
||||||
public class GatherMapSeq {
|
public class GatherMapSeq {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -49,7 +49,7 @@ import static org.openjdk.bench.java.util.stream.ops.ref.BenchmarkGathererImpls.
|
|||||||
@BenchmarkMode(Mode.Throughput)
|
@BenchmarkMode(Mode.Throughput)
|
||||||
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Fork(jvmArgs = "--enable-preview", value = 1)
|
@Fork(value = 1)
|
||||||
@OutputTimeUnit(TimeUnit.SECONDS)
|
@OutputTimeUnit(TimeUnit.SECONDS)
|
||||||
@State(Scope.Thread)
|
@State(Scope.Thread)
|
||||||
public class GatherMiscPar {
|
public class GatherMiscPar {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -51,7 +51,7 @@ import static org.openjdk.bench.java.util.stream.ops.ref.BenchmarkGathererImpls.
|
|||||||
@BenchmarkMode(Mode.Throughput)
|
@BenchmarkMode(Mode.Throughput)
|
||||||
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Fork(jvmArgs = "--enable-preview", value = 1)
|
@Fork(value = 1)
|
||||||
@OutputTimeUnit(TimeUnit.SECONDS)
|
@OutputTimeUnit(TimeUnit.SECONDS)
|
||||||
@State(Scope.Thread)
|
@State(Scope.Thread)
|
||||||
public class GatherMiscSeq {
|
public class GatherMiscSeq {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -49,7 +49,7 @@ import static org.openjdk.bench.java.util.stream.ops.ref.BenchmarkGathererImpls.
|
|||||||
@BenchmarkMode(Mode.Throughput)
|
@BenchmarkMode(Mode.Throughput)
|
||||||
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Fork(jvmArgs = "--enable-preview", value = 1)
|
@Fork(value = 1)
|
||||||
@OutputTimeUnit(TimeUnit.SECONDS)
|
@OutputTimeUnit(TimeUnit.SECONDS)
|
||||||
@State(Scope.Thread)
|
@State(Scope.Thread)
|
||||||
public class GatherReducePar {
|
public class GatherReducePar {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -51,7 +51,7 @@ import static org.openjdk.bench.java.util.stream.ops.ref.BenchmarkGathererImpls.
|
|||||||
@BenchmarkMode(Mode.Throughput)
|
@BenchmarkMode(Mode.Throughput)
|
||||||
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Fork(jvmArgs = "--enable-preview", value = 1)
|
@Fork(value = 1)
|
||||||
@OutputTimeUnit(TimeUnit.SECONDS)
|
@OutputTimeUnit(TimeUnit.SECONDS)
|
||||||
@State(Scope.Thread)
|
@State(Scope.Thread)
|
||||||
public class GatherReduceSeq {
|
public class GatherReduceSeq {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2023, 2024, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -49,7 +49,7 @@ import static org.openjdk.bench.java.util.stream.ops.ref.BenchmarkGathererImpls.
|
|||||||
@BenchmarkMode(Mode.Throughput)
|
@BenchmarkMode(Mode.Throughput)
|
||||||
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Warmup(iterations = 4, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
@Measurement(iterations = 7, time = 5, timeUnit = TimeUnit.SECONDS)
|
||||||
@Fork(jvmArgs = "--enable-preview", value = 1)
|
@Fork(value = 1)
|
||||||
@OutputTimeUnit(TimeUnit.SECONDS)
|
@OutputTimeUnit(TimeUnit.SECONDS)
|
||||||
@State(Scope.Thread)
|
@State(Scope.Thread)
|
||||||
public class GatherWhileOrdered {
|
public class GatherWhileOrdered {
|
||||||
|
Loading…
Reference in New Issue
Block a user