root / ia64-syscall.S @ 982b4315
History | View | Annotate | Download (884 Bytes)
1 | 0d330196 | bellard | /* derived from glibc sysdeps/unix/sysv/linux/ia64/sysdep.S */ |
---|---|---|---|
2 | 0d330196 | bellard | |
3 | 0d330196 | bellard | #define __ASSEMBLY__ |
4 | 0d330196 | bellard | |
5 | 0d330196 | bellard | #include <asm/asmmacro.h> |
6 | 0d330196 | bellard | #include <asm/unistd.h> |
7 | 0d330196 | bellard | |
8 | 0d330196 | bellard | ENTRY(__syscall_error) |
9 | 0d330196 | bellard | .prologue ASM_UNW_PRLG_RP|ASM_UNW_PRLG_PFS, ASM_UNW_PRLG_GRSAVE(0) |
10 | 0d330196 | bellard | alloc r33=ar.pfs, 0, 4, 0, 0 |
11 | 0d330196 | bellard | mov r32=rp |
12 | 0d330196 | bellard | .body |
13 | 0d330196 | bellard | mov r35=r8 |
14 | 0d330196 | bellard | mov r34=r1 |
15 | 0d330196 | bellard | ;; |
16 | 0d330196 | bellard | br.call.sptk.many b0 = __errno_location |
17 | 0d330196 | bellard | .Lret0: /* force new bundle */ |
18 | 0d330196 | bellard | st4 [r8]=r35 |
19 | 0d330196 | bellard | mov r1=r34 |
20 | 0d330196 | bellard | mov rp=r32 |
21 | 0d330196 | bellard | mov r8=-1 |
22 | 0d330196 | bellard | mov ar.pfs=r33 |
23 | 0d330196 | bellard | br.ret.sptk.few b0 |
24 | 0d330196 | bellard | END(__syscall_error) |
25 | 0d330196 | bellard | |
26 | 0d330196 | bellard | GLOBAL_ENTRY(__ia64_syscall) |
27 | 0d330196 | bellard | mov r15=r37 /* syscall number */ |
28 | 0d330196 | bellard | break __BREAK_SYSCALL |
29 | 0d330196 | bellard | cmp.eq p6,p0=-1,r10 /* r10 = -1 on error */ |
30 | 0d330196 | bellard | (p6) br.cond.spnt.few __syscall_error |
31 | 0d330196 | bellard | br.ret.sptk.few b0 |
32 | 0d330196 | bellard | .endp __ia64_syscall |