Changeset 445 in xtideuniversalbios for trunk/Configurator


Ignore:
Timestamp:
Aug 29, 2012, 12:59:23 PM (12 years ago)
Author:
krille_n_@…
google:author:
krille_n_@hotmail.com
Message:

Changes:

  • A speed optimization to the eSHL_IM macro for 386 and higher. This change breaks emulation in the sense that the macro will fail when given a memory operand as the first parameter.
  • Memory_SumCXbytesFromESSItoAL now returns with the zero flag set/cleared according to the result.
  • Unrolled all the 8 bit READ transfer loops to do 16 bytes per iteration. Added a new macro (UNROLL_SECTORS_IN_CX_TO_OWORDS) as part of it. Size wise this is expensive but I think it should be worth the ROM space. The WRITE transfer loops were left as is since writes are rare anyway (<10% of all disk I/O IIRC).
  • Minor optimizations and fixes here and there.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Configurator/Src/Libraries/math.asm

    r181 r445  
    104104    push    bx
    105105    mov     bx, dx              ; Copy hiword to BX
    106     xor     dx, dx              ; Zero DX for multiplication
    107106    mul     cx                  ; DX:AX = AX (loword) * CX (multiplier)
    108107    push    dx                  ; Push possible overflow
    109108    xchg    ax, bx              ; => AX=old hiword, BX=new loword
    110     xor     dx, dx              ; Zero DX for division
    111109    mul     cx                  ; DX:AX = AX (hiword) * CX (multiplier)
    112110    pop     dx                  ; Pop possible overflow from first mul
Note: See TracChangeset for help on using the changeset viewer.