Skip to content
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

Wayland + CachyOS, new crash 3.3.5 -> 3.3.6 #1039

Open
JakeTheDondorian opened this issue Jan 20, 2025 · 5 comments
Open

Wayland + CachyOS, new crash 3.3.5 -> 3.3.6 #1039

JakeTheDondorian opened this issue Jan 20, 2025 · 5 comments

Comments

@JakeTheDondorian
Copy link

Version

3.3.6

Platform

Linux x64

JDK

openJDK

Module

lwjgl

Bug description

Hello. recently updated to 3.3.6 and get new JVM crashes on linux.

I can't read these well. I've had crashes on both wayland and CatchyOs. 3.3.5 did not result in this crash. Adding the crash log.

https://limewire.com/?referrer=pq7i8xx7p2

Stacktrace or crash log output

#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x000077f20b6b0dde, pid=3786, tid=0x000077f2095ff6c0
#
# JRE version: OpenJDK Runtime Environment (8.0_412-b08) (build 1.8.0_412-412-b08)
# Java VM: OpenJDK 64-Bit Server VM (25.412-b08 mixed mode linux-amd64 compressed oops)
# Problematic frame:
# C  [libEGL_nvidia.so.0+0xb0dde]
#
# Core dump written. Default location: /home/arik/.local/share/Steam/steamapps/common/Songs of Syx/core or core.3786
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.java.com/bugreport/crash.jsp
#

---------------  T H R E A D  ---------------

Current thread is native thread

siginfo: si_signo: 11 (SIGSEGV), si_code: 1 (SEGV_MAPERR), si_addr: 0x0000000000000040

Registers:
RAX=0x0000000000000000, RBX=0x000077f208dfdf80, RCX=0x0000000000000001, RDX=0x000077f20b4d8cbc
RSP=0x000077f2095fea30, RBP=0x000077f2084dd040, RSI=0x0000000000000000, RDI=0x000077f2095fe9f0
R8 =0x00046c2381f957ee, R9 =0x0000000000000001, R10=0x3fffffffffffffff, R11=0x4000000000000000
R12=0x000077f20b4dd1a0, R13=0x000077f208dfe380, R14=0x000077f2084dd040, R15=0x000077f2084dd040
RIP=0x000077f20b6b0dde, EFLAGS=0x0000000000010202, CSGSFS=0x002b000000000033, ERR=0x0000000000000004
  TRAPNO=0x000000000000000e

Top of Stack: (sp=0x000077f2095fea30)
0x000077f2095fea30:   000077f20b4da0c0 000077f20a002a4a
0x000077f2095fea40:   000077f20b4da0c0 000077f209e27deb
0x000077f2095fea50:   000077f20b4d8cd0 0000000000018403
0x000077f2095fea60:   000077f2095ff6c0 0000000000000eca
0x000077f2095fea70:   000077f20b487140 0000000000000064
0x000077f2095fea80:   000077f2095fea90 000077f208dfe380
0x000077f2095fea90:   000077f20a003e30 fffffffffffffb68
0x000077f2095feaa0:   0000000000000000 000077f2367fb720
0x000077f2095feab0:   000077f208dff000 000077f20a004e0a
0x000077f2095feac0:   000077f2095ff6c0 000077f2095ffcdc
0x000077f2095fead0:   0000000000000000 000077f2390a0386
0x000077f2095feae0:   0000000000000000 000077f2095ff6c0
0x000077f2095feaf0:   000077f2095ff6c0 14bdcf411a7b5a2d
0x000077f2095feb00:   fffffffffffffb68 0000000000000000
0x000077f2095feb10:   000077f2367fb720 000077f208dff000
0x000077f2095feb20:   fb59ddfecfbb5a2d fb59bd5518c55a2d
0x000077f2095feb30:   0000000000000000 0000000000000000
0x000077f2095feb40:   0000000000000000 0000000000000000
0x000077f2095feb50:   0000000000000000 d59e21ecdb6f8300
0x000077f2095feb60:   000077f2390a0090 0000000000000000
0x000077f2095feb70:   fffffffffffffb68 000077f239121b0c
0x000077f2095feb80:   0000000000000000 0000000000000000
0x000077f2095feb90:   0000000000000000 0000000000000000
0x000077f2095feba0:   0000000000000000 0000000000000000
0x000077f2095febb0:   0000000000000000 0000000000000000
0x000077f2095febc0:   0000000000000000 0000000000000000
0x000077f2095febd0:   0000000000000000 0000000000000000
0x000077f2095febe0:   0000000000000000 0000000000000000
0x000077f2095febf0:   0000000000000000 0000000000000000
0x000077f2095fec00:   0000000000000000 0000000000000000
0x000077f2095fec10:   0000000000000000 0000000000000000
0x000077f2095fec20:   0000000000000000 0000000000000000 

