OLD | NEW |
1 // Copyright 2009 The Go Authors. All rights reserved. | 1 // Copyright 2009 The Go Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style | 2 // Use of this source code is governed by a BSD-style |
3 // license that can be found in the LICENSE file. | 3 // license that can be found in the LICENSE file. |
4 // | 4 // |
5 // System calls and other sys.stuff for 386, OpenBSD | 5 // System calls and other sys.stuff for 386, OpenBSD |
6 // /usr/src/sys/kern/syscalls.master for syscall numbers. | 6 // /usr/src/sys/kern/syscalls.master for syscall numbers. |
7 // | 7 // |
8 | 8 |
9 #include "zasm_GOOS_GOARCH.h" | 9 #include "go_asm.h" |
| 10 #include "go_tls.h" |
10 #include "textflag.h" | 11 #include "textflag.h" |
11 | 12 |
12 #define CLOCK_MONOTONIC $3 | 13 #define CLOCK_MONOTONIC $3 |
13 | 14 |
14 // Exit the entire program (like C exit) | 15 // Exit the entire program (like C exit) |
15 TEXT runtime·exit(SB),NOSPLIT,$-4 | 16 TEXT runtime·exit(SB),NOSPLIT,$-4 |
16 MOVL $1, AX | 17 MOVL $1, AX |
17 INT $0x80 | 18 INT $0x80 |
18 MOVL $0xf1, 0xf1 // crash | 19 MOVL $0xf1, 0xf1 // crash |
19 RET | 20 RET |
(...skipping 369 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
389 MOVL fd+0(FP), BX | 390 MOVL fd+0(FP), BX |
390 MOVL BX, 4(SP) // fd | 391 MOVL BX, 4(SP) // fd |
391 MOVL $2, 8(SP) // F_SETFD | 392 MOVL $2, 8(SP) // F_SETFD |
392 MOVL $1, 12(SP) // FD_CLOEXEC | 393 MOVL $1, 12(SP) // FD_CLOEXEC |
393 INT $0x80 | 394 INT $0x80 |
394 JAE 2(PC) | 395 JAE 2(PC) |
395 NEGL AX | 396 NEGL AX |
396 RET | 397 RET |
397 | 398 |
398 GLOBL runtime·tlsoffset(SB),NOPTR,$4 | 399 GLOBL runtime·tlsoffset(SB),NOPTR,$4 |
OLD | NEW |