x86---1

来源:互联网 发布:魅蓝note6网络频段 编辑:程序博客网 时间:2024/05/04 09:58

#cpuid.S a sample program to extract processor Verdor ID

.section .data

output:

.ascii "The processor Vendor ID is 'xxxxxxxxxxxx'\n"

.section .text

.globl _start

_start:

nop

movl $0,%eax

cpuid

movl $output,%edi 

movl %ebx,28(%edi)

movl %edx,32(%edi)

movl %ecx,36(%edi)

 

movl $4,%eax

movl $1,%ebx

movl $output,%ecx

movl $42,%edx

int $0x80

movl $1,%eax

movl $2,%ebx

int $0x80

原创粉丝点击