Commit Graph

43441 Commits

Author SHA1 Message Date
Herb Derby
10e48d4061 Allow SkMakeSpan to correctly handle the distinction between
const and non-const for container classes such as std::vector
and std::array.

Change-Id: I6ad49de7f2f2c379ba6c964115806d058c72cd7e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233296
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2019-08-08 18:44:24 +00:00
Brian Salomon
d4764a15f3 Rework how backend-specific formats are retrieved from GrBackendFormat.
Change-Id: If1047c477ff3f2cc4aaf19d2e2e838f2dbcb0126
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233160
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
2019-08-08 17:20:34 +00:00
Hal Canary
4acbab33bd experimental/editor: scroll on delete if necessary
Change-Id: Ib1c6ef3d257956c0876d5184423072226d70d973
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233257
Commit-Queue: Ben Wagner <bungeman@google.com>
Auto-Submit: Hal Canary <halcanary@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2019-08-08 16:08:15 +00:00
Mike Klein
0b84eab299 Reland "thread-local caches?"
This is a reland of 0c9995dc51

PS2 skips program caching on G3/iOS/ARMv7 builds.

It doesn't seem important to cache programs on this build configuration
yet, maybe ever: we're not yet JITting on ARMv7, ARMv7 iOS is a dying
platform, and non-G3 builds, both local and bot, work fine for me so
maybe it's just an old toolchain?  For now I'm just disabling caching by
returning nullptr.  If the list of platforms grows much bigger or more
important, I may put back a spinlock-based best-effort caching.

Original change's description:
> thread-local caches?
>
> Here's another idea... these SkVMBlitter program caches are probably
> best thread-local.  If there are a bunch of threads doing the same work
> with the same program, we don't need them fighting over that one slot in
> the cache, and if there are a bunch of threads doing _different_ work,
> they'll get the best cache behavior if they don't fight over slots in
> the LRU with different programs.  Either way, seems like a win?
>
> (I've kept the try-acquire/release pattern just to make the focus of
> this change more clear.  We can fold it through more if we like it.)
>
> Change-Id: Ib1ee270069c48446845ce27225652896661c5dfe
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233060
> Commit-Queue: Mike Klein <mtklein@google.com>
> Reviewed-by: Herb Derby <herb@google.com>

Cq-Include-Trybots: skia.primary:Build-Mac-Clang-arm-Debug-iOS
Change-Id: I8d8ef5ab56b914c9c305bb1729b72c8bca373337
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233237
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-08-08 14:27:33 +00:00
Hal Canary
54602eaaa6 SkQP: Docker compile helper script respects SKQP_OUTPUT_DIR
No-Try: True
Change-Id: Iefbcbc031a0b012de7751413581e78c0ee30007f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233159
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
2019-08-08 14:11:58 +00:00
Mike Klein
4e6f8c192e Revert "thread-local caches?"
This reverts commit 0c9995dc51.

Reason for revert:

Breaks G3 --config=ios_armv7.  Others seem ok?

third_party/skia/HEAD/src/core/SkVMBlitter.cpp:47:9: error: thread-local storage is not supported for the current target
        thread_local static auto* cache = new SkLRUCache<Key, skvm::Program>{8};


Original change's description:
> thread-local caches?
> 
> Here's another idea... these SkVMBlitter program caches are probably
> best thread-local.  If there are a bunch of threads doing the same work
> with the same program, we don't need them fighting over that one slot in
> the cache, and if there are a bunch of threads doing _different_ work,
> they'll get the best cache behavior if they don't fight over slots in
> the LRU with different programs.  Either way, seems like a win?
> 
> (I've kept the try-acquire/release pattern just to make the focus of
> this change more clear.  We can fold it through more if we like it.)
> 
> Change-Id: Ib1ee270069c48446845ce27225652896661c5dfe
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233060
> Commit-Queue: Mike Klein <mtklein@google.com>
> Reviewed-by: Herb Derby <herb@google.com>

TBR=mtklein@google.com,herb@google.com,reed@google.com

Change-Id: Ie93593490d793645492b6e964632c1e71b3e3ea6
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233236
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-08-08 13:35:20 +00:00
Mike Klein
0c9995dc51 thread-local caches?
Here's another idea... these SkVMBlitter program caches are probably
best thread-local.  If there are a bunch of threads doing the same work
with the same program, we don't need them fighting over that one slot in
the cache, and if there are a bunch of threads doing _different_ work,
they'll get the best cache behavior if they don't fight over slots in
the LRU with different programs.  Either way, seems like a win?

