RFR: 8304915: Create jdk.internal.util.Architecture enum and apply [v2]
Roger Riggs
rriggs at openjdk.org
Wed Apr 5 18:53:12 UTC 2023
> Define an internal jdk.internal.util.Architecture enumeration and static methods to replace uses of the system property `os.arch`.
> The enumeration values are defined to match those used in the build.
> The initial values are: `X64, X86, IA64, ARM, AARCH64, RISCV64, S390X, PPC64LE`
> Note that `amd64` and `x86_64` in the build are represented by `X64`.
> The values of the system property `os.arch` is unchanged.
>
> The API is similar to the jdk.internal.util.OperatingSystem enum created by #[12931](https://git.openjdk.org/jdk/pull/12931).
> Uses in `java.base` and a few others are included but other modules will be done in separate PRs.
Roger Riggs has updated the pull request incrementally with one additional commit since the last revision:
Rename isXXX method to be uppercase architecture names matching the enum.
Refactor the is64Bit method to be a static method for the current runtime.
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/13357/files
- new: https://git.openjdk.org/jdk/pull/13357/files/0c61382d..bef30f96
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=13357&range=01
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=13357&range=00-01
Stats: 72 lines in 5 files changed: 35 ins; 13 del; 24 mod
Patch: https://git.openjdk.org/jdk/pull/13357.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/13357/head:pull/13357
PR: https://git.openjdk.org/jdk/pull/13357
More information about the serviceability-dev
mailing list