Make dos errno multimapping linkage tinier

640 bytes for old kDos2Errno table
182 bytes for new kDos2Errno under hello2.com (MODE=fastbuild)
122 bytes for new kDos2Errno under hello2.com (MODE=tiny)
This commit is contained in:
Justine Tunney 2022-09-13 06:25:50 -07:00
parent 9fa6725067
commit 8f5678882d
No known key found for this signature in database
GPG key ID: BE714B4575D6E328
63 changed files with 602 additions and 160 deletions

View file

@ -89,7 +89,7 @@
#define kNtErrorBufferOverflow 111
#define kNtErrorDiskFull 112 /* ENOSPC */
#define kNtErrorNoMoreSearchHandles 113
#define kNtErrorInvalidTargetHandle 114
#define kNtErrorInvalidTargetHandle 114 /* EBADF */
#define kNtErrorInvalidCategory 117
#define kNtErrorInvalidVerifySwitch 118
#define kNtErrorBadDriverLevel 119
@ -103,7 +103,7 @@
#define kNtErrorProcNotFound 127
#define kNtErrorWaitNoChildren 128 /* ECHILD */
#define kNtErrorChildNotComplete 129
#define kNtErrorDirectAccessHandle 130
#define kNtErrorDirectAccessHandle 130 /* EBADF */
#define kNtErrorNegativeSeek 131
#define kNtErrorSeekOnDevice 132
#define kNtErrorIsJoinTarget 133

View file

@ -1,2 +1,15 @@
.include "o/libc/nt/codegen.inc"
.imp kernel32,__imp_SuspendThread,SuspendThread,0
.text.windows
SuspendThread:
push %rbp
mov %rsp,%rbp
.profilable
mov %rdi,%rcx
sub $32,%rsp
call *__imp_SuspendThread(%rip)
leave
ret
.endfn SuspendThread,globl
.previous

View file

@ -983,7 +983,7 @@ imp 'SleepConditionVariableSRW' SleepConditionVariableSRW kernel32 0
imp 'SleepEx' SleepEx kernel32 0 2
imp 'SortCloseHandle' SortCloseHandle kernel32 1416
imp 'SortGetHandle' SortGetHandle kernel32 1417
imp 'SuspendThread' SuspendThread kernel32 0
imp 'SuspendThread' SuspendThread kernel32 0 1
imp 'SwitchToFiber' SwitchToFiber kernel32 0
imp 'SwitchToThread' SwitchToThread kernel32 0
imp 'SystemTimeToFileTime' SystemTimeToFileTime kernel32 0 2