Commit Graph

624 Commits

Author SHA1 Message Date
Lee Salzman
5ca259a506 Bug 1838323 - Disambiguate skvx when building with different arch options. r=glandium
It seems that GCC, under certain circumstances, does not completely inline code in the skvx namespace in Skia, even though the code specifies "always_inline". As a side-effect, it leaves around symbols that are generated with different architecture flags supplied. LTO then picks one of the symbols, at what may as well be random.

This could potentially be an issue under clang if it ever failed to inline.

As a workaround for both, we force skvx to exist in arch-specific namespaces, i.e. -Dskvx=skvx_foo, so that even in the worst case, no ambiguous symbols will be generated.

Differential Revision: https://phabricator.services.mozilla.com/D182855
2023-07-06 02:24:40 +00:00
Mike Hommey
5eff8de550 Bug 1841199 - Work around tail-call optimization not happening on mips* and ppc64. r=gfx-reviewers,lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D182686
2023-07-03 22:57:24 +00:00
Mike Hommey
e4e26c4140 Bug 1841203 - Stop building SkICC. r=gfx-reviewers,lsalzman
It is not used.

Differential Revision: https://phabricator.services.mozilla.com/D182538
2023-06-30 22:12:34 +00:00
Mike Hommey
1413be85ca Bug 1841197 - Undefine the mips builtin macro on mips in skia. r=gfx-reviewers,lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D182536
2023-06-30 02:07:45 +00:00
Lee Salzman
346a76bee7 Bug 1835829 - Ensure MOZ_SKIA is always defined in Skia. r=aosmond
Differential Revision: https://phabricator.services.mozilla.com/D179878
2023-06-03 23:36:25 +00:00
Jason Kratzer
81ff1f5f49 Bug 1832604 - Disable AVX512 instructions on coverage builds. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D179098
2023-05-25 16:32:25 +00:00
Lee Salzman
e9fc456838 Bug 1830006 - Do not use malloc.h on OpenBSD. r=aosmond
Differential Revision: https://phabricator.services.mozilla.com/D176556
2023-04-26 16:58:44 +00:00
Lee Salzman
cbc46a5e31 Bug 1829521 - More Skia build fixes for GCC ARM. r=aosmond
Differential Revision: https://phabricator.services.mozilla.com/D176315
2023-04-25 14:00:13 +00:00
Lee Salzman
c891dafa82 Bug 1829203 - Fix valgrind suppression in Skia. r=aosmond
Differential Revision: https://phabricator.services.mozilla.com/D176074
2023-04-20 19:14:22 +00:00
Lee Salzman
94786390f2 Bug 1828931 - Cherry-pick SkSL fixes. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D175977
2023-04-20 02:59:26 +00:00
Lee Salzman
c46c54bdc7 Bug 1828393 - Fix building Skia on GCC SPARC. r=aosmond,gfx-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D175726
2023-04-18 15:09:40 +00:00
Lee Salzman
1b21d02a37 Bug 1827727 - Fix building Skia on GCC ARM. r=aosmond,gfx-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D175578
2023-04-18 15:09:01 +00:00
Lee Salzman
7672d64e69 Bug 1821512 - Update Skia build scripts. r=jrmuizel
This transitions generate_mozbuild to python3, since the existing script was
bitrotted with python2.

The generated moz.build is also fixed up for the new Skia files.

Differential Revision: https://phabricator.services.mozilla.com/D173323
2023-04-16 15:34:50 +00:00
Lee Salzman
629f4dc473 Bug 1821512 - Update Skia source files to milestone 113. r=aosmond
Differential Revision: https://phabricator.services.mozilla.com/D174378
2023-04-16 15:34:41 +00:00
Natalia Csoregi
53631b0cfb Backed out 6 changesets (bug 1821512) for failures on browser_screenshots_test_full_page.js. CLOSED TREE
Backed out changeset a31f2795710e (bug 1821512)
Backed out changeset 3985c29a6490 (bug 1821512)
Backed out changeset 0d9814a43a4d (bug 1821512)
Backed out changeset e5570884e8e4 (bug 1821512)
Backed out changeset efc92c86fafd (bug 1821512)
Backed out changeset 3222f6498a44 (bug 1821512)
2023-04-16 11:30:32 +03:00
Lee Salzman
faf9b2bb98 Bug 1821512 - Update Skia build scripts. r=jrmuizel
This transitions generate_mozbuild to python3, since the existing script was
bitrotted with python2.