Instructions: (pc=0x000077f20b6b0dde)
0x000077f20b6b0dbe:   c4 10 89 e8 5b 5d 41 5c c3 66 0f 1f 84 00 00 00
0x000077f20b6b0dce:   00 00 48 83 ec 08 bf 01 00 00 00 e8 82 60 ff ff
0x000077f20b6b0dde:   8b 70 40 48 8d 78 30 48 83 c4 08 e9 e2 a6 f8 ff
0x000077f20b6b0dee:   66 90 48 83 ec 18 48 8b 87 b0 04 00 00 ba 04 00 

Register to memory mapping:

RAX=0x0000000000000000 is an unknown value
RBX=0x000077f208dfdf80 is an unknown value
RCX=0x0000000000000001 is an unknown value
RDX=0x000077f20b4d8cbc: <offset 0x1ed8cbc> in /usr/lib/pressure-vessel/overrides/lib/x86_64-linux-gnu/libnvidia-eglcore.so.565.77 at 0x000077f209600000
RSP=0x000077f2095fea30 is an unknown value
RBP=0x000077f2084dd040 is an unknown value
RSI=0x0000000000000000 is an unknown value
RDI=0x000077f2095fe9f0 is an unknown value
R8 =0x00046c2381f957ee is an unknown value
R9 =0x0000000000000001 is an unknown value
R10=0x3fffffffffffffff is an unknown value
R11=0x4000000000000000 is an unknown value
R12=0x000077f20b4dd1a0: <offset 0x1edd1a0> in /usr/lib/pressure-vessel/overrides/lib/x86_64-linux-gnu/libnvidia-eglcore.so.565.77 at 0x000077f209600000
R13=0x000077f208dfe380 is an unknown value
R14=0x000077f2084dd040 is an unknown value
R15=0x000077f2084dd040 is an unknown value


Stack: [0x000077f208e00000,0x000077f209600000],  sp=0x000077f2095fea30,  free space=8186k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [libEGL_nvidia.so.0+0xb0dde]


---------------  P R O C E S S  ---------------

VM state:at safepoint (shutting down)

VM Mutex/Monitor currently owned by a thread:  ([mutex/lock_event])
[0x000077f2300082e0] Threads_lock - owner thread: 0x000077f230081800

heap address: 0x00000006c8c00000, size: 3956 MB, Compressed Oops mode: Zero based, Oop shift amount: 3
Narrow klass base: 0x0000000000000000, Narrow klass shift: 3
Compressed class space size: 1073741824 Address: 0x00000007c0000000

Heap:
 PSYoungGen      total 74240K, used 3779K [0x000000076d980000, 0x0000000772c00000, 0x00000007c0000000)
  eden space 64000K, 5% used [0x000000076d980000,0x000000076dd30cf0,0x0000000771800000)
  from space 10240K, 0% used [0x0000000771800000,0x0000000771800000,0x0000000772200000)
  to   space 10240K, 0% used [0x0000000772200000,0x0000000772200000,0x0000000772c00000)
 ParOldGen       total 169472K, used 18330K [0x00000006c8c00000, 0x00000006d3180000, 0x000000076d980000)
  object space 169472K, 10% used [0x00000006c8c00000,0x00000006c9de6b00,0x00000006d3180000)
 Metaspace       used 10732K, capacity 11016K, committed 11264K, reserved 1058816K
  class space    used 1054K, capacity 1195K, committed 1280K, reserved 1048576K

Card table byte_map: [0x000077f235085000,0x000077f235840000] byte_map_base: 0x000077f231a3f000

