> Found this when working on JOL support 
> ([CODETOOLS-7903364](https://bugs.openjdk.org/browse/CODETOOLS-7903364)). If 
> you try to attach to VM running with -XX:ObjectAlignmentInBytes=32, then SA 
> would fail with:
> 
> 
> Caused by: java.lang.RuntimeException: Object alignment 32 not yet supported
> at jdk.hotspot.agent/sun.jvm.hotspot.runtime.VM.<init>(VM.java:510)
> at jdk.hotspot.agent/sun.jvm.hotspot.runtime.VM.initialize(VM.java:544)
> at 
> jdk.hotspot.agent/sun.jvm.hotspot.HotSpotAgent.setupVM(HotSpotAgent.java:444)
> 
> 
> This code was added by 
> [JDK-6916623](https://bugs.openjdk.org/browse/JDK-6916623), but I don't see a 
> reason why it should only handle 8 and 16 byte alignment.
> 
> Additional testing:
>  - [x] New regression test
>  - [ ] Linux x86_64 fastdebug `serviceability/sa`, with the combination of:
>     - different `-XX:ObjectAlignmentInBytes=`: 8, 16, 32, 64, 128, 256
>     - different GCs: Serial, Parallel, G1, Shenandoah, Z
>  - [ ] Linux x86_64 fastdebug `sun/tools/jhsdb`, with the combination of:
>     - different `-XX:ObjectAlignmentInBytes=`: 8, 16, 32, 64, 128, 256
>     - different GCs: Serial, Parallel, G1, Shenandoah, Z

Aleksey Shipilev has updated the pull request with a new target base due to a 
merge or a rebase. The incremental webrev excludes the unrelated changes 
brought in by the merge/rebase. The pull request contains four additional 
commits since the last revision:

 - Drop range check
 - Merge branch 'master' into JDK-8295657-sa-obj-align
 - Simplify test
 - Basic fix

-------------

Changes:
  - all: https://git.openjdk.org/jdk/pull/10762/files
  - new: https://git.openjdk.org/jdk/pull/10762/files/d332b97d..6b49483e

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=10762&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=10762&range=00-01

  Stats: 8056 lines in 214 files changed: 3012 ins; 4002 del; 1042 mod
  Patch: https://git.openjdk.org/jdk/pull/10762.diff
  Fetch: git fetch https://git.openjdk.org/jdk pull/10762/head:pull/10762

PR: https://git.openjdk.org/jdk/pull/10762

Reply via email to