[PATCH] D65300: [clang] [CodeGen] clang-misexpect prototype for compiler warnings
Paul Kirth via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 6 14:55:06 PDT 2019
paulkirth updated this revision to Diff 213725.
paulkirth added a comment.
Use existing LLVM code for mapping case literals to their case arms.
This update refactors a great deal of the implementation and test code.
1. Removes the CaseMap data structure completely. LLVM already maintains a mapping of the constants to their case arm, so there is no reason to duplicate that logic. This also minimizes the changes impacting existing Clang/LLVM components.
2. Cleans up debug printing. Without the CaseMap printing debug output can be simplified.
3. Minimizes the code in the end-to-end tests & test profiles.
4. Improves formatting, white space, and comments.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D65300/new/
https://reviews.llvm.org/D65300
Files:
clang/include/clang/Basic/CodeGenOptions.def
clang/include/clang/Driver/Options.td
clang/lib/CodeGen/CGStmt.cpp
clang/lib/CodeGen/CMakeLists.txt
clang/lib/CodeGen/CodeGenFunction.cpp
clang/lib/CodeGen/MisExpect.cpp
clang/lib/CodeGen/MisExpect.h
clang/lib/Driver/ToolChains/Clang.cpp
clang/lib/Frontend/CompilerInvocation.cpp
clang/test/Profile/Inputs/misexpect-branch-nonconst-expect-arg.proftext
clang/test/Profile/Inputs/misexpect-branch.proftext
clang/test/Profile/Inputs/misexpect-switch-default-only.proftext
clang/test/Profile/Inputs/misexpect-switch.proftext
clang/test/Profile/misexpect-branch-cold.c
clang/test/Profile/misexpect-branch-nonconst-expected-val.c
clang/test/Profile/misexpect-branch.c
clang/test/Profile/misexpect-no-warning-without-flag.c
clang/test/Profile/misexpect-switch-default.c
clang/test/Profile/misexpect-switch-nonconst.c
clang/test/Profile/misexpect-switch-only-default-case.c
clang/test/Profile/misexpect-switch.c
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D65300.213725.patch
Type: text/x-patch
Size: 28195 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190806/d9793826/attachment-0001.bin>
More information about the cfe-commits
mailing list