The generated moz.build is also fixed up for the new Skia files.

Differential Revision: https://phabricator.services.mozilla.com/D173323
2023-04-16 03:59:59 +00:00
Lee Salzman
9cacdaacd4 Bug 1821512 - Update Skia source files to milestone 113. r=aosmond
Differential Revision: https://phabricator.services.mozilla.com/D174378
2023-04-16 03:59:51 +00:00
Iulian Moraru
6e2eff1bc5 Backed out 6 changesets (bug 1821512) for causing multiple failures. CLOSED TREE
Backed out changeset 97295a57babe (bug 1821512)
Backed out changeset 698104c7a5d1 (bug 1821512)
Backed out changeset 09aa18e47bf6 (bug 1821512)
Backed out changeset 20b46afb225f (bug 1821512)
Backed out changeset b531f604ea4c (bug 1821512)
Backed out changeset 0a7c0b0773d4 (bug 1821512)
2023-04-11 10:10:41 +03:00
Lee Salzman
e716f092b0 Bug 1821512 - Update Skia build scripts. r=jrmuizel
This transitions generate_mozbuild to python3, since the existing script was
bitrotted with python2.

The generated moz.build is also fixed up for the new Skia files.

Differential Revision: https://phabricator.services.mozilla.com/D173323
2023-04-11 05:00:04 +00:00
Lee Salzman
932d77fe8a Bug 1821512 - Update Skia source files to milestone 113. r=aosmond
Differential Revision: https://phabricator.services.mozilla.com/D174378
2023-04-11 04:59:58 +00:00
Emanuele Rocca
92da89bf60 Bug 1822827 - Remove explicit NEON flags from skia build r=glandium
While Firefox builds for Android ARMv7 don't support non-NEON
processors, downstreams (including non-Android ones) may still want to
support them.

On the Firefox builds that don't support non-NEON processors, the NEON
flags are actually already passed globally, and they don't need to be
explicitly added. NEON_FLAGS is actually only meant to be used for
sources that specifically need NEON support even when the target doesn't
support it, for, e.g. specialized code behind runtime CPU detection.

So removing NEON_FLAGS is a no-op in practice when NEON processors are
already targeted.

Differential Revision: https://phabricator.services.mozilla.com/D172801
2023-03-17 22:59:50 +00:00
Sylvestre Ledru
11543ba854 Bug 1802290 - Remove +x permissions on more files r=linter-reviewers,andi
Differential Revision: https://phabricator.services.mozilla.com/D165841
2023-01-03 08:17:50 +00:00
Marco Castelluccio
f69e697461 Bug 1801836 - Remove no longer necessary 'from __future__' imports. r=linter-reviewers,glandium,webdriver-reviewers,perftest-reviewers,geckoview-reviewers,jld,ahal,owlish,afinder DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D165395
2022-12-23 22:45:46 +00:00
Sylvestre Ledru
c7c6dfa5bb Bug 1803331 - skia/generator: refresh the list to have the up to date moz.build after running generate_mozbuild.py r=nical DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D163813
2022-12-13 13:28:32 +00:00
Sylvestre Ledru
af5d98a682 Bug 1803331 - skia/generator: remove SK_OUTLINE_EMBOLDEN_DIVISOR r=jfkthame DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D164566
2022-12-13 13:01:58 +00:00
Sylvestre Ledru
43326ed319 Bug 1803331 - skia/generator: ignore skia/src/sksl/SkSLJIT r=nical DONTBUILD
Depends on D163446

Differential Revision: https://phabricator.services.mozilla.com/D163448
2022-12-01 10:32:09 +00:00
Sylvestre Ledru
99ef6e2d79 Bug 1803331 - skia/generator: replace black/white list r=nical DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D163446
2022-12-01 10:32:09 +00:00
Sylvestre Ledru
b5a777afd7 Bug 1801612 - Update the skia sync documentation r=gfx-reviewers,nical DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D162542
2022-11-25 10:56:47 +00:00
Chris Peterson
33e4a145c6 Bug 1774522 - Make Skia C++20 compatible by replacing deprecated std::result_of_t. r=lsalzman
The C++ std library functions `std::result_of` and `std::result_of_t` were deprecated in C++17 and removed in C++20.