(I've kept the try-acquire/release pattern just to make the focus of
this change more clear.  We can fold it through more if we like it.)

Change-Id: Ib1ee270069c48446845ce27225652896661c5dfe
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233060
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Herb Derby <herb@google.com>
2019-08-08 13:27:38 +00:00
Greg Daniel
6fa62e2ab3 Remove use of GrColorType on GrCaps::getRenderTargetSampleCount.
Additionally this changes removes the version of the call that that takes
a GrPixelConfig.

As part of this change many call sites that were calling getRTSampleCount
to just check renderability have been changed to call
isFormat[AsColorType]Renderable instead. This change has also started to
move us to just checking format renderability (without GrCT) in classes
that are specifically dealing with GrSurface (GrResourceProvider, GrGpu, etc.).

Bug: skia:6718
Change-Id: Icf4a1a21a81a44e6863a7cd2059d21b9833d581f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233039
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2019-08-08 13:15:28 +00:00
Leon Scroggins III
19e3cd4c9c SkCodec: don't assume frameRect is valid
Bug: skia:9321

frameRect is the raw data stored in the image file, and it may not
intersect with the image's canvas. Remove that assumption.

Change-Id: I12802c9c20c0cb3506e64e14b129650ef0767f95
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233157
Auto-Submit: Leon Scroggins <scroggo@google.com>
Commit-Queue: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Nigel Tao <nigeltao@google.com>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
2019-08-08 12:26:08 +00:00
skia-autoroll
241e0ee4a7 Roll third_party/externals/angle2 415bb0cdb057..7424fe8b79c3 (7 commits)
415bb0cdb0..7424fe8b79

git log 415bb0cdb057..7424fe8b79c3 --date=short --no-merges --format='%ad %ae %s'
2019-08-07 ynovikov@chromium.org Skip BufferDataOverflowTest.VertexBufferIntegerOverflow
2019-08-07 iannucci@chromium.org [infra/config] Bump OS X SDK on mac builders to version 10.1
2019-08-07 jdarpinian@chromium.org Remove all global constructors and exit time destructors.
2019-08-07 jmadill@chromium.org Use RenderbufferID in place of GLuint handles.
2019-08-07 syoussefi@chromium.org Vulkan: Seamful cube map emulation
2019-08-07 clemendeng@google.com Have run_code_generation only call vpython when needed
2019-08-07 kkinnunen@nvidia.com Remove ShaderStorageBufferTest test skips for bug 2990, bug is marked fixed

Created with:
  gclient setdep -r third_party/externals/angle2@7424fe8b79c3

The AutoRoll server is located here: https://autoroll.skia.org/r/angle-skia-autoroll

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md

If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.


CQ_INCLUDE_TRYBOTS=skia.primary:Build-Debian9-Clang-x86_64-Release-ANGLE;skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC8i5BEK-GPU-IntelIris655-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE
Bug: None
TBR=reed@google.com
Change-Id: Ibf3754dc872f160f1cadedc71c6530c9966911b7
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233200
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2019-08-08 05:29:08 +00:00
skia-recreate-skps
8dd1c4ac3a Update Go deps
Change-Id: I994c71c53aa308217fb0db4aaf2578fef021438c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233206
Reviewed-by: <skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com>
Commit-Queue: <skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com>
2019-08-08 05:23:58 +00:00
skia-autoroll
e341e6b7dd Roll third_party/externals/swiftshader 3aec8a3be749..75efa7bb97a4 (2 commits)
https://swiftshader.googlesource.com/SwiftShader.git/+log/3aec8a3be749..75efa7bb97a4

git log 3aec8a3be749..75efa7bb97a4 --date=short --no-merges --format='%ad %ae %s'
2019-08-07 chrisforbes@google.com Remove unused parts of Stream interface
2019-08-07 chrisforbes@google.com Simplify query tracking machinery

Created with:
  gclient setdep -r third_party/externals/swiftshader@75efa7bb97a4

The AutoRoll server is located here: https://autoroll.skia.org/r/swiftshader-skia-autoroll

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md

If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.


