https://kotlinlang.org logo
Title
v

Vadim Kapustin

01/29/2021, 6:44 AM
I make a simple compose application (LazyColumn with Text, Buttons and LinearProgressIndicator in the rows). When I make it in Linux everything worked fine. But when I compiled it for Windows on the same computer and run, I got an fatal error in JRE. Compose version 0.3.0-build143. Another Compose application with a more complex interface worked fine with this version of Compose and with the previous ones. I try compile the project with different variants of JDK (liberica-14, liberica-15, adopt-openj9-15). This error occurs in different moments: while changing the progress bar or at the moment of a simple button click... JVM save different report files but they all have the same beginning:
Host: Intel(R) Core(TM) i3-7100 CPU @ 3.90GHz, 4 cores, 7G, Windows 7 , 64 bit Build 7601 (6.1.7601.24441)
Time: Fri Jan 29 08:56:28 2021 RTZ 2 (ceia) elapsed time: 104.855095 seconds (0d 0h 1m 44s)
--------------- T H R E A D ---------------
Current thread (0x0000000025190410): JavaThread "Cleaner-0" daemon [_thread_in_native, id=6984, stack(0x00000000257a0000,0x00000000258a0000)]
Stack: [0x00000000257a0000,0x00000000258a0000], sp=0x000000002589ec58, free space=1019k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C [OPENGL32.dll+0xdd004]
Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
J 2346 org.jetbrains.skija.impl.Managed._nInvokeFinalizer(JJ)V (0 bytes) @ 0x0000000013cc22f4 [0x0000000013cc22a0+0x0000000000000054]
J 4012 c2 org.jetbrains.skija.impl.Managed$CleanerThunk.run()V (31 bytes) @ 0x0000000013da2bf4 [0x0000000013da2ba0+0x0000000000000054]
J 3738 c2 jdk.internal.ref.PhantomCleanable.clean()V java.base@15.0.2 (16 bytes) @ 0x0000000013d72b64 [0x0000000013d728a0+0x00000000000002c4]
j jdk.internal.ref.CleanerImpl.run()V+77 java.base@15.0.2
j java.lang.Thread.run()V+11 java.base@15.0.2
j jdk.internal.misc.InnocuousThread.run()V+20 java.base@15.0.2
v ~StubRoutines::call_stub
siginfo: EXCEPTION_ACCESS_VIOLATION (0xc0000005), reading address 0x0000000000000828
How to find a solution to this problem?
j

jim

01/29/2021, 7:48 AM
Wow, I can already tell, this one is going to be a fun one to try and debug. 😩 It looks like maybe a native reference is getting free'd a little too early or free'd twice or something; almost certainly a bug in Skija. Does it fail consistently, or do you sometimes need to perform the action (button press, scroll bar move, etc) multiple times in order for the crash to occur? Can you create a simplified repro and post it to github or something so we can try to reproduce on our machines?
o

olonho

01/29/2021, 7:54 AM
Please create an issue with reproducer, it’s hard to decide without additional information
v

Vadim Kapustin

01/29/2021, 7:55 AM
I tried just pressing the buttons, without run progress - everything is fine. I think this happens after the changes in the progress indicator. This can happen during a change, or after the changes are finished, but when you click a button. The more indicators are running, the faster the app crashes. I'll try to find another computer now and check on it. Then I will publish this app on Bitbucket, and try to make issue
:tnx: 1
@olonho, @jim I try to run application on different computer (but the same OS: Windows 7 64-bit) - the same result. The crash may occur after a few clicks, or it may not occur for a long time. It occurs more often after the progress indicator is worked out and then click on some button. Demo application: https://bitbucket.org/Vadim303/simpletimer/src/master/ I make the issue: https://github.com/JetBrains/compose-jb/issues/327
i

Igor Demin

01/29/2021, 1:17 PM
It seems that somehow this is fixed in 0.3.0-build146 🤔
v

Vadim Kapustin

01/29/2021, 1:33 PM
I rebuild with 0.3.0-build146 and try to crash... The app is still working. At least it works much more stable 🙂👍
Wish: make announcements about new builds. At least in slack 😄
i

Igor Demin

01/29/2021, 1:39 PM
make announcements about new builds. At least in slack
There an issue 🙂 https://github.com/JetBrains/compose-jb/issues/300 After this you can see new versions in github notifications
👍 3