mtdbg: set rounding mode to -Inf

git-svn-id: svn://kolibrios.org@4909 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Sergey Semyonov (Serge) 2014-04-28 11:26:30 +00:00
parent 1658e3af3a
commit 212556765d
2 changed files with 12 additions and 5 deletions

View File

@ -105,7 +105,10 @@ start:
push eax
fstcw word [esp]
or word [esp], 3 shl 10 ; set round-to-zero mode
pop eax
and ax, not (3 shl 10)
or ax, 1 shl 10 ; set round-to-minus infinity mode
push eax
fldcw word [esp]
pop eax
@ -734,6 +737,9 @@ draw_fpu_register_2:
stosd
stosd
;int3
;nop
mov edx, ebp
shl edx, 4
@ -770,7 +776,6 @@ draw_fpu_register_2:
jmp .display
.decode:
fld tword [_st0+edx]
fldlg2
fld tword [_st0+edx]
@ -783,6 +788,9 @@ draw_fpu_register_2:
fist dword [.exp_v]
fld st0
fbstp tword [.bcd_exp]
push 8
fisub dword [esp]
pop eax
fldl2t
fmulp
fld st0
@ -796,7 +804,6 @@ draw_fpu_register_2:
fscale
fstp st1
fdivp
fimul dword [_10000000]
fbstp tword [.bcd_man]
lea esi, [.bcd_man-1]

View File

@ -2333,13 +2333,13 @@ avx_strs:
db '-YMM6-'
db '-YMM7-'
align 4
debuggee_pid dd 0
bSuspended db 0
bAfterGo db 0
temp_break dd 0
reg_mode db 1
_10000000 dd 1000000000
include 'disasm_tbl.inc'