New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 889898 link

Starred by 1 user

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Feature



Sign in to add a comment

Consider adding a gfx::codec perf test for image decode time

Project Member Reported by mcasas@chromium.org, Sep 27

Issue description

Consider making a small test target that decodes a given (set of) images
a user-chosen number of times and prints out some interesting info, e.g.
what was the average time taken for decoding and #pixels.
 
Status: Available (was: Unconfirmed)
Owner: mcasas@chromium.org
Status: Assigned (was: Available)
Project Member

Comment 3 by bugdroid1@chromium.org, Oct 11

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1c3205982f4b5663301878d2c60a74bf43aee08c

commit 1c3205982f4b5663301878d2c60a74bf43aee08c
Author: Miguel Casas <mcasas@chromium.org>
Date: Thu Oct 11 16:49:25 2018

blink image_decode_bench: use more Chromium stuff

This CL refactors image_decode_bench:
- Rewrites function ReadFile() to use base::FilePath etc.
- Configures the Logging and changes fprintf/stderr to LOG()
 statements, and exit()s into LOG_ASSERT().
- Names the constant kDefaultDecodeTimes.
- s/DecodeError/PrintErrorAndExit/ to clarify what it does.
- Changes uses of CurrentTimeTicks() with base::ElapsedTimer,
 and uses TimeDelta ISO double to count the elapsed time.