Upstream Skia removed use of `std::result_of_t` in 2021, so we can just copy upstream's new replacement code:

https://skia.googlesource.com/skia/+/7d8cdd5b7f277f3b661e1eea067cf45a467572c6%5E%21/
https://skia.googlesource.com/skia/+/dc976a96ea388ae49fd0ce18d5a07d8fc15779cf%5E%21/

Because we're just extracting code from upstream, our local changes here can be safely overwritten whenever we next vendor a new Skia version.

Differential Revision: https://phabricator.services.mozilla.com/D149490
2022-06-17 02:13:46 +00:00
Lee Salzman
5cf73489a8 Bug 1769082 - Avoid divide-by-zero in Skia's luminosity blend mode. r=jrmuizel,gfx-reviewers
This applies a fix that is present in Skia's HW luminosity blend mode to its
CPU pipeline so that the luminosity mode no longer divides by zero, thus avoiding
infs and nans.

Differential Revision: https://phabricator.services.mozilla.com/D149030
2022-06-16 03:39:41 +00:00
Butkovits Atila
297c111411 Backed out changeset f292760857f2 (bug 1769082) for causing build bustages at SkRasterPipeline_opts. CLOSED TREE 2022-06-16 06:18:27 +03:00
Lee Salzman
09080ca408 Bug 1769082 - Avoid divide-by-zero in Skia's luminosity blend mode. r=jrmuizel,gfx-reviewers
This applies a fix that is present in Skia's HW luminosity blend mode to its
CPU pipeline so that the luminosity mode no longer divides by zero, thus avoiding
infs and nans.

Differential Revision: https://phabricator.services.mozilla.com/D149030
2022-06-16 02:31:24 +00:00
Jonathan Kew
80ef7350dc Bug 1769279 - Disable FT_LOAD_COLOR when getting glyph metrics for fonts that include an SVG table. r=lsalzman
See https://gitlab.freedesktop.org/freetype/freetype/-/issues/1156
for the issue this is addressing.

Differential Revision: https://phabricator.services.mozilla.com/D146318
2022-05-14 06:36:43 +00:00
Jonathan Kew
f8aa71dcae Bug 1747272 - Apply current color when rasterizing glyphs from color fonts in Skia using Core Text. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D137567
2022-02-01 21:41:17 +00:00
Chris Peterson
f6fdbf028a Bug 1738401 - Remove -Wno-shadow warning suppressions. r=firefox-build-system-reviewers,glandium
-Wshadow warnings are not enabled globally, so these -Wno-shadow suppressions have no effect. I had intended to enable -Wshadow globally along with these suppressions in some directories (in bug 1272513), but that was blocked by other issues.

There are too many -Wshadow warnings (now over 2000) to realistically fix them all. We should remove all these unnecessary -Wno-shadow flags cluttering many moz.build files.

Differential Revision: https://phabricator.services.mozilla.com/D132289
2021-12-01 06:40:04 +00:00
Lee Salzman
73ad56c77f Bug 1739448 - Reduce Skia header pollution in Moz2D from sk_sp. r=gfx-reviewers,jgilbert
sk_sp requires its type to be defined at the point of sk_sp declaration.
Just use RefPtr instead which does not have this limitation so we can move
some Skia includes out of the Moz2D headers.

Differential Revision: https://phabricator.services.mozilla.com/D130387
2021-11-11 07:16:57 +00:00
Marian-Vasile Laza
748933bf4b Backed out 2 changesets (bug 1739448) for causing geckoview failures on 1246775-1.html. CLOSED TREE
Backed out changeset 7b82837e2f56 (bug 1739448)
Backed out changeset feac99f1dae3 (bug 1739448)
2021-11-11 07:39:10 +02:00
Lee Salzman
b54d5cc42c Bug 1739448 - Reduce Skia header pollution in Moz2D from sk_sp. r=gfx-reviewers,jgilbert
sk_sp requires its type to be defined at the point of sk_sp declaration.
Just use RefPtr instead which does not have this limitation so we can move
some Skia includes out of the Moz2D headers.

