Skip to content

Commit

Permalink
8318603: Parallelize sun/java2d/marlin/ClipShapeTest.java
Browse files Browse the repository at this point in the history
Reviewed-by: aivanov, shade
  • Loading branch information
mrserb committed Feb 10, 2024
1 parent e33d8a2 commit 6c7029f
Showing 1 changed file with 33 additions and 10 deletions.
43 changes: 33 additions & 10 deletions test/jdk/sun/java2d/marlin/ClipShapeTest.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2017, 2021, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2017, 2024, 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
Expand Down Expand Up @@ -52,20 +52,43 @@
import javax.imageio.ImageWriter;
import javax.imageio.stream.ImageOutputStream;

/**
* @test
/*
* @test id=Poly
* @bug 8191814
* @summary Verifies that Marlin rendering generates the same
* images with and without clipping optimization with all possible
* stroke (cap/join) and/or dashes or fill modes (EO rules)
* for paths made of either 9 lines, 4 quads, 2 cubics (random)
* Note: Use the argument -slow to run more intensive tests (too much time)
*
* @summary Runs the test with "-poly" option
* @run main/othervm/timeout=300 -Dsun.java2d.renderer=sun.java2d.marlin.DMarlinRenderingEngine ClipShapeTest -poly
*/

/*
* @test id=PolyDoDash
* @bug 8191814
* @summary Runs the test with "-poly -doDash" options
* @run main/othervm/timeout=300 -Dsun.java2d.renderer=sun.java2d.marlin.DMarlinRenderingEngine ClipShapeTest -poly -doDash
*/

/*
* @test id=Cubic
* @bug 8191814
* @summary Runs the test with "-cubic" option
* @run main/othervm/timeout=300 -Dsun.java2d.renderer=sun.java2d.marlin.DMarlinRenderingEngine ClipShapeTest -cubic
*/

/*
* @test id=CubicDoDash
* @bug 8191814
* @summary Runs the test with "-cubic -doDash" options
* @run main/othervm/timeout=300 -Dsun.java2d.renderer=sun.java2d.marlin.DMarlinRenderingEngine ClipShapeTest -cubic -doDash
*/
*/

