Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 9 Aug 2015 14:20:16 +0300
From:      Konstantin Belousov <kostikbel@gmail.com>
To:        Jan Beich <jbeich@FreeBSD.org>
Cc:        gecko@freebsd.org
Subject:   Re: firefox 40 crashes
Message-ID:  <20150809112016.GJ2072@kib.kiev.ua>
In-Reply-To: <tws9-bays-wny@FreeBSD.org>
References:  <20150808102223.GZ2072@kib.kiev.ua> <tws9-bays-wny@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Aug 09, 2015 at 01:46:03AM +0200, Jan Beich wrote:
> Konstantin Belousov <kostikbel@gmail.com> writes:
> 
> > I rushed to upgrade the firefox port due to reported pdf issues, and
> > I get a source of serious troubles.  All this happens on the up to date
> > stable/10 amd64 machine, all ports are from HEAD and also up to date.
> 
> Even if I did update to 39.0.3 which only fixed pdf issues this would
> still came up in less than a week. 40.0 official announcment is
> scheduled for 2015-08-11 when new vulnerabilities would be disclosed.
> The release candidate currently used will likely be the final version.
> 
> If you rush for security fixes it's good to have more of them, right?
> 
> > Updated firefox crashes randomly, usually in several minutes after the
> > startup. I ensured that there is no ABI-incompatible libraries linked
> > or loaded by the binary (e.g. libc++ and libstdc++, lib/compat/pkg-
> > originated libs etc). The dumped core' backtrace shows that there was
> > something wrong in libxul.so, so I enabled debugging in the ports
> > options and recompiled the firefox.
> >
> > Now, the browser does not even starts.  The following is printed on
> > the startup:
> 
> I don't recommend using DEBUG option. It does too much (sanity checks,
> online backtrace, non-optimized codepaths, tampers CFLAGS, debug
> symbols, etc) which makes firefox too verbose with false positives and
> known issues mixed in. Some debugging features maybe unstable on FreeBSD.
> 
> Better manually add symbols with the following in make.conf (or Makefile.local)
> 
>   STRIP = # empty
>   CFLAGS += -g -fno-omit-frame-pointer
>   OPTIONS_UNSET += OPTIMIZED_CFLAGS
> 
> As for the crash I suspect OMTC related to our use of system cairo which
> is not tested upstream. In the past system version caused issues like
> broken build, rendering artifacts and runtime warnings. So, try
> 
>   # www/firefox/Makefile.local
>   USE_MOZILLA += -cairo # use bundled cairo
> 
> with and without the following patch (or just tweak pref in about:config)
> 
> --- modules/libpref/moz.build.orig	2015-08-06 22:39:34 UTC
> +++ modules/libpref/moz.build
> @@ -42,5 +42,6 @@ FINAL_LIBRARY = 'xul'
>  
>  DEFINES['OS_ARCH'] = CONFIG['OS_ARCH']
>  DEFINES['MOZ_WIDGET_TOOLKIT'] = CONFIG['MOZ_WIDGET_TOOLKIT']
> +DEFINES['MOZ_TREE_CAIRO'] = CONFIG['MOZ_TREE_CAIRO']
>  
>  FAIL_ON_WARNINGS = True
> --- modules/libpref/init/all.js.orig	2015-08-06 22:39:34 UTC
> +++ modules/libpref/init/all.js
> @@ -4052,7 +4052,12 @@ pref("layers.max-active", -1);
>  pref("layers.tiles.adjust", true);
>  
>  // Set the default values, and then override per-platform as needed
> +#ifdef MOZ_TREE_CAIRO
>  pref("layers.offmainthreadcomposition.enabled", true);
> +#else
> +// OMTC causes frequent crashes with system cairo
> +pref("layers.offmainthreadcomposition.enabled", false);
> +#endif
>  // Compositor target frame rate. NOTE: If vsync is enabled the compositor
>  // frame rate will still be capped.
>  // -1 -> default (match layout.frame_rate or 60 FPS)


It seems that just flipping the layers.offmainthreadcomposition.enabled
in the about:config is enough to get usable browser.  It stays for a hour
already, while before it dumped core in not more than 10 minutes.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20150809112016.GJ2072>