cpuidtest.s

来自「*****汇编语言程序设计 源代码*****」· S 代码 · 共 33 行

S
33
字号
# cpuidtest.s - An example of using the TEST instruction.section .dataoutput_cpuid:   .asciz "This processor supports the CPUID instruction\n"output_nocpuid:   .asciz "This processor does not support the CPUID instruction\n".section .text.globl _start_start:   nop   pushfl   popl %eax   movl %eax, %edx   xor $0x00200000, %eax   pushl %eax   popfl   pushfl   popl %eax   xor %edx, %eax   test $0x00200000, %eax   jnz cpuid   pushl $output_nocpuid   call printf   add  $4, %esp   pushl $0   call exitcpuid:   pushl $output_cpuid   call printf   add  $4, %esp   pushl $0   call exit

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?