fpmath1.s
来自「*****汇编语言程序设计 源代码*****」· S 代码 · 共 46 行
S
46 行
# fpmath1.s - An example of basic FPU math.section .datavalue1: .float 43.65value2: .int 22value3: .float 76.34value4: .float 3.1value5: .float 12.43value6: .int 6value7: .float 140.2value8: .float 94.21output: .asciz "The result is %f\n".section .text.globl _start_start:nop finit flds value1 fidiv value2 flds value3 flds value4 fmul %st(1), %st(0) fadd %st(2), %st(0) flds value5 fimul value6 flds value7 flds value8 fdivrp fsubr %st(1), %st(0) fdivr %st(2), %st(0) subl $8, %esp fstpl (%esp) pushl $output call printf add $12, %esp pushl $0 call exit
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?