OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [linux/] [uClibc/] [libc/] [sysdeps/] [linux/] [i386/] [vfork.S] - Blame information for rev 1765

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 1325 phoenix
/*
2
 * June 3, 2003             Erik Andersen
3
 *
4
 */
5
 
6
#define _ERRNO_H        1
7
#include 
8
#include 
9
 
10
#ifndef __NR_vfork
11
 
12
/* No vfork so use fork instead */
13
.weak vfork ; vfork = __libc_fork
14
 
15
#else
16
 
17
        .text
18
        .globl __vfork;
19
        .type __vfork,@function;
20
        .align 1<<4;
21
 
22
__vfork:
23
        popl %ecx
24
        movl $__NR_vfork,%eax
25
        int $0x80
26
        pushl %ecx
27
        cmpl $-4095,%eax
28
        jae __syscall_error
29
        ret
30
 
31
__syscall_error:
32
        negl    %eax
33
        pushl   %eax
34
#ifdef __PIC__
35
        call .Lthere
36
.Lthere:
37
        popl    %ebx
38
        addl    $_GLOBAL_OFFSET_TABLE_+[.- .Lthere  ], %ebx
39
        call    __errno_location@PLT
40
#else
41
        call    __errno_location
42
#endif
43
        popl    %ecx
44
        movl    %ecx, (%eax)
45
        xorl    %eax, %eax
46
        decl    %eax
47
 
48
.Lsize:
49
        .size    __vfork,.Lsize-__vfork
50
 
51
 
52
.weak vfork ; vfork = __vfork
53
#endif

powered by: WebSVN 2.1.0

© copyright 1999-2025 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.