openj9 icon indicating copy to clipboard operation
openj9 copied to clipboard

Fix JIT System.nanoTime() in checkpoint mode

Open ymanton opened this issue 2 years ago • 10 comments

The attached patches

  1. Fix the x86 codegen's System.nanoTime() implementation to do the right thing in checkpoint mode
  2. Disable the Z codegen's implementation in checkpoint mode until it can be fixed to do the right thing
  3. Add a test case to check that JIT compiled code containing calls to System.nanoTime() behaves as expected in checkpoint mode

Fixes #15513

ymanton avatar Jul 25 '22 15:07 ymanton

@r30shah can you look at the Z changes in particular?

ymanton avatar Jul 25 '22 15:07 ymanton

@0xdaryl can you or someone else familiar with the x86 codegen look at that part?

ymanton avatar Jul 25 '22 15:07 ymanton

I've

  • added a new JIT FE query that uses isCRIUSupportEnabled.
  • split the test case in two to verify that compilation before and after the C/R transition work as expected.

ymanton avatar Jul 27 '22 14:07 ymanton

Jenkins test sanity.functional xlinuxcriu jdk11

ymanton avatar Aug 08 '22 20:08 ymanton

One failure, but it doesn't look related to timing or checkpoint/restore functionality. #15617 was recently merged and looks related. @mpirvu does this crash look familiar?

