jdk icon indicating copy to clipboard operation
jdk copied to clipboard

8287908: Use non-cloning reflection methods where acceptable

Open stsypanov opened this issue 2 years ago • 7 comments

Instead of Executable.getParameterTypes() we could use Executable.getSharedParameterTypes() in trusted code. Same is applicable for Executable.getExceptionTypes().


Progress

  • [ ] Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • [x] Change must not contain extraneous whitespace
  • [x] Commit message must refer to an issue

Issue

  • JDK-8287908: Use non-cloning reflection methods where acceptable

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk pull/9064/head:pull/9064
$ git checkout pull/9064

Update a local copy of the PR:
$ git checkout pull/9064
$ git pull https://git.openjdk.org/jdk pull/9064/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 9064

View PR using the GUI difftool:
$ git pr show -t 9064

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/9064.diff

stsypanov avatar Jun 07 '22 13:06 stsypanov

:wave: Welcome back stsypanov! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

bridgekeeper[bot] avatar Jun 07 '22 13:06 bridgekeeper[bot]

@stsypanov The following label will be automatically applied to this pull request:

  • core-libs

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command.

openjdk[bot] avatar Jun 07 '22 13:06 openjdk[bot]

Webrevs

mlbridge[bot] avatar Jun 07 '22 13:06 mlbridge[bot]

@stsypanov This pull request has been inactive for more than 4 weeks and will be automatically closed if another 4 weeks passes without any activity. To avoid this, simply add a new comment to the pull request. Feel free to ask for assistance if you need help with progressing this pull request towards integration!

bridgekeeper[bot] avatar Jul 13 '22 00:07 bridgekeeper[bot]

Let's wait

stsypanov avatar Jul 13 '22 07:07 stsypanov

@stsypanov This pull request has been inactive for more than 4 weeks and will be automatically closed if another 4 weeks passes without any activity. To avoid this, simply add a new comment to the pull request. Feel free to ask for assistance if you need help with progressing this pull request towards integration!

bridgekeeper[bot] avatar Aug 10 '22 08:08 bridgekeeper[bot]

Let's wait a bit

stsypanov avatar Aug 10 '22 09:08 stsypanov

@stsypanov This pull request has been inactive for more than 4 weeks and will be automatically closed if another 4 weeks passes without any activity. To avoid this, simply add a new comment to the pull request. Feel free to ask for assistance if you need help with progressing this pull request towards integration!

bridgekeeper[bot] avatar Sep 07 '22 18:09 bridgekeeper[bot]

@RogerRiggs is there anything I can do about this in addition to what is already done?

stsypanov avatar Sep 07 '22 18:09 stsypanov

:warning: @stsypanov the full name on your profile does not match the author name in this pull requests' HEAD commit. If this pull request gets integrated then the author name from this pull requests' HEAD commit will be used for the resulting commit. If you wish to push a new commit with a different author name, then please run the following commands in a local repository of your personal fork:

$ git checkout 8287908
$ git commit --author='Preferred Full Name <[email protected]>' --allow-empty -m 'Update full name'
$ git push

openjdk[bot] avatar Sep 07 '22 19:09 openjdk[bot]

@stsypanov This change now passes all automated pre-integration checks.

ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details.

After integration, the commit message for the final commit will be:

8287908: Use non-cloning reflection methods where acceptable