CQ_INCLUDE_TRYBOTS=skia.primary:Test-Debian9-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader
Bug: None
TBR=reed@google.com
Change-Id: I6a79547a8926c7a3a1e73d8ef359832b21b99586
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233201
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2019-08-08 04:36:39 +00:00
skia-autoroll
fcae89a806 Roll ../src 2d05439f2779..2cf71a3eaec3 (449 commits)
2d05439f27..2cf71a3eae


Created with:
  gclient setdep -r ../src@2cf71a3eae

The AutoRoll server is located here: https://autoroll.skia.org/r/chromium-skia-autoroll

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md

If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.


CQ_INCLUDE_TRYBOTS=skia.primary:Perf-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Release-All-CommandBuffer;skia.primary:Test-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Debug-All-CommandBuffer
Bug: None
TBR=reed@google.com
Change-Id: I8351859f2cb7efe3bb16f7cd82a2586b2fe77e9a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233202
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2019-08-08 04:36:38 +00:00
Hal Canary
bcfed55a8c experimental/editor: mouse drag select, modifierkeys cleanup.
Change-Id: I8c8de54ad6309424bdf18987ccf3eac6bdd41c19
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233080
Commit-Queue: Hal Canary <halcanary@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2019-08-08 02:33:44 +00:00
Greg Daniel
228518f0f8 Remove AMD workaround for new command buffer on pipeline changes.
Change-Id: Iab4e53513b0d42eed60b2910455eb15ef7e3d359
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233158
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2019-08-08 02:09:34 +00:00
Ben Wagner
1dac7bc29f Add Symbol encoding when renaming a font.
GDI will not use a Symbol encoded cmap table if there is no Symbol
encoded name. Always output both Unicode and Symbol names (same data,
different name entries). This fixes test_symbolfont on GDI.

Change-Id: I05dea903b9c3914a852cf31472a19a6a06b274e0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233079
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Herb Derby <herb@google.com>
2019-08-07 20:35:28 +00:00
Hal Canary
cd30375f36 SkQP: make_apk_list.py include pie-cts-dev branch
No-Try: true
Change-Id: I3482f0e55eebe325eef1c140a16b867d89aa6580
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233081
Commit-Queue: Ben Wagner <bungeman@google.com>
Auto-Submit: Hal Canary <halcanary@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2019-08-07 19:42:38 +00:00
Brian Salomon
ea4ad307eb Modify GrGLTexture/RenderTarget and related functions to not take
GrSurfaceDesc.

Change-Id: If853cff7624ec80e0152a28766dda188778913d0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232577
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2019-08-07 18:43:09 +00:00
Michael Ludwig
94322dcf73 Simplify luminance shader
Fixes TecnoSpark Pro compiler bug failure.

Bug: skia:9313
Change-Id: I54c077a2db71f75d50ba483b6932ffd2e18d2814
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232583
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
2019-08-07 18:23:57 +00:00
Jim Van Verth
6c8c9b3cea Remove invalid entry in RELEASE_NOTES
Bug: skia:8243
Change-Id: I85f2777e872a257f56031301654b9da8532a9555
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233077
Auto-Submit: Jim Van Verth <jvanverth@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2019-08-07 17:51:58 +00:00
Mike Klein
b2c5a94b1c switch program cache to try-acquire
No need to contend if someone else is using the cache.

I switched the attributes back to the front of the declaration;
the line for try_acquire_program_cache() was getting long and
I couldn't find any satisfyingly clear place to break it.

Change-Id: I28c24c342b10c043091c0c46bd27153e44308967
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233058
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-08-07 17:15:43 +00:00
Mike Klein
4d95befa5c add an SkVMBlitter bot
Switch the guard define to SK_USE_SKVM_BLITTER to match the expectations
of setting up these easy-mode-defines bots (anything starting with SK_).

Change-Id: I7dafdb31a5b2147cac8428e49d4599e50d125ab6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233059
Auto-Submit: Mike Klein <mtklein@google.com>
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-08-07 17:15:13 +00:00
Mike Klein
e6d800ac0e disable false-postive Wthread-safety-analysis
Some of these compilers seem to misdiagnose correct use of

    if (tryAcquire()) {

       release()
    }

as releasing a lock that hadn't been acquired, but newer compilers
seem just fine.  Let's just turn it off until they can be upgraded.

No bug for the Chromecast builders I can see, but here's the Macs.

