[libc-commits] [libc] [libc] added rest of yaml files for new headergen (PR #96977)

via libc-commits libc-commits at lists.llvm.org
Thu Jun 27 15:10:39 PDT 2024


https://github.com/RoseZhang03 created https://github.com/llvm/llvm-project/pull/96977

Added yaml files containing functions from only one standard.
Also added one combined standard yaml file (errno.yaml).
assert.yaml is still work in progress.

>From bb3eb3d262a9d3b0cd332fd96d0f40fb79bb9231 Mon Sep 17 00:00:00 2001
From: Rose Zhang <rosezhang at google.com>
Date: Thu, 27 Jun 2024 22:08:47 +0000
Subject: [PATCH] [libc] added rest of yaml files for new headergen

Added yaml files containing functions from only one standard.
Also added one combined standard yaml file (errno.yaml).
assert.yaml is still work in progress.
---
 libc/newhdrgen/yaml/gnu_ext_sys_sendfile.yaml |  18 +
 libc/newhdrgen/yaml/gnu_sys_auxv.yaml         |   8 +
 libc/newhdrgen/yaml/gpu_ext_rpc.yaml          |  27 +
 libc/newhdrgen/yaml/linux_sys_epoll.yaml      |  72 +++
 libc/newhdrgen/yaml/linux_sys_prctl.yaml      |   7 +
 libc/newhdrgen/yaml/linux_sys_random.yaml     |  18 +
 libc/newhdrgen/yaml/linux_sys_statvfs.yaml    |  23 +
 libc/newhdrgen/yaml/linux_sys_time.yaml       |   8 +
 libc/newhdrgen/yaml/posix_arpa_inet.yaml      |  41 ++
 libc/newhdrgen/yaml/posix_dirent.yaml         |  58 ++
 libc/newhdrgen/yaml/posix_fcntl.yaml          |  48 ++
 libc/newhdrgen/yaml/posix_search.yaml         |  76 +++
 libc/newhdrgen/yaml/posix_spawn.yaml          |  70 +++
 libc/newhdrgen/yaml/posix_sys_ioctl.yaml      |   7 +
 libc/newhdrgen/yaml/posix_sys_resource.yaml   |  24 +
 libc/newhdrgen/yaml/posix_sys_select.yaml     |  24 +
 libc/newhdrgen/yaml/posix_sys_socket.yaml     |  30 +
 libc/newhdrgen/yaml/posix_sys_stat.yaml       |  93 ++++
 libc/newhdrgen/yaml/posix_sys_types.yaml      |  30 +
 libc/newhdrgen/yaml/posix_sys_utsname.yaml    |  15 +
 libc/newhdrgen/yaml/posix_termios.yaml        | 107 ++++
 libc/newhdrgen/yaml/posix_unistd.yaml         | 414 ++++++++++++++
 libc/newhdrgen/yaml/stdc_float.yaml           |   8 +
 libc/newhdrgen/yaml/stdc_inttypes.yaml        |  44 ++
 libc/newhdrgen/yaml/stdc_limits.yaml          |   8 +
 libc/newhdrgen/yaml/stdc_setjmp.yaml          |  20 +
 libc/newhdrgen/yaml/stdc_stdbit.yaml          | 526 ++++++++++++++++++
 libc/newhdrgen/yaml/stdc_stdckdint.yaml       |   8 +
 libc/newhdrgen/yaml/stdc_stdint.yaml          |   8 +
 libc/newhdrgen/yaml/stdc_threads.yaml         | 184 ++++++
 libc/newhdrgen/yaml/stdc_uchar.yaml           |  12 +
 libc/newhdrgen/yaml/stdc_wchar.yaml           |  17 +
 libc/newhdrgen/yaml_combined/errno.yaml       |  10 +
 33 files changed, 2063 insertions(+)
 create mode 100644 libc/newhdrgen/yaml/gnu_ext_sys_sendfile.yaml
 create mode 100644 libc/newhdrgen/yaml/gnu_sys_auxv.yaml
 create mode 100644 libc/newhdrgen/yaml/gpu_ext_rpc.yaml
 create mode 100644 libc/newhdrgen/yaml/linux_sys_epoll.yaml
 create mode 100644 libc/newhdrgen/yaml/linux_sys_prctl.yaml
 create mode 100644 libc/newhdrgen/yaml/linux_sys_random.yaml
 create mode 100644 libc/newhdrgen/yaml/linux_sys_statvfs.yaml
 create mode 100644 libc/newhdrgen/yaml/linux_sys_time.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_arpa_inet.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_dirent.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_fcntl.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_search.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_spawn.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_sys_ioctl.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_sys_resource.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_sys_select.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_sys_socket.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_sys_stat.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_sys_types.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_sys_utsname.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_termios.yaml
 create mode 100644 libc/newhdrgen/yaml/posix_unistd.yaml
 create mode 100644 libc/newhdrgen/yaml/stdc_float.yaml
 create mode 100644 libc/newhdrgen/yaml/stdc_inttypes.yaml
 create mode 100644 libc/newhdrgen/yaml/stdc_limits.yaml
 create mode 100644 libc/newhdrgen/yaml/stdc_setjmp.yaml
 create mode 100644 libc/newhdrgen/yaml/stdc_stdbit.yaml
 create mode 100644 libc/newhdrgen/yaml/stdc_stdckdint.yaml
 create mode 100644 libc/newhdrgen/yaml/stdc_stdint.yaml
 create mode 100644 libc/newhdrgen/yaml/stdc_threads.yaml
 create mode 100644 libc/newhdrgen/yaml/stdc_uchar.yaml
 create mode 100644 libc/newhdrgen/yaml/stdc_wchar.yaml
 create mode 100644 libc/newhdrgen/yaml_combined/errno.yaml

diff --git a/libc/newhdrgen/yaml/gnu_ext_sys_sendfile.yaml b/libc/newhdrgen/yaml/gnu_ext_sys_sendfile.yaml
new file mode 100644
index 0000000000000..8743bf01b99ba
--- /dev/null
+++ b/libc/newhdrgen/yaml/gnu_ext_sys_sendfile.yaml
@@ -0,0 +1,18 @@
+header: sys-sendfile.h
+macros: []
+types:
+  - type_name: ssize_t
+  - type_name: size_t
+  - type_name: off_t
+enums: []
+objects: []
+functions: 
+  - name: sendfile
+    standards: 
+      - GNUExtensions
+    return_type: ssize_t
+    arguments: 
+      - type: int 
+      - type: int 
+      - type: off_t * 
+      - type: size_t 
diff --git a/libc/newhdrgen/yaml/gnu_sys_auxv.yaml b/libc/newhdrgen/yaml/gnu_sys_auxv.yaml
new file mode 100644
index 0000000000000..beea1d8b5f09f
--- /dev/null
+++ b/libc/newhdrgen/yaml/gnu_sys_auxv.yaml
@@ -0,0 +1,8 @@
+header: sys-auxv.h
+standards: 
+  - GNUExtensions
+macros: []
+types: []
+enums: []
+objects: []
+functions: []
diff --git a/libc/newhdrgen/yaml/gpu_ext_rpc.yaml b/libc/newhdrgen/yaml/gpu_ext_rpc.yaml
new file mode 100644
index 0000000000000..3a9348ba5a395
--- /dev/null
+++ b/libc/newhdrgen/yaml/gpu_ext_rpc.yaml
@@ -0,0 +1,27 @@
+header: gpu-rpc.h
+macros: []
+types: []
+enums: []
+objects: []
+functions:
+  - name: rpc_host_call
+    standards: 
+      - GPUExtensions
+    return_type: void
+    arguments:
+      - type: void *
+      - type: void *
+      - type: size_t
+    guard: null
+    attributes: []
+  - name: rpc_fprintf
+    standards: 
+      - GPUExtensions
+    return_type: int
+    arguments:
+      - type: ::FILE *__restrict
+      - type: const char *__restrict
+      - type: void *
+      - type: size_t
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/linux_sys_epoll.yaml b/libc/newhdrgen/yaml/linux_sys_epoll.yaml
new file mode 100644
index 0000000000000..f9d2a7c8b0830
--- /dev/null
+++ b/libc/newhdrgen/yaml/linux_sys_epoll.yaml
@@ -0,0 +1,72 @@
+header: sys-epoll.h
+macros: []
+types:
+  - type_name: struct_epoll_event
+  - type_name: struct_epoll_data
+  - type_name: sigset_t
+  - type_name: struct_timespec
+enums: []
+objects: []
+functions:
+  - name: epoll_create
+    standards: 
+      - Linux
+    return_type: int
+    arguments:
+      - type: int
+    guard: null
+    attributes: []
+  - name: epoll_create1
+    standards: 
+      - Linux
+    return_type: int
+    arguments:
+      - type: int
+    guard: null
+    attributes: []
+  - name: epoll_ctl
+    standards: 
+      - Linux
+    return_type: int
+    arguments:
+      - type: int
+      - type: int
+      - type: int
+      - type: struct epoll_event *
+    guard: null
+    attributes: []
+  - name: epoll_wait
+    standards: 
+      - Linux
+    return_type: int
+    arguments:
+      - type: int
+      - type: struct epoll_event *
+      - type: int
+      - type: int
+    guard: null
+    attributes: []
+  - name: epoll_pwait
+    standards: 
+      - Linux
+    return_type: int
+    arguments:
+      - type: int
+      - type: struct epoll_event *
+      - type: int
+      - type: int
+      - type: const sigset_t *
+    guard: null
+    attributes: []
+  - name: epoll_pwait2
+    standards: 
+      - Linux
+    return_type: int
+    arguments:
+      - type: int
+      - type: struct epoll_event *
+      - type: int
+      - type: const struct timespec *
+      - type: const sigset_t *
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/linux_sys_prctl.yaml b/libc/newhdrgen/yaml/linux_sys_prctl.yaml
new file mode 100644
index 0000000000000..35289f6274e7a
--- /dev/null
+++ b/libc/newhdrgen/yaml/linux_sys_prctl.yaml
@@ -0,0 +1,7 @@
+header: sys-prctl.h
+standards: Linux
+macros: []
+types: []
+enums: []
+objects: []
+functions: []
diff --git a/libc/newhdrgen/yaml/linux_sys_random.yaml b/libc/newhdrgen/yaml/linux_sys_random.yaml
new file mode 100644
index 0000000000000..3aaae2dda6cf4
--- /dev/null
+++ b/libc/newhdrgen/yaml/linux_sys_random.yaml
@@ -0,0 +1,18 @@
+header: sys-random.h
+macros: []
+types:
+  - type_name: ssize_t
+  - type_name: size_t
+enums: []
+objects:
+functions:
+  - name: getrandom
+    standards: 
+      - Linux
+    return_type: ssize_t
+    arguments:
+      - type: void *
+      - type: size_t
+      - type: unsigned int
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/linux_sys_statvfs.yaml b/libc/newhdrgen/yaml/linux_sys_statvfs.yaml
new file mode 100644
index 0000000000000..8d0004beef690
--- /dev/null
+++ b/libc/newhdrgen/yaml/linux_sys_statvfs.yaml
@@ -0,0 +1,23 @@
+header: sys-statvfs.h
+macros: []
+types:
+  - type_name: struct_statvfs
+enums: []
+objects: []
+functions:
+  - name: statvfs
+    standards: 
+      - Linux
+    return_type: int
+    arguments:
+      - type: const char *__restrict
+      - type: struct statvfs *__restrict
+    guard: null
+    attributes: []
+  - name: fstatvfs
+    standards: 
+      - Linux
+    return_type: int
+    arguments: 
+      - type: int
+      - type: struct statvfs *
diff --git a/libc/newhdrgen/yaml/linux_sys_time.yaml b/libc/newhdrgen/yaml/linux_sys_time.yaml
new file mode 100644
index 0000000000000..a901cdafd26a1
--- /dev/null
+++ b/libc/newhdrgen/yaml/linux_sys_time.yaml
@@ -0,0 +1,8 @@
+header: sys-time.h
+standards: Linux
+macros: []
+types:
+  - type_name: struct_timeval
+enums: []
+functions: []
+objects: []
diff --git a/libc/newhdrgen/yaml/posix_arpa_inet.yaml b/libc/newhdrgen/yaml/posix_arpa_inet.yaml
new file mode 100644
index 0000000000000..ae4bf1be47e82
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_arpa_inet.yaml
@@ -0,0 +1,41 @@
+header: arpa-inet.h
+macros: []
+types:
+  - type_name: uint32_t
+  - type_name: uint16_t
+  - type_name: inttypes.h
+enums: []
+objects: []
+functions:
+  - name: htonl
+    standards: 
+      - POSIX
+    return_type: uint32_t
+    arguments:
+      - type: uint32_t
+    guard: null
+    attributes: []
+  - name: htons
+    standards: 
+      - POSIX
+    return_type: uint16_t
+    arguments:
+      - type: uint16_t
+    guard: null
+    attributes: []
+  - name: ntohl
+    standards: 
+      - POSIX
+    return_type: uint32_t
+    arguments:
+      - type: uint32_t
+    guard: null
+    attributes: []
+  - name: ntohs
+    standards: 
+      - POSIX
+    return_type: uint16_t
+    arguments:
+      - type: uint16_t
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/posix_dirent.yaml b/libc/newhdrgen/yaml/posix_dirent.yaml
new file mode 100644
index 0000000000000..3665a8847b6be
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_dirent.yaml
@@ -0,0 +1,58 @@
+header: dirent.h
+macros: []
+types:
+  - type_name: struct_dirent
+  - type_name: DIR
+  - type_name: ino_t
+enums: []
+objects: []
+functions:
+  - name: alphasort
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const struct dirent **
+      - type: const struct dirent **
+    guard: null
+    attributes: []
+  - name: closedir
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: DIR *
+    guard: null
+    attributes: []
+  - name: dirfd
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: DIR *
+    guard: null
+    attributes: []
+  - name: fdopendir
+    standards: 
+      - POSIX
+    return_type: DIR *
+    arguments:
+      - type: int
+    guard: null
+    attributes: []
+  - name: opendir
+    standards: 
+      - POSIX
+    return_type: DIR *
+    arguments:
+      - type: const char *
+    guard: null
+    attributes: []
+  - name: readdir
+    standards: 
+      - POSIX
+    return_type: struct dirent *
+    arguments:
+      - type: DIR *
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/posix_fcntl.yaml b/libc/newhdrgen/yaml/posix_fcntl.yaml
new file mode 100644
index 0000000000000..1ef92e7fa2882
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_fcntl.yaml
@@ -0,0 +1,48 @@
+header: fcntl.h
+macros: []
+types: 
+  - type_name: off_t
+  - type_name: mode_t
+enums: []
+objects: []
+functions:
+  - name: creat
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+      - type: mode_t
+    guard: null
+    attributes: []
+  - name: fcntl
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: int
+      - type: ...
+    guard: null
+    attributes: []
+  - name: open
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+      - type: int
+      - type: ...
+    guard: null
+    attributes: []
+  - name: openat
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: const char *
+      - type: int
+      - type: ...
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/posix_search.yaml b/libc/newhdrgen/yaml/posix_search.yaml
new file mode 100644
index 0000000000000..ac890b1577d8f
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_search.yaml
@@ -0,0 +1,76 @@
+header: search.h
+macros: []
+types:
+  - type_name: size_t
+  - type_name: struct_hsearch_data
+  - type_name: ENTRY
+  - type_name: ACTION
+enums: []
+objects: []
+functions:
+  - name: hcreate
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: size_t
+    guard: null
+    attributes: []
+  - name: hcreate_r
+    standards: GNUExtensions
+    return_type: int
+    arguments:
+      - type: size_t
+      - type: struct hsearch_data *
+    guard: null
+    attributes: []
+  - name: hsearch
+    standards: 
+      - POSIX
+    return_type: ENTRY *
+    arguments:
+      - type: ENTRY
+      - type: ACTION
+    guard: null
+    attributes: []
+  - name: hsearch_r
+    standards: GNUExtensions
+    return_type: int
+    arguments:
+      - type: ENTRY
+      - type: ACTION
+      - type: ENTRY * *
+      - type: struct hsearch_data *
+    guard: null
+    attributes: []
+  - name: hdestroy
+    standards: GNUExtensions 
+    return_type: void
+    arguments: []
+    guard: null
+    attributes: []
+  - name: hdestroy_r
+    standards: 
+      - POSIX
+    return_type: void
+    arguments:
+      - type: struct hsearch_data *
+    guard: null
+    attributes: []
+  - name: insque
+    standards: 
+      - POSIX
+    return_type: void
+    arguments:
+      - type: void *
+      - type: void *
+    guard: null
+    attributes: []
+  - name: remque
+    standards: 
+      - POSIX
+    return_type: void
+    arguments:
+      - type: void *
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/posix_spawn.yaml b/libc/newhdrgen/yaml/posix_spawn.yaml
new file mode 100644
index 0000000000000..b5394c5d230be
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_spawn.yaml
@@ -0,0 +1,70 @@
+header: spawn.h
+macros: []
+types:
+  - type_name: posix_spawn_file_actions_t
+  - type_name: posix_spawnattr_t
+  - type_name: pid_t
+  - type_name: mode_t
+enums: []
+objects: []
+functions:
+  - name: posix_spawn
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: pid_t *__restrict
+      - type: const char *__restrict
+      - type: posix_spawn_file_actions_t *
+      - type: posix_spawnattr_t *__restrict
+      - type: const char *__restrict *
+      - type: const char *__restrict *
+    guard: null
+    attributes: []
+  - name: posix_spawn_file_actions_addclose
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: posix_spawn_file_actions_t *
+      - type: int
+    guard: null
+    attributes: []
+  - name: posix_spawn_file_actions_adddup2
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: posix_spawn_file_actions_t *
+      - type: int
+      - type: int
+    guard: null
+    attributes: []
+  - name: posix_spawn_file_actions_addopen
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: posix_spawn_file_actions_t *__restrict
+      - type: int
+      - type: const char *__restrict
+      - type: int
+      - type: mode_t
+    guard: null
+    attributes: []
+  - name: posix_spawn_file_actions_destroy
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: posix_spawn_file_actions_t *
+    guard: null
+    attributes: []
+  - name: posix_spawn_file_actions_init
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: posix_spawn_file_actions_t *
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/posix_sys_ioctl.yaml b/libc/newhdrgen/yaml/posix_sys_ioctl.yaml
new file mode 100644
index 0000000000000..ffe73a84d51b9
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_sys_ioctl.yaml
@@ -0,0 +1,7 @@
+header: sys-ioctl.h
+standards: POSIX
+macros: []
+types: []
+enums: []
+objects: []
+functions: []
diff --git a/libc/newhdrgen/yaml/posix_sys_resource.yaml b/libc/newhdrgen/yaml/posix_sys_resource.yaml
new file mode 100644
index 0000000000000..56404c6e8767d
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_sys_resource.yaml
@@ -0,0 +1,24 @@
+header: sys-resource.h
+macros: []
+types:
+  - type_name: struct_rlimit
+  - type_name: rlim_t
+enums: []
+objects: []
+functions:
+  - name: getrlimit
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: struct rlimit *
+    guard: null
+    attributes: []
+  - name: setrlimit
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const struct rlimit
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/posix_sys_select.yaml b/libc/newhdrgen/yaml/posix_sys_select.yaml
new file mode 100644
index 0000000000000..2e38ac438209e
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_sys_select.yaml
@@ -0,0 +1,24 @@
+header: sys-select.h
+macros: []
+types:
+  - type_name: struct_timeval
+  - type_name: struct_timespec
+  - type_name: suseconds_t
+  - type_name: sigset_t
+  - type_name: time_t
+  - type_name: fd_set
+enums: []
+objects: []
+functions:
+  - name: select
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: fd_set *__restrict
+      - type: fd_set *__restrict
+      - type: fd_set *__restrict
+      - type: struct timeval *__restrict
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/posix_sys_socket.yaml b/libc/newhdrgen/yaml/posix_sys_socket.yaml
new file mode 100644
index 0000000000000..b9310cba77261
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_sys_socket.yaml
@@ -0,0 +1,30 @@
+header: sys-socket.h
+macros: []
+types:
+  - type_name: struct_sockaddr_un
+  - type_name: struct_sockaddr
+  - type_name: socklen_t
+  - type_name: sa_family_t
+enums: []
+objects: []
+functions:
+  - name: socket
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: int
+      - type: int
+    guard: null
+    attributes: []
+  - name: bind
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: const struct sockaddr *
+      - type: socklen_t
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/posix_sys_stat.yaml b/libc/newhdrgen/yaml/posix_sys_stat.yaml
new file mode 100644
index 0000000000000..7f90dd9c1b764
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_sys_stat.yaml
@@ -0,0 +1,93 @@
+header: sys-stat.h
+macros: []
+types:
+  - type_name: blkcnt_t
+  - type_name: blksize_t
+  - type_name: off_t
+  - type_name: struct_timeval
+  - type_name: gid_t
+  - type_name: struct_stat
+  - type_name: uid_t
+  - type_name: nlink_t
+  - type_name: dev_t
+  - type_name: struct_timespec
+  - type_name: ino_t
+  - type_name: mode_t
+enums: []
+objects: []
+functions:
+  - name: chmod
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+      - type: mode_t
+    guard: null
+    attributes: []
+  - name: fchmod
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: mode_t
+    guard: null
+    attributes: []
+  - name: fchmodat
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: const char *
+      - type: mode_t
+      - type: int
+    guard: null
+    attributes: []
+  - name: fstat
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: struct stat *
+    guard: null
+    attributes: []
+  - name: lstat
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *__restrict
+      - type: struct stat *__restrict
+    guard: null
+    attributes: []
+  - name: mkdir
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+      - type: mode_t
+    guard: null
+    attributes: []
+  - name: mkdirat
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: const char *
+      - type: mode_t
+    guard: null
+    attributes: []
+  - name: stat
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *__restrict
+      - type: struct stat *__restrict
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/posix_sys_types.yaml b/libc/newhdrgen/yaml/posix_sys_types.yaml
new file mode 100644
index 0000000000000..6b08254a7fab1
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_sys_types.yaml
@@ -0,0 +1,30 @@
+header: sys-types.h
+standards: POSIX
+macros: []
+types:
+  - type_name: uid_t
+  - type_name: time_t
+  - type_name: pthread_t
+  - type_name: pthread_rwlockattr_t
+  - type_name: pthread_mutex_t
+  - type_name: blkcnt_t
+  - type_name: blksize_t
+  - type_name: clockid_t
+  - type_name: ssize_t
+  - type_name: pthread_mutexattr_t
+  - type_name: ino_t
+  - type_name: pthread_once_t
+  - type_name: mode_t
+  - type_name: dev_t
+  - type_name: pthread_attr_t
+  - type_name: gid_t
+  - type_name: pid_t
+  - type_name: nlink_t
+  - type_name: suseconds_t
+  - type_name: off_t
+  - type_name: size_t
+  - type_name: pthread_key_t
+  - type_name: pthread_condattr_t
+enums: []
+functions: []
+objects: []
diff --git a/libc/newhdrgen/yaml/posix_sys_utsname.yaml b/libc/newhdrgen/yaml/posix_sys_utsname.yaml
new file mode 100644
index 0000000000000..75404c6fed49c
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_sys_utsname.yaml
@@ -0,0 +1,15 @@
+header: sys-utsname.h
+macros: []
+types:
+  - type_name: struct_utsname
+enums: []
+objects: []
+functions:
+  - name: uname
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: struct utsname *
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/posix_termios.yaml b/libc/newhdrgen/yaml/posix_termios.yaml
new file mode 100644
index 0000000000000..ff76481e14b13
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_termios.yaml
@@ -0,0 +1,107 @@
+header: termios.h
+macros: []
+types:
+  - type_name: tcflag_t
+  - type_name: struct_termios
+  - type_name: speed_t
+  - type_name: pid_t
+  - type_name: cc_t
+enums: []
+objects: []
+functions:
+  - name: cfgetispeed
+    standards: 
+      - POSIX
+    return_type: speed_t
+    arguments:
+      - type: const struct termios *
+    guard: null
+    attributes: []
+  - name: cfgetospeed
+    standards: 
+      - POSIX
+    return_type: speed_t
+    arguments:
+      - type: const struct termios *
+    guard: null
+    attributes: []
+  - name: cfsetispeed
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: struct termios *
+      - type: speed_t
+    guard: null
+    attributes: []
+  - name: cfsetospeed
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: struct termios *
+      - type: speed_t
+    guard: null
+    attributes: []
+  - name: tcgetattr
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: struct termios *
+    guard: null
+    attributes: []
+  - name: tcgetsid
+    standards: 
+      - POSIX
+    return_type: pid_t
+    arguments:
+      - type: int
+    guard: null
+    attributes: []
+  - name: tcdrain
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+    guard: null
+    attributes: []
+  - name: tcflow
+    standards: 
+      - POSIX 
+    return_type: int
+    arguments:
+      - type: int
+      - type: int
+    guard: null
+    attributes: []
+  - name: tcflush
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: int
+    guard: null
+    attributes: []
+  - name: tcsendbreak
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: int
+    guard: null
+    attributes: []
+  - name: tcsetattr
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: int
+      - type: struct termios *
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/posix_unistd.yaml b/libc/newhdrgen/yaml/posix_unistd.yaml
new file mode 100644
index 0000000000000..ff1bd2ca02fac
--- /dev/null
+++ b/libc/newhdrgen/yaml/posix_unistd.yaml
@@ -0,0 +1,414 @@
+header: unistd.h
+macros: []
+types:
+  - type_name: uid_t
+  - type_name: ssize_t
+  - type_name: size_t
+  - type_name: pid_t
+  - type_name: off_t
+  - type_name: __getoptargv_t
+  - type_name: __exec_envp_t
+  - type_name: __exec_argv_t
+enums: []
+objects:
+  - object_name: environ
+    object_type: char **
+  - object_name: optarg
+    object_type: char *
+  - object_name: optind
+    object_type: int
+  - object_name: opterr
+    object_type: int
+  - object_name: optopt
+    object_type: int
+functions:
+  - name: access
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+      - type: int
+    guard: null
+    attributes: []
+  - name: chdir
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+    guard: null
+    attributes: []
+  - name: close
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+    guard: null
+    attributes: []
+  - name: dup
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+    guard: null
+    attributes: []
+  - name: dup2
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: int
+    guard: null
+    attributes: []
+  - name: dup3
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: int
+      - type: int
+    guard: null
+    attributes: []
+  - name: execve
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+      - type: __exec_argv_t
+      - type: __exec_envp_t
+    guard: null
+    attributes: []
+  - name: fchdir
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+    guard: null
+    attributes: []
+  - name: fsync
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+    guard: null
+    attributes: []
+  - name: ftruncate
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: off_t
+    guard: null
+    attributes: []
+  - name: getcwd
+    standards: 
+      - POSIX
+    return_type: char *
+    arguments:
+      - type: char *
+      - type: size_t
+    guard: null
+    attributes: []
+  - name: geteuid
+    standards: 
+      - POSIX
+    return_type: uid_t
+    arguments: []
+    guard: null
+    attributes: []
+  - name: getpid
+    standards: 
+      - POSIX
+    return_type: int
+    arguments: []
+    guard: null
+    attributes: []
+  - name: getppid
+    standards: 
+      - POSIX
+    return_type: int
+    arguments: []
+    guard: null
+    attributes: []
+  - name: getuid
+    standards: 
+      - POSIX
+    return_type: uid_t
+    arguments: []
+    guard: null
+    attributes: []
+  - name: isatty
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+    guard: null
+    attributes: []
+  - name: link
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+      - type: const char *
+    guard: null
+    attributes: []
+  - name: linkat
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: const char *
+      - type: int
+      - type: const char *
+      - type: int
+    guard: null
+    attributes: []
+  - name: lseek 
+    standards: 
+      - POSIX
+    return_type: off_t
+    arguments:
+      - type: int
+      - type: off_t
+      - type: int
+    guard: null
+    attributes: []
+  - name: pipe
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int *
+    guard: null
+    attributes: []
+  - name: pread
+    standards: 
+      - POSIX
+    return_type: ssize_t
+    arguments:
+      - type: int
+      - type: void *
+      - type: size_t
+      - type: off_t
+    guard: null
+    attributes: []
+  - name: pwrite
+    standards: 
+      - POSIX
+    return_type: ssize_t
+    arguments:
+      - type: int
+      - type: const void *
+      - type: size_t
+      - type: off_t
+    guard: null
+    attributes: []
+  - name: read
+    standards: 
+      - POSIX
+    return_type: ssize_t
+    arguments:
+      - type: int
+      - type: void *
+      - type: size_t
+    guard: null
+    attributes: []
+  - name: readlink
+    standards: 
+      - POSIX
+    return_type: ssize_t
+    arguments:
+      - type: const char * __restrict
+      - type: char * __restrict
+      - type: size_t
+    guard: null
+    attributes: []
+  - name: readlinkat
+    standards: 
+      - POSIX
+    return_type: ssize_t
+    arguments:
+      - type: const char * __restrict
+      - type: char * __restrict
+      - type: size_t
+    guard: null
+    attributes: []
+  - name: rmdir
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+    guard: null
+    attributes: []
+  - name: symlink
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+      - type: const char *
+    guard: null
+    attributes: []
+  - name: symlinkat
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: const char *
+      - type: int
+      - type: const char *
+    guard: null
+    attributes: []
+  - name: sysconf
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+    guard: null
+    attributes: []
+  - name: truncate
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+      - type: off_t
+    guard: null
+    attributes: []
+  - name: unlink
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+    guard: null
+    attributes: []
+  - name: unlinkat
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: const char *
+      - type: int
+    guard: null
+    attributes: []
+  - name: write
+    standards: 
+      - POSIX
+    return_type: ssize_t
+    arguments:
+      - type: int
+      - type: const void *
+      - type: size_t
+    guard: null
+    attributes: []
+  - name: _exit
+    standards: 
+      - POSIX
+    return_type: void
+    arguments:
+      - type: int
+    guard: null
+    attributes:
+      - noreturn
+  - name: execv
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: const char *
+      - type: __exec_argv_t
+    guard: null
+    attributes: []
+  - name: fork
+    standards: 
+      - POSIX
+    return_type: pid_t
+    arguments: []
+    guard: null
+    attributes: []
+  - name: __llvm_libc_syscall
+    standards: 
+      - POSIX
+    return_type: long
+    arguments:
+      - type: long
+      - type: long
+      - type: long
+      - type: long
+      - type: long
+      - type: long
+      - type: long
+    guard: null
+    attributes: []
+  - name: getopt
+    standards: 
+      - POSIX
+    return_type: int
+    arguments:
+      - type: int
+      - type: __getoptargv_t
+      - type: const char *
+    guard: null
+    attributes: []
+  - name: swab
+    standards: 
+      - POSIX
+    return_type: void
+    arguments:
+      - type: const void * __restrict
+      - type: void *
+      - type: ssize_t
+    guard: null
+    attributes: []
+  - name: enivron
+    standards: 
+      - POSIX
+    return_type: extern char **
+    arguments: []
+    guard: null
+    attributes: []
+  - name: optarg
+    standards: 
+      - POSIX
+    return_type: extern char *
+    arguments: []
+    guard: null
+    attributes: []
+  - name: optind
+    standards: 
+      - POSIX
+    return_type: extern int 
+    arguments: []
+    guard: null
+    attributes: []
+  - name: optopt
+    standards: 
+      - POSIX
+    return_type: extern int 
+    arguments: []
+    guard: null
+    attributes: []
+  - name: opterr
+    standards: 
+      - POSIX
+    return_type: extern int 
+    arguments: []
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/stdc_float.yaml b/libc/newhdrgen/yaml/stdc_float.yaml
new file mode 100644
index 0000000000000..fcbede018113c
--- /dev/null
+++ b/libc/newhdrgen/yaml/stdc_float.yaml
@@ -0,0 +1,8 @@
+header: float.h
+standards: 
+  - stdc
+macros: []
+types: []
+enums: []
+objects: []
+functions: []
diff --git a/libc/newhdrgen/yaml/stdc_inttypes.yaml b/libc/newhdrgen/yaml/stdc_inttypes.yaml
new file mode 100644
index 0000000000000..eae886344b2a1
--- /dev/null
+++ b/libc/newhdrgen/yaml/stdc_inttypes.yaml
@@ -0,0 +1,44 @@
+header: inttypes.h
+macros: 
+types:
+  - type_name: imaxdiv_t
+enums: []
+objects: []
+functions:
+  - name: imaxabs
+    standards: 
+      - stdc
+    return_type: intmax_t
+    arguments:
+      - type: intmax_t
+    guard: null
+    attributes: []
+  - name: imaxdiv
+    standards: 
+      - stdc
+    return_type: imaxdiv_t
+    arguments:
+      - type: intmax_t
+      - type: intmax_t
+    guard: null
+    attributes: []
+  - name: strtoimax
+    standards: 
+      - stdc
+    return_type: intmax_t
+    arguments:
+      - type: const char *__restrict
+      - type: char * *__restrict
+      - type: int
+    guard: null
+    attributes: []
+  - name: strtoumax
+    standards: 
+      - stdc
+    return_type: uintmax_t
+    arguments:
+      - type: const char *__restrict
+      - type: char * *__restrict
+      - type: int
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/stdc_limits.yaml b/libc/newhdrgen/yaml/stdc_limits.yaml
new file mode 100644
index 0000000000000..9d0f14fa3095d
--- /dev/null
+++ b/libc/newhdrgen/yaml/stdc_limits.yaml
@@ -0,0 +1,8 @@
+header: limits.h
+standards: 
+  - stdc
+macros: []
+types: []
+enums: []
+objects: []
+functions: []
diff --git a/libc/newhdrgen/yaml/stdc_setjmp.yaml b/libc/newhdrgen/yaml/stdc_setjmp.yaml
new file mode 100644
index 0000000000000..6959f4906cc4c
--- /dev/null
+++ b/libc/newhdrgen/yaml/stdc_setjmp.yaml
@@ -0,0 +1,20 @@
+header: setjmp.h
+macros: []
+types:
+  - type_name: jmp_buf
+enums: []
+objects: []
+functions:
+  - name: longjmp
+    standards: 
+      - stdc
+    return_type: void
+    arguments:
+      - type: _jmp_buf 
+      - type: int
+  - name: setjmp
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: _jmp_buf
diff --git a/libc/newhdrgen/yaml/stdc_stdbit.yaml b/libc/newhdrgen/yaml/stdc_stdbit.yaml
new file mode 100644
index 0000000000000..09339d855b9f1
--- /dev/null
+++ b/libc/newhdrgen/yaml/stdc_stdbit.yaml
@@ -0,0 +1,526 @@
+header: stdbit.h
+macros: []
+types: []
+enums: []
+objects: []
+functions:
+  - name: stdc_leading_zeros_uc
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_leading_zeros_us
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_leading_zeros_ui
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_leading_zeros_ul
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_leading_zeros_ull
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
+  - name: stdc_leading_ones_uc
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_leading_ones_us
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_leading_ones_ui
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_leading_ones_ul
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_leading_ones_ull
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
+  - name: stdc_trailing_zeros_uc
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_trailing_zeros_us
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_trailing_zeros_ui
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_trailing_zeros_ul
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_trailing_zeros_ull
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
+  - name: stdc_trailing_ones_uc
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_trailing_ones_us
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_trailing_ones_ui
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_trailing_ones_ul
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_trailing_ones_ull
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
+  - name: stdc_first_leading_zero_uc
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_first_leading_zero_us
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_first_leading_zero_ui
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_first_leading_zero_ul
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_first_leading_zero_ull
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
+  - name: stdc_first_leading_one_uc
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_first_leading_one_us
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_first_leading_one_ui
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_first_leading_one_ul
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_first_leading_one_ull
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
+  - name: stdc_first_trailing_one_uc
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_first_trailing_one_us
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_first_trailing_one_ui
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_first_trailing_one_ul
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_first_trailing_one_ull
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
+  - name: stdc_count_zeros_uc
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_count_zeros_us
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_count_zeros_ui
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_count_zeros_ul
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_count_zeros_ull
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
+  - name: stdc_count_ones_uc
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_count_ones_us
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_count_ones_ui
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_count_ones_ul
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_count_ones_ull
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
+  - name: stdc_has_single_bit_uc
+    standards: 
+      - stdc
+    return_type: bool
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_has_single_bit_us
+    standards: 
+      - stdc
+    return_type: bool
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_has_single_bit_ui
+    standards: 
+      - stdc
+    return_type: bool
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_has_single_bit_ul
+    standards: 
+      - stdc
+    return_type: bool
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_has_single_bit_ull
+    standards: 
+      - stdc
+    return_type: bool
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
+  - name: stdc_bit_width_uc
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_bit_width_us
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_bit_width_ui
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_bit_width_ul
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_bit_width_ull
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
+  - name: stdc_bit_floor_uc
+    standards: 
+      - stdc
+    return_type: unsigned char
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_bit_floor_us
+    standards: 
+      - stdc
+    return_type: unsigned short
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_bit_floor_ui
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_bit_floor_ul
+    standards: 
+      - stdc
+    return_type: unsigned long
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_bit_floor_ull
+    standards: 
+      - stdc
+    return_type: unsigned long long
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
+  - name: stdc_bit_ceil_uc
+    standards: 
+      - stdc
+    return_type: unsigned char
+    arguments:
+      - type: unsigned char
+    guard: null
+    attributes: []
+  - name: stdc_bit_ceil_us
+    standards: 
+      - stdc
+    return_type: unsigned short
+    arguments:
+      - type: unsigned short
+    guard: null
+    attributes: []
+  - name: stdc_bit_ceil_ui
+    standards: 
+      - stdc
+    return_type: unsigned int
+    arguments:
+      - type: unsigned int
+    guard: null
+    attributes: []
+  - name: stdc_bit_ceil_ul
+    standards: 
+      - stdc
+    return_type: unsigned long
+    arguments:
+      - type: unsigned long
+    guard: null
+    attributes: []
+  - name: stdc_bit_ceil_ull
+    standards: 
+      - stdc
+    return_type: unsigned long long
+    arguments:
+      - type: unsigned long long
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/stdc_stdckdint.yaml b/libc/newhdrgen/yaml/stdc_stdckdint.yaml
new file mode 100644
index 0000000000000..5cc2e109e90e7
--- /dev/null
+++ b/libc/newhdrgen/yaml/stdc_stdckdint.yaml
@@ -0,0 +1,8 @@
+header: stdckdint.h
+standards: 
+  - stdc
+macros: []
+types: []
+enums: []
+objects: []
+functions: []
diff --git a/libc/newhdrgen/yaml/stdc_stdint.yaml b/libc/newhdrgen/yaml/stdc_stdint.yaml
new file mode 100644
index 0000000000000..5f613e1daa67f
--- /dev/null
+++ b/libc/newhdrgen/yaml/stdc_stdint.yaml
@@ -0,0 +1,8 @@
+header: stdint.h
+standards: 
+  - stdc
+macros: []
+types: []
+enums: []
+objects: []
+functions: []
diff --git a/libc/newhdrgen/yaml/stdc_threads.yaml b/libc/newhdrgen/yaml/stdc_threads.yaml
new file mode 100644
index 0000000000000..ff5ac9e1cbe2a
--- /dev/null
+++ b/libc/newhdrgen/yaml/stdc_threads.yaml
@@ -0,0 +1,184 @@
+header: threads.h
+macros:
+  - macro_name: ONCE_FLAG_INIT
+    macro_value: "{0}"
+types:
+  - type_name: once_flag
+  - type_name: __call_once_func_t
+  - type_name: cnd_t
+  - type_name: mtx_t
+  - type_name: thrd_start_t
+  - type_name: thrd_t
+  - type_name: tss_t
+  - type_name: tss_dtor_t
+enums:
+  - name: mtx_plain
+    value: null
+  - name: mtx_recursive
+    value: null
+  - name: mtx_timed
+    value: null
+  - name: thrd_timedout
+    value: null
+  - name: thrd_success
+    value: null
+  - name: thrd_busy
+    value: null
+  - name: thrd_error
+    value: null
+  - name: thrd_nomem
+    value: null
+objects: []
+functions:
+  - name: call_once
+    standards: 
+      - stdc
+    return_type: void
+    arguments:
+      - type: once_flag *
+      - type: __call_once_func_t
+    guard: null
+    attributes: []
+  - name: cnd_broadcast
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: cnd_t *
+    guard: null
+    attributes: []
+  - name: cnd_destroy
+    standards: 
+      - stdc
+    return_type: void
+    arguments:
+      - type: cnd_t *
+    guard: null
+    attributes: []
+  - name: cnd_init
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: cnd_t *
+    guard: null
+    attributes: []
+  - name: cnd_signal
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: cnd_t *
+    guard: null
+    attributes: []
+  - name: cnd_wait
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: cnd_t *
+      - type: mtx_t *
+    guard: null
+    attributes: []
+  - name: mtx_init
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: mtx_t *
+      - type: int
+    guard: null
+    attributes: []
+  - name: mtx_destroy
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: void
+    guard: null
+    attributes: []
+  - name: mtx_lock
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: mtx_t *
+    guard: null
+    attributes: []
+  - name: mtx_unlock
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: mtx_t *
+    guard: null
+    attributes: []
+  - name: thrd_create
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: thrd_t *
+      - type: thrd_start_t
+      - type: void *
+    guard: null
+    attributes: []
+  - name: thrd_join
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: thrd_t
+      - type: int *
+    guard: null
+    attributes: []
+  - name: thrd_detach
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: thrd_t
+    guard: null
+    attributes: []
+  - name: thrd_current
+    standards: 
+      - stdc
+    return_type: thrd_t
+    arguments:
+      - type: void
+    guard: null
+    attributes: []
+  - name: thrd_equal
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: thrd_t
+      - type: thrd_t
+    guard: null
+    attributes: []
+  - name: thrd_exit
+    standards: 
+      - stdc
+    return_type: void
+    arguments:
+      - type: int
+    guard: null
+    attributes: []
+  - name: tss_create
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: tss_t *
+      - type: tss_dtor_t
+    guard: null
+    attributes: []
+  - name: tss_delete
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: tss_t
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml/stdc_uchar.yaml b/libc/newhdrgen/yaml/stdc_uchar.yaml
new file mode 100644
index 0000000000000..a73da17acdeac
--- /dev/null
+++ b/libc/newhdrgen/yaml/stdc_uchar.yaml
@@ -0,0 +1,12 @@
+header: uchar.h
+standards: 
+  - stdc
+macros: []
+types:
+  - type_name: char32_t
+  - type_name: char16_t
+  - type_name: char8_t
+  - type_name: mbstate_t
+enums: []
+objects: []
+functions: []
diff --git a/libc/newhdrgen/yaml/stdc_wchar.yaml b/libc/newhdrgen/yaml/stdc_wchar.yaml
new file mode 100644
index 0000000000000..191b44ecae53e
--- /dev/null
+++ b/libc/newhdrgen/yaml/stdc_wchar.yaml
@@ -0,0 +1,17 @@
+header: wchar.h
+macros: []
+types:
+  - type_name: size_t
+  - type_name: wint_t
+  - type_name: wchar_t
+enums: []
+objects: []
+functions:
+  - name: wctob
+    standards: 
+      - stdc
+    return_type: int
+    arguments:
+      - type: wint_t
+    guard: null
+    attributes: []
diff --git a/libc/newhdrgen/yaml_combined/errno.yaml b/libc/newhdrgen/yaml_combined/errno.yaml
new file mode 100644
index 0000000000000..5d8de90f035bd
--- /dev/null
+++ b/libc/newhdrgen/yaml_combined/errno.yaml
@@ -0,0 +1,10 @@
+header: errno.h
+standards: 
+  - stdc
+  - Linux
+  - POSIX
+macros: []
+types: []
+enums: []
+objects: []
+functions: []



More information about the libc-commits mailing list