Marking Bits: (ParMarkBitMap*) 0x000077f237799ec0
 Begin Bits: [0x000077f1f8460000, 0x000077f1fc230000)
 End Bits:   [0x000077f1fc230000, 0x000077f200000000)

Polling page: 0x000077f239418000

CodeCache: size=245760Kb used=5622Kb max_used=5626Kb free=240137Kb
 bounds [0x000077f221000000, 0x000077f221590000, 0x000077f230000000]
 total_blobs=2704 nmethods=1678 adapters=939
 compilation: enabled

Compilation events (10 events):
Event: 67.459 Thread 0x000077f2300cc000 nmethod 1674 0x000077f22157d290 code [0x000077f22157d500, 0x000077f22157e158]
Event: 67.468 Thread 0x000077f2300c5000 nmethod 1675 0x000077f22157ab90 code [0x000077f22157ad20, 0x000077f22157b1d8]
Event: 67.469 Thread 0x000077f2300c9800 nmethod 1676 0x000077f22157f810 code [0x000077f22157f9a0, 0x000077f22157fe78]
Event: 67.473 Thread 0x000077f2300cc000 1677       3       snake2d.util.sprite.text.Font::getEndIndex (194 bytes)
Event: 67.475 Thread 0x000077f2300cc000 nmethod 1677 0x000077f2215823d0 code [0x000077f221582620, 0x000077f221583178]
Event: 67.477 Thread 0x000077f2300c8000 nmethod 1673 0x000077f221583610 code [0x000077f221583840, 0x000077f221584338]
Event: 67.506 Thread 0x000077f2300cc000 1678       3       launcher.LSettings$SStrings::get (17 bytes)
Event: 67.506 Thread 0x000077f2300cc000 nmethod 1678 0x000077f22157a7d0 code [0x000077f22157a940, 0x000077f22157aaf0]
Event: 67.974 Thread 0x000077f2300cc000 1679       3       java.lang.System::lineSeparator (4 bytes)
Event: 67.974 Thread 0x000077f2300cc000 nmethod 1679 0x000077f22157f510 code [0x000077f22157f660, 0x000077f22157f7b0]

GC Heap History (4 events):
Event: 3.439 GC heap before
{Heap before GC invocations=1 (full 0):
 PSYoungGen      total 74240K, used 54951K [0x000000076d980000, 0x0000000772c00000, 0x00000007c0000000)
  eden space 64000K, 85% used [0x000000076d980000,0x0000000770f29c78,0x0000000771800000)
  from space 10240K, 0% used [0x0000000772200000,0x0000000772200000,0x0000000772c00000)
  to   space 10240K, 0% used [0x0000000771800000,0x0000000771800000,0x0000000772200000)
 ParOldGen       total 169472K, used 0K [0x00000006c8c00000, 0x00000006d3180000, 0x000000076d980000)
  object space 169472K, 0% used [0x00000006c8c00000,0x00000006c8c00000,0x00000006d3180000)
 Metaspace       used 10566K, capacity 10856K, committed 11264K, reserved 1058816K
  class space    used 1049K, capacity 1163K, committed 1280K, reserved 1048576K
Event: 3.462 GC heap after
Heap after GC invocations=1 (full 0):
 PSYoungGen      total 74240K, used 10226K [0x000000076d980000, 0x0000000772c00000, 0x00000007c0000000)
  eden space 64000K, 0% used [0x000000076d980000,0x000000076d980000,0x0000000771800000)
  from space 10240K, 99% used [0x0000000771800000,0x00000007721fc928,0x0000000772200000)
  to   space 10240K, 0% used [0x0000000772200000,0x0000000772200000,0x0000000772c00000)
 ParOldGen       total 169472K, used 8609K [0x00000006c8c00000, 0x00000006d3180000, 0x000000076d980000)
  object space 169472K, 5% used [0x00000006c8c00000,0x00000006c9468618,0x00000006d3180000)
 Metaspace       used 10566K, capacity 10856K, committed 11264K, reserved 1058816K
  class space    used 1049K, capacity 1163K, committed 1280K, reserved 1048576K
}
Event: 3.462 GC heap before
{Heap before GC invocations=2 (full 1):
 PSYoungGen      total 74240K, used 10226K [0x000000076d980000, 0x0000000772c00000, 0x00000007c0000000)
  eden space 64000K, 0% used [0x000000076d980000,0x000000076d980000,0x0000000771800000)
  from space 10240K, 99% used [0x0000000771800000,0x00000007721fc928,0x0000000772200000)
  to   space 10240K, 0% used [0x0000000772200000,0x0000000772200000,0x0000000772c00000)
 ParOldGen       total 169472K, used 8609K [0x00000006c8c00000, 0x00000006d3180000, 0x000000076d980000)
  object space 169472K, 5% used [0x00000006c8c00000,0x00000006c9468618,0x00000006d3180000)
 Metaspace       used 10566K, capacity 10856K, committed 11264K, reserved 1058816K
  class space    used 1049K, capacity 1163K, committed 1280K, reserved 1048576K
Event: 3.535 GC heap after
Heap after GC invocations=2 (full 1):
 PSYoungGen      total 74240K, used 0K [0x000000076d980000, 0x0000000772c00000, 0x00000007c0000000)
  eden space 64000K, 0% used [0x000000076d980000,0x000000076d980000,0x0000000771800000)
  from space 10240K, 0% used [0x0000000771800000,0x0000000771800000,0x0000000772200000)
  to   space 10240K, 0% used [0x0000000772200000,0x0000000772200000,0x0000000772c00000)
 ParOldGen       total 169472K, used 18330K [0x00000006c8c00000, 0x00000006d3180000, 0x000000076d980000)
  object space 169472K, 10% used [0x00000006c8c00000,0x00000006c9de6b00,0x00000006d3180000)
 Metaspace       used 10566K, capacity 10856K, committed 11264K, reserved 1058816K
  class space    used 1049K, capacity 1163K, committed 1280K, reserved 1048576K
}

