platform/upstream/libSkiaSharp.git
7 years agoRevert "Fix NoGPU compilation"
Brian Osman [Tue, 15 Nov 2016 18:06:18 +0000 (18:06 +0000)]
Revert "Fix NoGPU compilation"

This reverts commit d5a78805c5133bc55e07c5da21f8d72b91a3df4f.

Reason for revert: This was a patch for an earlier change that's going to be reverted as well.

Original change's description:
> Fix NoGPU compilation
>
> All of these functions were written to work without GPU support, just
> forgot to compile them in that situation.
>
> BUG=skia:
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4796
>
> Change-Id: Ia23d304f07eb16714390b459dd448bc08402f479
> Reviewed-on: https://skia-review.googlesource.com/4796
> Reviewed-by: Brian Osman <brianosman@google.com>
> Reviewed-by: Stan Iliev <stani@google.com>
> Commit-Queue: Brian Osman <brianosman@google.com>
> Commit-Queue: Stan Iliev <stani@google.com>
>

TBR=egdaniel@google.com,brianosman@google.com,stani@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: Id0b9db355f416c118c0ef95501a6cfdeb083b54e
Reviewed-on: https://skia-review.googlesource.com/4831
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
7 years agoRevert "While we can, restrict SkFixedAlloc/SkFallbackAlloc to POD."
Mike Klein [Tue, 15 Nov 2016 17:58:33 +0000 (17:58 +0000)]
Revert "While we can, restrict SkFixedAlloc/SkFallbackAlloc to POD."

This reverts commit 1ee70359a199f161ce38451989a706d727954cc1.

Reason for revert: breaking my various rolls.

Original change's description:
> While we can, restrict SkFixedAlloc/SkFallbackAlloc to POD.
>
> This trims the overhead down to a uniform 4 bytes.
>
> BUG=skia:
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4786
>
> Change-Id: I92127a0c2d6c23a4a372eca39842e22195d2dc99
> Reviewed-on: https://skia-review.googlesource.com/4786
> Reviewed-by: Herb Derby <herb@google.com>
> Commit-Queue: Mike Klein <mtklein@chromium.org>
>

TBR=mtklein@chromium.org,herb@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: Iae9ef553422352a1abf95b709fccd014d468da86
Reviewed-on: https://skia-review.googlesource.com/4829
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
7 years agoRevert "fix google3?"
Mike Klein [Tue, 15 Nov 2016 17:57:48 +0000 (17:57 +0000)]
Revert "fix google3?"

This reverts commit ccb8e8bf38f51e35e0a456c6a724bab96d1b657a.

Reason for revert: rolling back a CL this attempted to fix.

Original change's description:
> fix google3?
>
> TBR=brianosman@google.com
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4822
>
> Change-Id: I991232e90c6851938151daa59cdeb4a3e22a7f03
> Reviewed-on: https://skia-review.googlesource.com/4822
> Commit-Queue: Mike Klein <mtklein@chromium.org>
> Reviewed-by: Brian Osman <brianosman@google.com>
> Reviewed-by: Mike Klein <mtklein@chromium.org>
>

TBR=mtklein@chromium.org,brianosman@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I127165f065be45af98528c8ae825e2f0fe5c8b0d
Reviewed-on: https://skia-review.googlesource.com/4828
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
7 years agoFix up arguments passed to pipeline.
Mike Klein [Tue, 15 Nov 2016 15:31:38 +0000 (10:31 -0500)]
Fix up arguments passed to pipeline.

  - Add half to (x,y) to get pixel centers.
  - The x updates were just totally wrong...

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4794
CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot

Change-Id: I314489a74b54e2b88f12dd35896452ac0b9718f3
Reviewed-on: https://skia-review.googlesource.com/4794
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agofix google3?
Mike Klein [Tue, 15 Nov 2016 16:56:56 +0000 (11:56 -0500)]
fix google3?

TBR=brianosman@google.com

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4822

Change-Id: I991232e90c6851938151daa59cdeb4a3e22a7f03
Reviewed-on: https://skia-review.googlesource.com/4822
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Brian Osman <brianosman@google.com>
Reviewed-by: Mike Klein <mtklein@chromium.org>
7 years agochange SkCanvasStack to take ownership of its subcanvases
Mike Reed [Tue, 15 Nov 2016 16:52:55 +0000 (11:52 -0500)]
change SkCanvasStack to take ownership of its subcanvases

Inspired by https://bugs.chromium.org/p/chromium/issues/detail?id=663959

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4799

Change-Id: I69f7ac73386bb7ca96778e2fec4cb2757b982a52
Reviewed-on: https://skia-review.googlesource.com/4799
Commit-Queue: Mike Reed <reed@google.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
7 years agoFix NoGPU compilation
Brian Osman [Tue, 15 Nov 2016 15:55:12 +0000 (10:55 -0500)]
Fix NoGPU compilation

All of these functions were written to work without GPU support, just
forgot to compile them in that situation.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4796

Change-Id: Ia23d304f07eb16714390b459dd448bc08402f479
Reviewed-on: https://skia-review.googlesource.com/4796
Reviewed-by: Brian Osman <brianosman@google.com>
Reviewed-by: Stan Iliev <stani@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Commit-Queue: Stan Iliev <stani@google.com>

7 years agoWhile we can, restrict SkFixedAlloc/SkFallbackAlloc to POD.
Mike Klein [Tue, 15 Nov 2016 15:26:44 +0000 (10:26 -0500)]
While we can, restrict SkFixedAlloc/SkFallbackAlloc to POD.

This trims the overhead down to a uniform 4 bytes.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4786

Change-Id: I92127a0c2d6c23a4a372eca39842e22195d2dc99
Reviewed-on: https://skia-review.googlesource.com/4786
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoResurrect SkDebugger
Florin Malita [Tue, 15 Nov 2016 15:03:32 +0000 (10:03 -0500)]
Resurrect SkDebugger

Can't let go <sniffle>.

R=robertphillips@google.com

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4793

Change-Id: Ida5936d17af2ef60c3f50e27b4f4987a79165fa5
Reviewed-on: https://skia-review.googlesource.com/4793
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Florin Malita <fmalita@chromium.org>

7 years agoSupport decoding images to multiple formats, depending on usage
Brian Osman [Mon, 14 Nov 2016 20:09:56 +0000 (15:09 -0500)]
Support decoding images to multiple formats, depending on usage

Our codec generator will now preserve any asked-for color space, and
convert the encoded data to that representation. Cacherator now
allows decoding an image to both legacy (nullptr color space), and
color-correct formats. In color-correct mode, we choose the best
decoded format, based on the original properties, and our backend's
capabilities. Preference is given to the native format, when it's
already texturable (sRGB 8888 or F16 linear). Otherwise, we prefer
linear F16, and fall back to sRGB when that's not an option.

BUG=skia:5907

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4438

Change-Id: I847c243dcfb72d8c0f1f6fc73c09547adea933f0
Reviewed-on: https://skia-review.googlesource.com/4438
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>

7 years agoDefer more renderTargetContexts in the GPU image filter paths
Robert Phillips [Mon, 14 Nov 2016 18:23:15 +0000 (13:23 -0500)]
Defer more renderTargetContexts in the GPU image filter paths

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4767

Change-Id: I4c1f27247ef340a49d1ac96761810e77e6047ca2
Reviewed-on: https://skia-review.googlesource.com/4767
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>

7 years agoStart each pipeline with (x,y) in (dr,dg) registers for the shader.
Mike Klein [Tue, 15 Nov 2016 13:52:04 +0000 (08:52 -0500)]
Start each pipeline with (x,y) in (dr,dg) registers for the shader.

Image shaders need to do some geometry work before sampling the image colors:
  1) determine dst coordinates
  2) map back to src coordinates
  3) tiling

Feeding (x,y) through as (dr,dg) registers makes step 1) easy, perhaps trivial, while leaving (r,g,b,a) with their usual meanings, "the color", starting with the paint color.

This is easy to tweak into something like (x+0.5, y+0.5, 1) in (dr,dg,db) once this lands.  Mostly I just want to get all the uninteresting boilerplate out of the way first.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4791
CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot

