# An example of using command line parameters (使用命令行参数)
#
#
.section .data
output:
.asciz "The area is: %f\n"
.section .bss
.lcomm result, 4
.section .text
.globl main
main:
nop
finit
push 8(%esp)
call atoi
addl $4, %esp
movl %eax, result
fldpi
filds result
fmul %st(0), %st(0)
fmul %st(1), %st(0)
fstpl (%esp)
push $output
call printf
addl $12, %esp
push $0
call exit
# gcc -g -o 06 06-commandline-example.s
#
# ./06 10