Summary: | media-gfx/blender-3.3.0: Crash on startup, possibly due to mixing LLVM 14 or 15 | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Joshua Goins <josh> |
Component: | Current packages | Assignee: | Paul Zander <negril.nx+gentoo> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | bearcatsandor, darkdefende, leonchik1976, luke5083, proxy-maint, roland, sam |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
See Also: | https://bugs.gentoo.org/show_bug.cgi?id=821955 | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: |
output of emerge --info
blender 3.3 backtrace blender 3.1.2 backtrace blender-3.3-build-log.txt.xz equery u blender output blender 3.3 llvm 15+16 backtrace |
Description
Joshua Goins
2022-11-10 00:18:08 UTC
Created attachment 830245 [details]
blender 3.3 backtrace
Created attachment 830247 [details]
blender 3.1.2 backtrace
Created attachment 830249 [details]
blender-3.3-build-log.txt.xz
Created attachment 830251 [details]
equery u blender output
It's mixing LLVM 14 and LLVM 15, yeah :( Sadly I can't really do anything about this. I've filed a ticket about this last year here: https://bugs.gentoo.org/821955 At one point I was thinking about doing a manual ldd in the install phase to see if multiple llvm versions were linked in and error out if that was the case. However this does not catch the mesa llvm version. In addition to that, one could update mesa and the llvm version after the the package has been installed and get crashes that way. So I'm starting to think that static linking is the only way out of this. (This is what the official Blender build do) You should be able to work around this by unmasking a newer version of osl. It will be built with llvm 15. Thank you, I had a suspicion that Blender was statically linking LLVM (it explains why their binaries are like 250+ mb!) I thought I had unmasked osl, but I’ll check again when I can get back to my computer. Yes, using osl ~amd64 and then recompiling both blender versions fixed it. Thank you! For some reason, I can only mark this as "RESOLVED" (which isn't really the right option, I thought there was more?), I'll leave that up to your discretion :-) I think we can leave it open in case someone else with the same issue ends up here. It's happening now also with LLVM-15 vs. LLVM-16 (~amd64). As before, blender with USE=-osl fixes it for me. Can confirm with LLVM 15 and 16 (~amd64). Using "-osl" makes it finally start, but rendering a benchmark scene produces a segmentation fault with the usual backtrace #1 0x... in () at /usr/lib/llvm/16/lib64/libLLVM-16.so (In reply to Lorenzo Bertini from comment #12) > Can confirm with LLVM 15 and 16 (~amd64). Using "-osl" makes it finally > start, but rendering a benchmark scene produces a segmentation fault with > the usual backtrace > #1 0x... in () at /usr/lib/llvm/16/lib64/libLLVM-16.so Could you perhaps build Blender with debug flags so we can see where it is crashing? Created attachment 865610 [details]
blender 3.3 llvm 15+16 backtrace
This still happens with the current gentoo repository. Blender appears to use both LLVM 15 and LLVM 16 at the same time, and segmentation faults on startup.
I have another Gentoo system which does not have LLVM 16 installed yet, and the segmentation fault does not reproduce there. It seems the best/only workaround for this is: cat <<EOF> /etc/portage/package.mask/llvm >=sys-devel/llvm-16 >=sys-devel/clang-16 >=sys-devel/llvmgold-16 >=sys-devel/llvm-common-16 EOF emerge --unmerge '>=sys-devel/llvm-16' '>=sys-devel/clang-16' '>sys-devel/llvmgold-16' revdep-rebuild # rebuilds mesa in particular emerge --depclean After doing this, blender starts without a Segmentation Fault, and does not crash while rendering. It would be convenient if the blender and/or osl ebuild were able to entirely prevent the installation of llvm-16 until osl catches up. commit d6af608ad3b3519f7cbd4e4158afbb7c979d887c Author: Sebastian Parborg <darkdefende@gmail.com> Date: Sun Jul 2 23:06:55 2023 +0200 media-gfx/blender: Disable OSL support per default Because llvm 16 is now marked stable, there is a very high chance of users having Blender sefault on startup because of missmatched llvm libraries. Signed-off-by: Sebastian Parborg <darkdefende@gmail.com> Signed-off-by: Sam James <sam@gentoo.org> The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5618de75aec49009489efb560a89e014fd060524 commit 5618de75aec49009489efb560a89e014fd060524 Author: Michał Górny <mgorny@gentoo.org> AuthorDate: 2024-02-05 19:29:36 +0000 Commit: Michał Górny <mgorny@gentoo.org> CommitDate: 2024-02-10 10:47:23 +0000 llvm-r1.eclass: Initial version Bug: https://bugs.gentoo.org/923228 Bug: https://bugs.gentoo.org/880671 Closes: https://bugs.gentoo.org/821955 Closes: https://bugs.gentoo.org/919150 Signed-off-by: Michał Górny <mgorny@gentoo.org> eclass/llvm-r1.eclass | 250 ++++++++++++++++++++++++++++++++++++++++++++++++ eclass/tests/llvm-r1.sh | 151 +++++++++++++++++++++++++++++ 2 files changed, 401 insertions(+) building media-gfx/blender-4.0.2 with USE=osl fails with error: Cycles OSL requires WITH_LLVM, the library may not have been found. Configure LLVM or disable WITH_CYCLES_OSL is this related to current issue? This should be handled by.. commit 175d65e779e69e5702ca52cb3af973a2fa0b0e62 (HEAD -> master, origin/master, origin/HEAD) Author: Paul Zander <negril.nx+gentoo@gmail.com> Date: Thu Mar 28 23:08:25 2024 +0100 media-gfx/blender: add 4.0.2-r1, cleanup hopefully fixed osl build re-added hip flag in 4.0.2-r1 hide test code in release versions Bug: https://bugs.gentoo.org/693200 Closes: https://bugs.gentoo.org/925534 Closes: https://bugs.gentoo.org/927281 Closes: https://bugs.gentoo.org/927715 Closes: https://bugs.gentoo.org/927835 Closes: https://bugs.gentoo.org/927931 Signed-off-by: Paul Zander <negril.nx+gentoo@gmail.com> Closes: https://github.com/gentoo/gentoo/pull/35973 Signed-off-by: Sam James <sam@gentoo.org> ... which introduces use of llvm-r1.eclass. The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d4f66b668bb1255e8935d962cdac30a1af9e00c6 commit d4f66b668bb1255e8935d962cdac30a1af9e00c6 Author: Paul Zander <negril.nx+gentoo@gmail.com> AuthorDate: 2024-06-29 13:53:51 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2024-06-29 16:49:13 +0000 media-gfx/blender: 4.1.1-r1, 9999 propagate LLVM_SLOT to hip Bug: https://bugs.gentoo.org/880671 Signed-off-by: Paul Zander <negril.nx+gentoo@gmail.com> Signed-off-by: Sam James <sam@gentoo.org> media-gfx/blender/blender-4.1.1-r1.ebuild | 9 ++++++++- media-gfx/blender/blender-9999.ebuild | 9 ++++++++- 2 files changed, 16 insertions(+), 2 deletions(-) |