Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(80)

Side by Side Diff: gpu/command_buffer/service/gles2_cmd_decoder.cc

Issue 240073008: Add a gpu.SwapBuffers synthetic delay to PostSubBuffer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" 5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h"
6 6
7 #include <stdio.h> 7 #include <stdio.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <list> 10 #include <list>
(...skipping 7529 matching lines...) Expand 10 before | Expand all | Expand 10 after
7540 // Validation should have prevented us from getting here. 7540 // Validation should have prevented us from getting here.
7541 NOTREACHED(); 7541 NOTREACHED();
7542 break; 7542 break;
7543 } 7543 }
7544 return error::kNoError; 7544 return error::kNoError;
7545 } 7545 }
7546 7546
7547 error::Error GLES2DecoderImpl::HandlePostSubBufferCHROMIUM( 7547 error::Error GLES2DecoderImpl::HandlePostSubBufferCHROMIUM(
7548 uint32 immediate_data_size, const cmds::PostSubBufferCHROMIUM& c) { 7548 uint32 immediate_data_size, const cmds::PostSubBufferCHROMIUM& c) {
7549 TRACE_EVENT0("gpu", "GLES2DecoderImpl::HandlePostSubBufferCHROMIUM"); 7549 TRACE_EVENT0("gpu", "GLES2DecoderImpl::HandlePostSubBufferCHROMIUM");
7550 {
7551 TRACE_EVENT_SYNTHETIC_DELAY("gpu.SwapBuffers");
Zhenyao Mo 2014/04/17 20:45:48 I feel you should use a different name from "gpu.S
7552 }
7550 if (!supports_post_sub_buffer_) { 7553 if (!supports_post_sub_buffer_) {
7551 LOCAL_SET_GL_ERROR( 7554 LOCAL_SET_GL_ERROR(
7552 GL_INVALID_OPERATION, 7555 GL_INVALID_OPERATION,
7553 "glPostSubBufferCHROMIUM", "command not supported by surface"); 7556 "glPostSubBufferCHROMIUM", "command not supported by surface");
7554 return error::kNoError; 7557 return error::kNoError;
7555 } 7558 }
7556 bool is_tracing; 7559 bool is_tracing;
7557 TRACE_EVENT_CATEGORY_GROUP_ENABLED(TRACE_DISABLED_BY_DEFAULT("gpu.debug"), 7560 TRACE_EVENT_CATEGORY_GROUP_ENABLED(TRACE_DISABLED_BY_DEFAULT("gpu.debug"),
7558 &is_tracing); 7561 &is_tracing);
7559 if (is_tracing) { 7562 if (is_tracing) {
(...skipping 3174 matching lines...) Expand 10 before | Expand all | Expand 10 after
10734 } 10737 }
10735 } 10738 }
10736 10739
10737 // Include the auto-generated part of this file. We split this because it means 10740 // Include the auto-generated part of this file. We split this because it means
10738 // we can easily edit the non-auto generated parts right here in this file 10741 // we can easily edit the non-auto generated parts right here in this file
10739 // instead of having to edit some template or the code generator. 10742 // instead of having to edit some template or the code generator.
10740 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" 10743 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h"
10741 10744
10742 } // namespace gles2 10745 } // namespace gles2
10743 } // namespace gpu 10746 } // namespace gpu
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698