state: optimize xkb_state_led_update_all()
authorRan Benita <ran234@gmail.com>
Sat, 8 Feb 2014 13:53:50 +0000 (15:53 +0200)
committerRan Benita <ran234@gmail.com>
Sat, 8 Feb 2014 13:57:22 +0000 (15:57 +0200)
commit04bacf87ba0f91a4d4445c55565373830cb7ec4a
treebbf97a59606420a691b19e3e565597264016aa7b
parent769b91c580832eea279770d8a14f8aa23bf16f34
state: optimize xkb_state_led_update_all()

Before:
    ran@ran:~/src/libxkbcommon$ ./test/bench-key-proc
    ran 20000000 iterations in 6.623018074s

After:
    ran@ran:~/src/libxkbcommon$ ./test/bench-key-proc
    ran 20000000 iterations in 4.762291091s

Not that anyone needs to process millions of keys per second...

Signed-off-by: Ran Benita <ran234@gmail.com>
src/state.c