Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Removed obsolete timer workaround from Cocoa backend
  • Loading branch information
alexey-lysiuk committed Apr 23, 2017
1 parent 6fb1689 commit e78d880
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions src/posix/cocoa/i_timer.cpp
Expand Up @@ -35,7 +35,6 @@
#include <sys/sysctl.h>
#include <sys/time.h>
#include <pthread.h>
#include <libkern/OSAtomic.h>

#include "doomdef.h"
#include "i_system.h"
Expand Down Expand Up @@ -124,12 +123,7 @@ void* TimerThreadFunc(void*)

if (!s_isTicFrozen)
{
// The following GCC/Clang intrinsic can be used instead of OS X specific function:
// __sync_add_and_fetch(&s_tics, 1);
// Although it's not supported on all platform/compiler combination,
// e.g. GCC 4.0.1 with PowerPC target architecture

OSAtomicIncrement32(&s_tics);
__sync_add_and_fetch(&s_tics, 1);
}

s_timerStart = I_MSTime();
Expand Down

0 comments on commit e78d880

Please sign in to comment.