Reviewed-by: rriggs

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 1131 new commits pushed to the master branch:

  • 46e6e41b9a35c8665eb31be2f8c36bbdcc90564a: 8293051: Further refactor javac after removal of -source/-target/--release 7
  • c0ee30a25abda2f93806bbfaf940ba8638b864bf: 8293348: A false cyclic inheritance error reported
  • 85ec1f8d020cf2a9d7dfcc9ed75e43f0cd61c1f2: 8293492: ShenandoahControlThread missing from hs-err log and thread dump
  • 6bd2794175bac3c221d9b514bea01b0faa7af4a6: 8293304: Replace some usages of INTPTR_FORMAT with PTR_FORMAT
  • 98da03af50e2372817a7b5e381eea5ee6f2cb919: 8293432: Use diamond operator in java.management
  • ffc249ae2120752a9c0e9de18167b0c16f2de410: 8289613: Drop use of Thread.stop in jshell
  • 8d3399bf5f354931b0c62d2ed8095e554be71680: 8292758: put support for UNSIGNED5 format into its own header file
  • 6677227301acf06eb8be264e4eb3e092d0d7442f: 8293497: Build failure due to MaxVectorSize was not declared when C2 is disabled after JDK-8293254
  • 986b834148f425aa21611814d162a8578b26b502: 8293489: Accept CAs with BasicConstraints without pathLenConstraint
  • fc5f97fe379825cb927666ae26aef00082cfae56: 8293474: RISC-V: Unify the way of moving function pointer
  • ... and 1121 more: https://git.openjdk.org/jdk/compare/d959c22a9574359e2d5134ac8365e8a9df4f7cef...master

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

As you do not have Committer status in this project an existing Committer must agree to sponsor your change. Possible candidates are the reviewers of this PR (@RogerRiggs) but any other Committer may sponsor as well.

➡️ To flag this PR as ready for integration with the above commit message, type /integrate in a new comment. (Afterwards, your sponsor types /sponsor in a new comment to perform the integration).

openjdk[bot] avatar Sep 07 '22 19:09 openjdk[bot]

/integrate

stsypanov avatar Sep 08 '22 14:09 stsypanov

@stsypanov Your change (at version 7ef88f83b383d51ae84ebc55ac7c3a179783dc89) is now ready to be sponsored by a Committer.

openjdk[bot] avatar Sep 08 '22 14:09 openjdk[bot]

/sponsor

RogerRiggs avatar Sep 12 '22 13:09 RogerRiggs

Going to push as commit 9ef6c0925ae5a0ca774b23f6318551417a53e6c6. Since your change was applied there have been 1153 commits pushed to the master branch:

  • 0c61bf109f162621490df423c33f1bbc2c1524a0: 8293282: LoadLibraryUnloadTest.java fails with "Too few cleared WeakReferences"
  • 91c9091d7e64ba0bdb257521bd15ff183c6839fa: 8293343: sun/management/jmxremote/bootstrap/RmiSslNoKeyStoreTest.java failed with "Agent communication error: java.io.EOFException"
  • 4c77bd32a0d2cfbdd15e58a9b48f6952d52e7156: 6529151: NullPointerException in swing.plaf.synth.SynthLookAndFeel$Handler
  • d5aae0103a7c12db31f671dc9feb0976e13e4047: 8293544: G1: Add comment in G1BarrierSetC1::pre_barrier
  • 37df5f56259429482cfdbe38e8b6256f1efaf9e8: 8291599: Assertion in PhaseIdealLoop::skeleton_predicate_has_opaque after JDK-8289127
  • 699c42962eeaa6aa950ad86c2dd1f77316a1da3e: 8292866: Java_sun_awt_shell_Win32ShellFolder2_getLinkLocation check MultiByteToWideChar return value for failures
  • 68da02c7b536799ccca49e889c22f3e9a2691fb7: 8292240: CarrierThread.blocking not reset when spare not activated
  • 005b49bb78a468d4e372e6f5fa48bb0db4fd73c2: 8293044: C1: Missing access check on non-accessible class
  • 91d00b3022b8bb59ce04fb5f214e3deb93590f46: 8288473: Remove unused frame::set_pc_preserve_deopt methods
  • 45ff10cc68296c7c73d0eafe6fcc9946ab98267e: 8292695: SIGQUIT and jcmd attaching mechanism does not work with signal chaining library
  • ... and 1143 more: https://git.openjdk.org/jdk/compare/d959c22a9574359e2d5134ac8365e8a9df4f7cef...master

Your commit was automatically rebased without conflicts.

openjdk[bot] avatar Sep 12 '22 13:09 openjdk[bot]

@RogerRiggs @stsypanov Pushed as commit 9ef6c0925ae5a0ca774b23f6318551417a53e6c6.

:bulb: You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

openjdk[bot] avatar Sep 12 '22 13:09 openjdk[bot]