Skip to content

Conversation

magicus
Copy link
Member

@magicus magicus commented Sep 3, 2025

Several java classes in java.base is generated from templates using SPP, the "Stream Preprocessor". Unfortunately much of this code is very old and has survived unchanged since pre-JDK 7. It does not follow modern makefile standards for abstraction, safe coding practices, etc. In short, they have been a thorn in the side for a long time, and the time has finally come to clean them up.


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

Reviewing

Using git

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

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

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 27078

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

Using diff file

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

Using Webrev

Link to Webrev Comment

@bridgekeeper
Copy link

bridgekeeper bot commented Sep 3, 2025

👋 Welcome back ihse! 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
Copy link

openjdk bot commented Sep 3, 2025

❗ This change is not yet ready to be integrated.
See the Progress checklist in the description for automated requirements.

@openjdk
Copy link

openjdk bot commented Sep 3, 2025

@magicus The following labels will be automatically applied to this pull request:

  • build
  • core-libs
  • i18n

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

@magicus
Copy link
Member Author

magicus commented Sep 3, 2025

I have verified that the generated java source code in gensrc is byte-by-byte identical with and without this patch. That is really all that is needed in terms of correctness, but to make sure I do not run into some unexpected problem I am also running a confirmation round on our internal CI.

@magicus
Copy link
Member Author

magicus commented Sep 3, 2025

Hm, something is messing up the command lines on the GHA hosts. Funny, I did not see it when testing elsewhere. I'll look into it.

@magicus magicus marked this pull request as ready for review September 5, 2025 10:54
@magicus magicus marked this pull request as draft September 5, 2025 10:55
@openjdk openjdk bot added rfr Pull request is ready for review and removed rfr Pull request is ready for review labels Sep 5, 2025
@magicus
Copy link
Member Author

magicus commented Sep 5, 2025

For the record: the changes in the X-Coder template means that additional empty lines will be inserted in the generated source. This has no real effect on anything substantial, but it means that line numbers change, which make a complete byte-by-byte comparison fail for anything that is dependent on these classes.

@magicus magicus marked this pull request as ready for review September 5, 2025 15:38
@openjdk openjdk bot added the rfr Pull request is ready for review label Sep 5, 2025
@mlbridge
Copy link

mlbridge bot commented Sep 5, 2025

Webrevs

@magicus
Copy link
Member Author

magicus commented Sep 5, 2025

This has passed Oracle internal CI testing for "builds-infra" tier 1-5.

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

Successfully merging this pull request may close these issues.

1 participant