Differential Revision: https://phabricator.services.mozilla.com/D130387
2021-11-11 04:33:50 +00:00
Lee Salzman
b9f0d24c9c Bug 1734853 - Ensure unhinted fonts default to symmetric rendering in Skia. r=jfkthame
It would seem that the Microsoft implementation of GetRecommendedRenderingMode
is somewhat different from the WINE version and has further behavior of also
checking whether the font is hinted in the fallback case to determine if it
should truly default to natural rendering instead of natural symmetric. This
adds the hinting check to decide between natural or natural symmetric in that
fallback case.

Differential Revision: https://phabricator.services.mozilla.com/D129360
2021-10-25 15:43:01 +00:00
Lee Salzman
b164800498 Bug 1711553 - Avoid use of GetRecommendedRenderingMode in Skia. r=jrmuizel
This attempts to emulate the behavior of GetRecommendedRenderingMode without
actually calling it. In addition, it allows some Gecko-specific behavior
like overriding the render mode explicitly that allows some simplification
of the decision-making.

Inside GetRecommendedRenderingMode, natural is only allowed if <= 20 size.
This allows us to thus decide mostly based on whether the size is > 20 or
if an explicit mode was specified. In the remaining case where we need
to check a GASP table if available, we defer to the symmetric flag. If
there is no GASP, we assume natural.

Differential Revision: https://phabricator.services.mozilla.com/D122025
2021-08-09 19:16:16 +00:00
Mike Hommey
03223f9ea4 Bug 1722653 - Remove MOZ_CAIRO_CFLAGS. r=firefox-build-system-reviewers,jgilbert,andi
Differential Revision: https://phabricator.services.mozilla.com/D121066
2021-07-29 23:38:31 +00:00
Jonathan Kew
5820669ad6 Bug 1716117 - Build SkiaPDF with harfbuzz subsetting, and eliminate use of sfntly. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D117586
2021-06-15 16:45:30 +00:00
Lee Salzman
caa9cd4f4d Bug 1684050 - choose appropriate stroke res scale for PathSkia::StrokeContainsPoint. r=bobowen
This uses SkDraw::ComputeResScaleForStroking to ensure we exactly match the resolution scale
that is chosen for drawing the stroked path inside the guts of Skia. This should ensure these
two don't get out of sync.

This also cleans out the old overscale code in ComputeResScaleForStroking that was necessary
during an ancient Skia porting effort but has now bitrotted into irrelevance.

Differential Revision: https://phabricator.services.mozilla.com/D101686
2021-01-14 09:01:54 +00:00
tobar2018
d7a64d8211 Bug 1673051 - Remove OnYosemiteOrLater(), OnElCapitanOrLater(), and OnSierraOrLater(). r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D95304
2020-11-02 16:25:18 +00:00
Jeff Muizelaar
938d2dffe9 Bug 1672899. Avoid CGFonts in ctfont_create_exact_copy when possible. r=jfkthame
We should be able to use CTFontCreateCopyWithAttributes for non-system fonts
because we don't need to worry about them changing. This avoids the leaks
caused by going through a CGFont.

Differential Revision: https://phabricator.services.mozilla.com/D94772
2020-10-28 14:16:41 +00:00
Lee Salzman
88e30d29c4 Bug 1669575 - experimental backout of macOS 11 CoreText crash workaround in bug 1657440. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D92666
2020-10-06 20:37:27 +00:00
Lee Salzman
2ede866d22 Bug 1642028 - cherry-pick Skia blitting cleanups. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D92476
2020-10-06 14:36:49 +00:00
Lee Salzman
811a48a03b Bug 1657440 - avoid letting Skia query style information for Mac fonts. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D86492
2020-08-17 06:48:00 +00:00
Lee Salzman
c50a68e57e Bug 1645123 - avoid trapping instructions on Skia debug asserts. r=jrmuizel
clang may potentially insert trapping instructions when __builtin_unreachable() is used.
We need to ensure we do not use this intrinsic when asserts are disabled. To work around
this, we add a condition that is checked before entering the body of SK_ABORT.

Differential Revision: https://phabricator.services.mozilla.com/D83841
2020-07-16 19:56:29 +00:00
Lee Salzman
0adb330468 Bug 1611467 - disable Skia typeface cache to prevent it from leaking fonts. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D68131

--HG--
extra : moz-landing-system : lando
2020-03-25 00:58:41 +00:00