Change-Id: Ia07815d942ded6672dc1df785caf80a508fc8f37
Reviewed-on: https://skia-review.googlesource.com/4791
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoMake SkSmallAllocator obey the RAII invariants and move to heap structures when needed.
herb [Tue, 15 Nov 2016 14:26:56 +0000 (06:26 -0800)]
Make SkSmallAllocator obey the RAII invariants and move to heap structures when needed.

The biggest change is to the API which allowed code to bypass the
destruction invariants. This destruction bypass feature was needed in
only one use, and is totally encapsulated using createWithIniterT.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2488523003

Committed: https://skia.googlesource.com/skia/+/d5dc657b8c3ac916f98005dafdedafe02f023449
Committed: https://skia.googlesource.com/skia/+/c18b5f8f57a4efc5d5d1e399ed8bd3bd02c592ab
Review-Url: https://codereview.chromium.org/2488523003

7 years ago[nobuildbot] Nexus 6p
Eric Boren [Tue, 15 Nov 2016 12:25:23 +0000 (07:25 -0500)]
[nobuildbot] Nexus 6p

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4788

Change-Id: I5049bd59eccfc3106991096652765b79c9dbaffd
Reviewed-on: https://skia-review.googlesource.com/4788
Commit-Queue: Eric Boren <borenet@google.com>
Reviewed-by: Ravi Mistry <rmistry@google.com>
7 years agoFix iOS builders.
Mike Klein [Mon, 14 Nov 2016 23:05:16 +0000 (18:05 -0500)]
Fix iOS builders.

Gyp... sigh.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4787

Change-Id: I5488bbc6a8e267dc42d1c716cf0f879b662af171
Reviewed-on: https://skia-review.googlesource.com/4787
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoCatch width overflow in ASAN using int64
Yuqian Li [Mon, 14 Nov 2016 21:45:01 +0000 (16:45 -0500)]
Catch width overflow in ASAN using int64

This is related with our previous CL:
https://skia-review.googlesource.com/c/4628/

That previous CL fix won't pass the ASAN test (../../../include/core/SkRect.h:72:39: runtime error: signed integer overflow: 1 - -2147483648 cannot be represented in type 'int') so we use int64 in this CL.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4785

Change-Id: I39f7329c427d49f4be07588f37120722ac9892c2
Reviewed-on: https://skia-review.googlesource.com/4785
Reviewed-by: Mike Reed <reed@google.com>
7 years agoFill in gamut-transformation TODOs for software pipeline.
Mike Klein [Mon, 14 Nov 2016 21:02:41 +0000 (16:02 -0500)]
Fill in gamut-transformation TODOs for software pipeline.

This adds support for paint colors, color shaders, and mode color filters (everything that the software pipeline supports today).

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4781

Change-Id: I6e5da6d0dba03fbc82ecaa233ce8c727e7ce17b3
Reviewed-on: https://skia-review.googlesource.com/4781
Reviewed-by: Brian Osman <brianosman@google.com>
7 years agoFix Sk4fLinearGradient initial interval pinning
Florin Malita [Mon, 14 Nov 2016 20:54:04 +0000 (15:54 -0500)]
Fix Sk4fLinearGradient initial interval pinning

For repeat/mirror mode, fx tiling needs to ensure the value doesn't
collapse to the open interval value due to float arithmetic.

Clamp to the next lower representable value.

BUG=skia:5955
R=reed@google.com

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4784

Change-Id: I635394d15a80276e88c18a499f93f3047464f190
Reviewed-on: https://skia-review.googlesource.com/4784
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Florin Malita <fmalita@chromium.org>

7 years agoTemporarily Disable analytic AA for Google3
Yuqian Li [Mon, 14 Nov 2016 20:42:58 +0000 (15:42 -0500)]
Temporarily Disable analytic AA for Google3

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4782

Change-Id: Iba7ea0a5aaaf3ba3821094c527ddc4fe4e32cb79
Reviewed-on: https://skia-review.googlesource.com/4782
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Yuqian Li <liyuqian@google.com>

7 years agoAdd skpbench job
Kevin Lubick [Mon, 14 Nov 2016 18:42:27 +0000 (13:42 -0500)]
Add skpbench job

This entails a few parts:
1. Isolating tools/skpbench/ to be used by the perf task.

2. Adding skpbench to BUILD_PRODUCTS_ISOLATE_WHITELIST

3. Add recipe commands to run skpbench. While it is conceptually similar
to nanobench, it doesn't support images nor svgs, only skps, so we don't
need to copy those to devices or bring them in via CIPD.

4. Add recipe commands to parse skpbench output and upload to Perf.

5. Update gen_tasks.go to handle skpbench jobs and tasks.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4551

Change-Id: I09bf0b078067279e138e95eca9316e55539ec735
Reviewed-on: https://skia-review.googlesource.com/4551
Commit-Queue: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
7 years agoskpbench: skiaperf.py modifications
csmartdalton [Mon, 14 Nov 2016 18:35:02 +0000 (11:35 -0700)]
skpbench: skiaperf.py modifications

- Appends the clock and unit to the result type (e.g. "accum_cpu_ms").
- Removes the "options" key.
- Adds "bench_type" and "source_type" keys to the properties.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4737

Change-Id: I2fd27eac4f42f443131fef6b1774f20e60571cd5
Reviewed-on: https://skia-review.googlesource.com/4737
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>

7 years agoCompute the correct dst->src rect for bitmap tiles in SkGpuDevice
Brian Salomon [Mon, 14 Nov 2016 19:41:58 +0000 (14:41 -0500)]
Compute the correct dst->src rect for bitmap tiles in SkGpuDevice

Use anisotropic scale to show bug in verylargebitmap test.

BUG=chromium:664615

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4774

Change-Id: If92eab6d26b9fb506670412a80df259f99db2a21
Reviewed-on: https://skia-review.googlesource.com/4774
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
7 years agoStale visualize_color_gamut.cpp reference in tools.gyp
Florin Malita [Mon, 14 Nov 2016 19:29:00 +0000 (14:29 -0500)]
Stale visualize_color_gamut.cpp reference in tools.gyp

TBR=msarett@google.com

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4775

Change-Id: I6ca3379ca9578dc9a7f158a1a01b6a73bf301f17
Reviewed-on: https://skia-review.googlesource.com/4775
Commit-Queue: Florin Malita <fmalita@chromium.org>
Reviewed-by: Matt Sarett <msarett@google.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
7 years agoRevert "Add IORef capability to GrSurfaceProxy objects"
Robert Phillips [Mon, 14 Nov 2016 19:29:24 +0000 (19:29 +0000)]
Revert "Add IORef capability to GrSurfaceProxy objects"

This reverts commit 286b96f876953c94c178e3abbeb4eab186ad1fef.

Reason for revert:

Failure on Mac Mini:

FAILURE: ../../../tests/ProxyRefTest.cpp:59 proxy->getPendingWriteCnt_TestOnly() == expectedNumWrites

../../../tests/ProxyRefTest.cpp:64: fatal error: "assert(proxy->getPendingWriteCnt_TestOnly() == expectedNumWrites)"

Original change's description:
> Add IORef capability to GrSurfaceProxy objects
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4734
>
> Change-Id: If10fbe555e9fa3331bfa01065028e1afe82adb78
> Reviewed-on: https://skia-review.googlesource.com/4734
> Commit-Queue: Robert Phillips <robertphillips@google.com>
> Reviewed-by: Brian Salomon <bsalomon@google.com>
>

TBR=bsalomon@google.com,robertphillips@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I5e1c201e027d4e9687b01f28a418b1884d3f9ece
Reviewed-on: https://skia-review.googlesource.com/4776
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
7 years agoSet analytic AA as default.
liyuqian [Mon, 14 Nov 2016 19:17:16 +0000 (11:17 -0800)]
Set analytic AA as default.

We'll use https://codereview.chromium.org/2471123002/ to keep Chrome from using
analytic AA until we fix all the Chrome tests.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2471133002

Committed: https://skia.googlesource.com/skia/+/dca4f6530013cf43a2557ccb07f5cb4fd916b8e8
Review-Url: https://codereview.chromium.org/2471133002

7 years agoAdd IORef capability to GrSurfaceProxy objects
Robert Phillips [Mon, 14 Nov 2016 18:31:14 +0000 (13:31 -0500)]
Add IORef capability to GrSurfaceProxy objects

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4734