Deoptimization events (10 events):
Event: 66.473 Thread 0x000077f2313d0800 Uncommon trap: reason=unstable_if action=reinterpret pc=0x000077f2214982f8 method=java.lang.StrictMath.floorOrCeil(DDDD)D @ 115
Event: 67.440 Thread 0x000077f2313d0800 Uncommon trap: reason=class_check action=maybe_recompile pc=0x000077f2214b5468 method=snake2d.VboSpriteOpti.render(Lsnake2d/util/sprite/TextureCoords;Lsnake2d/util/sprite/TextureCoords;IIIILsnake2d/util/color/COLOR;Lsnake2d/util/color/OPACITY;)V @ 154
Event: 67.440 Thread 0x000077f2313d0800 Uncommon trap: reason=class_check action=maybe_recompile pc=0x000077f2214b5468 method=snake2d.VboSpriteOpti.render(Lsnake2d/util/sprite/TextureCoords;Lsnake2d/util/sprite/TextureCoords;IIIILsnake2d/util/color/COLOR;Lsnake2d/util/color/OPACITY;)V @ 154
Event: 67.440 Thread 0x000077f2313d0800 Uncommon trap: reason=class_check action=maybe_recompile pc=0x000077f2214b5468 method=snake2d.VboSpriteOpti.render(Lsnake2d/util/sprite/TextureCoords;Lsnake2d/util/sprite/TextureCoords;IIIILsnake2d/util/color/COLOR;Lsnake2d/util/color/OPACITY;)V @ 154
Event: 67.440 Thread 0x000077f2313d0800 Uncommon trap: reason=class_check action=maybe_recompile pc=0x000077f2214b5468 method=snake2d.VboSpriteOpti.render(Lsnake2d/util/sprite/TextureCoords;Lsnake2d/util/sprite/TextureCoords;IIIILsnake2d/util/color/COLOR;Lsnake2d/util/color/OPACITY;)V @ 154
Event: 67.440 Thread 0x000077f2313d0800 Uncommon trap: reason=class_check action=maybe_recompile pc=0x000077f2214cc540 method=snake2d.VboSpriteOpti.render(Lsnake2d/util/sprite/TextureCoords;Lsnake2d/util/sprite/TextureCoords;IIIILsnake2d/util/color/COLOR;Lsnake2d/util/color/OPACITY;)V @ 154
Event: 67.440 Thread 0x000077f2313d0800 Uncommon trap: reason=class_check action=maybe_recompile pc=0x000077f2214cb9cc method=snake2d.VboSpriteOpti.render(Lsnake2d/util/sprite/TextureCoords;Lsnake2d/util/sprite/TextureCoords;IIIILsnake2d/util/color/COLOR;Lsnake2d/util/color/OPACITY;)V @ 154
Event: 67.441 Thread 0x000077f2313d0800 Uncommon trap: reason=unstable_if action=reinterpret pc=0x000077f22155230c method=snake2d.util.sprite.text.Font.getEndIndex(Ljava/lang/CharSequence;IIID)I @ 80
Event: 67.441 Thread 0x000077f2313d0800 Uncommon trap: reason=unstable_if action=reinterpret pc=0x000077f22155538c method=snake2d.util.sprite.text.Font.getEndIndex(Ljava/lang/CharSequence;IIID)I @ 80
Event: 67.456 Thread 0x000077f2313d0800 Uncommon trap: reason=class_check action=maybe_recompile pc=0x000077f2214c4db8 method=snake2d.VboSpriteOpti.render(Lsnake2d/util/sprite/TextureCoords;Lsnake2d/util/sprite/TextureCoords;IIIILsnake2d/util/color/COLOR;Lsnake2d/util/color/OPACITY;)V @ 154
@Spasi
Copy link
Member

