Commit Graph

1383 Commits

Author SHA1 Message Date
mtklein
a1ebeb25e9 Remove const from const int loops.
This drives me nuts, and prevents `while (loops --> 0)`.

BUG=skia:

Review URL: https://codereview.chromium.org/1379923005
2015-10-01 09:43:39 -07:00
joshualitt
8a6697af95 Fix for nexus 5 crashing in GL benches
GLBenches do not expect gl state  to change between onPerCanvasPreDraw and *PostDraw, but we do a clear and sometimes we clear as draw.  This causes us to bind vertex objects / programs / etc.

This change creates two new virtual methods which are called right before and immediately after timing.

BUG=skia:

Review URL: https://codereview.chromium.org/1379853003
2015-09-30 12:11:07 -07:00
scroggo
46c5747256 Merge SkCodec with SkScanlineDecoder
Benefits:
- This mimics other decoding APIs (including the ones SkCodec relies
on, e.g. a png_struct, which can be used to decode an entire image or
one line at a time).

- It allows a client to ask us to do what we can do efficiently - i.e.
start from encoded data and either decode the whole thing or scanlines.

- It removes the duplicate methods which appeared in both SkCodec and
SkScanlineDecoder (some of which, e.g. in SkJpegScanlineDecoder, just
call fCodec->sameMethod()).

- It simplifies moving more checks into the base class (e.g. the
examples in skbug.com/4284).

BUG=skia:4175
BUG=skia:4284

=====================================================================

SkScanlineDecoder.h/.cpp:
Removed.

SkCodec.h/.cpp:
Add methods, enums, and variables which were previously in
SkScanlineDecoder.
Default fCurrScanline to -1, as a sentinel that start has not been
called.

General changes:
Convert SkScanlineDecoders to SkCodecs.

General changes in SkCodec subclasses:
Merge SkScanlineDecoder implementation into SkCodec. Most (all?) owned
an SkCodec, so they now call this-> instead of fCodec->.

SkBmpCodec.h/.cpp:
Replace the unused rowOrder method with an override for
onGetScanlineOrder.
Make getDstRow const, since it is called by onGetY, which is const.

SkCodec_libpng.h/.cpp:
Make SkPngCodec an abstract class, with two subclasses which handle
scanline decoding separately (they share code for decoding the entire
image). Reimplement onReallyHasAlpha so that it can return the most
recent result (e.g. after a scanline decode which only decoded part
of the image) or a better answer (e.g. if the whole image is known to
be opaque).
Compute fNumberPasses early, so we know which subclass to instantiate.
Make SkPngInterlaceScanlineDecoder use the base class' fCurrScanline
rather than a separate variable.

CodexTest.cpp:
Add tests for the state changes in SkCodec (need to call start before
decoding scanlines; calling getPixels means that start will need to
be called again before decoding more scanlines).
Add a test which decodes in stripes, currently only used for an
interlaced PNG.

TODO: Add tests for onReallyHasAlpha.