Change-Id: If10fbe555e9fa3331bfa01065028e1afe82adb78
Reviewed-on: https://skia-review.googlesource.com/4734
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
7 years agoRoll recipe DEPS
Eric Boren [Mon, 14 Nov 2016 17:18:34 +0000 (12:18 -0500)]
Roll recipe DEPS

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4771

Change-Id: Ie48178db0ea56909be61d32e3139b1ca1a648728
Reviewed-on: https://skia-review.googlesource.com/4771
Reviewed-by: Ravi Mistry <rmistry@google.com>
Commit-Queue: Eric Boren <borenet@google.com>

7 years agoRemove accumulative snapping error
Yuqian Li [Mon, 14 Nov 2016 16:51:41 +0000 (11:51 -0500)]
Remove accumulative snapping error

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4769

Change-Id: Ie70bdc280c680c82f3b8a186466bf3a0835a9107
Reviewed-on: https://skia-review.googlesource.com/4769
Reviewed-by: Cary Clark <caryclark@google.com>
Commit-Queue: Yuqian Li <liyuqian@google.com>

7 years agoRemove SkOSFile.cpp.
Ben Wagner [Mon, 14 Nov 2016 16:19:52 +0000 (11:19 -0500)]
Remove SkOSFile.cpp.

This file has been renamed SkOSPath.cpp and users no longer refer to the
old name. Remove this now empty file and its build rule.

Change-Id: I5041b61e749cc86f491b6c99b6744d7a0d4f9d1c
Reviewed-on: https://skia-review.googlesource.com/4766
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Ben Wagner <bungeman@google.com>

7 years agoAdd new A2B color space test images
Matt Sarett [Mon, 14 Nov 2016 16:06:36 +0000 (11:06 -0500)]
Add new A2B color space test images

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4763

Change-Id: I8972a4b31b2e284602e6f168d1d3ee20dcf537f1
Reviewed-on: https://skia-review.googlesource.com/4763
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Matt Sarett <msarett@google.com>

7 years agoProperly handle INT_MIN and related
Kevin Lubick [Mon, 14 Nov 2016 13:32:03 +0000 (08:32 -0500)]
Properly handle INT_MIN and related

BUG=skia:5967

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4751

Change-Id: Ie846560ebdaf11e1a5247842b3549ade1e100af2
Reviewed-on: https://skia-review.googlesource.com/4751
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Kevin Lubick <kjlubick@google.com>

7 years agoRemove static asserts for GrSLType and GrVertexAttribType enum values.
Brian Salomon [Mon, 14 Nov 2016 16:27:00 +0000 (11:27 -0500)]
Remove static asserts for GrSLType and GrVertexAttribType enum values.

Replaces with switch statements that will produce a compiler warning if a type is added and helper functions are not updated.

This also removes several unused helper functions for these enum types.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4486

Change-Id: Iee6d8e5095dc4ba2488a8928bf60f8e903cd3320
Reviewed-on: https://skia-review.googlesource.com/4486
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
7 years agoadded skslc to BUILD.gn
Ethan Nicholas [Mon, 14 Nov 2016 16:16:37 +0000 (11:16 -0500)]
added skslc to BUILD.gn

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4764

Change-Id: I89330cfa4be4d43d9183a8e53b28d6c0061f33e2
Reviewed-on: https://skia-review.googlesource.com/4764
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>

7 years agoGN: detect is_clang cheaply when possible.
Mike Klein [Sun, 13 Nov 2016 15:29:25 +0000 (10:29 -0500)]
GN: detect is_clang cheaply when possible.

Running is_clang.py is the current long-poll in `gn gen` time.
We can avoid it trivially in a few situations:
  - We always use Clang on Android, iOS, and Mac.
  - If cc and cxx are clang and clang++, it's Clang.

This cuts `gn gen` time from 80ms to 20ms on my laptop.

(Did you know gn has a --tracelog=trace.log option for creating Chrome-tracing-compatible traces?  Pretty neat.)

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4746

Change-Id: Ic81d221675e8309cc9942bb9e62243d86658b02d
Reviewed-on: https://skia-review.googlesource.com/4746
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Ben Wagner <bungeman@google.com>
7 years agoexperimental/xps_to_png: pass in DPI as program argument
Hal Canary [Mon, 14 Nov 2016 15:36:24 +0000 (10:36 -0500)]
experimental/xps_to_png: pass in DPI as program argument

NOTRY=true
Change-Id: Ieb4f43c69a4f185d8e7877c9c736bd6a7d7b1eac
Reviewed-on: https://skia-review.googlesource.com/4761
Reviewed-by: Hal Canary <halcanary@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>

7 years agoStart hooking shaders into SkRasterPipelineBlitter.
Mike Klein [Sat, 12 Nov 2016 15:29:26 +0000 (10:29 -0500)]
Start hooking shaders into SkRasterPipelineBlitter.

Here first just the simplest, constant-color shaders.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4743

Change-Id: I92c6523660e21a1e2aa353524570230282ba5dfe
Reviewed-on: https://skia-review.googlesource.com/4743
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoStart plumbing deferral of GPU resources in the image filters
Robert Phillips [Thu, 10 Nov 2016 22:03:43 +0000 (17:03 -0500)]
Start plumbing deferral of GPU resources in the image filters

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4688

Change-Id: I904d999ea87a55bee73765aa96a2f8aef7a0d61c
Reviewed-on: https://skia-review.googlesource.com/4688
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>

7 years agoApple's Clang can't assemble jsimd_arm_...
Mike Klein [Mon, 14 Nov 2016 14:16:32 +0000 (09:16 -0500)]
Apple's Clang can't assemble jsimd_arm_...

This should fix Build-Mac-Clang-arm64-Debug-GN_iOS_NoBuildbot.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4755

Change-Id: Ie49ce5642fb2d373102c9309074e13ee3035a569
Reviewed-on: https://skia-review.googlesource.com/4755
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoRevert "Always build the ANGLE test code. Always build ANGLE on windows and linux."
Mike Klein [Mon, 14 Nov 2016 14:53:13 +0000 (14:53 +0000)]
Revert "Always build the ANGLE test code. Always build ANGLE on windows and linux."

This reverts commit 238b820369c4b556c2e7c8277855e6950de3d9eb.

Reason for revert: breaks 32-bit bots, iOS bots, Google3 roll, -ASAN bot.

Original change's description:
> Always build the ANGLE test code. Always build ANGLE on windows and linux.
>
> Make ANGLE test code independent of having ANGLE lib. Make ANGLE test code not include EGL headers.
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4040
>
> DOCS_PREVIEW= https://skia.org/?cl=4040
>
> Change-Id: I7b857e9785246743f53fb969647b1162ce7419ab
> Reviewed-on: https://skia-review.googlesource.com/4040
> Commit-Queue: Brian Salomon <bsalomon@google.com>
> Reviewed-by: Mike Klein <mtklein@chromium.org>
>

TBR=mtklein@chromium.org,mtklein@google.com,bsalomon@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I19bab8c93baebf032f8a4cefbedfe7359317e806
Reviewed-on: https://skia-review.googlesource.com/4758
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
7 years agoAlways build the ANGLE test code. Always build ANGLE on windows and linux.
Brian Salomon [Fri, 11 Nov 2016 20:35:34 +0000 (15:35 -0500)]
Always build the ANGLE test code. Always build ANGLE on windows and linux.

Make ANGLE test code independent of having ANGLE lib. Make ANGLE test code not include EGL headers.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4040

DOCS_PREVIEW= https://skia.org/?cl=4040

Change-Id: I7b857e9785246743f53fb969647b1162ce7419ab
Reviewed-on: https://skia-review.googlesource.com/4040
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Mike Klein <mtklein@chromium.org>
7 years agoDocumentation: move some things around
Hal Canary [Mon, 14 Nov 2016 13:29:46 +0000 (08:29 -0500)]
Documentation:  move some things around

NOTRY=true
DOCS_PREVIEW= https://skia.org/?cl=4750

Change-Id: I0d1bc77a533ede8e0514ff0b680a5aa851051fc6
Reviewed-on: https://skia-review.googlesource.com/4750
Reviewed-by: Heather Miller <hcm@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>

7 years agoMark inline functions in SkTypes.h as static.
Mike Klein [Mon, 14 Nov 2016 13:39:39 +0000 (08:39 -0500)]
Mark inline functions in SkTypes.h as static.

