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

JDK-8252802: java launcher should set MALLOCOPTIONS and LDR_CNTRL in order to use 64KB pages on AIX #17906

Closed
wants to merge 1 commit into from

Conversation

varada1110
Copy link
Contributor

@varada1110 varada1110 commented Feb 19, 2024

DeCapo Benchmark Results (3 runs) :

Before :
===== DaCapo 9.12 h2 PASSED in 281402 msec =====
===== DaCapo 9.12 h2 PASSED in 269818 msec =====
===== DaCapo 9.12 h2 PASSED in 279279 msec =====

After:
===== DaCapo 9.12 h2 PASSED in 279192 msec =====
===== DaCapo 9.12 h2 PASSED in 269769 msec =====
===== DaCapo 9.12 h2 PASSED in 271577 msec =====

Environmental variables LDR_CNTRL and MALLOCOPTIONS has caused test/jdk/java/lang/ProcessBuilder/Basic.java failure.
Additional environmental variables has to removed from removeAixExpectedVars().

JBS Issue : JDK-8252802


Progress

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

Issue

  • JDK-8252802: java launcher should set MALLOCOPTIONS and LDR_CNTRL in order to use 64KB pages on AIX (Enhancement - P4)

Reviewing

Using git

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

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

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 17906

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

Using diff file

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

Webrev

Link to Webrev Comment

@bridgekeeper
Copy link

bridgekeeper bot commented Feb 19, 2024

👋 Welcome back varadam! 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 Pull request is ready for review label Feb 19, 2024
@openjdk
Copy link

openjdk bot commented Feb 19, 2024

@varada1110 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.

@mlbridge
Copy link

mlbridge bot commented Feb 19, 2024

Webrevs

@AlanBateman
Copy link
Contributor

AlanBateman commented Feb 19, 2024

Question: Is the java launcher the right place for this? I'm wondering about other launchers that uses JNI Invocation API to create the VM.

@dholmes-ora
Copy link
Member

I concur with Alan: is this the right way to fix this? And is it really the case that every single Java application on AIX wants this setting?

@tstuefe
Copy link
Member

tstuefe commented Feb 20, 2024

I don't think this works as intended.

IIRC, both variables must be set before process invocation. Setting them inside the launcher will only affect child processes. The dacapo results posted seem to support this, they seem random-ish to me.

Note that we already use 64KB pages for all large memory regions (everything that goes through os::reserve_memory). So, while the value of LDRCNTRL is not nil, it is very diminished. Mostly just the C-Heap would be affected.

But I would not change defaults for options like these anyway, especially not hard-coded. These knobs have far-ranging implications. If we want that, we need to investigate carefully.

(for example: would using 64KB pages increase average heap size? Possibly, depending on the implementation. But AIX still has this problem where the heap can only live in the break and can bump against low-hanging regions. So, AIX is especially vulnerable against any changes that increase average heap usage)

@varada1110
Copy link
Contributor Author

Thanks @tstuefe for the response. Closing the PR since it is not advisable to do.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core-libs [email protected] rfr Pull request is ready for review
Development

Successfully merging this pull request may close these issues.

4 participants