diff --git a/test/hotspot/jtreg/compiler/c2/Test7046096.java b/test/hotspot/jtreg/compiler/c2/Test7046096.java index 46eb935e2d0..fb73bba4373 100644 --- a/test/hotspot/jtreg/compiler/c2/Test7046096.java +++ b/test/hotspot/jtreg/compiler/c2/Test7046096.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2025, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -30,6 +30,18 @@ * compiler.c2.Test7046096 */ + +/* + * @test id=stringConcatInline + * @bug 7046096 8357822 + * @summary The same test with an updated compile directive that produces + * StringBuilder-backed string concatenations. + * + * @compile -XDstringConcat=inline Test7046096.java + * @run main/othervm -Xbatch compiler.c2.Test7046096 + */ + + package compiler.c2; public class Test7046096 { diff --git a/test/hotspot/jtreg/compiler/c2/Test7179138_2.java b/test/hotspot/jtreg/compiler/c2/Test7179138_2.java index 4e89f6aced0..5f96ea942ef 100644 --- a/test/hotspot/jtreg/compiler/c2/Test7179138_2.java +++ b/test/hotspot/jtreg/compiler/c2/Test7179138_2.java @@ -1,4 +1,5 @@ /* + * Copyright (c) 2025, Oracle and/or its affiliates. All rights reserved. * Copyright 2012 Skip Balk. All Rights Reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -32,6 +33,18 @@ * @author Skip Balk */ + +/* + * @test id=stringConcatInline + * @bug 7179138 + * @summary The same test with an updated compile directive that produces + * StringBuilder-backed string concatenations. + * + * @compile -XDstringConcat=inline Test7179138_2.java + * @run main/othervm -Xbatch -XX:-TieredCompilation compiler.c2.Test7179138_2 + */ + + package compiler.c2; public class Test7179138_2 { diff --git a/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Implicit01/cs_disabled/TestDescription.java b/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Implicit01/cs_disabled/TestDescription.java index 2eddeafa2c9..13bc3b4d640 100644 --- a/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Implicit01/cs_disabled/TestDescription.java +++ b/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Implicit01/cs_disabled/TestDescription.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017, 2020, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, 2025, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,3 +33,17 @@ * @run main/othervm -XX:-CompactStrings vm.compiler.optimizations.stringconcat.implicit.Implicit01 */ + +/* + * @test id=stringConcatInline + * + * @summary The same test with an updated compile directive that produces + * StringBuilder-backed string concatenations. + * VM Testbase keywords: [jit, quick] + * + * @library /vmTestbase + * /test/lib + * @compile -XDstringConcat=inline ../../Implicit01.java + * @run main/othervm -XX:-CompactStrings vm.compiler.optimizations.stringconcat.implicit.Implicit01 + */ + diff --git a/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Implicit01/cs_enabled/TestDescription.java b/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Implicit01/cs_enabled/TestDescription.java index 7e7295f5108..87e8bdcbcc7 100644 --- a/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Implicit01/cs_enabled/TestDescription.java +++ b/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Implicit01/cs_enabled/TestDescription.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017, 2020, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, 2025, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,3 +33,17 @@ * @run main/othervm -XX:+CompactStrings vm.compiler.optimizations.stringconcat.implicit.Implicit01 */ + +/* + * @test id=stringConcatInline + * + * @summary The same test with an updated compile directive that produces + * StringBuilder-backed string concatenations. + * VM Testbase keywords: [jit, quick] + * + * @library /vmTestbase + * /test/lib + * @compile -XDstringConcat=inline ../../Implicit01.java + * @run main/othervm -XX:+CompactStrings vm.compiler.optimizations.stringconcat.implicit.Implicit01 + */ + diff --git a/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Merge01/cs_disabled/TestDescription.java b/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Merge01/cs_disabled/TestDescription.java index c56a554b1da..cbbe4d97ee4 100644 --- a/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Merge01/cs_disabled/TestDescription.java +++ b/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Merge01/cs_disabled/TestDescription.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017, 2020, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, 2025, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,3 +33,17 @@ * @run main/othervm -XX:-CompactStrings vm.compiler.optimizations.stringconcat.implicit.Merge01 */ + +/* + * @test id=stringConcatInline + * + * @summary The same test with an updated compile directive that produces + * StringBuilder-backed string concatenations. + * VM Testbase keywords: [jit, quick] + * + * @library /vmTestbase + * /test/lib + * @compile -XDstringConcat=inline ../../Merge01.java + * @run main/othervm -XX:-CompactStrings vm.compiler.optimizations.stringconcat.implicit.Merge01 + */ + diff --git a/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Merge01/cs_enabled/TestDescription.java b/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Merge01/cs_enabled/TestDescription.java index 3c082fefd25..c6fc8d67de6 100644 --- a/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Merge01/cs_enabled/TestDescription.java +++ b/test/hotspot/jtreg/vmTestbase/vm/compiler/optimizations/stringconcat/implicit/Merge01/cs_enabled/TestDescription.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017, 2020, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2017, 2025, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -33,3 +33,17 @@ * @run main/othervm -XX:+CompactStrings vm.compiler.optimizations.stringconcat.implicit.Merge01 */ + +/* + * @test id=stringConcatInline + * + * @summary The same test with an updated compile directive that produces + * StringBuilder-backed string concatenations. + * VM Testbase keywords: [jit, quick] + * + * @library /vmTestbase + * /test/lib + * @compile -XDstringConcat=inline ../../Merge01.java + * @run main/othervm -XX:+CompactStrings vm.compiler.optimizations.stringconcat.implicit.Merge01 + */ +