mirror of
https://github.com/X11Libre/xserver.git
synced 2026-03-24 05:54:08 +00:00
dix: Push UpdateCurrentTimeIf down out of the main loop
This was added in:
commit 312910b4e3
Author: Chase Douglas <chase.douglas@canonical.com>
Date: Wed Apr 18 11:15:40 2012 -0700
Update currentTime in dispatch loop
Unfortunately this is equivalent to calling GetTimeInMillis() once per
request. In the absolute best case (as on Linux) you're only hitting the
vDSO; on other platforms that's a syscall. Either way it puts a pretty
hard ceiling on request throughput.
Instead, push the call down to the requests that need it; basically,
grab processing and event generation.
Cc: Chase Douglas <chase.douglas@canonical.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Adam Jackson <ajax@redhat.com>
This commit is contained in:
@@ -153,6 +153,7 @@ CursorDisplayCursor(DeviceIntPtr pDev, ScreenPtr pScreen, CursorPtr pCursor)
|
||||
if (pCursor != CursorCurrent[pDev->id]) {
|
||||
CursorEventPtr e;
|
||||
|
||||
UpdateCurrentTimeIf();
|
||||
CursorCurrent[pDev->id] = pCursor;
|
||||
for (e = cursorEvents; e; e = e->next) {
|
||||
if ((e->eventMask & XFixesDisplayCursorNotifyMask)) {
|
||||
|
||||
Reference in New Issue
Block a user