Bug: skia:9194
Change-Id: I009a142d4a248dc9d9d085e033b5c7303d732c5b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233057
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Auto-Submit: Mike Klein <mtklein@google.com>
2019-08-07 17:10:23 +00:00
Jim Van Verth
220988189b Add adjustable max size for Metal dynamic allocation ring buffer.
Maximum ring buffer size is based on the maxBufferLength of
the system. Also includes a sample for testing upload pressure.

Bug: skia:8243
Change-Id: I36863b725ba9cbcb02d575b2ab9695d186fcd529
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232759
Reviewed-by: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2019-08-07 15:59:42 +00:00
Mike Klein
e7f3850a0a make coverage a Color
Just a little no-op refactor.  Makes more sense to group clusters of
red,green,blue,alpha channel values into Colors.

Change-Id: I83ab628d008d68ca6d22d97f3ddd155d3e36f949
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232821
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Herb Derby <herb@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2019-08-07 15:30:32 +00:00
Mike Reed
41974000e2 note that drawAtlas does nothing if atlas is null
Change-Id: I8d2171b1f51a2beccff8a18f9e6324c08e4b864c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233076
Commit-Queue: Mike Reed <reed@google.com>
Reviewed-by: Mike Reed <reed@google.com>
Auto-Submit: Mike Reed <reed@google.com>
2019-08-07 15:27:02 +00:00
Mike Klein
5bf028e840 turn on force_opaque for opaque devices
Change-Id: I517be3182745baaff539cfd24dd47df4c17e24d9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232820
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Herb Derby <herb@google.com>
2019-08-07 15:21:12 +00:00
Mike Klein
46f7ff9692 Reland "begin caching Programs in SkVMBlitter"
This is a reland of d1d4cbf2e4

PS2 delays the cache initialization until acquire_program_cache()
is first called, eliminating the static initializer and destructor
from the original CL.

Original change's description:
> begin caching Programs in SkVMBlitter
>
> My first drafts put caching inside SkVM.cpp, which I rejected for
> feeling a little too magic, and then in SkVMBuilder.cpp using a
> fingerprint of the skvm::Builder to skip Builder::done().
>
> This version makes an explicit Key structure holding all the parameters
> that currently matter to the Blitter, and caches using that.  This is
> nice because it can be done much more cheaply than running the JIT, and
> much more cheaply even than running the Builder.  It also makes the
> parameterization of the Blitter explicit, which I like.
>
> This does sometimes create programs that are equivalent but have
> different keys, but that's not that common, and it's pretty harmless.
> E.g. today if the device colorType() is opaque or premul, we'll think
> those are different programs, but actually end up making the exact
> same calls to Builder.  No big deal, and maybe even gives us a
> suggestion to do something when the destination is opaque to skip work.
> I've left that as a TODO followup.
>
> We really only need a small cache to get a good hit rate.  Running all
> GMs in one process serially, we're now down to 22 calls to done() from
> >100K at head (and >500K yesterday).  (Would be 13 if we treated opaque
> and premul the same.)
>
> There are two places I'd like to have used tryAcquire() on an SkSpinlock
> but the thread safety static analysis is wrong and prevents me.  Left
> some TODOs.
>
> Change-Id: I83a365fc895720c76b56b0e5a78f4c673fcd9d64
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232817
> Commit-Queue: Mike Klein <mtklein@google.com>
> Reviewed-by: Herb Derby <herb@google.com>

Change-Id: Ib6a8528be1cd89ae32b09d63c14925d9ba2f529a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233056
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-08-07 15:11:02 +00:00
Ben Wagner
549476357c Mark SkBitmaskEnum operators constexpr.
Change-Id: I498beee590ff7728f4d49da28d9a2b9909409c48
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232763
Reviewed-by: Hal Canary <halcanary@skia.org>
Commit-Queue: Ben Wagner <bungeman@google.com>
2019-08-07 14:32:10 +00:00
Eric Boren
593290ed75 [infra] Remove flag from run_recipe.py
Change-Id: I2915bd06c96a55054e97e95e848a9ea12cdb0100
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233036
Reviewed-by: Ravi Mistry <rmistry@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
2019-08-07 12:31:00 +00:00
Mike Reed
63db48c3ce Revert "begin caching Programs in SkVMBlitter"
This reverts commit d1d4cbf2e4.

Reason for revert: static initializers broken checks in Chrome Roll

e.g. gProgramCache{8}

