Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(891)

Unified Diff: src/platform-linux.cc

Issue 6716021: Use different syscall constants on Android (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 9 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/platform-linux.cc
===================================================================
--- src/platform-linux.cc (revision 7276)
+++ src/platform-linux.cc (working copy)
@@ -803,7 +803,11 @@
static int GetThreadID() {
// Glibc doesn't provide a wrapper for gettid(2).
+#if defined(ANDROID)
+ return syscall(__NR_gettid);
+#else
return syscall(SYS_gettid);
+#endif
}
@@ -967,7 +971,11 @@
void SendProfilingSignal(int tid) {
if (!signal_handler_installed_) return;
// Glibc doesn't provide a wrapper for tgkill(2).
+#if defined(ANDROID)
+ syscall(__NR_tgkill, vm_tgid_, tid, SIGPROF);
+#else
syscall(SYS_tgkill, vm_tgid_, tid, SIGPROF);
+#endif
}
void Sleep(SleepInterval full_or_half) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698