Changeset 181 in xtideuniversalbios for trunk/Assembly_Library/Src/String


Ignore:
Timestamp:
Nov 13, 2011, 3:38:40 PM (12 years ago)
Author:
krille_n_@…
google:author:
krille_n_@hotmail.com
Message:

Changes to all parts of the project:

  • Size optimizations.
  • Added a define (EXCLUDE_FROM_XTIDECFG) to exclude unused library code from XTIDECFG.
  • Tried to minimize time spent with interrupts disabled.
  • Some minor attempts to improve speed (reordering instructions etc).
  • Tried to improve readability, did some cleanup and fixed some errors in comments.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Assembly_Library/Src/String/Char.asm

    r162 r181  
    161161Char_ALtoLowerCaseLetter:
    162162    call    Char_IsUpperCaseLetterInAL  ; Is upper case character?
    163     jnc     SHORT .Return               ;  If not, return
    164     add     al, 'a'-'A'                 ; Convert to lower case
    165 .Return:
    166     ret
     163    jmp     SHORT Char_ALtoUpperCaseLetter.CheckCF
    167164%endif
    168165
     
    179176Char_ALtoUpperCaseLetter:
    180177    call    Char_IsLowerCaseLetterInAL  ; Is lower case character?
    181     jnc     SHORT .Return               ;  If not, return
    182     sub     al, 'a'-'A'                 ; Convert to upper case
     178.CheckCF:
     179    jnc     SHORT Char_ChangeCaseInAL.Return
     180    ; Fall to Char_ChangeCaseInAL
     181
     182;--------------------------------------------------------------------
     183; Char_ChangeCaseInAL
     184;   Parameters:
     185;       AL:     Character to convert (must be A-Z or a-z)
     186;   Returns:
     187;       AL:     Character converted
     188;   Corrupts registers:
     189;       Nothing
     190;--------------------------------------------------------------------
     191Char_ChangeCaseInAL:
     192    xor     al, 32
    183193.Return:
    184194    ret
    185 
    186195
    187196;--------------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.