我使用this version of raspberry pi创建了一个虚拟机。我正在尝试汇编简单的汇编程序“ program.s”
.global _start
_start:
mov r0,#0 @ exit status code 0 for normal completion
mov r7,#1 @ service command 1 terminates this program
svc 0 @ issue linux command to terminate program
与
组装as -o program.o program.s
给予
GNU assembler version 2.28 (i686-linux-gnu) using BFD version (GNU Binutils
for Debian) 2.28
e.s: Assembler messages:
e.s:6: Error: expecting operand after ','; got nothing
e.s:7: Error: expecting operand after ','; got nothing
e.s:8: Error: no such instruction: `svc 0'
我不认为问题出在代码上,而是与汇编程序试图汇编的汇编类型有关。我是Raspberry Pi和组装的入门者,所以我完全不知所措。