Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

8261071: AArch64: Refactor interpreter native wrappers #2413

Conversation

@AntonKozlov
Copy link
Member

@AntonKozlov AntonKozlov commented Feb 4, 2021

Please review refactoring of interpreter signature handlers on aarch64. The main objective is to prepare for the new calling convention of macOS/AArch64, although this patch brings nothing from the new convention.

Tested with signature stress tests and tier1 on Linux/AArch64.

I have stared with a single function implementing SlowSignatureHandler (5ef1bd1#diff-1ff58ce70aeea7e9842d34e8d8fd9c94dd91182999d455618b2a171efd8f742cR164). The single function was compact but obscure. I was shuffling it until I eventually came to something similar of the initial approach with few pieces abstracted away.

The most notable changes in the final version should be

  • we count only parameters passed in registers
  • ldrw/strw are used to pass via stack in SignatureHandlerGenerator::pass_int

Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed

Issue

  • JDK-8261071: AArch64: Refactor interpreter native wrappers

Reviewers

Download

$ git fetch https://git.openjdk.java.net/jdk pull/2413/head:pull/2413
$ git checkout pull/2413

@bridgekeeper
Copy link

@bridgekeeper bridgekeeper bot commented Feb 4, 2021

👋 Welcome back akozlov! 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.

@openjdk openjdk bot added the rfr label Feb 4, 2021
@openjdk
Copy link

@openjdk openjdk bot commented Feb 4, 2021

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

  • hotspot

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 openjdk bot added the hotspot label Feb 4, 2021
@mlbridge
Copy link

@mlbridge mlbridge bot commented Feb 4, 2021

Webrevs

Copy link
Contributor

@theRealAph theRealAph left a comment

Thanks, that looks way better. Are all platform differences handled by Interpreter::local_offset_in_bytes() ?

@AntonKozlov
Copy link
Member Author

@AntonKozlov AntonKozlov commented Feb 5, 2021

Are all platform differences handled by Interpreter::local_offset_in_bytes() ?

Java local structure is very similar between CPUs. The function is a simple one:

  // Local values relative to locals[n]
  static int  local_offset_in_bytes(int n) {
    return ((frame::interpreter_frame_expression_stack_direction() * n) * stackElementSize);
  } 
@openjdk
Copy link

@openjdk openjdk bot commented Feb 5, 2021

@AntonKozlov 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:

8261071: AArch64: Refactor interpreter native wrappers

Reviewed-by: aph

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 43 new commits pushed to the master branch:

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 (@theRealAph) 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 openjdk bot added the ready label Feb 5, 2021
@AntonKozlov
Copy link
Member Author

@AntonKozlov AntonKozlov commented Feb 5, 2021

/integrate

@openjdk openjdk bot added the sponsor label Feb 5, 2021
@openjdk
Copy link

@openjdk openjdk bot commented Feb 5, 2021

@AntonKozlov
Your change (at version f303067) is now ready to be sponsored by a Committer.

@openjdk
Copy link

@openjdk openjdk bot commented Feb 12, 2021

@VladimirKempik Only the author (@AntonKozlov) is allowed to issue the integrate command. As this PR is ready to be sponsored, and you are an eligible sponsor, did you mean to issue the /sponsor command?

@VladimirKempik
Copy link

@VladimirKempik VladimirKempik commented Feb 12, 2021

/sponsor

@openjdk
Copy link

@openjdk openjdk bot commented Feb 12, 2021

@VladimirKempik @AntonKozlov Since your change was applied there have been 134 commits pushed to the master branch:

  • ebaa58d: 8261505: Test test/hotspot/jtreg/gc/parallel/TestDynShrinkHeap.java killed by Linux OOM Killer
  • 3210095: 8261079: Fix support for @hidden in classes and interfaces
  • 9c0ec8d: 8260941: Remove the conc_scan parameter for CardTable
  • da9895a: 8261499: Simplify HTML for javadoc links
  • 0779add: 8255059: Regressions >5% in all Javadoc benchmarks in 16-b19
  • 6a84ec6: 8260044: Parallel GC: Concurrent allocation after heap expansion may cause unnecessary full gc
  • 92ff891: 8261593: Do not use NULL pointer as write buffer parameter in jfrEmergencyDump.cpp write_repository_files
  • 60a2072: 8260431: com/sun/jdi/JdbOptions.java failed with "RuntimeException: 'prop[boo] = >foo<' missing from stdout/stderr"
  • bf47a47: 8261282: Lazy initialization of built-in ICC_Profile/ColorSpace classes is too lazy
  • f4cfd75: 8261510: Use RFC numbers and protocol titles in sun.security.ssl.SSLExtension comments
  • ... and 124 more: https://git.openjdk.java.net/jdk/compare/b0ee7a8624c42ca34d21e28bc23f208199a8eb4b...master

Your commit was automatically rebased without conflicts.

Pushed as commit 682e78e.

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
3 participants