Remove useless END from nls_hc.asm, add explicit byte overrides for older

versions of NASM for more compact code, and adjust silent relocation segments.


git-svn-id: https://svn.code.sf.net/p/freedos/svn/kernel/trunk@1567 6ac86273-5f31-0410-b378-82cca8765d1b
This commit is contained in:
Bart Oldeman 2011-04-09 02:03:20 +00:00
parent feaf5beb88
commit 3df307b933
7 changed files with 16 additions and 15 deletions

View File

@ -43,7 +43,7 @@ READPCCLOCK:
; (ah is still 0, al contains midnight flag)
add word [_DaysSinceEpoch ],ax ; *some* BIOSes accumulate several days
adc word [_DaysSinceEpoch+2],0 ;
adc word [_DaysSinceEpoch+2],byte 0;
; set return value dx:ax
xchg ax,cx ; ax=_cx, cx=_ax

View File

@ -540,6 +540,10 @@ strncmp_retzero:
strncmp_done:
lahf
ror ah,1
%ifdef _INIT
strncmp_done2: jmp short pascal_return
%else
strncmp_done2: jmp pascal_return
%endif
%endif

View File

@ -83,7 +83,7 @@ reloc_call_cpm_entry:
; psp seg
; 000ah
;
add sp, 2 ; remove unneeded far return offset 0ah
add sp, byte 2 ; remove unneeded far return offset 0ah
pushf ; start setting up int 21h stack
;
; now stack is
@ -173,7 +173,7 @@ stack_loop:
int 10h
inc si
inc si
cmp si, 13*2
cmp si, byte 13*2
jb stack_loop
mov al, 0dh
int 10h
@ -380,9 +380,9 @@ int21_exit_nodec:
%if XCPU >= 386
%ifdef WATCOM
sub bp, 4 ; for fs and gs only
sub bp, byte 4 ; for fs and gs only
%else
sub bp, 6 ; high parts of eax, ebx or ecx, edx
sub bp, byte 6 ; high parts of eax, ebx or ecx, edx
%endif
%endif

View File

@ -105,13 +105,13 @@ general_irq_service:
push bx
mov bx, sp
mov bx, [ss:bx+2] ; return address->old ivec
jmp common_irq
jmp short common_irq
general_irq_service_share:
push bx
mov bx, sp
mov bx, [ss:bx+2] ; return address->old ivec
sub bx, irq_3 - irq_2 - 2
sub bx, byte irq_3 - irq_2 - 2
common_irq:
push dx
push ax
@ -152,7 +152,7 @@ return: pop ds ; restore registers and return
pop ax
pop dx
pop bx
add sp, 2
add sp, byte 2
iret
dont_switch: pushf

View File

@ -1010,9 +1010,9 @@ global _ExecUserDisableA20
_ExecUserDisableA20:
cmp word [cs:_XMSDriverAddress],0
cmp word [cs:_XMSDriverAddress], byte 0
jne NeedToDisable
cmp word [cs:_XMSDriverAddress+2],0
cmp word [cs:_XMSDriverAddress+2], byte 0
je noNeedToDisable
NeedToDisable:
push ax

View File

@ -35,9 +35,9 @@ production: ../bin/$(TARGET).sys ../bin/country.sys
$(CP) kernel.map ..$(DIRSEP)bin$(DIRSEP)$(TARGET).map
# -S to avoid showing expected relocations
# 0x10 & 0x74 for non-fat32 kernel, 0x10 & 0x73 for fat32 enabled kernel
# 0x10 & 0x78 or 0x79 depending on compilation options
kernel.sys: kernel.exe ../utils/exeflat.exe
..$(DIRSEP)utils$(DIRSEP)exeflat.exe kernel.exe kernel.sys $(LOADSEG) -S0x10 -S0x79 $(UPXOPT) $(XUPX)
..$(DIRSEP)utils$(DIRSEP)exeflat.exe kernel.exe kernel.sys $(LOADSEG) -S0x10 -S0x78 -S0x79 $(UPXOPT) $(XUPX)
kernel.exe: $(TARGET).lnk $(OBJS) $(LIBS)
$(LINK) @$(TARGET).lnk;

View File

@ -125,6 +125,3 @@ _nlsDBCSHardcoded:
DB 000h, 000h, 000h, 000h
GLOBAL _hcTablesEnd
_hcTablesEnd:
END