Original change's description:
> begin caching Programs in SkVMBlitter
> 
> My first drafts put caching inside SkVM.cpp, which I rejected for
> feeling a little too magic, and then in SkVMBuilder.cpp using a
> fingerprint of the skvm::Builder to skip Builder::done().
> 
> This version makes an explicit Key structure holding all the parameters
> that currently matter to the Blitter, and caches using that.  This is
> nice because it can be done much more cheaply than running the JIT, and
> much more cheaply even than running the Builder.  It also makes the
> parameterization of the Blitter explicit, which I like.
> 
> This does sometimes create programs that are equivalent but have
> different keys, but that's not that common, and it's pretty harmless.
> E.g. today if the device colorType() is opaque or premul, we'll think
> those are different programs, but actually end up making the exact
> same calls to Builder.  No big deal, and maybe even gives us a
> suggestion to do something when the destination is opaque to skip work.
> I've left that as a TODO followup.
> 
> We really only need a small cache to get a good hit rate.  Running all
> GMs in one process serially, we're now down to 22 calls to done() from
> >100K at head (and >500K yesterday).  (Would be 13 if we treated opaque
> and premul the same.)
> 
> There are two places I'd like to have used tryAcquire() on an SkSpinlock
> but the thread safety static analysis is wrong and prevents me.  Left
> some TODOs.
> 
> Change-Id: I83a365fc895720c76b56b0e5a78f4c673fcd9d64
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232817
> Commit-Queue: Mike Klein <mtklein@google.com>
> Reviewed-by: Herb Derby <herb@google.com>

TBR=mtklein@google.com,herb@google.com

Change-Id: I9a32f24b79054f7174d82bb8e6aca2a9f65894e8
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/233037
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2019-08-07 12:15:22 +00:00
skia-autoroll
ed19e97294 Roll third_party/externals/angle2 bf176a0d6db9..415bb0cdb057 (9 commits)
bf176a0d6d..415bb0cdb0

git log bf176a0d6db9..415bb0cdb057 --date=short --no-merges --format='%ad %ae %s'
2019-08-07 dustingreen@google.com IWYU - zircon/assert.h without stdlib.h
2019-08-06 jmadill@chromium.org Strip extension from packed GLenum data.
2019-08-06 ianelliott@google.com Vulkan: Enable GL_UNPACK_SKIP_IMAGES in the Tex*Image* code
2019-08-06 syoussefi@chromium.org Vulkan: Refactor atomic counter retype code
2019-08-06 lujc@google.com Vulkan: Use a persistent CommandPool
2019-08-06 syoussefi@chromium.org Vulkan: Support unaligned atomic counter buffer binding
2019-08-06 timvp@google.com Vulkan: Suppress KHR-GLES2 ASTC 3D Texture Tests
2019-08-06 ianelliott@google.com Vulkan: Enable GL_NV_pixel_buffer_object extension
2019-08-06 angle-autoroll@skia-public.iam.gserviceaccount.com Roll ./third_party/spirv-tools/src 4f14b4c8cc25..698b56a8f024 (1 commits)

Created with:
  gclient setdep -r third_party/externals/angle2@415bb0cdb057

The AutoRoll server is located here: https://autoroll.skia.org/r/angle-skia-autoroll

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md

If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.


CQ_INCLUDE_TRYBOTS=skia.primary:Build-Debian9-Clang-x86_64-Release-ANGLE;skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC8i5BEK-GPU-IntelIris655-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE
Bug: None
TBR=reed@google.com
Change-Id: I38045cd214ad35c9e0246def573ae34512228316
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232941
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2019-08-07 05:30:59 +00:00
skia-recreate-skps
d70f4cbaef Update Go deps
Change-Id: Id8783eba4ea545d89165fcaafbb1b450e77b37d4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232949
Reviewed-by: <skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com>
Commit-Queue: <skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com>
2019-08-07 05:25:09 +00:00
skia-autoroll
6aef844345 Roll ../src aefed1d022e5..2d05439f2779 (412 commits)
aefed1d022..2d05439f27


Created with:
  gclient setdep -r ../src@2d05439f27

The AutoRoll server is located here: https://autoroll.skia.org/r/chromium-skia-autoroll

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md

If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.


