surfaceflinger: Trace HW vsync enable

This makes it possible to tell whether two HW vsync signals are too
far apart because one was late, or because we turned HW vsync off
briefly between them.

Bug: 17259382
Change-Id: If4fba2a8a6013568349949ce87c5c36f0468d2a2
This commit is contained in:
Jesse Hall 2014-08-25 14:44:16 -07:00
parent f00945cfd7
commit 4d407a0f05

View File

@ -524,6 +524,10 @@ void HWComposer::eventControl(int disp, int event, int enabled) {
if (!err) { if (!err) {
int32_t& events(mDisplayData[disp].events); int32_t& events(mDisplayData[disp].events);
events = (events & ~eventBit) | newValue; events = (events & ~eventBit) | newValue;
char tag[16];
snprintf(tag, sizeof(tag), "HW_VSYNC_ON_%1u", disp);
ATRACE_INT(tag, enabled);
} }
} }
// error here should not happen -- not sure what we should // error here should not happen -- not sure what we should