- Uses perf_test::PrintResult to add info about the image
 (size and #pixels), when a new parameter (-v / -verbose)
 is specified after the current two parameters, file and
 #iterations; output is e.g.:
*RESULT decode_time /usr/local/google/home/mcasas/Pictures/4.webp: 100 times 790528 pixels (1024x772)= 66.27827 ms/sample

Bug: 889898
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
Change-Id: Ic0a66d2aa3d2f08b13c8af99aed31e61d7246dec
Reviewed-on: https://chromium-review.googlesource.com/c/1225653
Commit-Queue: Miguel Casas <mcasas@chromium.org>
Reviewed-by: Leon Scroggins <scroggo@chromium.org>
Reviewed-by: Noel Gordon <noel@chromium.org>
Cr-Commit-Position: refs/heads/master@{#598803}
[modify] https://crrev.com/1c3205982f4b5663301878d2c60a74bf43aee08c/third_party/blink/renderer/platform/BUILD.gn
[modify] https://crrev.com/1c3205982f4b5663301878d2c60a74bf43aee08c/third_party/blink/renderer/platform/testing/image_decode_bench.cc

Project Member

Comment 4 by bugdroid1@chromium.org, Oct 11

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/6089db667be5e9ed19f1ef5eb804d1f0a94ebdda

commit 6089db667be5e9ed19f1ef5eb804d1f0a94ebdda
Author: Vasilii Sukhanov <vasilii@chromium.org>
Date: Thu Oct 11 17:14:28 2018

Revert "blink image_decode_bench: use more Chromium stuff"

This reverts commit 1c3205982f4b5663301878d2c60a74bf43aee08c.

Reason for revert: broke compilation on Win
https://logs.chromium.org/logs/chromium/buildbucket/cr-buildbucket.appspot.com/8932944647631542128/+/steps/compile/0/stdout

../../third_party/blink/renderer/platform/testing/image_decode_bench.cc(43,26):  error: no matching conversion for functional-style cast from 'const char *' to 'base::FilePath'
    const auto file_path = base::FilePath(name);

Original change's description:
> blink image_decode_bench: use more Chromium stuff
> 
> This CL refactors image_decode_bench:
> - Rewrites function ReadFile() to use base::FilePath etc.
> - Configures the Logging and changes fprintf/stderr to LOG()
>  statements, and exit()s into LOG_ASSERT().
> - Names the constant kDefaultDecodeTimes.
> - s/DecodeError/PrintErrorAndExit/ to clarify what it does.
> - Changes uses of CurrentTimeTicks() with base::ElapsedTimer,
>  and uses TimeDelta ISO double to count the elapsed time.
> - Uses perf_test::PrintResult to add info about the image
>  (size and #pixels), when a new parameter (-v / -verbose)
>  is specified after the current two parameters, file and
>  #iterations; output is e.g.:
> *RESULT decode_time /usr/local/google/home/mcasas/Pictures/4.webp: 100 times 790528 pixels (1024x772)= 66.27827 ms/sample
> 
> Bug: 889898
> Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
> Change-Id: Ic0a66d2aa3d2f08b13c8af99aed31e61d7246dec
> Reviewed-on: https://chromium-review.googlesource.com/c/1225653
> Commit-Queue: Miguel Casas <mcasas@chromium.org>
> Reviewed-by: Leon Scroggins <scroggo@chromium.org>
> Reviewed-by: Noel Gordon <noel@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#598803}

TBR=scroggo@chromium.org,noel@chromium.org,mcasas@chromium.org

Change-Id: I7f18f8a464536eb5b6cee86f25930a94f357a0f1
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 889898
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
Reviewed-on: https://chromium-review.googlesource.com/c/1277245
Reviewed-by: Vasilii Sukhanov <vasilii@chromium.org>
Commit-Queue: Vasilii Sukhanov <vasilii@chromium.org>
Cr-Commit-Position: refs/heads/master@{#598809}
[modify] https://crrev.com/6089db667be5e9ed19f1ef5eb804d1f0a94ebdda/third_party/blink/renderer/platform/BUILD.gn
[modify] https://crrev.com/6089db667be5e9ed19f1ef5eb804d1f0a94ebdda/third_party/blink/renderer/platform/testing/image_decode_bench.cc

Project Member

Comment 5 by bugdroid1@chromium.org, Oct 11

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/5a922743d749cefb3313878bed2d182dca4f6017

commit 5a922743d749cefb3313878bed2d182dca4f6017
Author: Miguel Casas <mcasas@chromium.org>
Date: Thu Oct 11 21:13:39 2018

RELAND: blink image_decode_bench: use more Chromium stuff

The original CL got reverted in crrev.com/c/1277245 because of a
window-specific bug:
../../third_party/blink/renderer/platform/testing/image_decode_bench.cc(43,26):  error: no matching conversion for functional-style cast from 'const char *' to 'base::FilePath'
    const auto file_path = base::FilePath(name);

which is solved in this CL: crrev.com/c/1277547/1..2
TBR=noel@chromium.org, scroggo@chromium.org, since the delta is trivial

Original CL description ------------------------------------------------
This CL refactors image_decode_bench:
- Rewrites function ReadFile() to use base::FilePath etc.
- Configures the Logging and changes fprintf/stderr to LOG()
 statements, and exit()s into LOG_ASSERT().
- Names the constant kDefaultDecodeTimes.
- s/DecodeError/PrintErrorAndExit/ to clarify what it does.
- Changes uses of CurrentTimeTicks() with base::ElapsedTimer,
 and uses TimeDelta ISO double to count the elapsed time.
- Uses perf_test::PrintResult to add info about the image
 (size and #pixels), when a new parameter (-v / -verbose)
 is specified after the current two parameters, file and
 #iterations; output is e.g.:
*RESULT decode_time /usr/local/google/home/mcasas/Pictures/4.webp: 100 times 790528 pixels (1024x772)= 66.27827 ms/sample

Bug: 889898
Change-Id: I5f553a8e1f661776c747e0433df0ac794680706d
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
Reviewed-on: https://chromium-review.googlesource.com/c/1225653
Commit-Queue: Miguel Casas <mcasas@chromium.org>
Reviewed-by: Leon Scroggins <scroggo@chromium.org>
Reviewed-by: Noel Gordon <noel@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/1277547
Reviewed-by: Miguel Casas <mcasas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#598939}
[modify] https://crrev.com/5a922743d749cefb3313878bed2d182dca4f6017/third_party/blink/renderer/platform/BUILD.gn
[modify] https://crrev.com/5a922743d749cefb3313878bed2d182dca4f6017/third_party/blink/renderer/platform/testing/image_decode_bench.cc

Project Member

Comment 6 by bugdroid1@chromium.org, Oct 11

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/6574cae70131d0e59612e508599fb1a099c393ec

commit 6574cae70131d0e59612e508599fb1a099c393ec
Author: Findit <findit-for-me@appspot.gserviceaccount.com>
Date: Thu Oct 11 21:55:15 2018

Revert "RELAND: blink image_decode_bench: use more Chromium stuff"

This reverts commit 5a922743d749cefb3313878bed2d182dca4f6017.

Reason for revert:

Findit (https://goo.gl/kROfz5) identified CL at revision 598939 as the
culprit for failures in the build cycles as shown on:
https://findit-for-me.appspot.com/waterfall/culprit?key=ag9zfmZpbmRpdC1mb3ItbWVyRAsSDVdmU3VzcGVjdGVkQ0wiMWNocm9taXVtLzVhOTIyNzQzZDc0OWNlZmIzMzEzODc4YmVkMmQxODJkY2E0ZjYwMTcM

Sample Failed Build: https://ci.chromium.org/buildbot/chromium/win-rel/4240

Sample Failed Step: compile

Original change's description:
> RELAND: blink image_decode_bench: use more Chromium stuff
> 
> The original CL got reverted in crrev.com/c/1277245 because of a
> window-specific bug:
> ../../third_party/blink/renderer/platform/testing/image_decode_bench.cc(43,26):  error: no matching conversion for functional-style cast from 'const char *' to 'base::FilePath'
>     const auto file_path = base::FilePath(name);
> 
> which is solved in this CL: crrev.com/c/1277547/1..2
> TBR=noel@chromium.org, scroggo@chromium.org, since the delta is trivial
> 
> Original CL description ------------------------------------------------
> This CL refactors image_decode_bench:
> - Rewrites function ReadFile() to use base::FilePath etc.
> - Configures the Logging and changes fprintf/stderr to LOG()
>  statements, and exit()s into LOG_ASSERT().
> - Names the constant kDefaultDecodeTimes.
> - s/DecodeError/PrintErrorAndExit/ to clarify what it does.
> - Changes uses of CurrentTimeTicks() with base::ElapsedTimer,
>  and uses TimeDelta ISO double to count the elapsed time.
> - Uses perf_test::PrintResult to add info about the image
>  (size and #pixels), when a new parameter (-v / -verbose)
>  is specified after the current two parameters, file and
>  #iterations; output is e.g.:
> *RESULT decode_time /usr/local/google/home/mcasas/Pictures/4.webp: 100 times 790528 pixels (1024x772)= 66.27827 ms/sample
> 
> Bug: 889898
> Change-Id: I5f553a8e1f661776c747e0433df0ac794680706d
> Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
> Reviewed-on: https://chromium-review.googlesource.com/c/1225653
> Commit-Queue: Miguel Casas <mcasas@chromium.org>
> Reviewed-by: Leon Scroggins <scroggo@chromium.org>
> Reviewed-by: Noel Gordon <noel@chromium.org>
> Reviewed-on: https://chromium-review.googlesource.com/c/1277547
> Reviewed-by: Miguel Casas <mcasas@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#598939}

Change-Id: If13bdf8fdf015c13db1ca9894b39e7d658235732
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 889898
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
Reviewed-on: https://chromium-review.googlesource.com/c/1278145
Cr-Commit-Position: refs/heads/master@{#598964}
[modify] https://crrev.com/6574cae70131d0e59612e508599fb1a099c393ec/third_party/blink/renderer/platform/BUILD.gn
[modify] https://crrev.com/6574cae70131d0e59612e508599fb1a099c393ec/third_party/blink/renderer/platform/testing/image_decode_bench.cc

Sign in to add a comment