Skip to content

Releases: jart/cosmopolitan

Cosmopolitan v3.7.0

16 Aug 15:09
de0cde8
Compare
Choose a tag to compare

Cosmopolitan Libc makes C a build-once run-anywhere language, like Java, except it doesn't need an interpreter or virtual machine. Instead, it reconfigures stock GCC and Clang to output a POSIX-approved polyglot format that runs natively on Linux + Mac + Windows + FreeBSD + OpenBSD + NetBSD + BIOS with the best possible performance and the tiniest footprint imaginable. For further details, read Cosmopolitan Third Edition, the Cosmo README, and the Cosmopolitan Toolchain README. Prebuilt software is available on https://cosmo.zip/

Improvements

Your malloc() function is now more scalable on Linux Aarch64 and other
platforms, where it previously was not working as well as advertised.

  • 0a79c69 Make malloc scalable on all platforms

Cosmopolitan Bash now works better on Windows. For example, if you start
a process that redirects stderr to a file, then your entire process tree
will now be able to cooperatively write to that file. When you update it
is recommended that you upgrade all your cosmos binaries at once.

  • 3f26dfb Share file offset across execve() on Windows
  • 761c6ad Share file offset across processes

Improvements have been made to cosmocc and libcxx which made it possible
for us to compile Clang as an APE binary.

  • 77d3a07 Fix std::filesystem
  • 0d7c272 Don't use sendfile() in libcxx
  • 18964e5 Fix remove() directory on Windows
  • 6ac3d3b Add precompiled header support to cosmocc
  • f8cfc89 Allow -c to be specified with -E in cosmocc
  • 01b09bc Support printf %n directive
  • 3dab207 Remove mkfifo() prototype
  • d0360bf Introduce cosmoranlib

Some upstream dependencies have been updated. In particular, Musl locale
handling is more true to the way it works upstream. You may need to have
setlocale(LC_ALL, "C.UTF-8") in your main() function for certain POSIX
functions to work the same way they did previously by default.

  • bb815ea Update Musl Libc code
  • ff1a0d1 Upgrade to superconfigure z0.0.51
  • 3fd275f Import optimized routines changes to exp10
  • d40acc6 Detect more x86 features

Additional Changes

  • a80ab3f Implement bf16 compiler runtime library
  • 8d8aecb Avoid legacy instruction penalties on x86
  • 24666e1 Add nightly cosmocc (artifact) builds (#1254)
  • 3119416 Remove .internal from more header filenames
  • 7499367 Ignore -Wimplicit-function-declaration in cosmocc
  • 9ebacb7 Convert GCC 14 errors back to warnings (#1247)
  • e18fe1e Freshen build/bootstrap/cocmd
  • cf1559c Remove __threaded variable

Cosmopolitan v3.6.2

28 Jul 03:43
8621034
Compare
Choose a tag to compare

Your cosmocc toolchain is now able to produce tinier binaries. For small
programs, passing -mtiny can cut binary size in half. In fact oftentimes
our fat binaries end up being half the size of statically linked
linux-only executables that use glibc. You can also pass -mdbg to link a
debug version of the cosmopolitan runtime.

  • 642e9cb Introduce cosmocc flags -mdbg -mtiny -moptlinux

Your cosmocc toolchain, which was recently built with GCC 14.1, is now
itself being compiled with GCC 14.1. We've also enabled the -fanalyzer
flag, which has been helping us find bugs.

Your fork() function will now go much faster when it's used by many
threads at once.

  • cdfcee5 Properly serialize fork() operations

Some additional improvements:

  • 59692b0 Make spinlocks faster
  • 18a620c Make some improvements of little consequence
  • 690d3df Expand the virtual address space on Windows
  • edd5e2c Expose gethostbyname()
  • a31d5ea Remove cosmoc++ compiler warning

Cosmopolitan v3.6.1

25 Jul 21:12
7d88343
Compare
Choose a tag to compare
  • f25fbba Use libcxx abi v1
  • d3a13e8 Improve lock hierarchy
  • fbc4b03 Restore support for AMD K8
  • 2c4b887 Add special errno handling to libcxx
  • 3915ca0 Have cosmocc define -Wno-implicit-int
  • 5dd7ddb Remove bad defines from early days of project
  • e398f38 Make more improvements to threads and mappings
  • 7ba9a73 Remove more _Atomic keywords from public headers
  • 1020dd4 bzero() should be defined without special defines

Cosmopolitan v3.6.0

23 Jul 10:35
5660ec4
Compare
Choose a tag to compare
  • This release performs an atomic upgrade to GCC 14.1.0. It features N-bit integer types.
  • This release upgrades libcxx to the latest code at HEAD from the LLVM project.
  • The mono repo now uses GNU C23 and C++23.

Cosmopolitan v3.5.9

23 Jul 04:14
62ace36
Compare
Choose a tag to compare

Cosmopolitan v3.5.8

22 Jul 00:19
e08a4cd
Compare
Choose a tag to compare
  • 30afd6d Improve multithreading
  • 7ebaff3 Fix ctype.h and wctype.h
  • d316712 Fix regression with last commit
  • e7be5a5 Upgrade to latest superconfigure
  • 29ce25c Start writing formal specification for APE

Cosmopolitan v3.5.7

20 Jul 10:58
7996bf6
Compare
Choose a tag to compare
  • 626a5d0 Add missing lock statement
  • 527aaa4 Prevent MODE=tiny ShowCrashReports() looping

Cosmopolitan v3.5.6

20 Jul 10:03
3374cbb
Compare
Choose a tag to compare
  • 2018cac Use better memory strategy on Windows
  • 6a5d4ed Fix issue with disabling sigaltstack()

Cosmopolitan v3.5.5

20 Jul 05:49
493ffc9
Compare
Choose a tag to compare

This release perfects the new memory manager. The impact of the mmap()
rewrite (introduced by Cosmo v3.5.0) is that LLaMAfiler's tokenization
endpoint was previously handling 2 million requests per second and now
it's handling 3.3 million per second.

  • 8c645fa Make mmap() scalable
  • 3756870 Implement new red-black tree
  • 1ff037d Add some mmap() documentation
  • f7780de Make realloc() go 100x faster on Linux/NetBSD
  • 76cea6c Squeeze more performance out of memory manager
  • fdab49b Demonstrate signal safety of recursive mutexes
  • 01587de Simplify memory manager

A few disruptive changes slipped in, but they're necessary. Aside from
the changes listed below, please note that you might need to update your
code to use sysconf(_SC_GRANSIZE) instead of sysconf(_SC_PAGESIZE)
when the alignment of the addr or offset parameters to mmap() is
the thing you care about.

  • 1029dcc Reduce default stack size from 256kb to 81kb
  • 86d884c Get rid of .internal.h convention in LIBC_INTRIN
  • fc65422 Remove __mmap() and __munmap()

Other changes:

  • 3f2a1b6 Fix greenbean example
  • 0ed916a Fix a bug in example code
  • 5a9a08d Fix regression in elf2pe program
  • c697133 Fix typo in accept4-sysv.c (#1235)
  • 15ea052 Reduce code size of mandatory runtime
  • 6dbc3fb Add AMD cache sizes to o//tool/viz/cpuid
  • bd6d9ff Get deathstar demo working again on metal
  • 135d538 Make ctl::set use 30% less memory than libcxx

Cosmopolitan v3.5.4

01 Jul 14:35
70f77aa
Compare
Choose a tag to compare