- The Python header generator has been removed.
- Docs giving a highlevel overview of the header gen scheme have been
added.
Paths
| Differential D70197
[libc] Add a TableGen based header generator. ClosedPublic Authored by sivachandra on Nov 13 2019, 11:37 AM.
Details
Diff Detail
Event Timelineabrachet added inline comments.
Comment Actions Not of huge importance, more of curiosity, but could you do what you did with a past revision where you pushed a review with an svg file to your fork so we could see what it looks like on your GitHub? sivachandra marked 19 inline comments as done. Comment ActionsAddress comments.
Comment Actions
Uploaded here: https://github.com/sivachandra/llvm-libc/blob/master/docs/header_gen_scheme.svg Comment Actions
It looks quite nice. I've said this before I believe, but I really like the focus on documentation. Its pretty crucial for what were trying to accomplish with the modularity of this libc and the changes that brings to the build process and I think its great so far.
sivachandra marked 5 inline comments as done. Comment ActionsFix few copy-paste errors pointed out by abrachet; Get rid of Command::Status. sivachandra added inline comments.
Comment Actions I think this is in a good spot, it's easy to read and modify later as needs change. I don't know much about TableGen, I've tried my best to look through, but it would be preferable if other reviewers would be able to take a look too. Up to your discretion how long you would like to wait to let others chime in. LGTM I think that incorporating clang-format down the line in the header generation process isn't a bad idea. For one it would get rid of that strange white space (if we can't find the cause) and would also get rid of inconsistencies of the placement of *, char * strtok(char *__restrict, const char *__restrict);. Certainly it doesn't matter for now, just something to think about. Also of note, I find a lot of libc's decide to put #pragma GCC system_header. Do you have thoughts on this?
This revision is now accepted and ready to land.Nov 20 2019, 2:17 PM phosek added inline comments.
sivachandra added inline comments.
Closed by commit rGb47f9eb55d18: [libc] Add a TableGen based header generator. (authored by sivachandra). · Explain WhyNov 22 2019, 1:03 PM This revision was automatically updated to reflect the committed changes. Comment Actions
I have now submitted it. Thanks a lot to you and to @phosek for reviewing.
Revision Contents
Diff 229168 libc/CMakeLists.txt
libc/cmake/modules/LLVMLibCRules.cmake
libc/config/linux/api.td
libc/config/public_api.td
libc/docs/ground_truth_specification.rst
libc/docs/header_gen_scheme.svg
libc/docs/header_generation.rst
libc/docs/mechanics_of_public_api.rst
libc/include/CMakeLists.txt
libc/include/string.h
libc/include/string.h.def
libc/spec/spec.td
libc/spec/stdc.td
libc/utils/HdrGen/CMakeLists.txt
libc/utils/HdrGen/Command.h
libc/utils/HdrGen/Generator.h
libc/utils/HdrGen/Generator.cpp
libc/utils/HdrGen/IncludeFileCommand.h
libc/utils/HdrGen/IncludeFileCommand.cpp
libc/utils/HdrGen/Main.cpp
libc/utils/HdrGen/PublicAPICommand.h
libc/utils/HdrGen/PublicAPICommand.cpp
libc/utils/build_scripts/gen_hdr.py
|
nit: Should this be spelled as StdIOAPI since both IO and API are acronyms?