You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by gs...@apache.org on 2007/03/23 16:32:53 UTC
svn commit: r521768 -
/harmony/enhanced/drlvm/trunk/vm/thread/src/linux/os_thread.c
Author: gshimansky
Date: Fri Mar 23 08:32:52 2007
New Revision: 521768
URL: http://svn.apache.org/viewvc?view=rev&rev=521768
Log:
Make gettid available on all platforms which don't have _syscall0
Modified:
harmony/enhanced/drlvm/trunk/vm/thread/src/linux/os_thread.c
Modified: harmony/enhanced/drlvm/trunk/vm/thread/src/linux/os_thread.c
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/thread/src/linux/os_thread.c?view=diff&rev=521768&r1=521767&r2=521768
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/thread/src/linux/os_thread.c (original)
+++ harmony/enhanced/drlvm/trunk/vm/thread/src/linux/os_thread.c Fri Mar 23 08:32:52 2007
@@ -24,8 +24,15 @@
#include "thread_private.h"
+#ifdef _syscall0
_syscall0(pid_t,gettid)
pid_t gettid(void);
+#else
+pid_t gettid(void)
+{
+ return (pid_t)syscall(__NR_gettid);
+}
+#endif
/**
* Creates new thread.