Summary: | www-client/firefox-71.0 - firefox: JavaScript error: , line 0: UnknownError: The operation failed for reasons unrelated to the database itself and not covered by any other error code. | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | klaus818 |
Component: | Current packages | Assignee: | Mozilla Gentoo Team <mozilla> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | gentoo.wayne, herrtimson, jana, jasmin+gentoo, mail, main.haarp, nagrigoriadis, poncho, redneb, slyfox, ziyad_fox |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
URL: | https://bugzilla.mozilla.org/show_bug.cgi?id=1601707 | ||
See Also: | https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92831 | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 915000 | ||
Attachments: | upstream patch to fix part 1 non addon corrections. |
Description
klaus818
2019-12-03 09:00:24 UTC
Same problem here after compiling firefox-71.0. Just in case it helps, in gdb I can see the following: Thread 44 "IndexedDB #1" received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7fffd6cff700 (LWP 4601)] 0x00007fffefafd70e in ?? () from /usr/lib64/firefox/libxul.so I compiled Firefox with GCC 9.2.0. Just started to recompile with the debug use flag. I'm seeing this too with gcc 9.2.0/lto. It does run if compiled with clang (9.0) though. The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=22503797645e16dc5f82bf2233d1c7e5dc407c7e commit 22503797645e16dc5f82bf2233d1c7e5dc407c7e Author: Thomas Deutschmann <whissi@gentoo.org> AuthorDate: 2019-12-03 12:48:47 +0000 Commit: Thomas Deutschmann <whissi@gentoo.org> CommitDate: 2019-12-03 12:48:47 +0000 www-client/firefox: Disable PGO when GCC is used due to startup crash Bug: https://bugs.gentoo.org/701866 Package-Manager: Portage-2.3.80, Repoman-2.3.19 Signed-off-by: Thomas Deutschmann <whissi@gentoo.org> www-client/firefox/firefox-71.0.ebuild | 4 ++++ 1 file changed, 4 insertions(+) (In reply to Søren Dalby Larsen from comment #2) > I'm seeing this too with gcc 9.2.0/lto. It does run if compiled with clang > (9.0) though. Thanks, I'm recompiling to try it and confirm. Recompiled with USE=-pgo but it still segfaults. I can confirm that the problem is solved after compiling with clang (enable clang use flag). I also kept the pgo and lto use flags enabled. I know it's not the proper place to make that question but I need to ask: is it better to keep the clang use flag as permanent? Or in other words: is it better to compile firefox (in general, not for that specific version) with clang or with gcc? Thank you in advance and sorry for the inapropiate question. PD: and also sorry for my bad english :P. That's a question of faith: For me, GCC 9.x PGO support is currently superior to Clang. However, upstream picked Clang (and therefore Clang+PGO is tested upstream) because they have to support not just Linux and cannot upgrade GCC on their build cluster for some reason. So their Clang version is superior to their GCC version... :) (In reply to Thomas Deutschmann from comment #7) > That's a question of faith: For me, GCC 9.x PGO support is currently > superior to Clang. However, upstream picked Clang (and therefore Clang+PGO > is tested upstream) because they have to support not just Linux and cannot > upgrade GCC on their build cluster for some reason. So their Clang version > is superior to their GCC version... :) Thank you for your quick and detailed answer :). I also prefere GCC 9.x with PGO (which has a really good performance) because almost all my system (which includes the Firefox's dependencies) is built with GCC. So my conclusion is the same than a few months ago: I'll keep the GCC as my first option and Clang will be the second option, just in case that GCC fails. *** Bug 701934 has been marked as a duplicate of this bug. *** (In reply to Tomasz Golinski from comment #5) > Recompiled with USE=-pgo but it still segfaults. Testing with -pgo +lto shows that lto is likely causes the problem, and pgo forces the usage of lto. -lto works for me on gcc. Not sure if related but I'm getting an extremely similar startup error with what seems like: -clang -pgo -lto, though I do also have custom-cflags custom-optimization hwaccel JavaScript error: resource://services-common/kinto-offline-client.js, line 603: Error: IndexedDB clear() The operation failed for reasons unrelated to the database itself and not covered by any other error code. console.error: PushService: stateChangeProcessEnqueue: Error transitioning state UnknownError JavaScript error: resource://gre/modules/ExtensionUtils.jsm, line 0: Error: An unexpected error occurred I'm also seeing some VERY odd behavior with addons unable to save settings whenever I try and edit certain preferences anytime after starting the browser, (downloadthemall preferences, specifically). I'm sure there are more, as this seems like a pretty consistent line failing. JavaScript error: resource://gre/modules/ExtensionUtils.jsm, line 0: Error: An unexpected error occurred This whole thing was built with: Installed versions: 71.0^td(09:46:29 PM 12/03/2019)(custom-cflags custom-optimization gmp-autoupdate hwaccel pulseaudio screenshot startup-notification system-av1 system-harfbuzz system-icu system-jpeg system-libevent system-libvpx system-sqlite system-webp -bindist -clang -debug -eme-free -geckodriver -hardened -jack -lto -pgo -selinux -test -wayland -wifi CPU_FLAGS_ARM="-neon" CPU_FLAGS_X86="-avx2" L10N="-ach -af -an -ar -ast -az -be -bg -bn -br -bs -ca -cak -cs -cy -da -de -dsb -el -en-CA -en-GB -eo -es-AR -es-CL -es-ES -es-MX -et -eu -fa -ff -fi -fr -fy -ga -gd -gl -gn -gu -he -hi -hr -hsb -hu -hy -ia -id -is -it -ja -ka -kab -kk -km -kn -ko -lij -lt -lv -mk -mr -ms -my -nb -nl -nn -oc -pa -pl -pt-BR -pt-PT -rm -ro -ru -si -sk -sl -son -sq -sr -sv -ta -te -th -tr -uk -ur -uz -vi -xh -zh-CN -zh-TW") I'm retrying with clang to see if it improves significantly. Update: Rebuilding my previous firefox-71.0 with clang fixed all issues, and I was able to maintain all my previous flags. It seems -lto -pgo wasn't enough for gcc-9.2.0 if additional problems had occurred? -lto and -pgo is enough fpr gcc-9.2.0. With this flags I can build it without problems and it run without problems. (In reply to JetDog from comment #12) > Update: Rebuilding my previous firefox-71.0 with clang fixed all issues, and > I was able to maintain all my previous flags. > > It seems -lto -pgo wasn't enough for gcc-9.2.0 if additional problems had > occurred? Not sure, but I think that your problems could be related with the custom-cflags and custom-optimization use flags. Those use flags are a kind of "critical" since nobody will test your custom cflags and your custom optimizations but you. So it isn't recommended to enable the custom-cflags and custom-optimization use flags. In order to confirm if that's the case, you could try to recompile with -custom-cflags -custom-optimization -clang -lto -pgo and see what happens. > I'm also seeing some VERY odd behavior with addons unable to save settings
> whenever I try and edit certain preferences anytime after starting the
> browser, (downloadthemall preferences, specifically). I'm sure there are
> more, as this seems like a pretty consistent line failing.
>
> JavaScript error: resource://gre/modules/ExtensionUtils.jsm, line 0: Error:
> An unexpected error occurred
Addons were broken for me when compiling with gcc-9.2.0
After enabling USE=clang (and changing nothing else) the addons were working again.
www-client/firefox-71.0::gentoo was built with the following:
USE="clang gmp-autoupdate pulseaudio screenshot startup-notification system-av1 system-harfbuzz system-icu system-jpeg system-libevent system-sqlite system-webp -bindist -custom-cflags -custom-optimization -debug -eme-free -geckodriver -hardened -hwaccel -jack -lto -pgo (-selinux) -system-libvpx -test -wayland -wifi" ABI_X86="(64)" CPU_FLAGS_X86="avx2"
For me only every vpn-addon was broken. All other addons works without problems. And this is the same under windows. So I don't think, that I can solve this problem with changing the compiler, but I try. I rebuild firefox with clang. pgo and lto is working. But the same with my vpn-addons. I have also hit this bug with sys-devel/gcc-9.2.0-r2 and USE="lto -clang -pgo", with FF segfaulting at startup. It is able to start successfully when rebuilt without the "lto" USE flag set. Same error occurs with -lto -pgo -custom-cflags -custom-optimization: Installed versions: 71.0^td(05:47:04 PM 12/04/2019)(gmp-autoupdate hwaccel pulseaudio screenshot startup-notification system-av1 system-harfbuzz system-icu system-jpeg system-libevent system-libvpx system-sqlite system-webp -bindist -clang -custom-cflags -custom-optimization -debug -eme-free -geckodriver -hardened -jack -lto -pgo -selinux -test -wayland -wifi CPU_FLAGS_ARM="-neon" CPU_FLAGS_X86="avx2" L10N="-ach -af -an -ar -ast -az -be -bg -bn -br -bs -ca -cak -cs -cy -da -de -dsb -el -en-CA -en-GB -eo -es-AR -es-CL -es-ES -es-MX -et -eu -fa -ff -fi -fr -fy -ga -gd -gl -gn -gu -he -hi -hr -hsb -hu -hy -ia -id -is -it -ja -ka -kab -kk -km -kn -ko -lij -lt -lv -mk -mr -ms -my -nb -nl -nn -oc -pa -pl -pt-BR -pt-PT -rm -ro -ru -si -sk -sl -son -sq -sr -sv -ta -te -th -tr -uk -ur -uz -vi -xh -zh-CN -zh-TW") console.error: PushService: stateChangeProcessEnqueue: Error transitioning state UnknownError Log warning: The log 'Services.Common.RESTRequest' is configured to use the preference 'services.common.log.logger.rest.request' - you must adjust the level by setting this preference, not by using the level setter JavaScript error: resource://gre/modules/ExtensionUtils.jsm, line 0: Error: An unexpected error occurred JavaScript error: resource://gre/modules/ExtensionUtils.jsm, line 0: Error: An unexpected error occurred Attempting to edit Preferences in "DownloadThemAll" extension results in: JavaScript error: resource://gre/modules/ExtensionUtils.jsm, line 0: Error: An unexpected error occurred "DownloadThemALl" preferences do not appear as last set by the user, after re-opening its preferences. It seems like we have a legit gcc 9.2.0 bug? Only remaining thing I have enabled here that i don't think I have on by default is hwaccel. We may have to make a recommendation for people to switch to USE="clang" in the meantime. I'm also seeing that I can't save new greasemonkey scripts with the GCC variant when using the same use flags from my previous comment. Something really screwy is going on with firefox-71.0 and GCC. It might be this one you're all hitting? https://bugzilla.mozilla.org/show_bug.cgi?id=1601707 there's also a gcc bug mentioned in the comments Yes, that's the issue. Thank you for sharing. The patch got commited to trunk in the meantime, it applies cleanly on top of gcc-9.2.0-r2. That might be worth a shot to test if it fixes the problem? I can't help that much, as I'm still bound to esr. Also clang-6 seems affected. Created attachment 598778 [details, diff]
upstream patch to fix part 1 non addon corrections.
If someone feels like testing and giving their feedback would be appreciated. I have recompiled with the attached patch and javascript errors are gone except for addons.
(In reply to tt_1 from comment #23) > The patch got commited to trunk in the meantime, it applies cleanly on top > of gcc-9.2.0-r2. That might be worth a shot to test if it fixes the problem? It applies cleanly, but then doesn't compile. The fixed the error not able to find build_local_temp by making it visible from tree.c. However, after rebuilding Firefox I was disappointed to see that the crash persisted. :( PS: Ok, I guess I'm experiencing a different crash because neither of these patches solve the issue. Please disregard my previous comment then. (In reply to Jory A. Pratt from comment #24) > Created attachment 598778 [details, diff] [details, diff] > upstream patch to fix part 1 non addon corrections. > > If someone feels like testing and giving their feedback would be > appreciated. I have recompiled with the attached patch and javascript errors > are gone except for addons. It works for me (USE="-clang custom-cflags custom-optimization lto pgo"). Without this patch I couldn’t emerge www-client/firefox-71.0 using GCC 9.2. Also, I managed to emerge Firefox using CLang (USE="clang custom-cflags custom-optimization lto pgo"). I tried to use GCC without this patch without any luck. Tried "-clang -lot -pgo", and "-clang -custom-cflags -custom-optimization -lto -pgo". Either it won’t emerge (in the case of USE="-clang pgo lto"), or it will emerge successfully but will SIGFAULT every time I try to run it). In both cases (using CLang and using GCC with this patch) all my add-ons are working as expected (uMatrix, Stylus, Old Reddit Redirect, disable-polymer-youtube, PwdHash2, and Greasemonkey) with a slight note that I lost all Greasemonkey scripts that were installed; but managed to restore them from a backup (Greasemonkey_backup_2019MMDD_HHmmss.zip) and it works like it should be. My system is stable with a few packages in package.accept_keywords: -mostly multimedia (ffmpeg, mpv, dav1d) -net-misc/youtube-dl -xfce-*/* -media-fonts/* Hope this helps. Thanks. Ziyad. The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c40cc87ed9378492d84a2c6c5e45fa3d399ba7a2 commit c40cc87ed9378492d84a2c6c5e45fa3d399ba7a2 Author: Jory Pratt <anarchy@gentoo.org> AuthorDate: 2019-12-09 23:51:50 +0000 Commit: Jory Pratt <anarchy@gentoo.org> CommitDate: 2019-12-09 23:52:11 +0000 www-client/firefox: Fix segfault with gcc lto builds Closes: https://bugs.gentoo.org/show_bug.cgi?id=701866 Package-Manager: Portage-2.3.81, Repoman-2.3.20 Signed-off-by: Jory Pratt <anarchy@gentoo.org> .../files/mozilla-bug1601707-gcc-fixup.patch | 114 +++++++++++++++++++++ www-client/firefox/firefox-71.0.ebuild | 1 + 2 files changed, 115 insertions(+) The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=089f2a1adee4dbc672b3a9295978efcef8b9d98e commit 089f2a1adee4dbc672b3a9295978efcef8b9d98e Author: Thomas Deutschmann <whissi@gentoo.org> AuthorDate: 2019-12-10 00:00:35 +0000 Commit: Thomas Deutschmann <whissi@gentoo.org> CommitDate: 2019-12-10 00:00:35 +0000 www-client/firefox: re-enable PGO Bug: https://bugs.gentoo.org/701866 Package-Manager: Portage-2.3.81, Repoman-2.3.20 Signed-off-by: Thomas Deutschmann <whissi@gentoo.org> www-client/firefox/firefox-71.0.ebuild | 4 ---- 1 file changed, 4 deletions(-) *** Bug 702418 has been marked as a duplicate of this bug. *** The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=16cba686662653bf738d51935c4acc3370cd35df commit 16cba686662653bf738d51935c4acc3370cd35df Author: Thomas Deutschmann <whissi@gentoo.org> AuthorDate: 2019-12-16 19:24:07 +0000 Commit: Thomas Deutschmann <whissi@gentoo.org> CommitDate: 2019-12-16 19:24:25 +0000 www-client/firefox: rev bump to force rebuild Rebuild is required to fix firefox for everyone using GCC who didn't notice yet that firefox wasn't properly working. Bug: https://bugs.gentoo.org/701866 Package-Manager: Portage-2.3.81, Repoman-2.3.20 Signed-off-by: Thomas Deutschmann <whissi@gentoo.org> www-client/firefox/{firefox-71.0.ebuild => firefox-71.0-r1.ebuild} | 0 1 file changed, 0 insertions(+), 0 deletions(-) there's now a backport available for gcc-9 in pr92831 The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/proj/gcc-patches.git/commit/?id=ba1c1c9ab955b533393e343bdfd8a0e7d7650639 commit ba1c1c9ab955b533393e343bdfd8a0e7d7650639 Author: Sergei Trofimovich <slyfox@gentoo.org> AuthorDate: 2019-12-22 00:04:55 +0000 Commit: Sergei Trofimovich <slyfox@gentoo.org> CommitDate: 2019-12-22 00:04:55 +0000 9.2.0: backport PR92831 (':?' lifetime extension) It's a backport of upstream commit 59693b226e245aeb99. Bug: https://gcc.gnu.org/PR92831 Bug: https://bugs.gentoo.org/701866 Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org> 9.2.0/gentoo/33_all_extend-lifetime.patch | 240 ++++++++++++++++++++++++++++++ 9.2.0/gentoo/README.history | 1 + 2 files changed, 241 insertions(+) The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/proj/gcc-patches.git/commit/?id=35beff919bc59076c5c1aa549e04d8119c559261 commit 35beff919bc59076c5c1aa549e04d8119c559261 Author: Sergei Trofimovich <slyfox@gentoo.org> AuthorDate: 2019-12-22 11:07:00 +0000 Commit: Sergei Trofimovich <slyfox@gentoo.org> CommitDate: 2019-12-22 11:07:00 +0000 9.2.0: cut 4 patchset 4 new patches: - 27_all_sparc-PIC-constant-PR91472.patch: fix PIC register alocation (bug detected by gmp test suite) - 31_all_openmp-for-SEGV.patch: fix opemnmp for loop condition folding - 32_all_sparc-PIC-constant-part2.patch: fix PIC register allocation (bug detected by python regressin) - 33_all_extend-lifetime.patch: fix lifetime extension on ':?' operator (bug detected by firefox LTO build Bug: https://gcc.gnu.org/PR91472 Bug: https://bugs.gentoo.org/699938 Bug: https://gcc.gnu.org/PR92504 Bug: https://bugs.gentoo.org/697708 Bug: https://gcc.gnu.org/PR92095 Bug: https://bugs.gentoo.org/701866 Bug: https://gcc.gnu.org/PR92831 Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org> 9.2.0/gentoo/README.history | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=649ef16ea81488d36fae3fa4a8881c9e665d2e7a commit 649ef16ea81488d36fae3fa4a8881c9e665d2e7a Author: Sergei Trofimovich <slyfox@gentoo.org> AuthorDate: 2019-12-22 11:24:45 +0000 Commit: Sergei Trofimovich <slyfox@gentoo.org> CommitDate: 2019-12-22 11:28:34 +0000 sys-devel/gcc: 9.2.0: cut 4 patchset 4 new patches: - 27_all_sparc-PIC-constant-PR91472.patch: fix PIC register alocation (bug detected by gmp test suite) - 31_all_openmp-for-SEGV.patch: fix opemnmp for loop condition folding - 32_all_sparc-PIC-constant-part2.patch: fix PIC register allocation (bug detected by python regressin) - 33_all_extend-lifetime.patch: fix lifetime extension on ':?' operator (bug detected by firefox LTO build Bug: https://gcc.gnu.org/PR91472 Bug: https://bugs.gentoo.org/699938 Bug: https://gcc.gnu.org/PR92504 Bug: https://bugs.gentoo.org/697708 Bug: https://gcc.gnu.org/PR92095 Bug: https://bugs.gentoo.org/701866 Bug: https://gcc.gnu.org/PR92831 Package-Manager: Portage-2.3.82, Repoman-2.3.20 Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org> sys-devel/gcc/Manifest | 1 + sys-devel/gcc/gcc-9.2.0-r3.ebuild | 19 +++++++++++++++++++ 2 files changed, 20 insertions(+) Should be fixed in gcc-9.2.0-r3 as well. |