[all-commits] [llvm/llvm-project] dc2b01: [libc] Add POSIX close, fsync, open, read and writ...

Siva Chandra via All-commits all-commits at lists.llvm.org
Thu Jan 27 12:32:49 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: dc2b01b3f7b0e89cb57a29542da2492276c61678
      https://github.com/llvm/llvm-project/commit/dc2b01b3f7b0e89cb57a29542da2492276c61678
  Author: Siva Chandra Reddy <sivachandra at google.com>
  Date:   2022-01-27 (Thu, 27 Jan 2022)

  Changed paths:
    M libc/config/linux/api.td
    M libc/config/linux/x86_64/entrypoints.txt
    M libc/include/CMakeLists.txt
    A libc/include/fcntl.h.def
    A libc/include/llvm-libc-macros/CMakeLists.txt
    A libc/include/llvm-libc-macros/fcntl-macros.h
    A libc/include/llvm-libc-macros/linux/CMakeLists.txt
    A libc/include/llvm-libc-macros/linux/fcntl-macros.h
    M libc/include/llvm-libc-types/CMakeLists.txt
    A libc/include/llvm-libc-types/mode_t.h
    M libc/spec/posix.td
    M libc/src/CMakeLists.txt
    A libc/src/fcntl/CMakeLists.txt
    A libc/src/fcntl/linux/CMakeLists.txt
    A libc/src/fcntl/linux/open.cpp
    A libc/src/fcntl/open.h
    M libc/src/unistd/CMakeLists.txt
    A libc/src/unistd/close.h
    A libc/src/unistd/fsync.h
    M libc/src/unistd/linux/CMakeLists.txt
    A libc/src/unistd/linux/close.cpp
    A libc/src/unistd/linux/fsync.cpp
    A libc/src/unistd/linux/read.cpp
    M libc/src/unistd/linux/write.cpp
    A libc/src/unistd/read.h
    M libc/test/src/unistd/CMakeLists.txt
    A libc/test/src/unistd/read_write_test.cpp
    R libc/test/src/unistd/write_test.cpp

  Log Message:
  -----------
  [libc] Add POSIX close, fsync, open, read and write functions.

They are implemented as simple syscall wrappers. The file creation
macros have been put in a header file as a temporary solution until we
have a cleaner approach to listing platform relevant macros.

Reviewed By: abrachet

Differential Revision: https://reviews.llvm.org/D118396




More information about the All-commits mailing list