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

Side by Side Diff: fusl/arch/x86_64/syscall_arch.h

Issue 1573973002: Add a "fork" of musl as //fusl. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 4 years, 11 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 unified diff | Download patch
« no previous file with comments | « fusl/arch/x86_64/reloc.h ('k') | fusl/configure » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 #define __SYSCALL_LL_E(x) (x)
2 #define __SYSCALL_LL_O(x) (x)
3
4 static __inline long __syscall0(long n)
5 {
6 unsigned long ret;
7 __asm__ __volatile__ ("syscall" : "=a"(ret) : "a"(n) : "rcx", "r11", "me mory");
8 return ret;
9 }
10
11 static __inline long __syscall1(long n, long a1)
12 {
13 unsigned long ret;
14 __asm__ __volatile__ ("syscall" : "=a"(ret) : "a"(n), "D"(a1) : "rcx", " r11", "memory");
15 return ret;
16 }
17
18 static __inline long __syscall2(long n, long a1, long a2)
19 {
20 unsigned long ret;
21 __asm__ __volatile__ ("syscall" : "=a"(ret) : "a"(n), "D"(a1), "S"(a2)
22 : "rcx", "r11", "memory");
23 return ret;
24 }
25
26 static __inline long __syscall3(long n, long a1, long a2, long a3)
27 {
28 unsigned long ret;
29 __asm__ __volatile__ ("syscall" : "=a"(ret) : "a"(n), "D"(a1), "S"(a2),
30 "d"(a3) : "rcx", "r11", "memor y");
31 return ret;
32 }
33
34 static __inline long __syscall4(long n, long a1, long a2, long a3, long a4)
35 {
36 unsigned long ret;
37 register long r10 __asm__("r10") = a4;
38 __asm__ __volatile__ ("syscall" : "=a"(ret) : "a"(n), "D"(a1), "S"(a2),
39 "d"(a3), "r"(r10): "rcx", "r11 ", "memory");
40 return ret;
41 }
42
43 static __inline long __syscall5(long n, long a1, long a2, long a3, long a4, long a5)
44 {
45 unsigned long ret;
46 register long r10 __asm__("r10") = a4;
47 register long r8 __asm__("r8") = a5;
48 __asm__ __volatile__ ("syscall" : "=a"(ret) : "a"(n), "D"(a1), "S"(a2),
49 "d"(a3), "r"(r10), "r"(r8) : " rcx", "r11", "memory");
50 return ret;
51 }
52
53 static __inline long __syscall6(long n, long a1, long a2, long a3, long a4, long a5, long a6)
54 {
55 unsigned long ret;
56 register long r10 __asm__("r10") = a4;
57 register long r8 __asm__("r8") = a5;
58 register long r9 __asm__("r9") = a6;
59 __asm__ __volatile__ ("syscall" : "=a"(ret) : "a"(n), "D"(a1), "S"(a2),
60 "d"(a3), "r"(r10), "r"(r8), "r "(r9) : "rcx", "r11", "memory");
61 return ret;
62 }
63
64 #define VDSO_USEFUL
65 #define VDSO_CGT_SYM "__vdso_clock_gettime"
66 #define VDSO_CGT_VER "LINUX_2.6"
OLDNEW
« no previous file with comments | « fusl/arch/x86_64/reloc.h ('k') | fusl/configure » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698