CQ_INCLUDE_TRYBOTS=skia.primary:Perf-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Release-All-CommandBuffer;skia.primary:Test-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Debug-All-CommandBuffer
Bug: None
TBR=reed@google.com
Change-Id: I429912fb15693568595b8e5740fce19267b590bf
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232943
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2019-08-07 04:38:59 +00:00
skia-autoroll
0429733a49 Roll third_party/externals/swiftshader 060fcf777159..3aec8a3be749 (1 commits)
https://swiftshader.googlesource.com/SwiftShader.git/+log/060fcf777159..3aec8a3be749

git log 060fcf777159..3aec8a3be749 --date=short --no-merges --format='%ad %ae %s'
2019-08-06 chrisforbes@google.com Tidy around sampler handling

Created with:
  gclient setdep -r third_party/externals/swiftshader@3aec8a3be749

The AutoRoll server is located here: https://autoroll.skia.org/r/swiftshader-skia-autoroll

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md

If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.


CQ_INCLUDE_TRYBOTS=skia.primary:Test-Debian9-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader
Bug: None
TBR=reed@google.com
Change-Id: Ib22584452e91ca04c98b6212c77e3061645e811e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232942
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2019-08-07 04:35:59 +00:00
Konstantin Pozin
c13305320f [fuchsia] Migrate SkFontMgr_fuchsia to approved fuchsia.fonts FIDL API
I18N-34

Bug: skia:9307

Change-Id: I6d6e777e4f60d266aa7bea97def482f398a7dbc1
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232122
Auto-Submit: Konstantin Pozin <kpozin@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
Reviewed-by: Sergey Ulanov <sergeyu@chromium.org>
2019-08-06 22:48:04 +00:00
recipe-roller
fcb8d5b662 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (e.g. depot_tools) into downstream projects
(e.g. tools/build).


More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.
recipe_engine:
  https://crrev.com/3250825222c4ad1b804b18c20fff693e7da55b4f [file] Add recursive=... option to file.listdir(...). (vadimsh@chromium.org)


TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ibce9f0f6665f39d907db98c76c720d16432ecc8c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232822
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2019-08-06 22:33:34 +00:00
Ben Wagner
ab961e9db1 Use MD instead of MMD for compile dependencies.
The current use of MMD appears to ignore all includes which are resolved
from pointy bracket includes or system paths. This can lead to very
interesting incomplete rebuilds (or no rebuild at all) when updating
third_party headers or when the system headers are updated. The use of
MD makes the build depend on all the headers transitively included no
matter how they were included. This greatly increases the dependencies,
but only so much as to make them correct (barring the ever difficult
issue of a file being created with the same name earlier in the search
path).

Change-Id: I852e617f23b4ff0c5b4eb3068455428c9568e078
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232762
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
2019-08-06 21:18:01 +00:00
Mike Klein
d1d4cbf2e4 begin caching Programs in SkVMBlitter
My first drafts put caching inside SkVM.cpp, which I rejected for
feeling a little too magic, and then in SkVMBuilder.cpp using a
fingerprint of the skvm::Builder to skip Builder::done().

This version makes an explicit Key structure holding all the parameters
that currently matter to the Blitter, and caches using that.  This is
nice because it can be done much more cheaply than running the JIT, and
much more cheaply even than running the Builder.  It also makes the
parameterization of the Blitter explicit, which I like.

This does sometimes create programs that are equivalent but have
different keys, but that's not that common, and it's pretty harmless.
E.g. today if the device colorType() is opaque or premul, we'll think
those are different programs, but actually end up making the exact
same calls to Builder.  No big deal, and maybe even gives us a
suggestion to do something when the destination is opaque to skip work.
I've left that as a TODO followup.

We really only need a small cache to get a good hit rate.  Running all
GMs in one process serially, we're now down to 22 calls to done() from
>100K at head (and >500K yesterday).  (Would be 13 if we treated opaque
and premul the same.)

There are two places I'd like to have used tryAcquire() on an SkSpinlock
but the thread safety static analysis is wrong and prevents me.  Left
some TODOs.

Change-Id: I83a365fc895720c76b56b0e5a78f4c673fcd9d64
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232817
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Herb Derby <herb@google.com>
2019-08-06 21:05:41 +00:00
Chris Dalton
08755129a1 Add a GrTextureResolveManager class
Adds a GrTextureResolveManager class and plumbs it through calls to
generate the drawing manager's dependency DAG. This new class is
currently unimplemented, but it wraps GrDrawingManager and will
eventually give limited access to functionality for making new tasks
that regenerate mipmaps and/or resolve MSAA. We will use this object
to move mipmap generation up to the DAG/proxy level.

