[libc] Add POSIX functions dup, dup2, and GNU extension function dup3.
authorSiva Chandra Reddy <sivachandra@google.com>
Tue, 13 Sep 2022 06:01:54 +0000 (06:01 +0000)
committerSiva Chandra Reddy <sivachandra@google.com>
Tue, 13 Sep 2022 18:06:30 +0000 (18:06 +0000)
commit8989aa003f3d33498801e3a41871472da1bc211e
tree949aa8731a5ed8d58a78b314c48bb6a2abb22aad
parent6c089b2af5d8d98f66b27b67f70958f520820a76
[libc] Add POSIX functions dup, dup2, and GNU extension function dup3.

Reviewed By: lntue

Differential Revision: https://reviews.llvm.org/D133748
17 files changed:
libc/config/linux/aarch64/entrypoints.txt
libc/config/linux/x86_64/entrypoints.txt
libc/include/llvm-libc-macros/linux/fcntl-macros.h
libc/spec/gnu_ext.td
libc/spec/posix.td
libc/src/unistd/CMakeLists.txt
libc/src/unistd/dup.h [new file with mode: 0644]
libc/src/unistd/dup2.h [new file with mode: 0644]
libc/src/unistd/dup3.h [new file with mode: 0644]
libc/src/unistd/linux/CMakeLists.txt
libc/src/unistd/linux/dup.cpp [new file with mode: 0644]
libc/src/unistd/linux/dup2.cpp [new file with mode: 0644]
libc/src/unistd/linux/dup3.cpp [new file with mode: 0644]
libc/test/src/unistd/CMakeLists.txt
libc/test/src/unistd/dup2_test.cpp [new file with mode: 0644]
libc/test/src/unistd/dup3_test.cpp [new file with mode: 0644]
libc/test/src/unistd/dup_test.cpp [new file with mode: 0644]