[PATCH] D72523: [remark][diagnostics] Using clang diagnostic handler for IR input files

2020-02-18 Thread Jeroen Dobbelaere via Phabricator via cfe-commits
jeroen.dobbelaere added a comment. This change triggers a crash in a release build of llvm: See https://bugs.llvm.org/show_bug.cgi?id=44896 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72523/new/ https://reviews.llvm.org/D72523

[PATCH] D72523: [remark][diagnostics] Using clang diagnostic handler for IR input files

2020-01-14 Thread Rong Xu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG60d39479221d: [remark][diagnostics] Using clang diagnostic handler for IR input files (authored by xur). Herald added a project: clang. Changed prior to commit:

Re: [PATCH] D72523: [remark][diagnostics] Using clang diagnostic handler for IR input files

2020-01-14 Thread Rong Xu via cfe-commits
Thanks for reviewing this. The new constructor is to avoid initializing the "OS" field (which is not used by the empty BackendConsumer. Setting this field will affect the output). I will add a comment there. -Rong On Mon, Jan 13, 2020 at 4:50 PM Teresa Johnson via Phabricator <

[PATCH] D72523: [remark][diagnostics] Using clang diagnostic handler for IR input files

2020-01-13 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson accepted this revision. tejohnson added a comment. This revision is now accepted and ready to land. LGTM. One more request for a comment below that I forgot to add earlier. Comment at: clang/lib/CodeGen/CodeGenAction.cpp:154 } +BackendConsumer(BackendAction

[PATCH] D72523: [remark][diagnostics] Using clang diagnostic handler for IR input files

2020-01-13 Thread Rong Xu via Phabricator via cfe-commits
xur updated this revision to Diff 237810. xur added a comment. Thanks Teresa for the suggestion: using the print() function in the llvm diagnosticPrinter is a lot better than duplicating the code. I changed the patch to use print() function. Also added comment as suggested by Teresa. CHANGES

[PATCH] D72523: [remark][diagnostics] Using clang diagnostic handler for IR input files

2020-01-13 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson added inline comments. Comment at: clang/lib/CodeGen/CodeGenAction.cpp:594 + // SourceLoc. + if (Context == nullptr) { +return FullSourceLoc(); xur wrote: > tejohnson wrote: > > Does this only happen with IR input? Does it always happen with IR

[PATCH] D72523: [remark][diagnostics] Using clang diagnostic handler for IR input files

2020-01-13 Thread Rong Xu via Phabricator via cfe-commits
xur updated this revision to Diff 237716. xur added a comment. Integrated Teresa's review comments. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D72523/new/ https://reviews.llvm.org/D72523 Files: clang/lib/CodeGen/CodeGenAction.cpp

[PATCH] D72523: [remark][diagnostics] Using clang diagnostic handler for IR input files

2020-01-13 Thread Rong Xu via Phabricator via cfe-commits
xur marked 3 inline comments as done. xur added inline comments. Comment at: clang/lib/CodeGen/CodeGenAction.cpp:594 + // SourceLoc. + if (Context == nullptr) { +return FullSourceLoc(); tejohnson wrote: > Does this only happen with IR input? Does it always

[PATCH] D72523: [remark][diagnostics] Using clang diagnostic handler for IR input files

2020-01-10 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson added a comment. Thanks for fixing this missing -Rpass support! Comment at: clang/lib/CodeGen/CodeGenAction.cpp:594 + // SourceLoc. + if (Context == nullptr) { +return FullSourceLoc(); Does this only happen with IR input? Does it always happen

[PATCH] D72523: [remark][diagnostics] Using clang diagnostic handler for IR input files

2020-01-10 Thread Rong Xu via Phabricator via cfe-commits
xur created this revision. xur added a reviewer: tejohnson. Herald added subscribers: dexonsmith, steven_wu, hiraditya, mehdi_amini. For IR input files, we currently use LLVM diagnostic handler even the compilation is from clang. As a result, we are not able to use -Rpass to get the