mmtk / mmtk-openjdk

OpenJDK binding for MMTk
Other
31 stars 33 forks source link

hsqldb fails with GenCopy and -Xcomp flag #59

Open qinsoon opened 3 years ago

qinsoon commented 3 years ago

Binding revision: c3dc9d037fbe1472888d1129f70241dcb6e6eb87

build

export MMTK_PLAN= && export DEBUG_LEVEL=release  && export RUSTUP_TOOLCHAIN=nightly-2020-12-20 && sh configure --disable-warnings-as-errors --with-debug-level=$DEBUG_LEVEL && make CONF=linux-x86_64-normal-server-$DEBUG_LEVEL THIRD_PARTY_HEAP=$PWD/../../openjdk

run

yilin@rat:~/Code/mmtk-openjdk/repos/openjdk$ MMTK_PLAN=GenCopy build/linux-x86_64-normal-server-release/jdk/bin/java -Xms467M -Xmx467M  -XX:MetaspaceSize=500M -XX:+DisableExplicitGC -server -XX:-TieredCompilation -Xcomp -XX:+UseThirdPartyHeap -jar /usr/share/benchmarks/dacapo/dacapo-2006-10-MR2.jar hsqldb
===== DaCapo hsqldb starting =====
*********************************************************
* PseudoJDBCBench v1.1                                  *
*********************************************************

Scale factor value: 64
Number of clients: 20
Number of transactions per client: 40

Initializing dataset...DBMS: HSQL Database Engine
In transaction mode
        80000@°np <------------- arbitrary chars here
        160000¸¹I@°np
        240000@°np
        320000@°np
        400000Hv@°np
        480000,°
¦°      560000,ð
        640000@°np
done.

* Starting Benchmark Run *

* Benchmark Report *
* Featuring <direct queries> <auto-commit> 
--------------------
0 / 800 failed to complete.

* Benchmark Report *
* Featuring <direct queries> <transactions> 
--------------------
0 / 800 failed to complete.

* Benchmark Report *
* Featuring <prepared statements> <auto-commit> 
--------------------
0 / 800 failed to complete.

* Benchmark Report *
* Featuring <prepared statements> <transactions> 
--------------------
0 / 800 failed to complete.
Digest validation failed for stdout.log, expecting 0x68f2be9306913c92688b6b34f8454b6311de9310 found 0xe1c63e7ebfba743f51b565295a03897b091cc540
===== DaCapo hsqldb FAILED =====
Validation FAILED for hsqldb default

This bug won't show if we use other plans (NoGC, SemiSpace, MarkSweep). It won't show if we do not use -Xcomp (force compilation beforehand).

qinsoon commented 3 years ago

The bug also existed in ef24f49dd3979c6914805f7061e21ae29f886c7e, suggesting it was not introduced in the recent barrier fastpath commit. The bug can also be reproduced in the slowdebug build.

qinsoon commented 3 years ago

This seems related with full heap GC. If we force full heap GC, this bug will show up.

qinsoon commented 3 years ago

The problem in https://github.com/mmtk/mmtk-core/pull/429 was resulted by a mistake that introduced more full heap GCs. See https://github.com/mmtk/mmtk-core/pull/429#issuecomment-913264667. I suspect this issue is linked with full heap GCs.