@@ -91,6 +91,7 @@ PStatCollector CLP(GraphicsStateGuardian)::_vertex_array_update_pcollector("Draw
91
91
PStatCollector CLP (GraphicsStateGuardian)::_texture_update_pcollector(" Draw:Update texture" );
92
92
PStatCollector CLP (GraphicsStateGuardian)::_fbo_bind_pcollector(" Draw:Bind FBO" );
93
93
PStatCollector CLP (GraphicsStateGuardian)::_check_error_pcollector(" Draw:Check errors" );
94
+ PStatCollector CLP (GraphicsStateGuardian)::_check_residency_pcollector(" *:PStats:Check residency" );
94
95
95
96
// The following noop functions are assigned to the corresponding glext
96
97
// function pointers in the class, in case the functions are not defined by
@@ -3949,6 +3950,7 @@ end_frame(Thread *current_thread) {
3949
3950
// connects PStats, at which point it will then correct the assessment. No
3950
3951
// harm done.
3951
3952
if (has_fixed_function_pipeline () && PStatClient::is_connected ()) {
3953
+ PStatTimer timer (_check_residency_pcollector);
3952
3954
check_nonresident_texture (_prepared_objects->_texture_residency .get_inactive_resident ());
3953
3955
check_nonresident_texture (_prepared_objects->_texture_residency .get_active_resident ());
3954
3956
@@ -7208,6 +7210,8 @@ do_issue_shade_model() {
7208
7210
*/
7209
7211
void CLP (GraphicsStateGuardian)::
7210
7212
do_issue_shader () {
7213
+ PStatTimer timer (_draw_set_state_shader_pcollector);
7214
+
7211
7215
ShaderContext *context = 0 ;
7212
7216
Shader *shader = (Shader *)_target_shader->get_shader ();
7213
7217
@@ -10919,7 +10923,6 @@ set_state_and_transform(const RenderState *target,
10919
10923
_instance_count = _target_shader->get_instance_count ();
10920
10924
10921
10925
if (_target_shader != _state_shader) {
10922
- // PStatGPUTimer timer(this, _draw_set_state_shader_pcollector);
10923
10926
do_issue_shader ();
10924
10927
_state_shader = _target_shader;
10925
10928
_state_mask.clear_bit (TextureAttrib::get_class_slot ());
@@ -11075,7 +11078,7 @@ set_state_and_transform(const RenderState *target,
11075
11078
int texture_slot = TextureAttrib::get_class_slot ();
11076
11079
if (_target_rs->get_attrib (texture_slot) != _state_rs->get_attrib (texture_slot) ||
11077
11080
!_state_mask.get_bit (texture_slot)) {
11078
- // PStatGPUTimer timer(this, _draw_set_state_texture_pcollector);
11081
+ PStatGPUTimer timer (this , _draw_set_state_texture_pcollector);
11079
11082
determine_target_texture ();
11080
11083
do_issue_texture ();
11081
11084
0 commit comments