/**
* Verifies that Marlin rendering generates the same images with and without
* clipping optimization with all possible stroke (cap/join) and/or dashes or
* fill modes (EO rules) for paths made of either 9 lines, 4 quads, 2 cubics
* (random).
* <p>
* Note: Use the argument {@code -slow} to run more intensive tests (too much
* time).
*/
public final class ClipShapeTest {

// test options:
Expand Down

9 comments on commit 6c7029f

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mrserb
Copy link
Member Author

@mrserb mrserb commented on 6c7029f Feb 11, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/backport jdk22u

@openjdk
Copy link

@openjdk openjdk bot commented on 6c7029f Feb 11, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mrserb the backport was successfully created on the branch backport-mrserb-6c7029ff in my personal fork of openjdk/jdk22u. To create a pull request with this backport targeting openjdk/jdk22u:master, just click the following link:

➡️ Create pull request

The title of the pull request is automatically filled in correctly and below you find a suggestion for the pull request body:

Hi all,

This pull request contains a backport of commit 6c7029ff from the openjdk/jdk repository.

The commit being backported was authored by Sergey Bylokhov on 10 Feb 2024 and was reviewed by Alexey Ivanov and Aleksey Shipilev.

Thanks!

If you need to update the source branch of the pull then run the following commands in a local clone of your personal fork of openjdk/jdk22u:

$ git fetch https://github.com/openjdk-bots/jdk22u.git backport-mrserb-6c7029ff:backport-mrserb-6c7029ff
$ git checkout backport-mrserb-6c7029ff
# make changes
$ git add paths/to/changed/files
$ git commit --message 'Describe additional changes made'
$ git push https://github.com/openjdk-bots/jdk22u.git backport-mrserb-6c7029ff

⚠️ @mrserb You are not yet a collaborator in my fork openjdk-bots/jdk22u. An invite will be sent out and you need to accept it before you can proceed.

@mrserb
Copy link
Member Author

@mrserb mrserb commented on 6c7029f Feb 12, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/backport jdk21u-dev

@openjdk
Copy link

@openjdk openjdk bot commented on 6c7029f Feb 12, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mrserb the backport was successfully created on the branch backport-mrserb-6c7029ff in my personal fork of openjdk/jdk21u-dev. To create a pull request with this backport targeting openjdk/jdk21u-dev:master, just click the following link:

➡️ Create pull request

The title of the pull request is automatically filled in correctly and below you find a suggestion for the pull request body:

Hi all,

This pull request contains a backport of commit 6c7029ff from the openjdk/jdk repository.

The commit being backported was authored by Sergey Bylokhov on 10 Feb 2024 and was reviewed by Alexey Ivanov and Aleksey Shipilev.

Thanks!

If you need to update the source branch of the pull then run the following commands in a local clone of your personal fork of openjdk/jdk21u-dev:

$ git fetch https://github.com/openjdk-bots/jdk21u-dev.git backport-mrserb-6c7029ff:backport-mrserb-6c7029ff
$ git checkout backport-mrserb-6c7029ff
# make changes
$ git add paths/to/changed/files
$ git commit --message 'Describe additional changes made'
$ git push https://github.com/openjdk-bots/jdk21u-dev.git backport-mrserb-6c7029ff

@mrserb
Copy link
Member Author

@mrserb mrserb commented on 6c7029f Feb 12, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/backport jdk17u-dev

@openjdk
Copy link

@openjdk openjdk bot commented on 6c7029f Feb 12, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mrserb the backport was successfully created on the branch backport-mrserb-6c7029ff in my personal fork of openjdk/jdk17u-dev. To create a pull request with this backport targeting openjdk/jdk17u-dev:master, just click the following link:

➡️ Create pull request

The title of the pull request is automatically filled in correctly and below you find a suggestion for the pull request body:

Hi all,

This pull request contains a backport of commit 6c7029ff from the openjdk/jdk repository.

The commit being backported was authored by Sergey Bylokhov on 10 Feb 2024 and was reviewed by Alexey Ivanov and Aleksey Shipilev.

Thanks!

If you need to update the source branch of the pull then run the following commands in a local clone of your personal fork of openjdk/jdk17u-dev:

$ git fetch https://github.com/openjdk-bots/jdk17u-dev.git backport-mrserb-6c7029ff:backport-mrserb-6c7029ff
$ git checkout backport-mrserb-6c7029ff
# make changes
$ git add paths/to/changed/files
$ git commit --message 'Describe additional changes made'
$ git push https://github.com/openjdk-bots/jdk17u-dev.git backport-mrserb-6c7029ff

@mrserb
Copy link
Member Author

@mrserb mrserb commented on 6c7029f Feb 12, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/backport jdk11u-dev

@openjdk
Copy link

@openjdk openjdk bot commented on 6c7029f Feb 12, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mrserb Could not automatically backport 6c7029ff to openjdk/jdk11u-dev due to conflicts in the following files:

  • test/jdk/sun/java2d/marlin/ClipShapeTest.java

Please fetch the appropriate branch/commit and manually resolve these conflicts by using the following commands in your personal fork of openjdk/jdk11u-dev. Note: these commands are just some suggestions and you can use other equivalent commands you know.

# Fetch the up-to-date version of the target branch
$ git fetch --no-tags https://git.openjdk.org/jdk11u-dev.git master:master

# Check out the target branch and create your own branch to backport
$ git checkout master
$ git checkout -b backport-mrserb-6c7029ff

# Fetch the commit you want to backport
$ git fetch --no-tags https://git.openjdk.org/jdk.git 6c7029ffd48186353fc1d2a03915386b5f386ae2

# Backport the commit
$ git cherry-pick --no-commit 6c7029ffd48186353fc1d2a03915386b5f386ae2
# Resolve conflicts now

# Commit the files you have modified
$ git add files/with/resolved/conflicts
$ git commit -m 'Backport 6c7029ffd48186353fc1d2a03915386b5f386ae2'

Once you have resolved the conflicts as explained above continue with creating a pull request towards the openjdk/jdk11u-dev with the title Backport 6c7029ffd48186353fc1d2a03915386b5f386ae2.

Below you can find a suggestion for the pull request body:

Hi all,

This pull request contains a backport of commit 6c7029ff from the openjdk/jdk repository.

The commit being backported was authored by Sergey Bylokhov on 10 Feb 2024 and was reviewed by Alexey Ivanov and Aleksey Shipilev.

Thanks!

Please sign in to comment.