文件名称:WORD lookKbits(BYTE k)
文件大小:1KB
文件格式:TXT
更新时间:2014-12-04 10:34:29
lookKbits WORD_hi_lo get svalue 汇编转C语言
将汇编代码转换成C语言 汇编代码: WORD lookKbits(BYTE k) { _asm { mov dl, k mov cl, 16 sub cl, dl mov eax, [wordval] shr eax, cl } } WORD WORD_hi_lo(BYTE byte_high,BYTE byte_low) { _asm { mov ah,byte_high mov al,byte_low } } SWORD get_svalue(BYTE k) { _asm { xor ecx, ecx mov cl,k mov eax,[wordval] shl eax,cl shr eax, 16 dec cl bt eax,ecx jc end_macro signed_value:inc cl mov ebx,[start_neg_pow2] add ax,word ptr [ebx+ecx*2] end_macro: } }