mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-02-07 23:13:34 +00:00
- Python static hello world now 1.8mb - Python static fully loaded now 10mb - Python HTTPS client now uses MbedTLS - Python REPL now completes import stmts - Increase stack size for Python for now - Begin synthesizing posixpath and ntpath - Restore Python \N{UNICODE NAME} support - Restore Python NFKD symbol normalization - Add optimized code path for Intel SHA-NI - Get more Python unit tests passing faster - Get Python help() pagination working on NT - Python hashlib now supports MbedTLS PBKDF2 - Make memcpy/memmove/memcmp/bcmp/etc. faster - Add Mersenne Twister and Vigna to LIBC_RAND - Provide privileged __printf() for error code - Fix zipos opendir() so that it reports ENOTDIR - Add basic chmod() implementation for Windows NT - Add Cosmo's best functions to Python cosmo module - Pin function trace indent depth to that of caller - Show memory diagram on invalid access in MODE=dbg - Differentiate stack overflow on crash in MODE=dbg - Add stb_truetype and tools for analyzing font files - Upgrade to UNICODE 13 and reduce its binary footprint - COMPILE.COM now logs resource usage of build commands - Start implementing basic poll() support on bare metal - Set getauxval(AT_EXECFN) to GetModuleFileName() on NT - Add descriptions to strerror() in non-TINY build modes - Add COUNTBRANCH() macro to help with micro-optimizations - Make error / backtrace / asan / memory code more unbreakable - Add fast perfect C implementation of μ-Law and a-Law audio codecs - Make strtol() functions consistent with other libc implementations - Improve Linenoise implementation (see also github.com/jart/bestline) - COMPILE.COM now suppresses stdout/stderr of successful build commands
183 lines
9 KiB
ArmAsm
183 lines
9 KiB
ArmAsm
/*-*- mode:unix-assembly; indent-tabs-mode:t; tab-width:8; coding:utf-8 -*-│
|
|
│vi: set et ft=asm ts=8 tw=8 fenc=utf-8 :vi│
|
|
╞══════════════════════════════════════════════════════════════════════════════╡
|
|
│ Copyright 2021 Justine Alexandra Roberts Tunney │
|
|
│ │
|
|
│ Permission to use, copy, modify, and/or distribute this software for │
|
|
│ any purpose with or without fee is hereby granted, provided that the │
|
|
│ above copyright notice and this permission notice appear in all copies. │
|
|
│ │
|
|
│ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL │
|
|
│ WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED │
|
|
│ WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE │
|
|
│ AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL │
|
|
│ DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR │
|
|
│ PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER │
|
|
│ TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR │
|
|
│ PERFORMANCE OF THIS SOFTWARE. │
|
|
╚─────────────────────────────────────────────────────────────────────────────*/
|
|
#include "libc/macros.internal.h"
|
|
|
|
.macro .e e s
|
|
.long \e - kErrorNamesLong
|
|
.long 1f - kErrorNamesLong
|
|
.rodata.str1.1
|
|
1: .asciz "\s"
|
|
.previous
|
|
.endm
|
|
|
|
.section .rodata
|
|
.align 4
|
|
kErrorNamesLong:
|
|
.e EPIPE,"EPIPE[Broken pipe]"
|
|
.e ENODEV,"ENODEV[No such device]"
|
|
.e EINVAL,"EINVAL[Invalid argument]"
|
|
.e EINTR,"EINTR[Interrupted system call]"
|
|
.e ENOTBLK,"ENOTBLK[Block device required]"
|
|
.e ENOSYS,"ENOSYS[Function not implemented]"
|
|
.e EHOSTUNREACH,"EHOSTUNREACH[No route to host]"
|
|
.e ESRCH,"ESRCH[No such process]"
|
|
.e EUSERS,"EUSERS[Too many users]"
|
|
.e EXDEV,"EXDEV[Cross-device link]"
|
|
.e E2BIG,"E2BIG[Arg list too long]"
|
|
.e EREMOTE,"EREMOTE[Object is remote]"
|
|
.e ECHILD,"ECHILD[No child processes]"
|
|
.e EMSGSIZE,"EMSGSIZE[Message too long]"
|
|
.e ENOTEMPTY,"ENOTEMPTY[Directory not empty]"
|
|
.e ENOBUFS,"ENOBUFS[No buffer space available]"
|
|
.e ELOOP,"ELOOP[Too many symbolic links encountered]"
|
|
.e EAFNOSUPPORT,"EAFNOSUPPORT[Address family not supported by protocol]"
|
|
.e EHOSTDOWN,"EHOSTDOWN[Host is down]"
|
|
.e EPFNOSUPPORT,"EPFNOSUPPORT[Protocol family not supported]"
|
|
.e ENOPROTOOPT,"ENOPROTOOPT[Protocol not available]"
|
|
.e EBUSY,"EBUSY[Device or resource busy]"
|
|
.e EWOULDBLOCK,"EWOULDBLOCK[Operation would block]"
|
|
.e EBADFD,"EBADFD[File descriptor in bad state]"
|
|
.e EISCONN,"EISCONN[Transport endpoint is already connected]"
|
|
.e ESHUTDOWN,"ESHUTDOWN[Cannot send after transport endpoint shutdown]"
|
|
.e ENONET,"ENONET[Machine is not on the network]"
|
|
.e EBADE,"EBADE[Invalid exchange]"
|
|
.e EBADF,"EBADF[Bad file number]"
|
|
.e EMULTIHOP,"EMULTIHOP[Multihop attempted]"
|
|
.e EIO,"EIO[I/O error]"
|
|
.e EUNATCH,"EUNATCH[Protocol driver not attached]"
|
|
.e EPROTOTYPE,"EPROTOTYPE[Protocol wrong type for socket]"
|
|
.e ENOSPC,"ENOSPC[No space left on device]"
|
|
.e ENOEXEC,"ENOEXEC[Exec format error]"
|
|
.e EALREADY,"EALREADY[Operation already in progress]"
|
|
.e ENETDOWN,"ENETDOWN[Network is down]"
|
|
.e ENOTNAM,"ENOTNAM[Not a XENIX named type file]"
|
|
.e EACCES,"EACCES[Permission denied]"
|
|
.e ELNRNG,"ELNRNG[Link number out of range]"
|
|
.e EILSEQ,"EILSEQ[Illegal byte sequence]"
|
|
.e ENOTDIR,"ENOTDIR[Not a directory]"
|
|
.e ENOTUNIQ,"ENOTUNIQ[Name not unique on network]"
|
|
.e EPERM,"EPERM[Operation not permitted]"
|
|
.e EDOM,"EDOM[Math argument out of domain of func]"
|
|
.e EXFULL,"EXFULL[Exchange full]"
|
|
.e ECONNREFUSED,"ECONNREFUSED[Connection refused]"
|
|
.e EISDIR,"EISDIR[Is a directory]"
|
|
.e EPROTONOSUPPORT,"EPROTONOSUPPORT[Protocol not supported]"
|
|
.e EROFS,"EROFS[Read-only file system]"
|
|
.e EADDRNOTAVAIL,"EADDRNOTAVAIL[Cannot assign requested address]"
|
|
.e EIDRM,"EIDRM[Identifier removed]"
|
|
.e ECOMM,"ECOMM[Communication error on send]"
|
|
.e ESRMNT,"ESRMNT[Srmount error]"
|
|
.e EREMOTEIO,"EREMOTEIO[Remote I/O error]"
|
|
.e EL3RST,"EL3RST[Level 3 reset]"
|
|
.e EBADMSG,"EBADMSG[Not a data message]"
|
|
.e ENFILE,"ENFILE[File table overflow]"
|
|
.e ELIBMAX,"ELIBMAX[Attempting to link in too many shared libraries]"
|
|
.e ESPIPE,"ESPIPE[Illegal seek]"
|
|
.e ENOLINK,"ENOLINK[Link has been severed]"
|
|
.e ENETRESET,"ENETRESET[Network dropped connection because of reset]"
|
|
.e ETIMEDOUT,"ETIMEDOUT[Connection timed out]"
|
|
.e ENOENT,"ENOENT[No such file or directory]"
|
|
.e EEXIST,"EEXIST[File exists]"
|
|
.e EDQUOT,"EDQUOT[Quota exceeded]"
|
|
.e ENOSTR,"ENOSTR[Device not a stream]"
|
|
.e EBADSLT,"EBADSLT[Invalid slot]"
|
|
.e EBADRQC,"EBADRQC[Invalid request code]"
|
|
.e ELIBACC,"ELIBACC[Can not access a needed shared library]"
|
|
.e EFAULT,"EFAULT[Bad address]"
|
|
.e EFBIG,"EFBIG[File too large]"
|
|
.e EDEADLK,"EDEADLK[Resource deadlock would occur]"
|
|
.e ENOTCONN,"ENOTCONN[Transport endpoint is not connected]"
|
|
.e EDESTADDRREQ,"EDESTADDRREQ[Destination address required]"
|
|
.e ELIBSCN,"ELIBSCN[.lib section in a.out corrupted]"
|
|
.e ENOLCK,"ENOLCK[No record locks available]"
|
|
.e EISNAM,"EISNAM[Is a named type file]"
|
|
.e ECONNABORTED,"ECONNABORTED[Software caused connection abort]"
|
|
.e ENETUNREACH,"ENETUNREACH[Network is unreachable]"
|
|
.e ESTALE,"ESTALE[Stale NFS file handle]"
|
|
.e ENOSR,"ENOSR[Out of streams resources]"
|
|
.e ENOMEM,"ENOMEM[Out of memory]"
|
|
.e ENOTSOCK,"ENOTSOCK[Socket operation on non-socket]"
|
|
.e ESTRPIPE,"ESTRPIPE[Streams pipe error]"
|
|
.e EMLINK,"EMLINK[Too many links]"
|
|
.e ERANGE,"ERANGE[Math result not representable]"
|
|
.e ELIBEXEC,"ELIBEXEC[Cannot exec a shared library directly]"
|
|
.e EL3HLT,"EL3HLT[Level 3 halted]"
|
|
.e ECONNRESET,"ECONNRESET[Connection reset by peer]"
|
|
.e EADDRINUSE,"EADDRINUSE[Address already in use]"
|
|
.e EOPNOTSUPP,"EOPNOTSUPP[Operation not supported on transport endpoint]"
|
|
.e EREMCHG,"EREMCHG[Remote address changed]"
|
|
.e EAGAIN,"EAGAIN[Try again]"
|
|
.e ENAMETOOLONG,"ENAMETOOLONG[File name too long]"
|
|
.e ENOTTY,"ENOTTY[Not a typewriter]"
|
|
.e ERESTART,"ERESTART[Interrupted system call should be restarted]"
|
|
.e ESOCKTNOSUPPORT,"ESOCKTNOSUPPORT[Socket type not supported]"
|
|
.e ETIME,"ETIME[Timer expired]"
|
|
.e ETOOMANYREFS,"ETOOMANYREFS[Too many references: cannot splice]"
|
|
.e EMFILE,"EMFILE[Too many open files]"
|
|
.e ETXTBSY,"ETXTBSY[Text file busy]"
|
|
.e EINPROGRESS,"EINPROGRESS[Operation now in progress]"
|
|
.e ENXIO,"ENXIO[No such device or address]"
|
|
.e ENOTSUP,"ENOTSUP[Operation not supported]"
|
|
.e EPROTO,"EPROTO[Protocol error]"
|
|
.e ENOMSG,"ENOMSG[No message of desired type]"
|
|
.e ENODATA,"ENODATA[No data available]"
|
|
.e EOVERFLOW,"EOVERFLOW[Value too large for defined data type]"
|
|
.e ENOMEDIUM,"ENOMEDIUM[No medium found]"
|
|
.e EMEDIUMTYPE,"EMEDIUMTYPE[Wrong medium type]"
|
|
.e ECANCELED,"ECANCELED[Operation Canceled]"
|
|
.e EOWNERDEAD,"EOWNERDEAD[Owner died]"
|
|
.e ENOTRECOVERABLE,"ENOTRECOVERABLE[State not recoverable]"
|
|
.e EOWNERDEAD,"EOWNERDEAD[Process died with the lock]"
|
|
.e ENOTRECOVERABLE,"ENOTRECOVERABLE[Lock is not recoverable]"
|
|
.e EFTYPE,"EFTYPE[Inappropriate file type or format]"
|
|
.e EAUTH,"EAUTH[Authentication error]"
|
|
.e EBADRPC,"EBADRPC[RPC struct is bad]"
|
|
.e ENEEDAUTH,"ENEEDAUTH[Need authenticator]"
|
|
.e ENOATTR,"ENOATTR[Attribute not found]"
|
|
.e EPROCUNAVAIL,"EPROCUNAVAIL[Bad procedure for program]"
|
|
.e EPROGMISMATCH,"EPROGMISMATCH[Program version wrong]"
|
|
.e EPROGUNAVAIL,"EPROGUNAVAIL[RPC prog. not avail]"
|
|
.e ERPCMISMATCH,"ERPCMISMATCH[RPC version wrong]"
|
|
.e EPROCLIM,"EPROCLIM[Too many processes]"
|
|
.e EBADARCH,"EBADARCH[Bad CPU type in executable]"
|
|
.e EBADEXEC,"EBADEXEC[Bad executable (or shared library)]"
|
|
.e EBADMACHO,"EBADMACHO[Malformed Mach-o file]"
|
|
.e EDEVERR,"EDEVERR[Device error]"
|
|
.e ENOPOLICY,"ENOPOLICY[Policy not found]"
|
|
.e EPWROFF,"EPWROFF[Device power is off]"
|
|
.e ESHLIBVERS,"ESHLIBVERS[Shared library version mismatch]"
|
|
.e ENOANO,"ENOANO[No anode]"
|
|
.e EADV,"EADV[Advertise error]"
|
|
.e EL2HLT,"EL2HLT[Level 2 halted]"
|
|
.e EDOTDOT,"EDOTDOT[RFS specific error]"
|
|
.e ENOPKG,"ENOPKG[Package not installed]"
|
|
.e EBADR,"EBADR[Invalid request descriptor]"
|
|
.e ENOCSI,"ENOCSI[No CSI structure available]"
|
|
.e ENOKEY,"ENOKEY[Required key not available]"
|
|
.e EUCLEAN,"EUCLEAN[Structure needs cleaning]"
|
|
.e ECHRNG,"ECHRNG[Channel number out of range]"
|
|
.e EL2NSYNC,"EL2NSYNC[Level 2 not synchronized]"
|
|
.e EKEYEXPIRED,"EKEYEXPIRED[Key has expired]"
|
|
.e ENAVAIL,"ENAVAIL[No XENIX semaphores available]"
|
|
.e EKEYREVOKED,"EKEYREVOKED[Key has been revoked]"
|
|
.e ELIBBAD,"ELIBBAD[Accessing a corrupted shared library]"
|
|
.e EKEYREJECTED,"EKEYREJECTED[Key was rejected by service]"
|
|
.e ERFKILL,"ERFKILL[Operation not possible due to RF-kill]"
|
|
.long 0
|
|
.endobj kErrorNamesLong,globl,hidden
|