This website works better with JavaScript.
首頁
探索
帮助
返回水杉在线
登录水杉在线
登录水杉码园
10213903403
/
os_kernel_lab
關註
1
收藏
0
複製
0
程式碼
問題管理
0
合併請求
0
版本發佈
0
Wiki
Activity
瀏覽代碼
add lab1 related info
main
chyyuu
11 年之前
父節點
43ac8a7152
當前提交
759eca9dda
共有
3 個文件被更改
,包括
46 次插入
和
0 次删除
分割檢視
Diff Options
Show Stats
Download Patch File
Download Diff File
+6
-0
related_info/lab1/Makefile
+26
-0
related_info/lab1/defines.h
+14
-0
related_info/lab1/write.s
+ 6
- 0
related_info/lab1/Makefile
查看文件
@ -0,0 +1,6 @@
all
:
write
write
:
defines
.
h
write
.
s
gcc -o write write.s
clean
:
rm write write.o
+ 26
- 0
related_info/lab1/defines.h
查看文件
@ -0,0 +1,26 @@
SYS_exit
=
1
SYS_fork
=
2
SYS_write
=
4
SYS_open
=
5
SYS_close
=
6
SYS_execve
=
11
SYS_lseek
=
19
SYS_dup2
=
63
SYS_mmap
=
90
SYS_munmap
=
91
SYS_socketcall
=
102
SYS_socketcall_socket
=
1
SYS_socketcall_bind
=
2
SYS_socketcall_listen
=
4
SYS_socketcall_accept
=
5
SEEK_END
=
2
PROT_READ
=
1
MAP_SHARED
=
1
AF_INET
=
2
SOCK_STREAM
=
1
IPPROTO_TCP
=
6
STDOUT
=
1
+ 14
- 0
related_info/lab1/write.s
查看文件
@ -0,0 +1,14 @@
.include
"defines.h"
.data
hello:
.string
"hello world\n"
.globl
main
main:
movl
$SYS_write
,
%eax
movl
$STDOUT
,
%ebx
movl
$hello
,
%ecx
movl
$12
,
%edx
int
$0x80
ret
Write
Preview
Loading…
取消
儲存