Andrew Kelley
5258c3caad
std: add type safety to cc_t
2024-02-12 15:41:38 -07:00
Andrew Kelley
7680c5330c
some API work on std.c, std.os, std.os.wasi
...
* std.c: consolidate some definitions, making them share code. For
example, freebsd, dragonfly, and openbsd can all share the same
`pthread_mutex_t` definition.
* add type safety to std.c.O
- this caught a bug where mode flags were incorrectly passed as the
open flags.
* 3 fewer uses of usingnamespace keyword
* as per convention, remove purposeless field prefixes from struct field
names even if they have those prefixes in the corresponding C code.
* fix incorrect wasi libc Stat definition
* remove C definitions from incorrectly being in std.os.wasi
* make std.os.wasi definitions type safe
* go through wasi native APIs even when linking libc because the libc
APIs are problematic and wasteful
* don't expose WASI definitions in std.posix
* remove std.os.wasi.rights_t.ALL: this is a footgun. should it be all
future rights too? or only all current rights known? both are
the wrong answer.
2024-02-11 13:38:55 -07:00
Andrew Kelley
a60f219660
std.c.MAP: use a packed struct
...
Same as previous commit, but for the libc interface.
2024-02-06 22:06:01 -07:00
Veikka Tuominen
74010fecc7
translate-c: use Aro's tokenizer
2023-11-25 12:28:19 +02:00
Andrew Kelley
7733894761
Merge pull request #17341 from rzezeski/illumos-updates
...
Illumos/Solaris updates
2023-10-03 11:04:41 -07:00
xdBronch
c9c3ee704c
correctly detect apple a15 and a16 chips
2023-10-03 00:36:59 -07:00
Ryan Zezeski
c17ebdca6a
solaris: fix path component max
2023-09-30 11:38:56 -06:00
Ryan Zezeski
f0724229d6
solaris: add missing registers
2023-09-30 11:38:56 -06:00
Aven Bross
6c54ed73f7
Added basic support for wasm32-emscripten target
2023-09-22 12:49:03 -07:00
Linus Groh
c097209792
std.c.linux: Add getpw{nam,uid}()
2023-09-08 21:46:05 +03:00
Michael Dusan
e1216686f3
dragonfly: std.c: more decls
...
- add ucontext_t, mcontext_t
- add pthread_rwlock_t
2023-08-15 17:29:35 -04:00
Michael Dusan
4532ff2780
netbsd: std.c: fix pthread_rwlock_t
...
- make .owner field optional
2023-08-15 17:29:35 -04:00
Michael Dusan
25542c3443
netbsd: std.c.REG: populate indexes for x86_64
2023-08-15 17:20:04 -04:00
Andrew Kelley
04d5e07d40
std.c.openbsd: remove "msg_" prefixes from structs
...
Reapplies 8f14431bc8 which was reverted in
95e2605d30 .
2023-07-31 11:57:48 -07:00
Andrew Kelley
479fd2f721
std.c.openbsd: add PTHREAD_STACK_MIN
...
@semarie audited this definition.
2023-07-31 11:54:27 -07:00
Andrew Kelley
b1bde35651
std.c.openbsd: add ucontext_t for aarch64
...
Reapplies 1585ed637d which was reverted in
f3adbe249b .
I removed use of `usingnamespace` in this commit.
@semarie audited this struct definition.
2023-07-31 11:51:08 -07:00
Andrew Kelley
235b9fc28a
Revert "std: add FreeBSD's procctl api."
...
This reverts commit 2e2d37917d .
2023-07-31 11:24:21 -07:00
Andrew Kelley
99c70ec24f
Revert "std: add kinfo_vmentry for FreeBSD"
...
This reverts commit 4a0508e56c .
2023-07-31 11:24:14 -07:00
Andrew Kelley
68134e56cb
Revert "std add getrandom to solato solaris based systems"
...
This reverts commit 56d800ff7e .
2023-07-31 11:24:09 -07:00
Andrew Kelley
a18a116bda
Revert "std: add shm_create_largepage for FreeBSD, completing MFD* constants."
...
This reverts commit 7b908e173f .
2023-07-31 11:24:04 -07:00
Andrew Kelley
c0ac1411db
Revert "std: freebsd update proposal"
...
This reverts commit 2568da2f41 .
2023-07-31 11:23:56 -07:00
Andrew Kelley
26777d98fe
Revert "std: adding freebsd's elf_aux_info api"
...
This reverts commit 83970b6d91 .
2023-07-31 11:23:49 -07:00
Andrew Kelley
b5df1bfcdb
Revert "os: expand sched_getaffinity wrapper and update freebsd's cpuset api flags."
...
This reverts commit dbdafb6cc5 .
2023-07-31 11:23:38 -07:00
Andrew Kelley
14353590f2
Revert "std: adding netbsd's pthread to cpu affinity api"
...
This reverts commit 3f259d3550 .
2023-07-31 11:23:33 -07:00
Andrew Kelley
a2439e161b
Revert "std: enriching malloc api on freebsd."
...
This reverts commit 9140249d29 .
2023-07-31 11:21:50 -07:00
Andrew Kelley
c7f2a7ea82
Revert "std: add a subset of the macOs's libproc api."
...
This reverts commit 7b0e015eb4 .
2023-07-31 11:20:57 -07:00
Andrew Kelley
aa5808c26c
Revert "std: add accept_filter struct to make use of SO_ACCEPTFILTER socket option"
...
This reverts commit 1d322fe510 .
2023-07-31 11:20:53 -07:00
Andrew Kelley
62deaaacd5
Revert "std: mcontext layout for x86 and fixing few x86_64 fields types for"
...
This reverts commit 9691cded95 .
2023-07-31 11:20:49 -07:00
Andrew Kelley
963b2a2a4d
Revert "std: adding FreeBSD's sched wrappers"
...
This reverts commit 9ef615104a .
2023-07-31 11:20:44 -07:00
Andrew Kelley
5f101b253e
Revert "std: adding sigevent to supported platforms."
...
This reverts commit 23c4f55a61 .
2023-07-31 11:20:39 -07:00
Andrew Kelley
c6ec217e23
Revert "std.c: add find_path for haiku"
...
This reverts commit 1084590ec4 .
2023-07-31 11:18:19 -07:00
Andrew Kelley
ddd7b0ea9e
Revert "std.c: adding mincore for freebsd"
...
This reverts commit 8d88dcdc61 .
2023-07-31 11:18:07 -07:00
Andrew Kelley
1f9161a9c6
Revert "std.c: add mincore api to darwin."
...
This reverts commit 05f9608115 .
2023-07-31 11:17:57 -07:00
Andrew Kelley
c9de5304ab
Revert "std.c:complete further more netbsd's mmap flags"
...
This reverts commit 4f248e1b51 .
2023-07-31 11:17:25 -07:00
Andrew Kelley
70a7210e92
Revert "std.c: freebsd add procctl exclusive x86_64 flags"
...
This reverts commit 3fb93fc8f2 .
2023-07-31 11:17:20 -07:00
Andrew Kelley
1d4e6e6c73
Revert "std.c: add essential freebsd's capsicum api subset."
...
This reverts commit 6ae19fa48d .
2023-07-31 11:17:11 -07:00
Andrew Kelley
f96f57930c
Revert "std.c: adding freebsd's CPU_COUNT macro portage."
...
This reverts commit b9841750f9 .
2023-07-31 11:14:03 -07:00
Andrew Kelley
a397952932
Revert "std.c: add os_proc_available_memory for darwin"
...
This reverts commit 012f9a97eb .
2023-07-31 11:13:40 -07:00
Andrew Kelley
a92be49851
Revert "Merge pull request #15317 from devnexen/darwin_rand_nativegen"
...
This reverts commit a111130977 , reversing
changes made to 9f3f9fb40f .
2023-07-31 11:13:27 -07:00
Andrew Kelley
421022929a
Revert "std.c: adding cpu affinity api for macOs (mainly x86_64)"
...
This reverts commit 4bfd37ddb4 .
2023-07-31 11:12:19 -07:00
Andrew Kelley
614ae886db
Revert "std.c: darwin add host_info based data."
...
This reverts commit ff59c45840 .
2023-07-31 11:11:05 -07:00
Andrew Kelley
afca695b64
Revert "std.c: adding freebsd's kinfo_proc type."
...
This reverts commit 3dd0afe787 .
2023-07-31 11:10:56 -07:00
Andrew Kelley
f3adbe249b
Revert "std.c: openbsd sigcontext/ucontext for arm64."
...
This reverts commit 1585ed637d .
2023-07-31 11:10:40 -07:00
Andrew Kelley
8c7eb8c8da
Revert "std.c: adding freebsd's domainset api"
...
This reverts commit e8f76b452b .
2023-07-31 11:09:34 -07:00
Andrew Kelley
5d345b69ea
Revert "std.fs: selfExePath haiku using constants instead"
...
This reverts commit e21739dd8c .
2023-07-31 11:09:28 -07:00
Andrew Kelley
a048ddaf91
Revert "std.c: adding freebsd's domainset_t bitset"
...
This reverts commit 10a7cf58c1 .
2023-07-31 11:09:16 -07:00
Andrew Kelley
ac7be71d8e
Revert "std.c: add freebsd's kinfo_vmobject"
...
This reverts commit 5260657230 .
2023-07-31 11:05:38 -07:00
Andrew Kelley
6d7c6f4da7
Revert "std.c: adding freebsd's ioctl base operands."
...
This reverts commit cd7e2bf57a .
2023-07-31 11:05:21 -07:00
Andrew Kelley
f3fa47a984
Revert "std.c: darwin adding more host_info api data"
...
This reverts commit 20cc69318f .
2023-07-31 11:04:37 -07:00
Andrew Kelley
942848de58
Revert "std.c: adding basic darwin's host_statistics data."
...
This reverts commit 6547d23312 .
2023-07-31 11:04:04 -07:00