Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: PerlGameDev/SDL
base: 3c93c9abcb36
Choose a base ref
...
head repository: PerlGameDev/SDL
compare: cc9b323237b4
Choose a head ref
  • 1 commit
  • 1 file changed
  • 1 contributor

Commits on Mar 17, 2015

  1. remove apparently unnecessary pump_events to smooth out performance p…

    …rofile
    
    Note ahead, in this comment @kthakore observed issues around pump_events
    that i do not understand fully, and i would love if he could find the time
    to provide input on this:
    
    SHA-1: 4aa0251
    
    * Need to pump before we poll to prevent skipping too many events before processing something
    
    That said, according to the documentation:
    
    http://sdl.beuc.net/sdl.wiki/SDL_PumpEvents
    
    > Often the need for calls to SDL_PumpEvents is hidden from the user
    > since SDL_PollEvent [...] implicitly call SDL_PumpEvents.
    > [...] if you are not polling or waiting for events [...]
    > you must call SDL_PumpEvents
    
    http://sdl.beuc.net/sdl.wiki/SDL_PollEvent
    
    > this function implicitly calls SDL_PumpEvents
    
    This means that removing it should have no deleterious effects.
    
    At the same time, its presence does seem to cause some. In the graph in
    this screenshot you will notice occasional red spikes at the bottom. These
    are caused by pump_events taking more time than ordinary, and disappear
    with (on Win7) no noticable side effects when pump_events is removed.
    
    Given that clear benefit, i would like to see this commit released live in
    a production release to see if it causes ill effects for anyone using SDL.
    wchristian committed Mar 17, 2015
    Copy the full SHA
    cc9b323 View commit details
    Browse the repository at this point in the history