[2022-08-08T22:58:01.867Z] ===============================================
[2022-08-08T22:58:01.867Z] Running test pthreadDestructor_0 ...
[2022-08-08T22:58:01.867Z] ===============================================
...
[2022-08-08T22:58:01.868Z] Assertion failed at /home/jenkins/workspace/Build_JDK11_x86-64_linux_criu_Personal/openj9/runtime/compiler/env/J9SharedCache.cpp:699: false
[2022-08-08T22:58:01.868Z] VMState: 0x00050080
[2022-08-08T22:58:01.868Z] 	Shared cache pointer 0x7f3c426155d0 out of bounds
[2022-08-08T22:58:01.868Z] compiling sun/util/locale/LanguageTag.parseVariants(Lsun/util/locale/StringTokenIterator;Lsun/util/locale/ParseStatus;)Z at level: warm
[2022-08-08T22:58:01.868Z] #0: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x8af2b5) [0x7f3e066d32b5]
[2022-08-08T22:58:01.868Z] #1: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x8ba660) [0x7f3e066de660]
[2022-08-08T22:58:01.868Z] #2: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x583bbe) [0x7f3e063a7bbe]
[2022-08-08T22:58:01.868Z] #3: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x58533d) [0x7f3e063a933d]
[2022-08-08T22:58:01.868Z] #4: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x206944) [0x7f3e0602a944]
[2022-08-08T22:58:01.868Z] #5: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x443177) [0x7f3e06267177]
[2022-08-08T22:58:01.868Z] #6: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x443c33) [0x7f3e06267c33]
[2022-08-08T22:58:01.868Z] #7: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x443c5f) [0x7f3e06267c5f]
[2022-08-08T22:58:01.868Z] #8: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x44bd9f) [0x7f3e0626fd9f]
[2022-08-08T22:58:01.868Z] #9: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x2824ed) [0x7f3e060a64ed]
[2022-08-08T22:58:01.868Z] #10: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x55c529) [0x7f3e06380529]
[2022-08-08T22:58:01.868Z] #11: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x54285c) [0x7f3e0636685c]
[2022-08-08T22:58:01.868Z] #12: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x14aaef) [0x7f3e05f6eaef]
[2022-08-08T22:58:01.868Z] #13: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x14bb54) [0x7f3e05f6fb54]
[2022-08-08T22:58:01.868Z] #14: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9prt29.so(+0x2b573) [0x7f3e0c90b573]
[2022-08-08T22:58:01.868Z] #15: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x149279) [0x7f3e05f6d279]
[2022-08-08T22:58:01.868Z] #16: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x1498c0) [0x7f3e05f6d8c0]
[2022-08-08T22:58:01.868Z] #17: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x1483f3) [0x7f3e05f6c3f3]
[2022-08-08T22:58:01.868Z] #18: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x1488d2) [0x7f3e05f6c8d2]
[2022-08-08T22:58:01.868Z] #19: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x148982) [0x7f3e05f6c982]
[2022-08-08T22:58:01.868Z] #20: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9prt29.so(+0x2b573) [0x7f3e0c90b573]
[2022-08-08T22:58:01.868Z] #21: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x148db2) [0x7f3e05f6cdb2]
[2022-08-08T22:58:01.868Z] #22: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9thr29.so(+0xe4f2) [0x7f3e0c6d34f2]
[2022-08-08T22:58:01.868Z] #23: /lib/x86_64-linux-gnu/libpthread.so.0(+0x76ba) [0x7f3e0e6cf6ba]
[2022-08-08T22:58:01.868Z] #24: /lib/x86_64-linux-gnu/libc.so.6(clone+0x6d) [0x7f3e0dff051d]
[2022-08-08T22:58:01.868Z] 
[2022-08-08T22:58:01.868Z] #0: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x8af2b5) [0x7f3e066d32b5]
[2022-08-08T22:58:01.868Z] #1: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x8ba660) [0x7f3e066de660]
[2022-08-08T22:58:01.869Z] #2: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x1369f9) [0x7f3e05f5a9f9]
[2022-08-08T22:58:01.869Z] #3: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9prt29.so(+0x2aa3a) [0x7f3e0c90aa3a]
[2022-08-08T22:58:01.869Z] #4: /lib/x86_64-linux-gnu/libpthread.so.0(+0x11390) [0x7f3e0e6d9390]
[2022-08-08T22:58:01.869Z] #5: /lib/x86_64-linux-gnu/libpthread.so.0(raise+0x29) [0x7f3e0e6d9269]
[2022-08-08T22:58:01.869Z] #6: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x5852b7) [0x7f3e063a92b7]
[2022-08-08T22:58:01.869Z] #7: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x585342) [0x7f3e063a9342]
[2022-08-08T22:58:01.869Z] #8: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x206944) [0x7f3e0602a944]
[2022-08-08T22:58:01.869Z] #9: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x443177) [0x7f3e06267177]
[2022-08-08T22:58:01.869Z] #10: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x443c33) [0x7f3e06267c33]
[2022-08-08T22:58:01.869Z] #11: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x443c5f) [0x7f3e06267c5f]
[2022-08-08T22:58:01.869Z] #12: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x44bd9f) [0x7f3e0626fd9f]
[2022-08-08T22:58:01.869Z] #13: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x2824ed) [0x7f3e060a64ed]
[2022-08-08T22:58:01.869Z] #14: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x55c529) [0x7f3e06380529]
[2022-08-08T22:58:01.869Z] #15: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x54285c) [0x7f3e0636685c]
[2022-08-08T22:58:01.869Z] #16: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x14aaef) [0x7f3e05f6eaef]
[2022-08-08T22:58:01.869Z] #17: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x14bb54) [0x7f3e05f6fb54]
[2022-08-08T22:58:01.869Z] #18: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9prt29.so(+0x2b573) [0x7f3e0c90b573]
[2022-08-08T22:58:01.869Z] #19: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x149279) [0x7f3e05f6d279]
[2022-08-08T22:58:01.869Z] #20: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x1498c0) [0x7f3e05f6d8c0]
[2022-08-08T22:58:01.869Z] #21: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x1483f3) [0x7f3e05f6c3f3]
[2022-08-08T22:58:01.869Z] #22: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x1488d2) [0x7f3e05f6c8d2]
[2022-08-08T22:58:01.869Z] #23: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x148982) [0x7f3e05f6c982]
[2022-08-08T22:58:01.869Z] #24: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9prt29.so(+0x2b573) [0x7f3e0c90b573]
[2022-08-08T22:58:01.869Z] #25: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9jit29.so(+0x148db2) [0x7f3e05f6cdb2]
[2022-08-08T22:58:01.869Z] #26: /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/lib/default/libj9thr29.so(+0xe4f2) [0x7f3e0c6d34f2]
[2022-08-08T22:58:01.869Z] #27: /lib/x86_64-linux-gnu/libpthread.so.0(+0x76ba) [0x7f3e0e6cf6ba]
[2022-08-08T22:58:01.869Z] #28: /lib/x86_64-linux-gnu/libc.so.6(clone+0x6d) [0x7f3e0dff051d]
[2022-08-08T22:58:01.869Z] Unhandled exception
[2022-08-08T22:58:01.869Z] Type=Unhandled trap vmState=0x00050080
[2022-08-08T22:58:01.869Z] J9Generic_Signal_Number=00000108 Signal_Number=00000005 Error_Value=00000000 Signal_Code=fffffffa
[2022-08-08T22:58:01.869Z] Handler1=00007F3E0CBAFF50 Handler2=00007F3E0C90A810
[2022-08-08T22:58:01.869Z] RDI=00000000000045B8 RSI=00000000000045BB RAX=0000000000000000 RBX=00007F3E080EBCD0
[2022-08-08T22:58:01.869Z] RCX=00007F3E0E6D9269 RDX=0000000000000005 R8=000000000000FFFF R9=0000000000000001
[2022-08-08T22:58:01.869Z] R10=00007F3E0DF75370 R11=0000000000000206 R12=00007F3C7BFFA830 R13=00007F3C426155D0
[2022-08-08T22:58:01.869Z] R14=00007F3E080EBCD0 R15=0000000000000000
[2022-08-08T22:58:01.869Z] RIP=00007F3E0E6D9269 GS=0000 FS=0000 RSP=00007F3C6BF6D3F8
[2022-08-08T22:58:01.869Z] EFlags=0000000000000206 CS=0033 RBP=0000000012BFFF10 ERR=0000000000000007
[2022-08-08T22:58:01.869Z] TRAPNO=000000000000000E OLDMASK=0000000000000000 CR2=00007FEC08B6D080
[2022-08-08T22:58:01.869Z] xmm0 0000000000000000 (f: 0.000000, d: 0.000000e+00)
[2022-08-08T22:58:01.869Z] xmm1 3933373237343939 (f: 926169408.000000, d: 3.700792e-33)
[2022-08-08T22:58:01.869Z] xmm2 0000000000000000 (f: 0.000000, d: 0.000000e+00)
[2022-08-08T22:58:01.869Z] xmm3 ffff000000000000 (f: 0.000000, d: -nan)
[2022-08-08T22:58:01.869Z] xmm4 0000000000000000 (f: 0.000000, d: 0.000000e+00)
[2022-08-08T22:58:01.869Z] xmm5 0000000000000000 (f: 0.000000, d: 0.000000e+00)
[2022-08-08T22:58:01.869Z] xmm6 0000000000000000 (f: 0.000000, d: 0.000000e+00)
[2022-08-08T22:58:01.869Z] xmm7 00007f3c6bf76f50 (f: 1811378048.000000, d: 6.911854e-310)
[2022-08-08T22:58:01.869Z] xmm8 6f6c2f6c6974752f (f: 1769239808.000000, d: 5.341566e+228)
[2022-08-08T22:58:01.870Z] xmm9 3f40520c1c0c1c38 (f: 470555712.000000, d: 4.980621e-04)
[2022-08-08T22:58:01.870Z] xmm10 3b460f0c1b460e07 (f: 457575936.000000, d: 3.649319e-23)
[2022-08-08T22:58:01.870Z] xmm11 000000003c075284 (f: 1007112832.000000, d: 4.975799e-315)
[2022-08-08T22:58:01.870Z] xmm12 0000000040400000 (f: 1077936128.000000, d: 5.325712e-315)
[2022-08-08T22:58:01.870Z] xmm13 0000000000000000 (f: 0.000000, d: 0.000000e+00)
[2022-08-08T22:58:01.870Z] xmm14 0000000000000000 (f: 0.000000, d: 0.000000e+00)
[2022-08-08T22:58:01.870Z] xmm15 0000000000000000 (f: 0.000000, d: 0.000000e+00)
[2022-08-08T22:58:01.870Z] Module=/lib/x86_64-linux-gnu/libpthread.so.0
[2022-08-08T22:58:01.870Z] Module_base_address=00007F3E0E6C8000 Symbol=raise
[2022-08-08T22:58:01.870Z] Symbol_address=00007F3E0E6D9240
[2022-08-08T22:58:01.870Z] 
[2022-08-08T22:58:01.870Z] Method_being_compiled=sun/util/locale/LanguageTag.parseVariants(Lsun/util/locale/StringTokenIterator;Lsun/util/locale/ParseStatus;)Z
[2022-08-08T22:58:01.870Z] Target=2_90_20220808_75 (Linux 4.4.0-170-generic)
[2022-08-08T22:58:01.870Z] CPU=amd64 (4 logical CPUs) (0x5e2f07000 RAM)
[2022-08-08T22:58:01.870Z] ----------- Stack Backtrace -----------
[2022-08-08T22:58:01.870Z] raise+0x29 (0x00007F3E0E6D9269 [libpthread.so.0+0x11269])
[2022-08-08T22:58:01.870Z] _ZN2TR4trapEv+0x47 (0x00007F3E063A92B7 [libj9jit29.so+0x5852b7])
[2022-08-08T22:58:01.870Z]  (0x00007F3E063A9342 [libj9jit29.so+0x585342])
[2022-08-08T22:58:01.870Z] _ZN16TR_J9SharedCache30offsetInSharedCacheFromPointerEPv.localalias.284+0xa4 (0x00007F3E0602A944 [libj9jit29.so+0x206944])
[2022-08-08T22:58:01.870Z] _ZN20TR_IPBCDataCallGraph20createPersistentCopyEP16TR_J9SharedCacheP24TR_IPBCDataStorageHeaderPN2TR14PersistentInfoE+0x1e7 (0x00007F3E06267177 [libj9jit29.so+0x443177])
[2022-08-08T22:58:01.870Z] _ZN12TR_IProfiler17createBalancedBSTEPmiimPN2TR11CompilationE+0xc3 (0x00007F3E06267C33 [libj9jit29.so+0x443c33])
[2022-08-08T22:58:01.870Z] _ZN12TR_IProfiler17createBalancedBSTEPmiimPN2TR11CompilationE+0xef (0x00007F3E06267C5F [libj9jit29.so+0x443c5f])
[2022-08-08T22:58:01.870Z] _ZN12TR_IProfiler19persistIprofileInfoEPN2TR20ResolvedMethodSymbolEP17TR_ResolvedMethodPNS0_11CompilationE+0x5ef (0x00007F3E0626FD9F [libj9jit29.so+0x44bd9f])
[2022-08-08T22:58:01.870Z] _ZN24TR_J9ByteCodeIlGenerator5genILEv+0x1ad (0x00007F3E060A64ED [libj9jit29.so+0x2824ed])
[2022-08-08T22:58:01.870Z] _ZN3OMR20ResolvedMethodSymbol5genILEP11TR_FrontEndPN2TR11CompilationEPNS3_20SymbolReferenceTableERNS3_12IlGenRequestE+0x2a9 (0x00007F3E06380529 [libj9jit29.so+0x55c529])
[2022-08-08T22:58:01.870Z] _ZN3OMR11Compilation7compileEv+0x1dc (0x00007F3E0636685C [libj9jit29.so+0x54285c])
[2022-08-08T22:58:01.870Z] _ZN2TR28CompilationInfoPerThreadBase7compileEP10J9VMThreadPNS_11CompilationEP17TR_ResolvedMethodR11TR_J9VMBaseP19TR_OptimizationPlanRKNS_16SegmentAllocatorE+0x4bf (0x00007F3E05F6EAEF [libj9jit29.so+0x14aaef])
[2022-08-08T22:58:01.870Z] _ZN2TR28CompilationInfoPerThreadBase14wrappedCompileEP13J9PortLibraryPv+0x314 (0x00007F3E05F6FB54 [libj9jit29.so+0x14bb54])
[2022-08-08T22:58:01.870Z] omrsig_protect+0x1e3 (0x00007F3E0C90B573 [libj9prt29.so+0x2b573])
[2022-08-08T22:58:01.870Z] _ZN2TR28CompilationInfoPerThreadBase7compileEP10J9VMThreadP21TR_MethodToBeCompiledRN2J917J9SegmentProviderE+0x309 (0x00007F3E05F6D279 [libj9jit29.so+0x149279])
[2022-08-08T22:58:01.870Z] _ZN2TR24CompilationInfoPerThread12processEntryER21TR_MethodToBeCompiledRN2J917J9SegmentProviderE+0x1c0 (0x00007F3E05F6D8C0 [libj9jit29.so+0x1498c0])
[2022-08-08T22:58:01.870Z] _ZN2TR24CompilationInfoPerThread14processEntriesEv+0x3b3 (0x00007F3E05F6C3F3 [libj9jit29.so+0x1483f3])
[2022-08-08T22:58:01.870Z] _ZN2TR24CompilationInfoPerThread3runEv+0x42 (0x00007F3E05F6C8D2 [libj9jit29.so+0x1488d2])
[2022-08-08T22:58:01.870Z] _Z30protectedCompilationThreadProcP13J9PortLibraryPN2TR24CompilationInfoPerThreadE+0x82 (0x00007F3E05F6C982 [libj9jit29.so+0x148982])
[2022-08-08T22:58:01.870Z] omrsig_protect+0x1e3 (0x00007F3E0C90B573 [libj9prt29.so+0x2b573])
[2022-08-08T22:58:01.870Z] _Z21compilationThreadProcPv+0x1d2 (0x00007F3E05F6CDB2 [libj9jit29.so+0x148db2])
[2022-08-08T22:58:01.870Z] thread_wrapper+0x162 (0x00007F3E0C6D34F2 [libj9thr29.so+0xe4f2])
[2022-08-08T22:58:01.870Z] start_thread+0xca (0x00007F3E0E6CF6BA [libpthread.so.0+0x76ba])
[2022-08-08T22:58:01.870Z] clone+0x6d (0x00007F3E0DFF051D [libc.so.6+0x10751d])
[2022-08-08T22:58:01.870Z] ---------------------------------------
[2022-08-08T22:58:01.870Z] JVMDUMP039I Processing dump event "gpf", detail "" at 2022/08/08 18:58:01 - please wait.
...

