Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 628340 - www-client/firefox[pgo] : Text corruption on GCC 6
Summary: www-client/firefox[pgo] : Text corruption on GCC 6
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Mozilla Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-08-19 22:46 UTC by Nick Sarnie
Modified: 2019-03-31 20:06 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Screenshot of Firefox garbled (firefox-garbled.png,428.31 KB, image/png)
2017-08-21 22:08 UTC, Lee Trager
Details
video demonstrating the bug (bug_demo.mkv,341.83 KB, video/x-matroska)
2017-09-01 06:54 UTC, Matt Whitlock
Details
dep graph (file_628340.txt,4.14 KB, text/plain)
2017-09-06 11:11 UTC, William
Details
Screen shot of different font corrupution (corrupt-fonts.png,162.88 KB, image/png)
2017-10-01 11:01 UTC, Peter Asplund
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nick Sarnie gentoo-dev 2017-08-19 22:46:34 UTC
Hi all,
I experience text corruption when setting the PGO useflag on Firefox. I'm using Firefox 55 now. My use flags are below. Please note that I still experience the corruption when using -custom-cflags and -custom-optimization.


Thanks,
Sarnex

www-client/firefox-55.0.1::gentoo was built with the following:
USE="custom-cflags custom-optimization dbus gmp-autoupdate hwaccel pulseaudio startup-notification system-libvpx -bindist -debug -hardened -jack (-neon) -nsplugin -pgo (-selinux) (-system-cairo) -system-harfbuzz -system-icu -system-jpeg -system-libevent -system-sqlite -test -wifi" ABI_X86="(64)" L10N="-ach -af -an -ar -as -ast -az -bg -bn-BD -bn-IN -br -bs -ca -cak -cs -cy -da -de -dsb -el -en-GB -en-ZA -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 -id -is -it -ja -ka -kab -kk -km -kn -ko -lij -lt -lv -mai -mk -ml -mr -ms -nb -nl -nn -or -pa -pl -pt-BR -pt-PT -rm -ro -ru -si -sk -sl -son -sq -sr -sv -ta -te -th -tr -uk -uz -vi -xh -zh-CN -zh-TW"
CFLAGS="-march=native -pipe"
CXXFLAGS="-march=native -pipe -fno-delete-null-pointer-checks -fno-lifetime-dse -fno-schedule-insns2"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,-rpath=/usr/lib64/firefox,--enable-new-dtags"
Comment 1 Nick Sarnie gentoo-dev 2017-08-19 22:47:17 UTC
Current GCC is 6.4.0 but I experienced it on 6.3.0 also.
Comment 2 Jory A. Pratt gentoo-dev 2017-08-20 20:12:06 UTC
Please enable system-harfbuzz system-jpeg and re-emerge so we can determine if it is breakage in bundled libs or not.
Comment 3 Nick Sarnie gentoo-dev 2017-08-21 01:03:58 UTC
(In reply to Jory A. Pratt from comment #2)
> Please enable system-harfbuzz system-jpeg and re-emerge so we can determine
> if it is breakage in bundled libs or not.

The issue persists with +system-harfbuzz +system-jpeg
Comment 4 Lee Trager 2017-08-21 22:08:51 UTC
Created attachment 490042 [details]
Screenshot of Firefox garbled

Attached is a screenshot showing the issue. If a I type in the comment box, text looks fine until I hit space.
Comment 5 Nick Sarnie gentoo-dev 2017-08-21 23:19:26 UTC
I can confirm I see the same corruption as Lee
Comment 6 Lee Trager 2017-08-23 01:52:22 UTC
Recompiling with gcc 5.4.0 fixes the garbled text for me.
Comment 7 Andrew Savchenko gentoo-dev 2017-08-23 07:58:29 UTC
Nick, are you sure that gcc-6.4.0 has this issue with custom-cflags and custom-optimization disabled? Check your gcc-config -l before rebuilding.

It is known that ( >=gcc-6.0 <=gcc-6.3 ) causes garbled fonts with PGO enabled, but it was reported that gcc-6.4 fixes this issue: https://bugs.gentoo.org/show_bug.cgi?id=617690#c35

Have you tried patch provided in the bug above? It is now in upstream, but tagged as firefox-57: https://hg.mozilla.org/mozilla-central/rev/97dae871389b

If it works for you, I'll backport it to the tree.
Comment 8 Jory A. Pratt gentoo-dev 2017-08-23 11:18:18 UTC
(In reply to Andrew Savchenko from comment #7)
> Nick, are you sure that gcc-6.4.0 has this issue with custom-cflags and
> custom-optimization disabled? Check your gcc-config -l before rebuilding.
> 
> It is known that ( >=gcc-6.0 <=gcc-6.3 ) causes garbled fonts with PGO
> enabled, but it was reported that gcc-6.4 fixes this issue:
> https://bugs.gentoo.org/show_bug.cgi?id=617690#c35
> 
> Have you tried patch provided in the bug above? It is now in upstream, but
> tagged as firefox-57: https://hg.mozilla.org/mozilla-central/rev/97dae871389b
> 
> If it works for you, I'll backport it to the tree.
Gonna be hard to backport anything when it is already a part of the firefox patchset.
Comment 9 Andrew Savchenko gentoo-dev 2017-08-23 12:40:13 UTC
(In reply to Jory A. Pratt from comment #8)
> Gonna be hard to backport anything when it is already a part of the firefox
> patchset.

Ah, damn, sorry, I missed that. Now its strange that bug happens again. I need some way to reproduce it :/
Comment 10 Nick Sarnie gentoo-dev 2017-08-24 02:11:19 UTC
(In reply to Andrew Savchenko from comment #7)
> Nick, are you sure that gcc-6.4.0 has this issue with custom-cflags and
> custom-optimization disabled? Check your gcc-config -l before rebuilding.
> 
> It is known that ( >=gcc-6.0 <=gcc-6.3 ) causes garbled fonts with PGO
> enabled, but it was reported that gcc-6.4 fixes this issue:
> https://bugs.gentoo.org/show_bug.cgi?id=617690#c35
> 
> Have you tried patch provided in the bug above? It is now in upstream, but
> tagged as firefox-57: https://hg.mozilla.org/mozilla-central/rev/97dae871389b
> 
> If it works for you, I'll backport it to the tree.

Hi Andrew,

I just recompiled with +pgo -custom-optimization -custom-cflags and confirmed that I still experience the corruption. I only have GCC 6.4.0 installed, and gcc -config -l run on both user and root reflect GCC 6.4.0 is selected.

Let me know if you have any other ideas.


Thanks,
Sarnex
Comment 11 Andrew Savchenko gentoo-dev 2017-08-24 08:04:01 UTC
(In reply to Nick Sarnie from comment #10)
> Let me know if you have any other ideas.

Try to remove -march=native for testing. I experienced in the past weird gcc bugs due to -march=native. (This should not happen as march=native should be a safe option, but still it may happen.) What is your CPU?

Also please try to simplify these:
> CFLAGS="-march=native -pipe"
> CXXFLAGS="-march=native -pipe -fno-delete-null-pointer-checks -fno-lifetime-dse -fno-schedule-insns2"
> LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,-rpath=/usr/lib64/firefox,--enable-new-dtags"

e.g. set CFLAGS and CXXFLAGS to "-pipe" and LDFLAGS to empty value.

Disabled custom-optimization actually means strip-flags call which still may allow something causing troubles.
Comment 12 Nick Sarnie gentoo-dev 2017-08-24 23:05:39 UTC
(In reply to Andrew Savchenko from comment #11)
> (In reply to Nick Sarnie from comment #10)
> > Let me know if you have any other ideas.
> 
> Try to remove -march=native for testing. I experienced in the past weird gcc
> bugs due to -march=native. (This should not happen as march=native should be
> a safe option, but still it may happen.) What is your CPU?
> 
> Also please try to simplify these:
> > CFLAGS="-march=native -pipe"
> > CXXFLAGS="-march=native -pipe -fno-delete-null-pointer-checks -fno-lifetime-dse -fno-schedule-insns2"
> > LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,-rpath=/usr/lib64/firefox,--enable-new-dtags"
> 
> e.g. set CFLAGS and CXXFLAGS to "-pipe" and LDFLAGS to empty value.
> 
> Disabled custom-optimization actually means strip-flags call which still may
> allow something causing troubles.

Hi Andrew,

Good idea. I no longer experience the corruption if I remove -march=native. My CPU is the Ryzen 1800X, so it may be a compiler bug in this new platform.

Please see my new emerge --info below, and let me know if you have any ideas on how to fix this bug.

Thanks,
Sarnex


www-client/firefox-55.0.2::gentoo was built with the following:
USE="custom-cflags custom-optimization dbus gmp-autoupdate hwaccel pgo pulseaudio startup-notification system-libvpx -bindist -debug -hardened -jack (-neon) -nsplugin (-selinux) (-system-cairo) -system-harfbuzz -system-icu -system-jpeg -system-libevent -system-sqlite -test -wifi" ABI_X86="(64)" L10N="-ach -af -an -ar -as -ast -az -bg -bn-BD -bn-IN -br -bs -ca -cak -cs -cy -da -de -dsb -el -en-GB -en-ZA -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 -id -is -it -ja -ka -kab -kk -km -kn -ko -lij -lt -lv -mai -mk -ml -mr -ms -nb -nl -nn -or -pa -pl -pt-BR -pt-PT -rm -ro -ru -si -sk -sl -son -sq -sr -sv -ta -te -th -tr -uk -uz -vi -xh -zh-CN -zh-TW"
CFLAGS="-pipe"
CXXFLAGS="-pipe -fno-delete-null-pointer-checks -fno-lifetime-dse -fno-schedule-insns2"
LDFLAGS="-Wl,-rpath=/usr/lib64/firefox,--enable-new-dtags"
Comment 13 Matt Whitlock 2017-09-01 06:54:34 UTC
Created attachment 491310 [details]
video demonstrating the bug

I too am experiencing this bug (in www-client/firefox-55.0.2, built with GCC 4.6.0), but I have not enabled the "pgo" USE flag.

See the attached video for a demonstration of the bug on my system.

www-client/firefox-55.0.2::gentoo was built with the following:
USE="custom-optimization dbus gmp-autoupdate nsplugin startup-notification system-harfbuzz system-icu system-jpeg system-libevent system-libvpx -bindist -custom-cflags -debug -hardened -hwaccel -jack (-neon) -pgo -pulseaudio (-selinux) (-system-cairo) -system-sqlite -test -wifi" ABI_X86="(64)" L10N="-ach -af -an -ar -as -ast -az -bg -bn-BD -bn-IN -br -bs -ca -cak -cs -cy -da -de -dsb -el -en-GB -en-ZA -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 -id -is -it -ja -ka -kab -kk -km -kn -ko -lij -lt -lv -mai -mk -ml -mr -ms -nb -nl -nn -or -pa -pl -pt-BR -pt-PT -rm -ro -ru -si -sk -sl -son -sq -sr -sv -ta -te -th -tr -uk -uz -vi -xh -zh-CN -zh-TW"
CFLAGS="-march=native -ggdb -pipe -g0"
CXXFLAGS="-march=native -ggdb -pipe -g0 -fno-delete-null-pointer-checks -fno-lifetime-dse -fno-schedule-insns2"
LDFLAGS="-Wl,-O2 -Wl,--as-needed -Wl,-rpath=/usr/lib64/firefox,--enable-new-dtags"

The "-ggdb -g0" is because I have "-ggdb" in my global CFLAGS, but I have CFLAGS="${CFLAGS} -g0" in a package.env file for www-client/firefox.

With USE="custom-optimization", mozcoreconf-v5.eclass seems to extract the wrong optimization level from my CFLAGS. I have "-O3" in my global CFLAGS, but I have CFLAGS="${CFLAGS} -O1" in a package.env file for www-client/firefox. Nevertheless, Firefox builds with -O3, not -O1. This was clearly not my intention. This appears to occur because the "is-flag -O3" test in mozcoreconf-v5.eclass returns true when CFLAGS="-O3 -O1" even though the "-O3" is being overridden by the "-O1".

Setting USE="-custom-optimization", thereby reverting to the default "-O2" optimization level, produces a Firefox that does not exhibit this bug.
Comment 14 William 2017-09-06 11:11:05 UTC
Created attachment 492736 [details]
dep graph

Same here: firefox-52.0.2 with PGO is buggy, without PGO is fine. 
I tried both gcc 6.4.0 & 6.3.0, same result.
firefox-55.0_beta11::mozilla without PGO was fine too, wouldn't build with PGO though. 

USE: custom-optimization dbus gmp-autoupdate pulseaudio startup-notification system-harfbuzz system-icu system-jpeg system-libevent system-libvpx system-sqlite -bindist -custom-cflags -debug -hardened -hwaccel -jack -neon -nsplugin -pgo -selinux -system-cairo -test -wifi
CFLAGS: -march=native -mtune=native -O2 -pipe

On an intel i7.

Is there anything else that could help?
I've attached a dep gragh, maybe that'll help reproduce the bug.
Comment 15 Peter Asplund 2017-10-01 11:01:04 UTC
Created attachment 497294 [details]
Screen shot of different font corrupution
Comment 16 Peter Asplund 2017-10-01 11:02:31 UTC
I'm seeing font corruption as well, but mine is a bit different.

My firefox is compiled without pgo. The problem started the day before yesterday, after upgrading my system using emerge -uDvatN world. I'm running ~x64.

root@skare$ eix firefox -v
* www-client/firefox
     Available versions:  52.2.0^d 52.3.0^d (~)55.0.2^d
     IUSE (all versions): bindist custom-cflags custom-optimization dbus debug +gmp-autoupdate gtk2 hardened hwaccel jack +jemalloc neon nsplugin pgo pulseaudio rust selinux startup-notification system-cairo system-harfbuzz system-icu system-jpeg system-libevent system-libvpx system-sqlite test wifi L10N="ach af an ar as ast az bg bn-BD bn-IN br bs ca cak cs cy da de dsb el en-GB en-ZA 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 id is it ja ka kab kk km kn ko lij lt lv mai mk ml mr ms nb nl nn or pa pl pt-BR pt-PT rm ro ru si sk sl son sq sr sv ta te th tr uk uz vi xh zh-CN zh-TW"
     Installed versions:  Version:   55.0.2^d
                          Date:      05:05:26 PM 09/30/2017
                          USE:       custom-optimization dbus gmp-autoupdate nsplugin pulseaudio startup-notification wifi -bindist -custom-cflags -debug -hardened -hwaccel -jack -neon -pgo -selinux -system-cairo -system-harfbuzz -system-icu -system-jpeg -system-libevent -system-libvpx -system-sqlite -test L10N="-ach -af -an -ar -as -ast -az -bg -bn-BD -bn-IN -br -bs -ca -cak -cs -cy -da -de -dsb -el -en-GB -en-ZA -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 -id -is -it -ja -ka -kab -kk -km -kn -ko -lij -lt -lv -mai -mk -ml -mr -ms -nb -nl -nn -or -pa -pl -pt-BR -pt-PT -rm -ro -ru -si -sk -sl -son -sq -sr -sv -ta -te -th -tr -uk -uz -vi -xh -zh-CN -zh-TW"
                          DEPEND:    >=dev-libs/nss-3.32 >=dev-libs/nspr-4.16 >=virtual/rust-1.15.1 >=dev-lang/yasm-1.1 virtual/opengl >=sys-apps/sed-4 virtual/pkgconfig >=dev-lang/python-2.7.5-r2:2.7[ncurses,sqlite,ssl,threads] app-arch/zip app-arch/unzip >=sys-devel/binutils-2.16.1 sys-apps/findutils media-sound/pulseaudio >=app-text/hunspell-1.5.4:0/1.6= dev-libs/atk dev-libs/expat >=x11-libs/cairo-1.10[X] >=x11-libs/gtk+-2.18:2 x11-libs/gdk-pixbuf >=x11-libs/pango-1.22.0 >=media-libs/libpng-1.6.29:0/16=[apng] >=media-libs/mesa-10.2:* media-libs/fontconfig >=media-libs/freetype-2.4.10 || ( media-sound/pulseaudio >=media-sound/apulse-0.1.9 ) virtual/freedesktop-icon-theme >=sys-apps/dbus-0.60 >=dev-libs/dbus-glib-0.72 >=x11-libs/startup-notification-0.8 >=dev-libs/glib-2.26:2 >=sys-libs/zlib-1.2.3 >=virtual/libffi-3.0.10 virtual/ffmpeg x11-libs/libX11 x11-libs/libXcomposite x11-libs/libXdamage x11-libs/libXext x11-libs/libXfixes x11-libs/libXrender x11-libs/libXt >=x11-libs/gtk+-3.4.0:3 >=sys-apps/dbus-0.60 >=dev-libs/dbus-glib-0.72 net-misc/networkmanager >=app-portage/elt-patches-20170422 !<sys-devel/gettext-0.18.1.1-r3 >=sys-devel/automake-1.15:1.15 ~sys-devel/autoconf-2.13 >=sys-devel/libtool-2.4 app-arch/unzip
                          RDEPEND:   >=dev-libs/nss-3.32 >=dev-libs/nspr-4.16 >=app-text/hunspell-1.5.4:0/1.6= dev-libs/atk dev-libs/expat >=x11-libs/cairo-1.10[X] >=x11-libs/gtk+-2.18:2 x11-libs/gdk-pixbuf >=x11-libs/pango-1.22.0 >=media-libs/libpng-1.6.29:0/16=[apng] >=media-libs/mesa-10.2:* media-libs/fontconfig >=media-libs/freetype-2.4.10 || ( media-sound/pulseaudio >=media-sound/apulse-0.1.9 ) virtual/freedesktop-icon-theme >=sys-apps/dbus-0.60 >=dev-libs/dbus-glib-0.72 >=x11-libs/startup-notification-0.8 >=dev-libs/glib-2.26:2 >=sys-libs/zlib-1.2.3 >=virtual/libffi-3.0.10 virtual/ffmpeg x11-libs/libX11 x11-libs/libXcomposite x11-libs/libXdamage x11-libs/libXext x11-libs/libXfixes x11-libs/libXrender x11-libs/libXt >=x11-libs/gtk+-3.4.0:3 >=sys-apps/dbus-0.60 >=dev-libs/dbus-glib-0.72 net-misc/networkmanager || ( media-sound/pulseaudio >=media-sound/apulse-0.1.9 )
                          EAPI:      6
                          (~)55.0.2^d
     Homepage:            http://www.mozilla.com/firefox
     Find open bugs:      https://bugs.gentoo.org/buglist.cgi?quicksearch=www-client%2Ffirefox
     Description:         Firefox Web Browser
     License:             MPL-2.0 GPL-2 LGPL-2.1

See attached screenshot.

The issue cannot be seen in Nautilus or epiphany, only Firefox. As you can see in the screenshot, the problem is seen in tabs and all over the GUI.
Comment 17 Jory A. Pratt gentoo-dev 2017-10-01 18:25:25 UTC
(In reply to Peter Asplund from comment #16)
> I'm seeing font corruption as well, but mine is a bit different.
> 
> My firefox is compiled without pgo. The problem started the day before
> yesterday, after upgrading my system using emerge -uDvatN world. I'm running
> ~x64.
> 
> root@skare$ eix firefox -v
> * www-client/firefox
>      Available versions:  52.2.0^d 52.3.0^d (~)55.0.2^d
>      IUSE (all versions): bindist custom-cflags custom-optimization dbus
> debug +gmp-autoupdate gtk2 hardened hwaccel jack +jemalloc neon nsplugin pgo
> pulseaudio rust selinux startup-notification system-cairo system-harfbuzz
> system-icu system-jpeg system-libevent system-libvpx system-sqlite test wifi
> L10N="ach af an ar as ast az bg bn-BD bn-IN br bs ca cak cs cy da de dsb el
> en-GB en-ZA 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 id is it ja ka kab kk km kn ko lij lt lv mai mk ml mr ms
> nb nl nn or pa pl pt-BR pt-PT rm ro ru si sk sl son sq sr sv ta te th tr uk
> uz vi xh zh-CN zh-TW"
>      Installed versions:  Version:   55.0.2^d
>                           Date:      05:05:26 PM 09/30/2017
>                           USE:       custom-optimization dbus gmp-autoupdate
> nsplugin pulseaudio startup-notification wifi -bindist -custom-cflags -debug
> -hardened -hwaccel -jack -neon -pgo -selinux -system-cairo -system-harfbuzz
> -system-icu -system-jpeg -system-libevent -system-libvpx -system-sqlite
> -test L10N="-ach -af -an -ar -as -ast -az -bg -bn-BD -bn-IN -br -bs -ca -cak
> -cs -cy -da -de -dsb -el -en-GB -en-ZA -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 -id -is
> -it -ja -ka -kab -kk -km -kn -ko -lij -lt -lv -mai -mk -ml -mr -ms -nb -nl
> -nn -or -pa -pl -pt-BR -pt-PT -rm -ro -ru -si -sk -sl -son -sq -sr -sv -ta
> -te -th -tr -uk -uz -vi -xh -zh-CN -zh-TW"
>                           DEPEND:    >=dev-libs/nss-3.32
> >=dev-libs/nspr-4.16 >=virtual/rust-1.15.1 >=dev-lang/yasm-1.1
> virtual/opengl >=sys-apps/sed-4 virtual/pkgconfig
> >=dev-lang/python-2.7.5-r2:2.7[ncurses,sqlite,ssl,threads] app-arch/zip
> app-arch/unzip >=sys-devel/binutils-2.16.1 sys-apps/findutils
> media-sound/pulseaudio >=app-text/hunspell-1.5.4:0/1.6= dev-libs/atk
> dev-libs/expat >=x11-libs/cairo-1.10[X] >=x11-libs/gtk+-2.18:2
> x11-libs/gdk-pixbuf >=x11-libs/pango-1.22.0
> >=media-libs/libpng-1.6.29:0/16=[apng] >=media-libs/mesa-10.2:*
> media-libs/fontconfig >=media-libs/freetype-2.4.10 || (
> media-sound/pulseaudio >=media-sound/apulse-0.1.9 )
> virtual/freedesktop-icon-theme >=sys-apps/dbus-0.60
> >=dev-libs/dbus-glib-0.72 >=x11-libs/startup-notification-0.8
> >=dev-libs/glib-2.26:2 >=sys-libs/zlib-1.2.3 >=virtual/libffi-3.0.10
> virtual/ffmpeg x11-libs/libX11 x11-libs/libXcomposite x11-libs/libXdamage
> x11-libs/libXext x11-libs/libXfixes x11-libs/libXrender x11-libs/libXt
> >=x11-libs/gtk+-3.4.0:3 >=sys-apps/dbus-0.60 >=dev-libs/dbus-glib-0.72
> net-misc/networkmanager >=app-portage/elt-patches-20170422
> !<sys-devel/gettext-0.18.1.1-r3 >=sys-devel/automake-1.15:1.15
> ~sys-devel/autoconf-2.13 >=sys-devel/libtool-2.4 app-arch/unzip
>                           RDEPEND:   >=dev-libs/nss-3.32
> >=dev-libs/nspr-4.16 >=app-text/hunspell-1.5.4:0/1.6= dev-libs/atk
> dev-libs/expat >=x11-libs/cairo-1.10[X] >=x11-libs/gtk+-2.18:2
> x11-libs/gdk-pixbuf >=x11-libs/pango-1.22.0
> >=media-libs/libpng-1.6.29:0/16=[apng] >=media-libs/mesa-10.2:*
> media-libs/fontconfig >=media-libs/freetype-2.4.10 || (
> media-sound/pulseaudio >=media-sound/apulse-0.1.9 )
> virtual/freedesktop-icon-theme >=sys-apps/dbus-0.60
> >=dev-libs/dbus-glib-0.72 >=x11-libs/startup-notification-0.8
> >=dev-libs/glib-2.26:2 >=sys-libs/zlib-1.2.3 >=virtual/libffi-3.0.10
> virtual/ffmpeg x11-libs/libX11 x11-libs/libXcomposite x11-libs/libXdamage
> x11-libs/libXext x11-libs/libXfixes x11-libs/libXrender x11-libs/libXt
> >=x11-libs/gtk+-3.4.0:3 >=sys-apps/dbus-0.60 >=dev-libs/dbus-glib-0.72
> net-misc/networkmanager || ( media-sound/pulseaudio
> >=media-sound/apulse-0.1.9 )
>                           EAPI:      6
>                           (~)55.0.2^d
>      Homepage:            http://www.mozilla.com/firefox
>      Find open bugs:     
> https://bugs.gentoo.org/buglist.cgi?quicksearch=www-client%2Ffirefox
>      Description:         Firefox Web Browser
>      License:             MPL-2.0 GPL-2 LGPL-2.1
> 
> See attached screenshot.
> 
> The issue cannot be seen in Nautilus or epiphany, only Firefox. As you can
> see in the screenshot, the problem is seen in tabs and all over the GUI.

sync and update, your using freetype-2.8.1 with an unfixed version of firefox.
Comment 18 Peter Asplund 2017-10-22 17:31:32 UTC
(In reply to Jory A. Pratt from comment #17)
> (In reply to Peter Asplund from comment #16)
> > I'm seeing font corruption as well, but mine is a bit different.
> > 
> > My firefox is compiled without pgo. The problem started the day before
> > yesterday, after upgrading my system using emerge -uDvatN world. I'm running
> > ~x64.
> > 
> > root@skare$ eix firefox -v
> > * www-client/firefox
> >      Available versions:  52.2.0^d 52.3.0^d (~)55.0.2^d
> >      IUSE (all versions): bindist custom-cflags custom-optimization dbus
> > debug +gmp-autoupdate gtk2 hardened hwaccel jack +jemalloc neon nsplugin pgo
> > pulseaudio rust selinux startup-notification system-cairo system-harfbuzz
> > system-icu system-jpeg system-libevent system-libvpx system-sqlite test wifi
> > L10N="ach af an ar as ast az bg bn-BD bn-IN br bs ca cak cs cy da de dsb el
> > en-GB en-ZA 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 id is it ja ka kab kk km kn ko lij lt lv mai mk ml mr ms
> > nb nl nn or pa pl pt-BR pt-PT rm ro ru si sk sl son sq sr sv ta te th tr uk
> > uz vi xh zh-CN zh-TW"
> >      Installed versions:  Version:   55.0.2^d
> >                           Date:      05:05:26 PM 09/30/2017
> >                           USE:       custom-optimization dbus gmp-autoupdate
> > nsplugin pulseaudio startup-notification wifi -bindist -custom-cflags -debug
> > -hardened -hwaccel -jack -neon -pgo -selinux -system-cairo -system-harfbuzz
> > -system-icu -system-jpeg -system-libevent -system-libvpx -system-sqlite
> > -test L10N="-ach -af -an -ar -as -ast -az -bg -bn-BD -bn-IN -br -bs -ca -cak
> > -cs -cy -da -de -dsb -el -en-GB -en-ZA -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 -id -is
> > -it -ja -ka -kab -kk -km -kn -ko -lij -lt -lv -mai -mk -ml -mr -ms -nb -nl
> > -nn -or -pa -pl -pt-BR -pt-PT -rm -ro -ru -si -sk -sl -son -sq -sr -sv -ta
> > -te -th -tr -uk -uz -vi -xh -zh-CN -zh-TW"
> >                           DEPEND:    >=dev-libs/nss-3.32
> > >=dev-libs/nspr-4.16 >=virtual/rust-1.15.1 >=dev-lang/yasm-1.1
> > virtual/opengl >=sys-apps/sed-4 virtual/pkgconfig
> > >=dev-lang/python-2.7.5-r2:2.7[ncurses,sqlite,ssl,threads] app-arch/zip
> > app-arch/unzip >=sys-devel/binutils-2.16.1 sys-apps/findutils
> > media-sound/pulseaudio >=app-text/hunspell-1.5.4:0/1.6= dev-libs/atk
> > dev-libs/expat >=x11-libs/cairo-1.10[X] >=x11-libs/gtk+-2.18:2
> > x11-libs/gdk-pixbuf >=x11-libs/pango-1.22.0
> > >=media-libs/libpng-1.6.29:0/16=[apng] >=media-libs/mesa-10.2:*
> > media-libs/fontconfig >=media-libs/freetype-2.4.10 || (
> > media-sound/pulseaudio >=media-sound/apulse-0.1.9 )
> > virtual/freedesktop-icon-theme >=sys-apps/dbus-0.60
> > >=dev-libs/dbus-glib-0.72 >=x11-libs/startup-notification-0.8
> > >=dev-libs/glib-2.26:2 >=sys-libs/zlib-1.2.3 >=virtual/libffi-3.0.10
> > virtual/ffmpeg x11-libs/libX11 x11-libs/libXcomposite x11-libs/libXdamage
> > x11-libs/libXext x11-libs/libXfixes x11-libs/libXrender x11-libs/libXt
> > >=x11-libs/gtk+-3.4.0:3 >=sys-apps/dbus-0.60 >=dev-libs/dbus-glib-0.72
> > net-misc/networkmanager >=app-portage/elt-patches-20170422
> > !<sys-devel/gettext-0.18.1.1-r3 >=sys-devel/automake-1.15:1.15
> > ~sys-devel/autoconf-2.13 >=sys-devel/libtool-2.4 app-arch/unzip
> >                           RDEPEND:   >=dev-libs/nss-3.32
> > >=dev-libs/nspr-4.16 >=app-text/hunspell-1.5.4:0/1.6= dev-libs/atk
> > dev-libs/expat >=x11-libs/cairo-1.10[X] >=x11-libs/gtk+-2.18:2
> > x11-libs/gdk-pixbuf >=x11-libs/pango-1.22.0
> > >=media-libs/libpng-1.6.29:0/16=[apng] >=media-libs/mesa-10.2:*
> > media-libs/fontconfig >=media-libs/freetype-2.4.10 || (
> > media-sound/pulseaudio >=media-sound/apulse-0.1.9 )
> > virtual/freedesktop-icon-theme >=sys-apps/dbus-0.60
> > >=dev-libs/dbus-glib-0.72 >=x11-libs/startup-notification-0.8
> > >=dev-libs/glib-2.26:2 >=sys-libs/zlib-1.2.3 >=virtual/libffi-3.0.10
> > virtual/ffmpeg x11-libs/libX11 x11-libs/libXcomposite x11-libs/libXdamage
> > x11-libs/libXext x11-libs/libXfixes x11-libs/libXrender x11-libs/libXt
> > >=x11-libs/gtk+-3.4.0:3 >=sys-apps/dbus-0.60 >=dev-libs/dbus-glib-0.72
> > net-misc/networkmanager || ( media-sound/pulseaudio
> > >=media-sound/apulse-0.1.9 )
> >                           EAPI:      6
> >                           (~)55.0.2^d
> >      Homepage:            http://www.mozilla.com/firefox
> >      Find open bugs:     
> > https://bugs.gentoo.org/buglist.cgi?quicksearch=www-client%2Ffirefox
> >      Description:         Firefox Web Browser
> >      License:             MPL-2.0 GPL-2 LGPL-2.1
> > 
> > See attached screenshot.
> > 
> > The issue cannot be seen in Nautilus or epiphany, only Firefox. As you can
> > see in the screenshot, the problem is seen in tabs and all over the GUI.
> 
> sync and update, your using freetype-2.8.1 with an unfixed version of
> firefox.

Thank you, I've just updated to Firefox 56, which has fixed the issue. Finally, I can read again! :D
Comment 19 Jory A. Pratt gentoo-dev 2019-03-31 20:06:18 UTC
Please feel free to reopen and update any bug report that can be duplicated with current esr builds, 60.x. If you feel your feature needs to be re looked at in any of these bugs reopen and update, please attach patches when appropriate. Thank you Mozilla Team