[foreign-memaccess+abi] RFR: 8298532: Declare private constructors for FFM internal Architecture implementations
Per Minborg
pminborg at openjdk.org
Tue Dec 13 11:31:29 UTC 2022
This PR proposes declaring AArch64Architecture and X86_64Architecture final and creating a private constructor so that this redundant byte code can be eliminated:
public jdk.internal.foreign.abi.x64.X86_64Architecture();
Code:
0: aload_0
1: invokespecial #1 // Method java/lang/Object."<init>":()V
4: return
public jdk.internal.foreign.abi.aarch64.AArch64Architectur();
Code:
0: aload_0
1: invokespecial #1 // Method java/lang/Object."<init>":()V
4: return
and other potential optimizations can be unlocked.
-------------
Commit messages:
- Update src/java.base/share/classes/jdk/internal/foreign/abi/aarch64/AArch64Architecture.java
- Declare private constructors
Changes: https://git.openjdk.org/panama-foreign/pull/760/files
Webrev: https://webrevs.openjdk.org/?repo=panama-foreign&pr=760&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8298532
Stats: 8 lines in 2 files changed: 6 ins; 0 del; 2 mod
Patch: https://git.openjdk.org/panama-foreign/pull/760.diff
Fetch: git fetch https://git.openjdk.org/panama-foreign pull/760/head:pull/760
PR: https://git.openjdk.org/panama-foreign/pull/760
More information about the panama-dev
mailing list