ymanton avatar Aug 09 '22 19:08 ymanton

I'll have a look as the failure looks related to my changes.

mpirvu avatar Aug 09 '22 21:08 mpirvu

I talked to Irwin and he doesn't see how the pointer we get from rememberClass() can be outside the SCC bounds. I speculated that this may somehow happen in CRIU mode if we are unlucky to checkpoint at the wrong moment, but that doesn't seem to be possible.

mpirvu avatar Aug 09 '22 22:08 mpirvu

It doesn't look like this test does any checkpointing at all.

ymanton avatar Aug 09 '22 22:08 ymanton

Tried to reproduce this problem here: https://openj9-jenkins.osuosl.org/job/Grinder/1240/ but tests passed

mpirvu avatar Aug 10 '22 01:08 mpirvu

50 runs of the problematic test passed (https://openj9-jenkins.osuosl.org/job/Grinder/1243/). Irwin also pointed out that the address flagged by the assert is actually within SCC bounds, so at this point we cannot explain the assert. This PR can be delivered.

mpirvu avatar Aug 10 '22 16:08 mpirvu

19:10:31  Testing: Create CRIU checkpoint image and restore three times - testSystemNanoTimeJitPreCheckpointCompile
19:10:31  Test start time: 2022/08/08 19:10:31 Eastern Standard Time
19:10:31  Running command: bash /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/aqa-tests/TKG/../../jvmtest/functional/cmdLineTests/criu/criuScript.sh /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/aqa-tests/TKG/../../jvmtest/functional/cmdLineTests/criu /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/bin/java " -Xjit -XX:+CRIURestoreNonPortableMode " "org.openj9.criu.TimeChangeTest testSystemNanoTimeJitPreCheckpointCompile" 3 3 false
19:10:31  Time spent starting: 8 milliseconds
19:10:39  Time spent executing: 6957 milliseconds
19:10:39  Test result: PASSED
19:10:39  
19:10:39  Testing: Create CRIU checkpoint image and restore three times - testSystemNanoTimeJitPostCheckpointCompile
19:10:39  Test start time: 2022/08/08 19:10:38 Eastern Standard Time
19:10:39  Running command: bash /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/aqa-tests/TKG/../../jvmtest/functional/cmdLineTests/criu/criuScript.sh /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/aqa-tests/TKG/../../jvmtest/functional/cmdLineTests/criu /home/jenkins/workspace/Test_openjdk11_j9_sanity.functional_x86-64_linux_criu_Personal_testList_1/openjdkbinary/j2sdk-image/bin/java " -Xjit -XX:+CRIURestoreNonPortableMode " "org.openj9.criu.TimeChangeTest testSystemNanoTimeJitPostCheckpointCompile" 3 3 false
19:10:39  Time spent starting: 7 milliseconds
19:10:45  Time spent executing: 6958 milliseconds
19:10:45  Test result: PASSED
19:10:45  

All new criu tests are working as expected.

Will merge now

tajila avatar Aug 10 '22 20:08 tajila