Spasi commented Jan 20, 2025

Hey @JakeTheDondorian,

3.3.6 didn't change anything wrt Wayland/EGL. It was 3.3.5 that made EGL the default context management API when Wayland is detected.

There's no way to tell what might be wrong from the crash log above. When does it happen? On program start, exit, randomly? Any chance you could post a minimal program that reproduces the crash?

@JakeTheDondorian
Copy link
Author

Hey @JakeTheDondorian,

3.3.6 didn't change anything wrt Wayland/EGL. It was 3.3.5 that made EGL the default context management API when Wayland is detected.

There's no way to tell what might be wrong from the crash log above. When does it happen? On program start, exit, randomly? Any chance you could post a minimal program that reproduces the crash?

I would like to know that too. First context is spawned in a child process (a launcher). When they click play, this context is destroyed, and the parent process launches its context. So it can be either in the destruction, or creation of a new context.

The last crash-free version might actually have been 3.3.4.

I understand this is likely impossible to pin down, but I took a chance you could see something in the log. Maybe it's something about callback registering, not getting cleaned up. Call-backs do get mentioned a lot.

Event: 67.974 loading class java/util/IdentityHashMap$IdentityHashMapIterator done
Event: 67.974 loading class java/util/IdentityHashMap$KeyIterator done
Event: 67.975 Thread 0x000077f2313d0800 Thread exited: 0x000077f2313d0800
Event: 67.990 loading class org/lwjgl/glfw/Callbacks
Event: 67.990 loading class org/lwjgl/glfw/Callbacks done
Event: 68.005 loading class java/lang/Shutdown
Event: 68.005 loading class java/lang/Shutdown done
Event: 68.005 loading class java/lang/Shutdown$Lock
Event: 68.005 loading class java/lang/Shutdown$Lock done
Event: 68.005 Executing VM operation: Exit

@IMS212
Copy link

IMS212 commented Jan 20, 2025

This is a common issue I have experienced with Minecraft on Wayland. It's caused by NVIDIA's broken threaded optimizations; try putting __GL_THREADED_OPTIMIZATIONS=0 in your environmen t variables.

@Wunderharke
Copy link

This is a common issue I have experienced with Minecraft on Wayland. It's caused by NVIDIA's broken threaded optimizations; try putting __GL_THREADED_OPTIMIZATIONS=0 in your environmen t variables.

Indeed solves that. So this is an upstream Nvidia driver bug? Is this likely to be fixed anytime soon?

@ArikRahman
Copy link

ArikRahman commented Jan 21, 2025

I added export __GL_THREADED_OPTIMIZATIONS=0 to .zshrc file, that did not change non-launch error on songs of syx. Am I putting it in the right place?

I also put __GL_THREADED_OPTIMIZATIONS=0 in /etc/environment

EDIT: I forgot to source .zshrc lol. It works now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants