Commit f82e8f7c authored by siva.gunturi's avatar siva.gunturi Committed by Commit bot

Time of first use cost of upload.

This test is to check whether there is a time-of-first-use
cost (e.g. driver doesn't upload to the texture until we
draw with it).

BUG= 423481

Review URL: https://codereview.chromium.org/1031463002

Cr-Commit-Position: refs/heads/master@{#322131}
parent 66175b00
......@@ -349,8 +349,11 @@ class TextureUploadPerfTest : public testing::Test {
UploadTexture(texture_id, size, pixels, format, subimage);
tex_timers.Record();
MeasurementTimers draw_timers(gpu_timing_client_.get());
MeasurementTimers first_draw_timers(gpu_timing_client_.get());
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
first_draw_timers.Record();
MeasurementTimers draw_timers(gpu_timing_client_.get());
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
draw_timers.Record();
......@@ -374,6 +377,8 @@ class TextureUploadPerfTest : public testing::Test {
if (!gpu_timer_errors) {
measurements.push_back(tex_timers.GetAsMeasurement(
subimage ? "texsubimage2d" : "teximage2d"));
measurements.push_back(
first_draw_timers.GetAsMeasurement("firstdrawarrays"));
measurements.push_back(draw_timers.GetAsMeasurement("drawarrays"));
measurements.push_back(finish_timers.GetAsMeasurement("finish"));
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment