Make improvements

- Polyfill readlink("foo/") dir check on Windows
- Support asynchronous signal delivery on Windows
- Restore Windows Console from execve() daisy chain
- Work around bug in AARCH64 Optimized Routines memcmp()
- Disable unbourne.com shell completion on Windows for now
- Don't always set virtual terminal input state on console
- Remove Musl Libc's unusual preservation of realpath("//")
- Make realpath() strongly link malloc() to pass configure test
- Delete cosh.com shell, now that unbourne.com works on Windows!
This commit is contained in:
Justine Tunney 2023-09-06 22:39:36 -07:00
parent f9c9a323fe
commit 425c055116
No known key found for this signature in database
GPG key ID: BE714B4575D6E328
40 changed files with 581 additions and 706 deletions

View file

@ -94,6 +94,12 @@ o/$(MODE)/libc/fmt/strsignal.greg.o: private \
-ffreestanding \
$(NO_MAGIC)
# we can't use sanitizers because:
# WinMain calls this
o/$(MODE)/libc/str/tprecode8to16.o: private \
COPTS += \
-fno-sanitize=all
o/$(MODE)/libc/str/eastasianwidth.bin: \
libc/str/eastasianwidth.txt \
o/$(MODE)/tool/decode/mkwides.com

View file

@ -24,9 +24,9 @@
#include "libc/str/thompike.h"
#include "libc/str/utf16.h"
/* 34x speedup for ascii */
static inline dontasan axdx_t tprecode8to16_sse2(char16_t *dst, size_t dstsize,
const char *src, axdx_t r) {
// 34x speedup for ascii
static inline axdx_t tprecode8to16_sse2(char16_t *dst, size_t dstsize,
const char *src, axdx_t r) {
uint8_t v1[16], v2[16], vz[16];
memset(vz, 0, 16);
while (r.ax + 16 < dstsize) {
@ -62,9 +62,11 @@ axdx_t tprecode8to16(char16_t *dst, size_t dstsize, const char *src) {
r.ax = 0;
r.dx = 0;
for (;;) {
#ifdef __x86_64__
if (!IsTiny() && !((uintptr_t)(src + r.dx) & 15)) {
r = tprecode8to16_sse2(dst, dstsize, src, r);
}
#endif
x = src[r.dx++] & 0377;
if (x >= 0300) {
a = ThomPikeByte(x);