-
Notifications
You must be signed in to change notification settings - Fork 1.6k
feat(architecture): support arm64 based on JDK17 #6327
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
feat(architecture): support arm64 based on JDK17 #6327
Conversation
|
The |
chainbase/src/main/java/org/tron/common/storage/rocksdb/RocksDbDataSourceImpl.java
Show resolved
Hide resolved
chainbase/src/main/java/org/tron/common/utils/StorageUtils.java
Outdated
Show resolved
Hide resolved
platform/src/main/java/arm/org/tron/common/math/MathWrapper.java
Outdated
Show resolved
Hide resolved
platform/src/main/java/arm/org/tron/common/math/MathWrapper.java
Outdated
Show resolved
Hide resolved
platform/src/main/java/common/org/tron/common/utils/MarketComparator.java
Show resolved
Hide resolved
platform/src/main/java/common/org/tron/common/utils/MarketComparator.java
Show resolved
Hide resolved
platform/src/main/java/arm/org/tron/common/math/MathWrapper.java
Outdated
Show resolved
Hide resolved
chainbase/src/main/java/org/tron/common/storage/rocksdb/RocksDbDataSourceImpl.java
Outdated
Show resolved
Hide resolved
aeddfa1 to
e5055a7
Compare
| ### ARM64 JDK17 | ||
| ```bash | ||
| $ nohup java -Xms9G -Xmx9G -XX:+UseZGC \ | ||
| -Xlog:gc*:file=gc.log:time,uptime,level,tags:filecount=50,filesize=100M \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suggest make the -Xmx14G
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same for above x86_64 JDK8
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On 16GB nodes, the -Xmx9G JVM parameter in this example reserves sufficient memory for database off-heap allocation (2-4GB). Setting -Xmx too aggressively could lead to memory pressure and OOM issues.
chainbase/src/main/java/org/tron/common/storage/rocksdb/RocksDbDataSourceImpl.java
Outdated
Show resolved
Hide resolved
058b98c to
512cc6f
Compare
006a253 to
d2b84a9
Compare
| import java.util.Map; | ||
| import java.util.Objects; | ||
|
|
||
| /** |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it necessary to add an explanation for why the arm MathWrapper uses strictMath?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to maintain consistency with existing historical data when migrating from JDK8 x86 to ARM. StrictMath ensures that pow operations yield identical results regardless of the underlying hardware architecture.
7e155bb to
18deb27
Compare
- update condition to check for NullPointerException instances
- maintain compatibility with both pre-Java 14 and Java 14+ versions
- address JEP 358 changes to NullPointerException behavior
- ensure correct handling of non-empty NPE messages in Java 14+
Refs: JEP 358, JDK-8220715
- use `java.specification.version` instead of parsing `java.version` - ensure consistent version reporting across different Java releases(jdk10+)
add javax.jws-api:1.1 and javax.annotation-api:1.3.2, refs:JDK-8190378, JEP 320 remove com.carrotsearch:java-sizeof:0.0.5 bump lombok from 1.18.12 to 1.18.34, refs: [Lombok Changelog](https://projectlombok.org/changelog) bump aspectjrt from 1.18.13 to 1.9.8, refs: [AspectJ Java version compatibility](https://eclipse.dev/aspectj/doc/latest/release/JavaVersionCompatibility.html)
18deb27 to
1622dc8
Compare
1622dc8 to
c9cea43
Compare
Closes #5954