Bug: skia:
Change-Id: Ie1deef21e7ae579a0262f2eeb93d451f0740d823
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232633
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2019-08-06 20:47:31 +00:00
Shachar Langbeheim
87cef069ca Allow compilation without embedded font but with font manager
Change-Id: Ib21ec28d7d2051bc19c07294b37034f44af47004
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232856
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Kevin Lubick <kjlubick@google.com>
2019-08-06 19:53:30 +00:00
Mike Klein
5fac8a15c8 really no-op Program default constructor
By funnelling the no-arg Program constructor through the main one, we're
actually JITting a small program that doesn't do anything but loop
today.  Skipping that saves _a whole lot_ of pointless mmap, mprotect,
munmap, Assembler calls, etc.

Change-Id: I88b3589177dfd86978b030644759a28e1783b702
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232818
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-08-06 19:51:30 +00:00
recipe-roller
68fbc2654a Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (e.g. depot_tools) into downstream projects
(e.g. tools/build).


More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.
depot_tools:
  https://crrev.com/f994d87e5693b6f8c66f686324c85777f9e9dae5 Revert "Reland "depot_tools: Move six to depot_tools' .vpython"" (jdarpinian@chromium.org)


TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: I2a2167a922d5a6b1eb2281b2e9bab06a4632a648
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232838
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2019-08-06 19:31:07 +00:00
Chris Dalton
5fe99773c5 Add a 'closeRenderTasksForNewOpList' method to GrDrawingManager
This consolidates some duplicate code across newRTOpList and
newTextureOpList.

Bug: skia:
Change-Id: I3a3c150e20e3db279de476307c5281668c3fdd9a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232836
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2019-08-06 19:02:32 +00:00
recipe-roller
f64b46e5a7 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (e.g. depot_tools) into downstream projects
(e.g. tools/build).


More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.
depot_tools:
  https://crrev.com/d52b306f84eaf9e5e8be0f22536a3f589b010ae6 Reland "depot_tools: Move six to depot_tools' .vpython" (ehmaldonado@chromium.org)
recipe_engine:
  https://crrev.com/001b2e2cd58a5ecd31f1ae49bf6227fe0706d59c Add update script for buildbucket protos. (iannucci@chromium.org)


TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: I40197ba7d85eca00f03b1468cf2b2ce3200b7239
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232837
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2019-08-06 18:39:12 +00:00
Hal Canary
d5611554c3 SkQP: modify make_universal_apk to work in AOSP branch
Change-Id: I2e7c6c3fce1561e3727a2a6d4a69e2b1bbd8c75c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232758
Commit-Queue: Hal Canary <halcanary@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Auto-Submit: Hal Canary <halcanary@google.com>
2019-08-06 18:17:38 +00:00
recipe-roller
a933257ba3 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (e.g. depot_tools) into downstream projects
(e.g. tools/build).


More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.
recipe_engine:
  https://crrev.com/5d464559eb518abe977bcccf2c5d95b6c76b0cc8 Output the command one argument per line in execution details. (gbeaty@chromium.org)


TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ieb6ae35c4d96c534c0212c18b0104f7d42d2574f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232796
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2019-08-06 17:41:31 +00:00
Mike Klein
c853bf2867 build programs lazily in SkVMBlitter
When run over all GMs, this cuts the number of programs
we build and JIT from 531,012 down to 141,930.

Draws the same, of course.

Change-Id: Ia804ded23496a2f534fb94d047547c9b644f3cfc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232776
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-08-06 17:15:28 +00:00
Greg Daniel
900583a11e Update some gpu caps isFormatRenderable calls.
This adds an isFormatRenderable call that doesn't take a GrColorType
which will be used in future changes. Also renamed the one that
takes a GrColorType to be more explixit what its use is.

Bug: skia:6718
Change-Id: Ib5a11aacccc4d94d21bc39be05f116ec3b23a3e6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232757
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2019-08-06 17:09:08 +00:00
Hal Canary
e45bf6a603 experimental/editor: interface no longer uses stringslice
Editor::copy() now writes into a buffer provided by the client.

    Editor::text() now returns a series of `pair<const char*, size_t>`
    instead of `const StringSlice&`

Change-Id: Iff298dd7a80aaad19f9326d10c5b67bea5ef8e22
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/232579
Commit-Queue: Hal Canary <halcanary@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2019-08-06 16:52:08 +00:00