If these are not marked static (or SK_FORCE_INLINE) they become extremely dangerous to use from files built with different optimization flags than the baseline.  The One Definition Rule becomes trivially easy to violate, and the linker can easily pick a CPU-specific version of the function.

TBR=reed@google.com

BUG=chromium:664864

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4752

Change-Id: If3044a32229db1a1e3a8b83aace6047d92b36d05
Reviewed-on: https://skia-review.googlesource.com/4752
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
7 years agoGN: turn on easy libjpeg-turbo SIMD backends (ARMv7 and ARMv8)
Mike Klein [Sun, 13 Nov 2016 13:52:07 +0000 (08:52 -0500)]
GN: turn on easy libjpeg-turbo SIMD backends (ARMv7 and ARMv8)

These are so easy we might as well...

I did a quick check of relevant-looking defines:
   - GYP defined WITH_SIMD, but it looks like that's already defined (by jconfig.h?);
   - GYP defined RGBX_FILLER_0XFF, but that affects only x86/x86-64;
   - GYP defined STRICT_MEMORY_ACCESS, which does nothing;
   - GYP defined MOTION_JPEG_SUPPORTED, which does nothing (and we'd probably not care anyway).

BUG=skia:5875

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4745

Change-Id: Ib1f28d354630be472c4d9648d5ade74a452a9e24
Reviewed-on: https://skia-review.googlesource.com/4745
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoRevert[2] "Change SkCanvas to *not* inherit from SkRefCnt"
Mike Reed [Sat, 12 Nov 2016 14:06:55 +0000 (08:06 -0600)]
Revert[2] "Change SkCanvas to *not* inherit from SkRefCnt"

Changes over original:
- conditionalize ownership in SkPictureRecorder
- conditionalize ownership in SkCanvasStateUtils

This reverts commit b613c266df48cf45296ecc23d1bd7098c84bb7ba.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4742

Change-Id: Ib25514d6f546c69b6650b5c957403b04f7380dc2
Reviewed-on: https://skia-review.googlesource.com/4742
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>

7 years agoRevert of Make SkSmallAllocator obey the RAII invariants and be expandable (patchset...
mtklein [Sun, 13 Nov 2016 17:55:05 +0000 (09:55 -0800)]
Revert of Make SkSmallAllocator obey the RAII invariants and be expandable (patchset #15 id:280001 of https://codereview.chromium.org/2488523003/ )

Reason for revert:
bots crashing / asserting

Original issue's description:
> Make SkSmallAllocator obey the RAII invariants and move to heap structures when needed.
>
> The biggest change is to the API which allowed code to bypass the
> destruction invariants. This destruction bypass feature was needed in
> only one use, and is totally encapsulated using createWithIniterT.
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2488523003
>
> Committed: https://skia.googlesource.com/skia/+/d5dc657b8c3ac916f98005dafdedafe02f023449
> Committed: https://skia.googlesource.com/skia/+/c18b5f8f57a4efc5d5d1e399ed8bd3bd02c592ab

TBR=bungeman@google.com,herb@google.com
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review-Url: https://codereview.chromium.org/2494353002

7 years agoMake SkSmallAllocator obey the RAII invariants and move to heap structures when needed.
herb [Sun, 13 Nov 2016 17:34:18 +0000 (09:34 -0800)]
Make SkSmallAllocator obey the RAII invariants and move to heap structures when needed.

The biggest change is to the API which allowed code to bypass the
destruction invariants. This destruction bypass feature was needed in
only one use, and is totally encapsulated using createWithIniterT.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2488523003

Committed: https://skia.googlesource.com/skia/+/d5dc657b8c3ac916f98005dafdedafe02f023449
Review-Url: https://codereview.chromium.org/2488523003

7 years ago[gn] Disable use of dng SDK in Fuchsia
James Robinson [Sun, 13 Nov 2016 02:29:39 +0000 (18:29 -0800)]
[gn] Disable use of dng SDK in Fuchsia

These libraries aren't configured in Fuchsia and would need some GN
reworking to enable. We can wire this up in Fuchsia if/when this
capability when needed.

Change-Id: Iec2d339da07f44516592d6114563a8a4fb59d952
Reviewed-on: https://skia-review.googlesource.com/4744
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoSkPath::fIsVolatile does not need to be mutable.
Mike Klein [Fri, 11 Nov 2016 15:43:44 +0000 (10:43 -0500)]
SkPath::fIsVolatile does not need to be mutable.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4696

Change-Id: I48b438ab1d99033ab2a422fb28e976cdf9188365
Reviewed-on: https://skia-review.googlesource.com/4696
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoFix SkModeColorFilter in 565
Mike Klein [Fri, 11 Nov 2016 17:51:36 +0000 (12:51 -0500)]
Fix SkModeColorFilter in 565

It has been incorrectly interpreting its SkColor as sRGB all the time.  Now, we plumb through the destintation color space and some scratch space, letting it decide how to interpret its SkColor later when it knows about the dst color space.  The scratch space is blitter scoped, which lets this be thread safe (this is much like SkShader::Context).

This only corrects the gamma transformation for now.  I've kept my previous TODO about gamut transformation.  Everything assumes sRGB gamut for now.

Shaders will get the same treatement in this pipeline.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4725

Change-Id: I55b0c7d5db9ad8d7dcdd6295c9dac61d10aeaed4
Reviewed-on: https://skia-review.googlesource.com/4725
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoRevert "Annotate benign race on SkPath::fConvexity."
Mike Klein [Sat, 12 Nov 2016 12:04:05 +0000 (12:04 +0000)]
Revert "Annotate benign race on SkPath::fConvexity."

This reverts commit c51a3a4e3c81a1d4100d5d29d31bf3a02eda2a7c.

Reason for revert: had to revert this in the copy constructor.  Might as well revert here too for consistency.

Original change's description:
> Annotate benign race on SkPath::fConvexity.
>
> We're tired of this making our TSAN bot flaky, and equally tired of trying to fix it.
>
> BUG=skia:5776
>
> CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-Clang-GCE-CPU-AVX2-x86_64-Release-TSAN-Trybot
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4691
>
> Change-Id: Ib6005282c514a6d785fd4fffe5387cbb1caccbe1
> Reviewed-on: https://skia-review.googlesource.com/4691
> Commit-Queue: Mike Klein <mtklein@chromium.org>
> Reviewed-by: Ben Wagner <bungeman@google.com>
>

TBR=mtklein@chromium.org,bungeman@google.com,reed@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I906b1e017471d9e00fc58402136497459d881f72
Reviewed-on: https://skia-review.googlesource.com/4740
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
7 years agoRevert "Annotate SkPath::fCovexity benign race in the other constructor too."
Mike Klein [Sat, 12 Nov 2016 12:00:44 +0000 (12:00 +0000)]
Revert "Annotate SkPath::fCovexity benign race in the other constructor too."

This reverts commit f978f12af553f899cfed7078ab63d3a71c6fbcb1.

Reason for revert: slowing the TSAN bot down to the point of timeouts.

Original change's description:
> Annotate SkPath::fCovexity benign race in the other constructor too.
>
> I overlooked the copy constructor last time.
>
> BUG=skia:5776
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4730
>
> Change-Id: I30bc89e1472dd48badf57664cfae8899f44bca9e
> Reviewed-on: https://skia-review.googlesource.com/4730
> Reviewed-by: Mike Klein <mtklein@chromium.org>
> Commit-Queue: Mike Klein <mtklein@chromium.org>
>

TBR=mtklein@chromium.org,reed@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I6e34b1fc80fd98387d79521ce24f4545b990eb25
Reviewed-on: https://skia-review.googlesource.com/4739
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
7 years agoInitial implementation of a SkColorSpace_A2B xform
raftias [Fri, 11 Nov 2016 23:27:39 +0000 (15:27 -0800)]
Initial implementation of a SkColorSpace_A2B xform

There is support for all features of SkColorSpace_A2B.

Tests for these functionality were adapted from
the XYZ xform, plus a CLUT-specific test was added.

Shared functions used by both SkColorSpaceXform_XYZ and SkColorSpaceXform_A2B
have been moved into a shared header.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2449243003
CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot

Review-Url: https://codereview.chromium.org/2449243003

7 years agoClean up glyph id handling.
Ben Wagner [Fri, 11 Nov 2016 19:31:06 +0000 (14:31 -0500)]
Clean up glyph id handling.

Extract SkPackedID and its strongly typed subclasses SkPackedGlyphID and
SkPackedUnicharID out of SkGlyph. This simplifies the code handling
these types, as well as making it clearer that we wouuld eventually like
to get away from this scheme.

Changes SkScalerContext::getPath to take SkPackedGlyphID.
Changes SkScalerContext::generatePath to take SkGlyphID.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4722

Change-Id: I365c0c618b7ae0d348272155fac7761a69faa920
Reviewed-on: https://skia-review.googlesource.com/4722
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Herb Derby <herb@google.com>
7 years agoRevert "Revert "Add integer texture support.""
Brian Salomon [Fri, 11 Nov 2016 21:08:03 +0000 (16:08 -0500)]
Revert "Revert "Add integer texture support.""

This reverts commit 9c7edb8311409a141b0dc1d5e480c68c629f1997.

Fixes ASAN errors

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4736

Change-Id: I1b1dae754d357b01da7169c8e7c59d7d8d8a10f6
Reviewed-on: https://skia-review.googlesource.com/4736
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>

7 years agoRevert of Set analytic AA as default. (patchset #8 id:140001 of https://codereview...
liyuqian [Fri, 11 Nov 2016 21:30:48 +0000 (13:30 -0800)]
Revert of Set analytic AA as default. (patchset #8 id:140001 of https://codereview.chromium.org/2471133002/ )

Reason for revert:
SkASSERT triggered in some perf tests. Roll back.

Original issue's description:
> Set analytic AA as default.
>
> We'll use https://codereview.chromium.org/2471123002/ to keep Chrome from using
> analytic AA until we fix all the Chrome tests.
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2471133002
>
> Committed: https://skia.googlesource.com/skia/+/dca4f6530013cf43a2557ccb07f5cb4fd916b8e8

TBR=fmalita@chromium.org,msarett@google.com,mtklein@google.com,reed@google.com,mtklein@chromium.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review-Url: https://codereview.chromium.org/2499723002

7 years agore-re-land of skslc now uses standard Skia caps
Ethan Nicholas [Fri, 11 Nov 2016 20:16:46 +0000 (15:16 -0500)]
re-re-land of skslc now uses standard Skia caps

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4732

Change-Id: I144110bf66f67a28da7ad333173db43bddf9e8d0
Reviewed-on: https://skia-review.googlesource.com/4732
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>

7 years agoSet analytic AA as default.
liyuqian [Fri, 11 Nov 2016 21:07:16 +0000 (13:07 -0800)]
Set analytic AA as default.

We'll use https://codereview.chromium.org/2471123002/ to keep Chrome from using
analytic AA until we fix all the Chrome tests.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2471133002

Review-Url: https://codereview.chromium.org/2471133002

7 years agoAnnotate SkPath::fCovexity benign race in the other constructor too.
Mike Klein [Fri, 11 Nov 2016 19:36:17 +0000 (14:36 -0500)]
Annotate SkPath::fCovexity benign race in the other constructor too.

I overlooked the copy constructor last time.

BUG=skia:5776

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4730

Change-Id: I30bc89e1472dd48badf57664cfae8899f44bca9e
Reviewed-on: https://skia-review.googlesource.com/4730
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoClean up validation layers
Jim Van Verth [Fri, 11 Nov 2016 17:41:04 +0000 (09:41 -0800)]
Clean up validation layers

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4727

Change-Id: I92cef6fd23cd629a7a68e6ecb9e048674556517b
Reviewed-on: https://skia-review.googlesource.com/4727
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>

7 years agoSnap y when updating cubic
Yuqian Li [Fri, 11 Nov 2016 17:37:45 +0000 (12:37 -0500)]
Snap y when updating cubic

If we don't snap, we could have end up with many tiny line segments
wihtin a single row of pixels. That combined with our partial alpha
rounding code (https://codereview.chromium.org/2483523002/) could
accumlate so much error that violates our alpha <= 256 assert.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4724

Change-Id: I58b02cffc8a4dc9f541e194d61a2f6fef7b85c97
Reviewed-on: https://skia-review.googlesource.com/4724
Reviewed-by: Cary Clark <caryclark@google.com>
Commit-Queue: Yuqian Li <liyuqian@google.com>

7 years agoRe-purpose color space tool
Matt Sarett [Fri, 11 Nov 2016 18:59:14 +0000 (13:59 -0500)]
Re-purpose color space tool

(1) Compile tool with GN.
(2) Rename tool to colorspaceinfo.
(3) Support both images and icc profiles as input.
(4) Print out information on transfer fn in addition to gamut.

TODO: Output graphs of the three transfer fn curves.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4721

Change-Id: I2e75139685ea41446d3ae6f9803c8068ea05661a
Reviewed-on: https://skia-review.googlesource.com/4721
Commit-Queue: Matt Sarett <msarett@google.com>
Reviewed-by: Mike Klein <mtklein@chromium.org>
Reviewed-by: Brian Osman <brianosman@google.com>
7 years agoRevert "re-land of skslc now uses standard Skia caps"
Leon Scroggins [Fri, 11 Nov 2016 18:44:37 +0000 (18:44 +0000)]
Revert "re-land of skslc now uses standard Skia caps"

This reverts commit 498d403f7703cb2157bf3c877b84906db5a06cd4.

Reason for revert: Breaking compile bot:
https://uberchromegw.corp.google.com/i/client.skia.compile/builders/Build-Ubuntu-GCC-x86_64-Release-NoGPU/builds/10116/steps/compile_skia%20on%20Ubuntu/logs/stdio

undefined reference to `GrGLSLCaps::GrGLSLCaps(GrContextOptions const&)

Original change's description:
> re-land of skslc now uses standard Skia caps
>
> BUG=skia:
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4726
>
> Change-Id: Ib1ea5d4269396e6c57ee1f0d7209aa9a9f2798e8
> Reviewed-on: https://skia-review.googlesource.com/4726
> Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
> Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
>

TBR=bsalomon@google.com,benjaminwagner@google.com,kjlubick@google.com,ethannicholas@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I7ee96d6c658be6b7b79027c147b8950c78c79a70
Reviewed-on: https://skia-review.googlesource.com/4729
Commit-Queue: Leon Scroggins <scroggo@google.com>
Reviewed-by: Leon Scroggins <scroggo@google.com>
7 years agoAdd explicit UniqueID classes for GrGpuResource & GrSurfaceProxy
Robert Phillips [Fri, 11 Nov 2016 17:38:40 +0000 (12:38 -0500)]
Add explicit UniqueID classes for GrGpuResource & GrSurfaceProxy

This sets the stage for using the Proxy's/RenderTargetContext's ID above the flush and the RenderTarget's/GrGpuResource's below the flush.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4650

Change-Id: I9f1e6b00c02a0691d90b58c49e1d8c60684884c1
Reviewed-on: https://skia-review.googlesource.com/4650
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
7 years agore-land of skslc now uses standard Skia caps
Ethan Nicholas [Fri, 11 Nov 2016 17:38:50 +0000 (12:38 -0500)]
re-land of skslc now uses standard Skia caps

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4726

Change-Id: Ib1ea5d4269396e6c57ee1f0d7209aa9a9f2798e8
Reviewed-on: https://skia-review.googlesource.com/4726
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>

7 years agoTighten SkAAClip Bounds by Path Bounds
liyuqian [Fri, 11 Nov 2016 17:59:51 +0000 (09:59 -0800)]
Tighten SkAAClip Bounds by Path Bounds

This bug chromium:662780 exists after our original fix (https://codereview.chromium.org/2477393002/) because this path (added in unit test) is calling blitAntiRect rather than blitAntiH when the path is drifted across the boundary. (The quadratic edge drifts across the boundary after an update and sets a dX=0 line segment which triggers blitAntiRect.)

Note that I didn't assert for the dLeft = dRite = 0 case because the left/right there won't drift after the SkTMin/SkTMax in line 964/966.

Theoretically we can revert the relaxation in https://codereview.chromium.org/2477393002/ (that's only a relaxation for analytic AA, not supersampled AA). However, consider that the initial landing of analytic AA is so painful, I decide to revert that relaxation only after our successful landing...

BUG=chromium:662780, chromium:662862
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2482193004

Review-Url: https://codereview.chromium.org/2482193004

7 years agoGN: build Lua tools when skia_use_lua.
Mike Klein [Fri, 11 Nov 2016 16:39:44 +0000 (11:39 -0500)]
GN: build Lua tools when skia_use_lua.

When we opt into Lua, this builds SampleLua into SampleApp, and the lua_app and lua_pictures tools.

I've tested this builds with and without skia_use_system_lua on my Mac laptop and Linux desktop.

I've made lua_pictures.cpp's flags static to avoid conflicts with flags in SkCommonFlags.cpp.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4699

DOCS_PREVIEW= https://skia.org/?cl=4699

Change-Id: I8176fd51d8a38746e7d730cfcce66da42b9a015a
Reviewed-on: https://skia-review.googlesource.com/4699
Reviewed-by: Hal Canary <halcanary@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoDocumentation: more gn, less gyp
Hal Canary [Fri, 11 Nov 2016 16:40:04 +0000 (11:40 -0500)]
Documentation: more gn, less gyp

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4698
NOTRY=true
DOCS_PREVIEW= https://skia.org/?cl=4698

Change-Id: I03100542752a769060a7f0c9671cc44acbea2e48
Reviewed-on: https://skia-review.googlesource.com/4698
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Hal Canary <halcanary@google.com>

7 years agoSkFixedAlloc
Mike Klein [Fri, 11 Nov 2016 15:38:49 +0000 (10:38 -0500)]
SkFixedAlloc

Looking at SkSmallAlloc hasn't left me terribly impressed.  I think we can replace it with something a lot simpler to work with.

That simpler thing's core would be something like SkFixedAlloc, which allocates objects out of a fixed sized buffer, and cleans them up when done.

If needed, we can wrap that with logic to try to allocate out of an SkFixedAlloc, falling back on mallc() when exhausted.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4658

Change-Id: I8d94156ddf98802e42ec0890cff0f06b21f073b0
Reviewed-on: https://skia-review.googlesource.com/4658
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Reed <reed@google.com>
7 years agoSkip left/right if alpha = 0 in SkRectClipCheckBlitter::blitAntiRect
Yuqian Li [Fri, 11 Nov 2016 14:40:34 +0000 (09:40 -0500)]
Skip left/right if alpha = 0 in SkRectClipCheckBlitter::blitAntiRect

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4684

Change-Id: I8c5e5f460dba76f9d74718f7ea104cb1f3cea993
Reviewed-on: https://skia-review.googlesource.com/4684
Commit-Queue: Yuqian Li <liyuqian@google.com>
Reviewed-by: Cary Clark <caryclark@google.com>
7 years agoCatch width overflow
Yuqian Li [Fri, 11 Nov 2016 14:36:53 +0000 (09:36 -0500)]
Catch width overflow

BUG=chromium:662730

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4628

Change-Id: Iaf3a30d39fda3166a6f8fc62a30580629418dc88
Reviewed-on: https://skia-review.googlesource.com/4628
Reviewed-by: Cary Clark <caryclark@google.com>
Commit-Queue: Yuqian Li <liyuqian@google.com>

7 years agoRevert "skslc now uses standard Skia caps"
Leon Scroggins [Fri, 11 Nov 2016 15:50:45 +0000 (15:50 +0000)]
Revert "skslc now uses standard Skia caps"

This reverts commit 8af38a96475ac5ce83b20c16d9cf82bf1006b8c4.

Reason for revert: Breaking compile bots, e.g. from https://uberchromegw.corp.google.com/i/client.skia.compile/builders/Build-Ubuntu-GCC-x86_64-Debug-NoGPU/builds/10029/steps/compile_skia%20on%20Ubuntu/logs/stdio :

In function `sk_make_sp<GrGLSLCaps, GrContextOptions>'
undefined reference to `GrGLSLCaps::GrGLSLCaps(GrContextOptions const&)

In function `_Z10sk_make_spI10GrGLSLCapsI16GrContextOptionsEE5sk_spIT_EDpOT0_':
undefined reference to `GrGLSLCaps::GrGLSLCaps(GrContextOptions const&)

Original change's description:
> skslc now uses standard Skia caps
>
> BUG=skia:
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4660
>
> Change-Id: Idaedae3f81426b97f5052bb872cdf0610e47a84f
> Reviewed-on: https://skia-review.googlesource.com/4660
> Reviewed-by: Ben Wagner <benjaminwagner@google.com>
> Reviewed-by: Brian Salomon <bsalomon@google.com>
> Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
>

TBR=bsalomon@google.com,benjaminwagner@google.com,ethannicholas@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: Ic7f987f5c050ac2e333f5a0f16c8de85c1047a74
Reviewed-on: https://skia-review.googlesource.com/4697
Commit-Queue: Leon Scroggins <scroggo@google.com>
Reviewed-by: Leon Scroggins <scroggo@google.com>
7 years agoskslc now uses standard Skia caps
Ethan Nicholas [Thu, 10 Nov 2016 21:42:58 +0000 (16:42 -0500)]
skslc now uses standard Skia caps

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4660

Change-Id: Idaedae3f81426b97f5052bb872cdf0610e47a84f
Reviewed-on: https://skia-review.googlesource.com/4660
Reviewed-by: Ben Wagner <benjaminwagner@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>

7 years agoAnnotate benign race on SkPath::fConvexity.
Mike Klein [Thu, 10 Nov 2016 23:09:51 +0000 (18:09 -0500)]
Annotate benign race on SkPath::fConvexity.

We're tired of this making our TSAN bot flaky, and equally tired of trying to fix it.

BUG=skia:5776

CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-Clang-GCE-CPU-AVX2-x86_64-Release-TSAN-Trybot

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4691

Change-Id: Ib6005282c514a6d785fd4fffe5387cbb1caccbe1
Reviewed-on: https://skia-review.googlesource.com/4691
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Ben Wagner <bungeman@google.com>
7 years agoAvoid platform-dependent function params in Fuzzer
Kevin Lubick [Thu, 10 Nov 2016 21:17:49 +0000 (16:17 -0500)]
Avoid platform-dependent function params in Fuzzer

We use this approach instead of T next() because different compilers
evaluate function parameters in different orders. If fuzz->next()
returned 5 and then 7, foo(fuzz->next(), fuzz->next()) would be
foo(5, 7) when compiled on GCC and foo(7, 5) when compiled on Clang.
By requiring params to be passed in, we avoid the temptation to call
next() in a way that does not consume fuzzed bytes in a single
platform-independent order.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4392

Change-Id: I35de849f82e8be45378f662a48100eb732fa8895
Reviewed-on: https://skia-review.googlesource.com/4392
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Kevin Lubick <kjlubick@google.com>

7 years agoCheck and report FreeType error.
Ben Wagner [Thu, 10 Nov 2016 21:14:52 +0000 (16:14 -0500)]
Check and report FreeType error.

BUG=chromium:648959

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4685

Change-Id: Ibc3cd5ddf37926accf1b7bf0959668510de903a8
Reviewed-on: https://skia-review.googlesource.com/4685
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Ben Wagner <bungeman@google.com>

7 years agoRevert "Change SkCanvas to *not* inherit from SkRefCnt"
Heather Miller [Thu, 10 Nov 2016 21:25:30 +0000 (21:25 +0000)]
Revert "Change SkCanvas to *not* inherit from SkRefCnt"

This reverts commit 824075071885b6b741c141cbe2134d8345d34589.

Reason for revert: Breaking WebView (chromium:663959)

Original change's description:
> Change SkCanvas to *not* inherit from SkRefCnt
>
> Definitely tricky for classes like SkNWayCanvas, where the caller (today)
> need not pay attention to ownership of the canvases it gave the NWay
> (after this CL, the caller *must* managed ownership)
>
> BUG=skia:
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4441
>
> DOCS_PREVIEW= https://skia.org/?cl=4441
>
> Change-Id: Ib1ac07a3cdf0686d78e7aaa4735d45cc90bea081
> Reviewed-on: https://skia-review.googlesource.com/4441
> Commit-Queue: Mike Reed <reed@google.com>
> Reviewed-by: Florin Malita <fmalita@chromium.org>
> Reviewed-by: Robert Phillips <robertphillips@google.com>
>

TBR=djsollen@google.com,mtklein@google.com,halcanary@google.com,robertphillips@google.com,fmalita@chromium.org,fmalita@google.com,reed@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I5e3b3e876b7d2c09833cf841801321033b6b968b
Reviewed-on: https://skia-review.googlesource.com/4687
Commit-Queue: Heather Miller <hcm@google.com>
Reviewed-by: Heather Miller <hcm@google.com>
7 years agoRevert "Fix BUG=chromium:664036"
Heather Miller [Thu, 10 Nov 2016 21:21:55 +0000 (21:21 +0000)]
Revert "Fix BUG=chromium:664036"

This reverts commit 805eb6c7779eb855a26d0f1e821d58ce2bf5ffd2.

Reason for revert: Backing up to original change causing issues w/ WebView (chromium:663959)

Original change's description:
> Fix BUG=chromium:664036
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4659
>
> Change-Id: Idac00fef9cac023649a50d9c70d107f988fd2510
> Reviewed-on: https://skia-review.googlesource.com/4659
> Reviewed-by: Mike Reed <reed@google.com>
> Commit-Queue: Hal Canary <halcanary@google.com>
>

TBR=halcanary@google.com,reed@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I1c3258a3d46a713e9fa60fef829b8b6c6d73b2c4
Reviewed-on: https://skia-review.googlesource.com/4686
Commit-Queue: Heather Miller <hcm@google.com>
Reviewed-by: Heather Miller <hcm@google.com>
7 years agoskpbench: add utility to format results for Skia Perf
Kevin Lubick [Thu, 10 Nov 2016 19:19:00 +0000 (14:19 -0500)]
skpbench: add utility to format results for Skia Perf

Adds skiaperf.py for formatting skpbench.py outputs for Skia Perf.
Also renames parseskpbench.py to sheet.py.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4657

Change-Id: I758678e1c589b15ec2d07c43e4921663e919b47b
Reviewed-on: https://skia-review.googlesource.com/4657
Commit-Queue: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
7 years agoFix BUG=skia:5662
Hal Canary [Thu, 10 Nov 2016 18:03:21 +0000 (13:03 -0500)]
Fix BUG=skia:5662

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4661

Change-Id: I5f5b10387be5d538347a3626c165cc17af154212
Reviewed-on: https://skia-review.googlesource.com/4661
Reviewed-by: Hal Canary <halcanary@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>

7 years agoRevert "Add integer texture support."
Leon Scroggins [Thu, 10 Nov 2016 18:31:58 +0000 (18:31 +0000)]
Revert "Add integer texture support."

This reverts commit 434c534bd0ec08cb355fecfb6d2110197b523e74.

Reason for revert: Undefined behavior. From

https://uberchromegw.corp.google.com/i/client.skia/builders/Test-Ubuntu-Clang-Golo-GPU-GT610-x86_64-Debug-ASAN/builds/1272/steps/test_skia%20on%20Ubuntu/logs/stdio

../../../tests/IntTextureTest.cpp:51:44: runtime error: left shift of negative value -1
    #0 0x2257480 in test_IntTexture(skiatest::Reporter*, sk_gpu_test::ContextInfo const&) (/b/swarm_slave/w/ir0aO1sa/out/Debug/dm+0x2257480)
    #1 0x1ca1066 in skiatest::RunWithGPUTestContexts(void (*)(skiatest::Reporter*, sk_gpu_test::ContextInfo const&), bool (*)(sk_gpu_test::GrContextFactory::ContextType), skiatest::Reporter*, sk_gpu_test::GrContextFactory*) (/b/swarm_slave/w/ir0aO1sa/out/Debug/dm+0x1ca1066)
    #2 0x1ca080d in run_test(skiatest::Test) (/b/swarm_slave/w/ir0aO1sa/out/Debug/dm+0x1ca080d)
    #3 0x1c9e5e9 in dm_main() (/b/swarm_slave/w/ir0aO1sa/out/Debug/dm+0x1c9e5e9)
    #4 0x7f2d2ba8df44 in __libc_start_main /build/eglibc-oGUzwX/eglibc-2.19/csu/libc-start.c:287
    #5 0x1bb3028 in _start (/b/swarm_slave/w/ir0aO1sa/out/Debug/dm+0x1bb3028)

SUMMARY: AddressSanitizer: undefined-behavior ../../../tests/IntTextureTest.cpp:51:44 in
step returned non-zero exit code: 1

Original change's description:
> Add integer texture support.
>
> This allows us to create integer textures and sample them from a GrProcessor's code.
>
> Filtering is limited to NEAREST.
>
> Adds tests for reading/writing pixels, copying, and drawing. These operations are not allowed to convert to fixed/float configs.
>
> Vulkan support is TBD.
>
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4348
>
> Change-Id: If38d89a03285d4bd98d1f14f9638b0320977e43d
> Reviewed-on: https://skia-review.googlesource.com/4348
> Commit-Queue: Brian Salomon <bsalomon@google.com>
> Reviewed-by: Chris Dalton <csmartdalton@google.com>
>

TBR=bsalomon@google.com,csmartdalton@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I39f1a0a0dd3e6cde1143c8cc1217d2e3d5977b21
Reviewed-on: https://skia-review.googlesource.com/4663
Commit-Queue: Leon Scroggins <scroggo@google.com>
Reviewed-by: Leon Scroggins <scroggo@google.com>
7 years agoFix BUG=chromium:664036
Hal Canary [Thu, 10 Nov 2016 17:24:16 +0000 (12:24 -0500)]
Fix BUG=chromium:664036

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4659

Change-Id: Idac00fef9cac023649a50d9c70d107f988fd2510
Reviewed-on: https://skia-review.googlesource.com/4659
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>

7 years agoSkPDF: paths as rects when possible
Hal Canary [Thu, 10 Nov 2016 16:46:21 +0000 (11:46 -0500)]
SkPDF: paths as rects when possible

http://crrev.com/2269593003

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4652

Change-Id: I12e238e8f00ac1c54a1b8dcf82a5502240563288
Reviewed-on: https://skia-review.googlesource.com/4652
Commit-Queue: Hal Canary <halcanary@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
7 years agoAdd integer texture support.
Brian Salomon [Thu, 10 Nov 2016 16:19:51 +0000 (11:19 -0500)]
Add integer texture support.

This allows us to create integer textures and sample them from a GrProcessor's code.

Filtering is limited to NEAREST.

Adds tests for reading/writing pixels, copying, and drawing. These operations are not allowed to convert to fixed/float configs.

Vulkan support is TBD.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4348

Change-Id: If38d89a03285d4bd98d1f14f9638b0320977e43d
Reviewed-on: https://skia-review.googlesource.com/4348
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Chris Dalton <csmartdalton@google.com>
7 years agoSimplify SkBitmapProvider
Florin Malita [Thu, 10 Nov 2016 16:10:30 +0000 (11:10 -0500)]
Simplify SkBitmapProvider

We're no longer using SkBitmap sources for SkBitmapProvider, so we can
restrict it to SkImage only.

At this point we could also remove it, but I think it'll come in handy
when we add shader subset support.

BUG=skia:5806
R=reed@google.com

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4655

Change-Id: I298da253cc8f7c1205b543521e62060a202a9f78
Reviewed-on: https://skia-review.googlesource.com/4655
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Florin Malita <fmalita@chromium.org>

7 years agoUpdate skia.org docs to reference Gerrit instead of Rietveld
Ravi Mistry [Thu, 10 Nov 2016 15:07:29 +0000 (10:07 -0500)]
Update skia.org docs to reference Gerrit instead of Rietveld

BUG=skia:5958

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4648
NOTRY=true
DOCS_PREVIEW= https://skia.org/?cl=4648

Change-Id: I6a57b7f9b92f6b769ba2b78f8e0ab9f4ae7bb24e
Reviewed-on: https://skia-review.googlesource.com/4648
Commit-Queue: Ravi Mistry <rmistry@google.com>
Reviewed-by: Heather Miller <hcm@google.com>
7 years agoskpbench: add "resultsfile" option
csmartdalton [Thu, 10 Nov 2016 15:36:28 +0000 (10:36 -0500)]
skpbench: add "resultsfile" option

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4654

Change-Id: I1a26eddb40de1398cad5348d3fe0ba397a87dbb0
Reviewed-on: https://skia-review.googlesource.com/4654
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>

7 years agoSnug the clip with path bounds inside SkAAClip
Yuqian Li [Thu, 10 Nov 2016 14:44:55 +0000 (09:44 -0500)]
Snug the clip with path bounds inside SkAAClip

https://codereview.chromium.org/2482193004/ is related with this patch.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4636

Change-Id: Ibd6d64578e08c75a3cfcef45489afc9b59ad40be
Reviewed-on: https://skia-review.googlesource.com/4636
Commit-Queue: Yuqian Li <liyuqian@google.com>
Reviewed-by: Mike Reed <reed@google.com>
7 years agoMake SSE2/Neon convolution functions not to read extra bytes
xiangze.zhang [Thu, 10 Nov 2016 13:44:32 +0000 (05:44 -0800)]
Make SSE2/Neon convolution functions not to read extra bytes

This change makes SSE2/Neon horizontal convolution functions do not read
extra pixels past the end of the buffer. So we can remove all the SIMD
specific logic in SkConvolver to deal with last couple of rows and also
avoid applying padding to convolution filters.

Performance impact is small. Nanobench time change:
                              SSE2    NEON
bitmap_scale_filter_64_256     1%     -2%
bitmap_scale_filter_256_64     1%      2%
bitmap_scale_filter_90_10      1%     -1%
bitmap_scale_filter_90_30      1%      0%
bitmap_scale_filter_90_80      1%      0%
bitmap_scale_filter_90_90      1%      1%
bitmap_scale_filter_80_90      0%      0%
bitmap_scale_filter_30_90      3%      6%
bitmap_scale_filter_10_90      0%      2%

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2481733003
CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot

Review-Url: https://codereview.chromium.org/2481733003

7 years agoClamp parametric gamma values to 0-1 range
Matt Sarett [Wed, 9 Nov 2016 23:14:47 +0000 (18:14 -0500)]
Clamp parametric gamma values to 0-1 range

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4641

Change-Id: I1c6963da956500deea559d5ece31529add89980a
Reviewed-on: https://skia-review.googlesource.com/4641
Reviewed-by: Robert Aftias <raftias@google.com>
Commit-Queue: Matt Sarett <msarett@google.com>

7 years agoskpbench: remove --path flag
csmartdalton [Wed, 9 Nov 2016 21:34:53 +0000 (16:34 -0500)]
skpbench: remove --path flag

Replaces the confusing --path flag with a positional argument that
gives the path to the skpbench binary.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4635

Change-Id: I2b5eeca61ec85e7fe45fd3370625eddf34a2fd0e
Reviewed-on: https://skia-review.googlesource.com/4635
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Kevin Lubick <kjlubick@google.com>

7 years ago[nobuildbot] Copy timeouts from swarm_trigger
Eric Boren [Wed, 9 Nov 2016 23:35:15 +0000 (18:35 -0500)]
[nobuildbot] Copy timeouts from swarm_trigger

BUG=skia:

TBR=benjaminwagner
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4642

Change-Id: Ia81609af8ae11c0171c99c459e8711fa786c1e20
Reviewed-on: https://skia-review.googlesource.com/4642
Commit-Queue: Eric Boren <borenet@google.com>
Reviewed-by: Ben Wagner <benjaminwagner@google.com>
7 years agoRemove call to getMetrics from GlyphGenerator.
Ben Wagner [Wed, 9 Nov 2016 18:44:00 +0000 (13:44 -0500)]
Remove call to getMetrics from GlyphGenerator.

GlyphGenerator::generatePath does not need to call getMetrics before
calling getPath. This is wasted effort, especially since the
SkScalerContext is being used directly instead of going through a glyph
cache (which would require this ordering).

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4620

Change-Id: I140a6715a1d1692b161ee3dae48e5482b6004b63
Reviewed-on: https://skia-review.googlesource.com/4620
Reviewed-by: Chris Dalton <csmartdalton@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>

7 years agoRevert of Make SkSmallAllocator obey the RAII invariants and be expandable (patchset...
mtklein [Wed, 9 Nov 2016 22:50:31 +0000 (14:50 -0800)]
Revert of Make SkSmallAllocator obey the RAII invariants and be expandable (patchset #6 id:100001 of https://codereview.chromium.org/2488523003/ )

Reason for revert:
Crashing Mac Perf and Test bots.

This is a flaky but extremely likely crash.  I've only seen one Mac Perf or Test bot that had this patch that didn't crash.

This should be easy to reproduce like this:
  $ gn gen out --args=is_debug=false
  $ ninja -C out dm
  $ out/dm -m xfermodes3 --config gpu

This is crashing every time I run it on my laptop, and never when I revert this CL.

Building in release and running --config gpu probably don't matter.

Original issue's description:
> Make SkSmallAllocator obey the RAII invariants and move to heap structures when needed.
>
> The biggest change is to the API which allowed code to bypass the
> destruction invariants. This destruction bypass feature was needed in
> only one use, and is totally encapsulated using createWithIniterT.
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2488523003
>
> Committed: https://skia.googlesource.com/skia/+/d5dc657b8c3ac916f98005dafdedafe02f023449

TBR=bungeman@google.com,herb@google.com
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review-Url: https://codereview.chromium.org/2485853005

7 years agoAndroid builders do not need host toolchains.
Mike Klein [Wed, 9 Nov 2016 21:31:42 +0000 (16:31 -0500)]
Android builders do not need host toolchains.

This trims a few packages.  We do the same in buildbot.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4634

Change-Id: I4c76d744917cb244ca3390d55d9ea602cda2dd58
Reviewed-on: https://skia-review.googlesource.com/4634
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoauto-add Build jobs
Mike Klein [Wed, 9 Nov 2016 22:25:02 +0000 (17:25 -0500)]
auto-add Build jobs

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4639

Change-Id: I61acce39abf08c4307e5a7ec990ec8857539f943
Reviewed-on: https://skia-review.googlesource.com/4639
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>

7 years agoskpbench: call adb wait-for-device after root
csmartdalton [Wed, 9 Nov 2016 20:37:48 +0000 (15:37 -0500)]
skpbench: call adb wait-for-device after root

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4632

Change-Id: I310600e79141d2eafd668c76b97a017b151ac0fd
Reviewed-on: https://skia-review.googlesource.com/4632
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>

7 years agoadded constant folding & branch elimination to skslc
ethannicholas [Wed, 9 Nov 2016 21:26:45 +0000 (13:26 -0800)]
added constant folding & branch elimination to skslc

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2489673002

Committed: https://skia.googlesource.com/skia/+/6136310ee8f43247548bcefcaeca6d43023c10aa
Review-Url: https://codereview.chromium.org/2489673002

7 years agoskpbench: filter out junk spewed by Pixel C driver
csmartdalton [Wed, 9 Nov 2016 21:25:23 +0000 (13:25 -0800)]
skpbench: filter out junk spewed by Pixel C driver

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2488043003

Review-Url: https://codereview.chromium.org/2488043003

7 years agoFix implicit nullability cast of [NSScreen mainScreen].
Mike Klein [Wed, 9 Nov 2016 20:34:18 +0000 (15:34 -0500)]
Fix implicit nullability cast of [NSScreen mainScreen].

Without this patch I get this warning-as-error with XCode 8.1 (8B62):

../src/views/mac/SkOSWindow_Mac.mm:88:43: error: implicit conversion from nullable pointer 'NSScreen * _Nullable' to non-nullable pointer type 'NSScreen * _Nonnull' [-Werror,-Wnullable-to-nonnull-conversion]
    [(SkNSView*)fHWND enterFullScreenMode:[NSScreen mainScreen] withOptions:nil];

Seems like the thing to do is explicitly null check [NSScreen mainScreen] before calling enterFullScreenMode?

(google.com/images?q=i+have+no+idea+what+i+am+doing)

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4631

Change-Id: I20c4a2b559a347a6a128479b81cb515692832e72
Reviewed-on: https://skia-review.googlesource.com/4631
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
7 years agoRevert "add alias for xfermode::getproc to allow legacy g client to bulid"
Mike Reed [Wed, 9 Nov 2016 20:33:57 +0000 (15:33 -0500)]
Revert "add alias for xfermode::getproc to allow legacy g client to bulid"

Alias no longer needed

This reverts commit 40c07dc797ada471ba89cb81acc4b7b93f7374d7.

BUG=skia:

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4630

Change-Id: Ia3d13d6b1055ecb4b569c99f6047e4ab3d21f107
Reviewed-on: https://skia-review.googlesource.com/4630
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>