[libc-commits] [libc] [libc][docs] adds threads.h impl status docs (PR #89275)
Michael Flanders via libc-commits
libc-commits at lists.llvm.org
Thu Apr 18 11:29:09 PDT 2024
https://github.com/Flandini updated https://github.com/llvm/llvm-project/pull/89275
>From 268d716c10e79fecd861b51edfdb5dd65a63019e Mon Sep 17 00:00:00 2001
From: Michael Flanders <flanders.michaelk at gmail.com>
Date: Thu, 18 Apr 2024 10:32:24 -0700
Subject: [PATCH 1/2] [libc][docs] adds threads.h impl status docs
---
libc/docs/index.rst | 1 +
libc/docs/threads.rst | 88 +++++++++++++++++++++++++++++++++
libc/utils/docgen/threads.json | 89 ++++++++++++++++++++++++++++++++++
3 files changed, 178 insertions(+)
create mode 100644 libc/docs/threads.rst
create mode 100644 libc/utils/docgen/threads.json
diff --git a/libc/docs/index.rst b/libc/docs/index.rst
index 11d5ae197d7189..f71920b058d83f 100644
--- a/libc/docs/index.rst
+++ b/libc/docs/index.rst
@@ -71,6 +71,7 @@ stages there is no ABI stability in any form.
c23
ctype
signal
+ threads
.. toctree::
:hidden:
diff --git a/libc/docs/threads.rst b/libc/docs/threads.rst
new file mode 100644
index 00000000000000..78e17e9fdec3aa
--- /dev/null
+++ b/libc/docs/threads.rst
@@ -0,0 +1,88 @@
+.. include:: check.rst
+
+threads.h Functions
+===================
+
+.. list-table::
+ :widths: auto
+ :align: center
+ :header-rows: 1
+
+ * - Function
+ - Implemented
+ - Standard
+ * - call_once
+ - |check|
+ - 7.28.2.1
+ * - cnd_broadcast
+ - |check|
+ - 7.28.3.1
+ * - cnd_destroy
+ - |check|
+ - 7.28.3.2
+ * - cnd_init
+ - |check|
+ - 7.28.3.3
+ * - cnd_signal
+ - |check|
+ - 7.28.3.4
+ * - cnd_timedwait
+ -
+ - 7.28.3.5
+ * - cnd_wait
+ - |check|
+ - 7.28.3.6
+ * - mtx_destroy
+ - |check|
+ - 7.28.4.1
+ * - mtx_init
+ - |check|
+ - 7.28.4.2
+ * - mtx_lock
+ - |check|
+ - 7.28.4.3
+ * - mtx_timedlock
+ -
+ - 7.28.4.4
+ * - mtx_trylock
+ -
+ - 7.28.4.5
+ * - mtx_unlock
+ - |check|
+ - 7.28.4.6
+ * - thrd_create
+ - |check|
+ - 7.28.5.1
+ * - thrd_current
+ - |check|
+ - 7.28.5.2
+ * - thrd_detach
+ - |check|
+ - 7.28.5.3
+ * - thrd_equal
+ - |check|
+ - 7.28.5.4
+ * - thrd_exit
+ - |check|
+ - 7.28.5.5
+ * - thrd_join
+ - |check|
+ - 7.28.5.6
+ * - thrd_sleep
+ -
+ - 7.28.5.7
+ * - thrd_yield
+ -
+ - 7.28.5.8
+ * - tss_create
+ - |check|
+ - 7.28.6.1
+ * - tss_delete
+ - |check|
+ - 7.28.6.2
+ * - tss_get
+ - |check|
+ - 7.28.6.3
+ * - tss_set
+ - |check|
+ - 7.28.6.4
diff --git a/libc/utils/docgen/threads.json b/libc/utils/docgen/threads.json
new file mode 100644
index 00000000000000..1e6b7cb4681fd4
--- /dev/null
+++ b/libc/utils/docgen/threads.json
@@ -0,0 +1,89 @@
+{
+ "macros": {
+ "ONCE_FLAG_INIT": {
+ "defined": "7.28.1.3",
+ "implemented": true
+ },
+ "TSS_DTOR_ITERATIONS": {
+ "defined": "7.28.1.3",
+ "implemented": false
+ }
+ },
+ "functions": {
+ "call_once": {
+ "defined": "7.28.2.1"
+ },
+ "cnd_broadcast": {
+ "defined": "7.28.3.1"
+ },
+ "cnd_destroy": {
+ "defined": "7.28.3.2"
+ },
+ "cnd_init": {
+ "defined": "7.28.3.3"
+ },
+ "cnd_signal": {
+ "defined": "7.28.3.4"
+ },
+ "cnd_timedwait": {
+ "defined": "7.28.3.5"
+ },
+ "cnd_wait": {
+ "defined": "7.28.3.6"
+ },
+ "mtx_destroy": {
+ "defined": "7.28.4.1"
+ },
+ "mtx_init": {
+ "defined": "7.28.4.2"
+ },
+ "mtx_lock": {
+ "defined": "7.28.4.3"
+ },
+ "mtx_timedlock": {
+ "defined": "7.28.4.4"
+ },
+ "mtx_trylock": {
+ "defined": "7.28.4.5"
+ },
+ "mtx_unlock": {
+ "defined": "7.28.4.6"
+ },
+ "thrd_create": {
+ "defined": "7.28.5.1"
+ },
+ "thrd_current": {
+ "defined": "7.28.5.2"
+ },
+ "thrd_detach": {
+ "defined": "7.28.5.3"
+ },
+ "thrd_equal": {
+ "defined": "7.28.5.4"
+ },
+ "thrd_exit": {
+ "defined": "7.28.5.5"
+ },
+ "thrd_join": {
+ "defined": "7.28.5.6"
+ },
+ "thrd_sleep": {
+ "defined": "7.28.5.7"
+ },
+ "thrd_yield": {
+ "defined": "7.28.5.8"
+ },
+ "tss_create": {
+ "defined": "7.28.6.1"
+ },
+ "tss_delete": {
+ "defined": "7.28.6.2"
+ },
+ "tss_get": {
+ "defined": "7.28.6.3"
+ },
+ "tss_set": {
+ "defined": "7.28.6.4"
+ }
+ }
+}
>From 5139f23de3400d5fbf0381f195a0680d694bf52d Mon Sep 17 00:00:00 2001
From: Michael Flanders <flanders.michaelk at gmail.com>
Date: Thu, 18 Apr 2024 11:28:57 -0700
Subject: [PATCH 2/2] remove defined field from docgen json
---
libc/utils/docgen/threads.json | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/libc/utils/docgen/threads.json b/libc/utils/docgen/threads.json
index 1e6b7cb4681fd4..aef6ffaf75bae3 100644
--- a/libc/utils/docgen/threads.json
+++ b/libc/utils/docgen/threads.json
@@ -1,12 +1,10 @@
{
"macros": {
"ONCE_FLAG_INIT": {
- "defined": "7.28.1.3",
- "implemented": true
+ "defined": "7.28.1.3"
},
"TSS_DTOR_ITERATIONS": {
- "defined": "7.28.1.3",
- "implemented": false
+ "defined": "7.28.1.3"
}
},
"functions": {
More information about the libc-commits
mailing list