Review URL: https://codereview.chromium.org/1365313002
2015-09-30 08:57:14 -07:00
halcanary
c11c62f4a2 DM: PDFSink sets rasterizer keyword
Review URL: https://codereview.chromium.org/1376573002
2015-09-28 11:51:54 -07:00
reed
c9e190ddac Revert of change pixel-serializer to support reencoding existing data (patchset #5 id:80001 of https://codereview.chromium.org/1373683003/ )
Reason for revert:
Need to somehow get access to encoders in chrome -- link error on the roll since SkImageEncoder is not built as part of chrome.

Original issue's description:
> change pixel-serializer to support reencoding existing data
>
> Trying to evolve this interface so it can
> - support rich set of backend-encoders (including ones like ETC1 that can cheaply convert to KXT
> - allow for encoding images as well as bitmaps (e.g. for picture serialization)
> - perhaps replace SkImageEncoder as an API (assuming we create a factory that returns a serializer given a format)
>
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/13f48dc85aa68a60da66aaf39c93d527d11d1278

TBR=scroggo@google.com,msarett@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review URL: https://codereview.chromium.org/1371983003
2015-09-28 09:58:41 -07:00
reed
13f48dc85a change pixel-serializer to support reencoding existing data
Trying to evolve this interface so it can
- support rich set of backend-encoders (including ones like ETC1 that can cheaply convert to KXT
- allow for encoding images as well as bitmaps (e.g. for picture serialization)
- perhaps replace SkImageEncoder as an API (assuming we create a factory that returns a serializer given a format)

BUG=skia:

Review URL: https://codereview.chromium.org/1373683003
2015-09-28 08:58:53 -07:00
reed
d114645d93 SkInstallDiscardablePixelRef is deprecated, enforce that
No functionality change, just a renaming.

BUG=skia:
TBR=

Review URL: https://codereview.chromium.org/1372593002
2015-09-25 06:56:57 -07:00
joshualitt
8db65a6d0c stop scaling loops and improve warmup bench
BUG=skia:

Review URL: https://codereview.chromium.org/1363663004
2015-09-24 12:42:02 -07:00
joshualitt
7d4b458b9f Add warmup bench to visual bench
BUG=skia:

Review URL: https://codereview.chromium.org/1358373003
2015-09-24 08:08:23 -07:00
benjaminwagner
6fccec34d2 Blacklist ReadPixels on GalaxyS4 due to skia:4368.
BUG=skia:4368

Review URL: https://codereview.chromium.org/1366723002
2015-09-24 06:39:06 -07:00
benjaminwagner
3420d2796b Blacklist GLVertexAttributesBench and GLVec4ScalarBench for GalaxyS4 due to skia:4373
BUG=skia:4373

Review URL: https://codereview.chromium.org/1365683003
2015-09-23 12:20:47 -07:00
benjaminwagner
a1a8a601ae Blacklist GLInstancedArraysBench for GalaxyS4 due to skia:4371
BUG=skia:4371

Review URL: https://codereview.chromium.org/1363963002
2015-09-23 11:41:04 -07:00
msarett
7f69144aaa Add nanobench tests for BitmapRegionDecoder
SkBitmapRegionDecoderInterface provides an interface
for multiple implementations of Android's
BitmapRegionDecoder.

We already have correctness tests in DM that will enable us
to compare the quality of our various BRD implementations.

We also need these performance tests to compare the speed
of our various implementations.

BUG=skia:4357

Review URL: https://codereview.chromium.org/1344993003
2015-09-22 11:56:16 -07:00
benjaminwagner
31459a4ace This file was supposed to be in https://codereview.chromium.org/1347143006/
BUG=skia:4367

Review URL: https://codereview.chromium.org/1351073003
2015-09-22 11:38:51 -07:00
benjaminwagner
59ea019fa0 Blacklist bleed_image on GalaxyS4.
BUG=skia:4367

Review URL: https://codereview.chromium.org/1347143006
2015-09-22 09:49:47 -07:00
borenet
08d7747ffe Buildbot specs for Linux ANGLE bot
BUG=skia:4362

Review URL: https://codereview.chromium.org/1361453002
2015-09-21 08:20:24 -07:00
robertphillips
5ce341fcd7 Add slice tool
Don't know if we want to add this but I found it useful when tracking down blur circle bugs.

Review URL: https://codereview.chromium.org/1350323002
2015-09-18 09:04:43 -07:00
joshualitt
fb33ae15ce Not correctly initializing VisualBench commandline arguments
TBR=mtklein@google.com
BUG=skia:

Review URL: https://codereview.chromium.org/1340163004
2015-09-18 06:47:39 -07:00
borenet
9063e427d2 Buildbot spec and gyp defs for SK_USE_DISCARDABLE_SCALEDIMAGECACHE bot
BUG=skia:4354

Review URL: https://codereview.chromium.org/1350283003
2015-09-18 06:37:14 -07:00
mtklein
d0fff5b6d8 Test-...-Release-SK_FOO --> -DSK_FOO
When a bot ends with extra_config SK_LIKE_THIS,
we'll define SK_LIKE_THIS when compiling.

CQ_EXTRA_TRYBOTS=client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SK_USE_DISCARDABLE_SCALEDIMAGECACHE-Trybot,Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot

BUG=skia:4354

Review URL: https://codereview.chromium.org/1346833004
2015-09-18 06:15:55 -07:00
ericrk
0a5fa484fd Add onMemoryDump to GrContext
Adds an entry point to GrContext to allow enumeration and tracing of GPU resources
via the newly added SkTraceMemoryDump.

Plan is for Chrome to call this on each of its GrContexts.

Dumps both the total size of GPU resources, as well as the total purgeable size.

BUG=526261

Review URL: https://codereview.chromium.org/1313743002
2015-09-15 14:16:10 -07:00
mtklein
ca6f43b6fd vb: also thread --key through to .json
BUG=skia:

Review URL: https://codereview.chromium.org/1342203002
2015-09-15 13:29:20 -07:00
jvanverth
f5d1b2de03 Add viewer mode to VisualBench.
Displays each benchmark/skp with a graph showing a series of frame times.
Use the space bar to skip to the next benchmark.

Adds an option to hit ESC to quit VisualBench. Useful in fullscreen mode.

Review URL: https://codereview.chromium.org/1336043003
2015-09-15 07:40:56 -07:00
reed
4d5b67637b formalize generate->bitmap
just move block of code to expose it

BUG=skia:4328
TBR=

Review URL: https://codereview.chromium.org/1334033004
2015-09-13 11:03:32 -07:00
mtklein
fe81e2d274 Make SkGraphics::Term a no-op, stop calling it.
I'd remove it entirely but Android is calling it explicitly.

BUG=skia:4259

Committed: https://skia.googlesource.com/skia/+/925979f733fe8e70d84627147dee04d030423349

Review URL: https://codereview.chromium.org/1329853005
2015-09-09 07:35:42 -07:00
mtklein
d9b8d7ac1f Revert of Make SkGraphics::Term a no-op, stop calling it. (patchset #2 id:20001 of https://codereview.chromium.org/1329853005/ )
Reason for revert:
SK_ATTR_DEPRECATED is meaningful to Android.  Don't use it.

Original issue's description:
> Make SkGraphics::Term a no-op, stop calling it.
>
> I'd remove it entirely but Android is calling it explicitly.
>
> BUG=skia:4259
>
> Committed: https://skia.googlesource.com/skia/+/925979f733fe8e70d84627147dee04d030423349

TBR=reed@google.com,scroggo@google.com,mtklein@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:4259

Review URL: https://codereview.chromium.org/1314483006
2015-09-09 07:22:09 -07:00
msarett
a5783aeff0 Provides various implementations of Android's SkBitmapRegionDecoder.
Implements testing in DM for these implementations.

nanobench testing will follow after this.

TBR=scroggo
BUG=skia:

Committed: https://skia.googlesource.com/skia/+/76f755e6d54a32f9887ad254ce59a3a62f28bde4

Review URL: https://codereview.chromium.org/1288963002
2015-09-08 15:35:32 -07:00
mtklein
925979f733 Make SkGraphics::Term a no-op, stop calling it.
I'd remove it entirely but Android is calling it explicitly.

BUG=skia:4259

Review URL: https://codereview.chromium.org/1329853005
2015-09-08 15:18:21 -07:00
joshualitt
189aef7834 Create module system for VisualBench
The newly created VisualLightweightBenchModule is just the old VisualBench.cpp, but gutted to only include timing code.

Future CLs will harden this abstraction, but for this CL the module owns a backpointer to VisualBench.cpp for a couple of calls.

BUG=skia:

Review URL: https://codereview.chromium.org/1304083007
2015-09-08 07:08:11 -07:00
joshualitt
55143211e9 Minor tweak to visual bench timing
BUG=skia:

Review URL: https://codereview.chromium.org/1310153005
2015-09-04 07:48:42 -07:00
robertphillips
943a462fef Minor code cleanup (left over from prior CL)
This was requested in https://codereview.chromium.org/1309543012/ (Add new GM to directly exercise perspective bitmap drawing)

Review URL: https://codereview.chromium.org/1320673011
2015-09-03 13:32:33 -07:00
borenet
d34d94766d Appurify bot: don't use flags that visualbench doesn't support
Depends on https://codereview.chromium.org/1320423005/
BUG=skia:4277

Review URL: https://codereview.chromium.org/1310903006
2015-09-03 12:31:26 -07:00
bsalomon
afcd7cd324 Rename flag from "distance field" to "device independent."
Review URL: https://codereview.chromium.org/1322433006
2015-08-31 12:39:41 -07:00
borenet
5e04bcfddd Run Appurify bot in release mode
BUG=skia:4093

Review URL: https://codereview.chromium.org/1306953006
2015-08-31 09:30:57 -07:00
caryclark
5ef194c31a Suppress embedding fonts when the skp's fonts match the OS fonts.
The million SKPs generated require >5T of storage. A good deal
of that are copies of system fonts.

Chrome built with
#DEFINE SK_WHITELIST_SERIALIZED_TYPEFACES
will omit the font data if the font matches a precomputed
checksum.

The captured SKP prepends sk_ to the names of fonts that
have their data omitted. The SKP consumer can either add
renamed fonts from the recording machine, or add

gDeserializeTypefaceDelegate = WhitelistDeserializeTypeface;

which strips the sk_ prefix when deserializing typefaces.

whitelist_typefaces --check
Computes the checksums of fallback
fonts and returns 0 if the checksums match the checked-in
file SkWhitelistChecksum.cpp.

whitelist_typefaces --generate
Writes an updated version of SkWhitelistChecksum.cpp.

(Added Mike since this modifies a public header)

R=bungeman@google.com,rmistry@google.com,reed@google.com

Review URL: https://codereview.chromium.org/1317913005
2015-08-31 09:22:38 -07:00
hendrikw
885bf09255 skia: add ability to load command_buffer_gles2
BUG=skia:

Review URL: https://codereview.chromium.org/1306823003
2015-08-27 10:38:39 -07:00
halcanary
96fcdcc219 Style Change: NULL->nullptr
DOCS_PREVIEW= https://skia.org/?cl=1316233002

Review URL: https://codereview.chromium.org/1316233002
2015-08-27 07:41:16 -07:00
halcanary
385fe4d4b6 Style Change: SkNEW->new; SkDELETE->delete
DOCS_PREVIEW= https://skia.org/?cl=1316123003

Review URL: https://codereview.chromium.org/1316123003
2015-08-26 13:07:49 -07:00
bungeman
60e0fee6d4 Remove include of stdlib.h from SkTypes.h.
Unfortunately, immintrin.h (which is also included by SkTypes)
includes xmmintrin.h which includes mm_malloc.h which includes
stdlib.h for malloc even though, from the implementation, it is
difficult to see why.

Fortunately, arm_neon.h does not seem to be involved in such
shenanigans, so building for Android will keep things sane.

TBR=reed@google.com
Doesn't change Skia API, just moves an include.

Review URL: https://codereview.chromium.org/1313203003
2015-08-26 05:15:46 -07:00
borenet
cf72ed6a3e Skip scaled_tilemodes_npot on Galaxy S4
It's hanging.

BUG=skia:3932

Review URL: https://codereview.chromium.org/1318503003
2015-08-25 06:53:37 -07:00
borenet
98f7e334e7 Add buildbot_spec info for Appurify bot
BUG=skia:4093

Review URL: https://codereview.chromium.org/1296593003
2015-08-24 12:50:59 -07:00
halcanary
2f0a728e5a GMs: change some GMs to use SkImage over SkBitmap
Also, add GetResourceAsImage() to Resources.h

Motivation:  test drawImage() as much as we test drawBitmap()

Review URL: https://codereview.chromium.org/1306133003
2015-08-21 07:47:23 -07:00
bungeman
99fe822606 Use static_assert instead of SK_COMPILE_ASSERT.
Now that static_assert is allowed, there is no need to use a non-
standard compile time assertion

Review URL: https://codereview.chromium.org/1306443004
2015-08-20 07:57:52 -07:00
bungeman
f3c15b7cfc Move SkTemplates.h to private.
SkTemplates.h contains a number of Skia specific utilities which are
not designed for external use. In addition to reducing the external
support burden, this will allow Skia to freely refactor this file.

Review URL: https://codereview.chromium.org/1272293004
2015-08-19 11:56:48 -07:00
mtklein
c6ad06acef unsigned -> int for counts and indices in picture-related code
also, (C)

BUG=skia:

Review URL: https://codereview.chromium.org/1300163002
2015-08-19 09:51:01 -07:00
joshualitt
5b4a7abd48 Adding sucessful exit message to VisualBench
BUG=skia:

Review URL: https://codereview.chromium.org/1287763004
2015-08-19 08:21:48 -07:00
bsalomon
f3bf892d71 Fix VS 2015 build
TBR=robertphillips@google.com

Review URL: https://codereview.chromium.org/1297283003
2015-08-19 06:12:36 -07:00
egdaniel
73caadf277 Try enabling all nanobenches on Nexus7
BUG=skia:2774

Review URL: https://codereview.chromium.org/1290223005
2015-08-18 13:08:36 -07:00
joshualitt
892b0c3db9 Add skeleton json support to visualbench
BUG=skia:

Review URL: https://codereview.chromium.org/1298213002
2015-08-18 12:13:34 -07:00
mtklein
d55d13af4f Update BUILD.public a bit.
- SSE2 files are unfortunately now mixed-case, _SSE2 or _sse2.
 - Adds lists for SSSE3 and SSE4 files.
 - Remove SkDocument_PDF_None.cpp
 - Remove a few more references to animator.
 - Exclude private headers from HDRS.
 - Formatting and notes.

BUG=skia:

Review URL: https://codereview.chromium.org/1298003007
2015-08-18 08:51:49 -07:00
halcanary
bf3dde2716 Clean up BUILD_simulator.py
Review URL: https://codereview.chromium.org/1298813002
2015-08-18 08:35:45 -07:00
benjaminwagner
f82c13fced Reland of Fix a few bugs in the google3 sync scripts. (patchset #1 id:1 of https://codereview.chromium.org/1295213002/ )
Reason for revert:
Retry.

Original issue's description:
> Revert of Fix a few bugs in the google3 sync scripts. (patchset #1 id:1 of https://codereview.chromium.org/1291343006/ )
>
> Reason for revert:
> MacMini buildbots were unable to apply the patch.
> fatal: Could not parse object '18af0a0080cc2b2b3464292d35a0886cdade551f'.
> http://build.chromium.org/p/client.skia/builders/Test-Mac10.9-Clang-MacMini6.2-CPU-AVX-x86_64-Release/builds/1580
> http://build.chromium.org/p/client.skia/builders/Test-Mac10.9-Clang-MacMini6.2-CPU-AVX-x86_64-Debug/builds/1474
> http://build.chromium.org/p/client.skia/builders/Test-Mac10.9-Clang-MacMini6.2-GPU-HD4000-x86_64-Release/builds/1566
> http://build.chromium.org/p/client.skia/builders/Perf-Mac10.9-Clang-MacMini6.2-GPU-HD4000-x86_64-Release/builds/1480
> http://build.chromium.org/p/client.skia/builders/Perf-Mac10.9-Clang-MacMini6.2-CPU-AVX-x86_64-Release/builds/1456
> http://build.chromium.org/p/client.skia/builders/Test-Mac10.9-Clang-MacMini6.2-GPU-HD4000-x86_64-Debug/builds/1364
>
>
> Original issue's description:
> > Fix a few bugs in the google3 sync scripts.
> >
> > BUG=skia:
> >
> > Committed: https://skia.googlesource.com/skia/+/18af0a0080cc2b2b3464292d35a0886cdade551f
>
> TBR=mtklein@google.com
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/e349d6b92574c1b0acdb4ba1ed8ff905ea830131

TBR=mtklein@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review URL: https://codereview.chromium.org/1284093003
2015-08-18 06:25:14 -07:00
robertphillips
ea4529d09a Move normal map creation methods to sk_tools
Split off of https://codereview.chromium.org/1261433009/ (Add SkCanvas::drawLitAtlas call)

Review URL: https://codereview.chromium.org/1298763002
2015-08-17 15:04:47 -07:00
mtklein
df5b7603d2 Add a simple script to simulate BUILD file glob() expansion.
This lets us test changes to BUILD.public.

This is not yet automated in any way.  My hope is to trigger it quietly via the presubmit for any CL that adds or removes a file, or changes BUILD.public.

BUG=skia:

Review URL: https://codereview.chromium.org/1290833003
2015-08-17 15:02:57 -07:00
benjaminwagner
e349d6b925 Revert of Fix a few bugs in the google3 sync scripts. (patchset #1 id:1 of https://codereview.chromium.org/1291343006/ )
Reason for revert:
MacMini buildbots were unable to apply the patch.
fatal: Could not parse object '18af0a0080cc2b2b3464292d35a0886cdade551f'.
http://build.chromium.org/p/client.skia/builders/Test-Mac10.9-Clang-MacMini6.2-CPU-AVX-x86_64-Release/builds/1580
http://build.chromium.org/p/client.skia/builders/Test-Mac10.9-Clang-MacMini6.2-CPU-AVX-x86_64-Debug/builds/1474
http://build.chromium.org/p/client.skia/builders/Test-Mac10.9-Clang-MacMini6.2-GPU-HD4000-x86_64-Release/builds/1566
http://build.chromium.org/p/client.skia/builders/Perf-Mac10.9-Clang-MacMini6.2-GPU-HD4000-x86_64-Release/builds/1480
http://build.chromium.org/p/client.skia/builders/Perf-Mac10.9-Clang-MacMini6.2-CPU-AVX-x86_64-Release/builds/1456
http://build.chromium.org/p/client.skia/builders/Test-Mac10.9-Clang-MacMini6.2-GPU-HD4000-x86_64-Debug/builds/1364

Original issue's description:
> Fix a few bugs in the google3 sync scripts.
>
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/18af0a0080cc2b2b3464292d35a0886cdade551f

TBR=mtklein@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review URL: https://codereview.chromium.org/1295213002
2015-08-17 14:44:01 -07:00
benjaminwagner
18af0a0080 Fix a few bugs in the google3 sync scripts.
BUG=skia:

Review URL: https://codereview.chromium.org/1291343006
2015-08-17 14:23:03 -07:00
benjaminwagner
787ca87b33 Add files added to Skia HEAD in google3 to the Git repo.
LICENSE is modified in google3 to mention some code copied from other projects.

BUG=skia:

Review URL: https://codereview.chromium.org/1291603003
2015-08-17 12:58:10 -07:00
emmaleer
8f4ba76742 SkScaledCodec class
This class does scaling by using a scanlineDecoder.
getScanlines and skipScanlines are used for y sampling,
the swizzler is used for x sampling

this class is currently only working for png and jpeg images
I will update other Codec types to work soon

For SkJpegCodec to implement width wise swizzling it now
uses a swizzler. I ran performance tests on this change.
Here are the performance test results:
https://docs.google.com/a/google.com/spreadsheets/d/1D7-Q_GXD_dI68LZO005NNvb8Wq2Ee0wEBEPG72671yw/edit?usp=sharing

BUG=skia:

Committed: https://skia.googlesource.com/skia/+/0944100ac89f797714eeae0cf2875e2335ff52ee

Committed: https://skia.googlesource.com/skia/+/d518ea7927f9f4e0ed5b4134d1b4f48243855a47

Committed: https://skia.googlesource.com/skia/+/b157917507d4f7d2651f0aeb566d31603cc02240

Review URL: https://codereview.chromium.org/1260673002
2015-08-14 07:44:46 -07:00
Mike Klein
dd958e72f9 Add tools/ubsan.supp.
Should unbreak TSAN bots.

BUG=skia:

Review URL: https://codereview.chromium.org/1272213003 .
2015-08-05 10:12:33 -04:00
borenet
dbf9f014a8 buildbot_spec: Add configuration, do_*_steps, upload_*_results, more env
NOTRY=true
BUG=skia:4132

Review URL: https://codereview.chromium.org/1258193004
2015-07-30 07:09:20 -07:00
borenet
2481b8b719 buildbot_spec.py: Include dm_flags and nanobench_flags
Eventually I'll want to merge them into this file, but not just yet.

NOTRY=true
BUG=skia:4132

Review URL: https://codereview.chromium.org/1257933003
2015-07-29 11:43:07 -07:00
borenet
7bccca1a82 buildbot_spec.py: Add Android/ChromeOS device info, add builder_cfg dict
NOTRY=true
BUG=skia:4132

Review URL: https://codereview.chromium.org/1269543002
2015-07-29 11:15:42 -07:00
borenet
b76c1f706c Add builder_spec.py
Works like dm_flags.py and nanobench_flags.py; adds things like
GYP_DEFINES, additional environment variables, and build targets.

Required copying builder_name_schema from the tools/build repo.

BUG=skia:4132

Review URL: https://codereview.chromium.org/1265623002
2015-07-29 07:38:49 -07:00
mtklein
e0effd6080 Allow Srcs to veto Sinks based on their broad type.
This breaks Sinks down into three auto-detected types:
  - GPU:    anything that requests to be run in the GPU enclave
  - Vector: anything that writes to the stream instead of the bitmap
  - Raster: everything else

Some examples: gpu -> GPU, msaa16 -> GPU, 8888 -> raster, pdf -> vector,
               svg -> vector, pipe-8888 -> raster, tiles_rt-gpu -> GPU

This lets image decoding sinks veto non-raster backends explicitly,
and can let particular GMs veto GPU or non-GPU sinks as they like.

BUG=skia:

Review URL: https://codereview.chromium.org/1239953004
2015-07-29 06:37:28 -07:00
caryclark
1818acb6a4 rename portable_typeface_always to portable_typeface
TBR=reed@google.com

Review URL: https://codereview.chromium.org/1257773002
2015-07-24 12:09:25 -07:00
caryclark
37213558e6 make fontscalar gammatext lcdtext typeface verttext2 gm portable
Pass generic font names to tool util function to generate
platform specific fonts and gm test output by unique name.

R=bungeman@google.com

Review URL: https://codereview.chromium.org/1256903002
2015-07-24 11:08:01 -07:00
caryclark
3b0f98ee17 fix typeface leak
TBR=bungeman@google.com

Review URL: https://codereview.chromium.org/1239303003
2015-07-23 11:52:01 -07:00
caryclark
e663341605 fix typo
TBR=reed@google.com

Review URL: https://codereview.chromium.org/1245993003
2015-07-23 09:11:58 -07:00
borenet
4cb300340e Coverage: add a trace for not_covered_lines per file
Example output:

{
    "build_number": "2",
    "gitHash": "71f5db892ee7ed9fbb573da28ccb906e18ba24a4",
    "key": {
        "arch": "x86_64",
        "compiler": "Clang",
        "configuration": "Coverage",
        "cpu_or_gpu": "CPU",
        "cpu_or_gpu_value": "AVX2",
        "model": "GCE",
        "os": "Ubuntu"
    },
    "results": {
        "dm_DMGpuSupport_h": {
            "coverage": {
                "lines_not_covered": 6,
                "options": {
                    "dir": "dm",
                    "fullname": "dm/DMGpuSupport.h",
                    "source_type": "coverage"
                },
                "percent": 33.33333333333333
            }
        },
        "dm_DMJsonWriter_cpp": {
......

BUG=skia:2430

Review URL: https://codereview.chromium.org/1246043002
2015-07-22 08:19:25 -07:00
caryclark
c3dcb67f07 make color emoji gm portable
R=bungeman@google.com

Review URL: https://codereview.chromium.org/1248703004
2015-07-21 12:27:36 -07:00
borenet
9b8d3580c2 Skip imagefiltersclipped GM on Galaxy S4
BUG=skia:4079

Review URL: https://codereview.chromium.org/1250473005
2015-07-21 05:57:22 -07:00
caryclark
6531c3619f Generate platform specific fontmgr gm.
The gm output on different font platforms is so different
that comparing images in Gold has little value. Separate the
images by appending platform information to the gm name to
group somewhat similar images together.

Note that this does not attempt to make sure that all images
generated by Gold are nearly pixel identical; it only reduces
the number of nonsensical comparisons.

R=bungeman@google.com

Review URL: https://codereview.chromium.org/1245643002
2015-07-20 13:38:56 -07:00
borenet
a6ae14e223 Split llvm_coverage_run into two scripts
... One for running to generate the coverage data, another to parse the data into various formats.

NOTRY=true
BUG=skia:2430

Review URL: https://codereview.chromium.org/1239963002
2015-07-20 09:43:36 -07:00
joshualitt
a2a6fe8699 Some cleanups of VisualBench
BUG=skia:

Review URL: https://codereview.chromium.org/1240633005
2015-07-17 09:09:23 -07:00
borenet
5150a77ee7 llvm_coverage_build: Use CC and CXX variables by default
NOTRY=true
BUG=skia:2430

Review URL: https://codereview.chromium.org/1242573003
2015-07-17 07:31:07 -07:00
joshualitt
47d280d3b0 Fix visual bench memory leak
BUG=skia:

Review URL: https://codereview.chromium.org/1239103002
2015-07-16 14:23:22 -07:00
joshualitt
31b21f6719 Small fix for visualbench
BUG=skia:

Review URL: https://codereview.chromium.org/1237563005
2015-07-16 13:40:51 -07:00
scroggo
c1121efbc6 Stop running image tests on msaa.
Blacklist all image tests on msaa. We do not run them anyway (since
they will not do anything interestingly different from drawing to the
raster backend) - we early exit from Src::draw(), but we still need to
create a render target that matches the size of the image (when not
blacklisted).

Remove the more specific blacklist of a particular image, which is
covered by this one.

BUG=skia:4045

Review URL: https://codereview.chromium.org/1234313006
2015-07-16 12:36:10 -07:00
borenet
8a955af001 Coverage script: fix missing data
BUG=skia:2430

Review URL: https://codereview.chromium.org/1242023002
2015-07-16 07:01:44 -07:00
joshualitt
82874f8b28 Match works correctly on visualbench
BUG=skia:

Review URL: https://codereview.chromium.org/1234123004
2015-07-15 08:38:02 -07:00
borenet
f0c84407ae llvm-coverage script: respect SKIA_OUT
NOTRY=true
BUG=skia:2430

Review URL: https://codereview.chromium.org/1239803002
2015-07-15 07:43:06 -07:00
joshualitt
d4fa90feea Fix VisualBench to hold onto a surface
BUG=skia:

Review URL: https://codereview.chromium.org/1236723003
2015-07-15 06:18:57 -07:00
msarett
02b5aa3cac Fixed valgrind issues with libjpeg-turbo
The fixes are in the updated libjpeg-turbo repository
pulled in by DEPS.  The fixes are detailed in the linked
skia bug.  To summarize briefly, we now use calloc()
instead of malloc().

BUG=skia:4030

Review URL: https://codereview.chromium.org/1237213004
2015-07-14 14:39:59 -07:00
mtklein
f059900f75 Fix up -Winconsistent-missing-override
(and a couple presubmit fixes)

This allows us to turn back on -Werror for LLVM coverage builds,
and more generally supports building with Clang 3.7.

No public API changes.
TBR=reed@google.com

BUG=skia:

Review URL: https://codereview.chromium.org/1232463006
2015-07-13 06:18:39 -07:00
reed
1c84634454 add runtime option to provide data->imagegenerator factory
BUG=skia:

Review URL: https://codereview.chromium.org/1229933003
2015-07-09 11:47:36 -07:00
msarett
ef46468063 Temporarily suppress valgrind errors in tip of tree libjpeg-turbo
BUG=skia:4030

Review URL: https://codereview.chromium.org/1231613004
2015-07-09 08:23:50 -07:00
mtklein
60c0475575 Add tools/flatten to flatten nested pictures in .skps.
Tested by running on skps/sp_desk_nytimes.skp.
The output .skp had no nested draw picture calls, and the files were both 9.3M.

BUG=skia:

Review URL: https://codereview.chromium.org/1221303020
2015-07-08 10:06:01 -07:00
caryclark
fc95be17c3 fix pathops battle test
The intermediate subtraction threw away bits causing
the subsequent cross product to fail. Defer the
bit truncation until after the vector is computed.

TBR=reed@google.com

Review URL: https://codereview.chromium.org/1226933003
2015-07-07 18:09:32 -07:00
mtklein
1b24933e52 Remove SkThread.h, include SkMutex.h or SkAtomics.h as appropriate.
SkThread.h doesn't do anything anymore execept include those two,
and thankfully, it doesn't seem to be mentioned outside Skia.

No public API changes.
TBR=reed@google.com

BUG=skia:

Committed: https://skia.googlesource.com/skia/+/c50acf2321d7a934c80d754e9cbe936dfb8eb4cc

Review URL: https://codereview.chromium.org/1215393002
2015-07-07 12:21:22 -07:00
caryclark
27c8eb8ffd When three or more edges are coincident, the logic needs
to compute the overlapping ranges and combine the winding
into a single destination.

This computes coincidence more rigorously, fixing the
edge cases exposed by this bug.

Also, add the ability to debug and dump pathop structures
from the coincident context.

TBR=reed@google.com
BUG=skia:3651

Review URL: https://codereview.chromium.org/1182493015
2015-07-06 11:38:33 -07:00
borenet
334e588d9e Add nanobench-style JSON output to llvm_coverage_run
Runs the build and run scripts for coverage, then dumps the results into
a file in nanobench-compatible format.

BUG=skia:2430

Review URL: https://codereview.chromium.org/1227523004
2015-07-06 11:18:45 -07:00
borenet
11271fe3a4 Add scripts for running LLVM coverage
BUG=skia:2430

Review URL: https://codereview.chromium.org/1213063009
2015-07-06 07:43:58 -07:00
jvanverth
02802f64ea Revert of Remove SkThread.h, include SkMutex.h or SkAtomics.h as appropriate. (patchset #4 id:60001 of https://codereview.chromium.org/1215393002/)
Reason for revert:
Breaking the roll.

E.g. on android_chromium_gn_compile_dbg:

FAILED: /b/build/goma/gomacc ../../third_party/android_tools/ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-g++ -MMD -MF obj/skia/ext/libskia.SkMemory_new_handler.o.d -DV8_DEPRECATION_WARNINGS -DCLD_VERSION=1 -DENABLE_NOTIFICATIONS -DENABLE_BROWSER_CDMS -DENABLE_PRINTING=1 -DENABLE_BASIC_PRINTING=1 -DDONT_EMBED_BUILD_METADATA -DUSE_OPENSSL=1 -DUSE_OPENSSL_CERTS=1 -DNO_TCMALLOC -DDISABLE_NACL -DENABLE_CONFIGURATION_POLICY -DENABLE_SUPERVISED_USERS=1 -DENABLE_AUTOFILL_DIALOG=1 -DUSE_PROPRIETARY_CODECS -DV8_USE_EXTERNAL_STARTUP_DATA -DVIDEO_HOLE=1 -DMOBILE_SAFE_BROWSING -DSAFE_BROWSING_SERVICE -DCHROMIUM_BUILD -D_FILE_OFFSET_BITS=64 -DANDROID -DHAVE_SYS_UIO_H -DCOMPONENT_BUILD -D__GNU_SOURCE=1 -D_DEBUG -DDYNAMIC_ANNOTATIONS_ENABLED=1 -DWTF_USE_DYNAMIC_ANNOTATIONS=1 -DSKIA_IMPLEMENTATION=1 -DSK_ARM_HAS_OPTIONAL_NEON -DSK_GAMMA_APPLY_TO_A8 -DSK_GAMMA_EXPONENT=1.4 -DSK_GAMMA_CONTRAST=0.0 -DSK_DEFAULT_FONT_CACHE_LIMIT=1048576 -DSK_IGNORE_LINEONLY_AA_CONVEX_PATH_OPTS -DSKIA_DLL -DGR_GL_IGNORE_ES3_MSAA=0 -DSK_SUPPORT_GPU=1 -DSK_BUILD_FOR_ANDROID -DUSE_CHROMIUM_SKIA -DXML_STATIC -I../.. -Igen -I../../third_party/skia/include/private -I../../third_party/skia/src/core -I../../third_party/skia/src/image -I../../third_party/skia/src/opts -I../../third_party/skia/src/pdf -I../../third_party/skia/src/ports -I../../third_party/skia/src/sfnt -I../../third_party/skia/src/utils -I../../third_party/skia/src/lazy -I../../skia/config -I../../skia/ext -I../../third_party/skia/include/c -I../../third_party/skia/include/config -I../../third_party/skia/include/core -I../../third_party/skia/include/effects -I../../third_party/skia/include/images -I../../third_party/skia/include/lazy -I../../third_party/skia/include/pathops -I../../third_party/skia/include/pdf -I../../third_party/skia/include/pipe -I../../third_party/skia/include/ports -I../../third_party/skia/include/utils -I../../third_party/skia/include/gpu -I../../third_party/skia/src/gpu -I../../third_party/zlib -I../../third_party/expat/files/lib -I../../third_party/freetype-android/include -I../../third_party/freetype-android/src/include -I../../third_party/android_tools/ndk/sources/android/cpufeatures -fno-strict-aliasing -march=armv7-a -mfloat-abi=softfp -mtune=generic-armv7-a -mthumb -mthumb-interwork -fno-tree-sra -fno-caller-saves -funwind-tables -fPIC -pipe -ffunction-sections -funwind-tables -fno-short-enums -finline-limit=64 -mfpu=vfpv3-d16 -isystem../../third_party/android_tools/ndk/sources/cxx-stl/llvm-libc++/libcxx/include -isystem../../third_party/android_tools/ndk/sources/cxx-stl/llvm-libc++abi/libcxxabi/include -isystem../../third_party/android_tools/ndk/sources/android/support/include -fvisibility=hidden --sysroot=/b/build/slave/android_chromium_gn/build/src/third_party/android_tools/ndk/platforms/android-16/arch-arm -Os -fdata-sections -ffunction-sections -fomit-frame-pointer -g1 -Wno-format -Wendif-labels -Werror -Wno-missing-field-initializers -Wno-unused-parameter -Wno-psabi -Wno-extra -Wno-ignored-qualifiers -Wno-type-limits -Wno-unused-local-typedefs -fno-threadsafe-statics -fvisibility-inlines-hidden -std=gnu++11 -fno-rtti -fno-exceptions -Wno-deprecated -Wno-narrowing -Wno-literal-suffix -Wno-error=c++0x-compat -Wno-non-virtual-dtor -Wno-sign-promo -c ../../skia/ext/SkMemory_new_handler.cpp -o obj/skia/ext/libskia.SkMemory_new_handler.o
../../skia/ext/SkMemory_new_handler.cpp:12:52: fatal error: third_party/skia/include/core/SkThread.h: No such file or directory
 #include "third_party/skia/include/core/SkThread.h"

Original issue's description:
> Remove SkThread.h, include SkMutex.h or SkAtomics.h as appropriate.
>
> SkThread.h doesn't do anything anymore execept include those two,
> and thankfully, it doesn't seem to be mentioned outside Skia.
>
> No public API changes.
> TBR=reed@google.com
>
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/c50acf2321d7a934c80d754e9cbe936dfb8eb4cc

TBR=mtklein@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review URL: https://codereview.chromium.org/1214603003
2015-07-02 06:42:49 -07:00
mtklein
c50acf2321 Remove SkThread.h, include SkMutex.h or SkAtomics.h as appropriate.
SkThread.h doesn't do anything anymore execept include those two,
and thankfully, it doesn't seem to be mentioned outside Skia.

No public API changes.
TBR=reed@google.com

BUG=skia:

Review URL: https://codereview.chromium.org/1215393002
2015-07-01 14:00:57 -07:00
herb
19fb80ed14 Revert of Skip SkSharedMutexMultiThreaded test on TSAN bot while investigating. (patchset #1 id:1 of https://codereview.chromium.org/1213033003/)
Reason for revert:
Add tsan annotations to repair tests.

Original issue's description:
> Skip SkSharedMutexMultiThreaded test on TSAN bot while investigating.
>
> The ~ means "don't run this".  This keeps all the other bots running the code, skipping it only on the whiny TSAN bot.
>
> BUG=skia:3997
>
> Committed: https://skia.googlesource.com/skia/+/37cc0b2e31e4a078b12790253d7032d36271440c

TBR=mtklein@google.com,mtklein@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:3997

Review URL: https://codereview.chromium.org/1218153004
2015-06-30 14:23:29 -07:00
mtklein
37cc0b2e31 Skip SkSharedMutexMultiThreaded test on TSAN bot while investigating.
The ~ means "don't run this".  This keeps all the other bots running the code, skipping it only on the whiny TSAN bot.

BUG=skia:3997

Review URL: https://codereview.chromium.org/1213033003
2015-06-30 10:51:50 -07:00
borenet
3691e669ae Add wrapper script for computing n-grams from SKPs on Cluster Telemetry
Add --n argument

BUG=skia:3840

Review URL: https://codereview.chromium.org/1216073007
2015-06-30 10:24:03 -07:00
bsalomon
73bb435a58 Remove default for --images in common flags
Review URL: https://codereview.chromium.org/1214363002
2015-06-30 09:38:35 -07:00
rmistry
16857e46bb Use AddStory instead of deprecated AddUserStory
BUG=skia:3967
TBR=nednguyen
NOTRY=true

Review URL: https://codereview.chromium.org/1212843008
2015-06-30 09:20:17 -07:00
rmistry
8f74c160c3 Revert of Use page_set_module.PageSet instead of story.StorySet (patchset #1 id:1 of https://codereview.chromium.org/1221553003/)
Reason for revert:
This should no longer be required due to Ned's fix in https://codereview.chromium.org/1217823005/

Original issue's description:
> Use page_set_module.PageSet instead of story.StorySet
>
> BUG=skia:3967
> NOTRY=true
> TBR=nednguyen
>
> Committed: https://skia.googlesource.com/skia/+/7b971f0152299ae9a924252a9bfd220318497bdd

TBR=nednguyen@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:3967

Review URL: https://codereview.chromium.org/1214903008
2015-06-30 08:22:25 -07:00