]> granicus.if.org Git - llvm/commit
This patch fixes https://bugs.llvm.org/show_bug.cgi?id=32352
authorVivek Pandya <vivekvpandya@gmail.com>
Fri, 15 Sep 2017 20:10:09 +0000 (20:10 +0000)
committerVivek Pandya <vivekvpandya@gmail.com>
Fri, 15 Sep 2017 20:10:09 +0000 (20:10 +0000)
commit18b4c37d1e6cde86c699785a78644a1b8a838a86
tree74589208d7ed19cfce8030a721888ff59f9fa265
parent32598e1bf4f4cd8951a2005a6997b0852ad88538
This patch fixes https://bugs.llvm.org/show_bug.cgi?id=32352
It enables OptimizationRemarkEmitter::allowExtraAnalysis and MachineOptimizationRemarkEmitter::allowExtraAnalysis to return true not only for -fsave-optimization-record but when specific remarks are requested with
command line options.
The diagnostic handler used to be callback now this patch adds a class
DiagnosticHandler. It has virtual method to provide custom diagnostic handler
and methods to control which particular remarks are enabled.
However LLVM-C API users can still provide callback function for diagnostic handler.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@313390 91177308-0d34-0410-b5e6-96231b3b80d8
23 files changed:
include/llvm/Analysis/OptimizationDiagnosticInfo.h
include/llvm/CodeGen/MachineOptimizationRemarkEmitter.h
include/llvm/IR/DiagnosticHandler.h [new file with mode: 0644]
include/llvm/IR/DiagnosticInfo.h
include/llvm/IR/LLVMContext.h
include/llvm/LTO/Config.h
include/llvm/LTO/legacy/LTOCodeGenerator.h
lib/IR/CMakeLists.txt
lib/IR/Core.cpp
lib/IR/DiagnosticHandler.cpp [new file with mode: 0644]
lib/IR/DiagnosticInfo.cpp
lib/IR/LLVMContext.cpp
lib/IR/LLVMContextImpl.cpp
lib/IR/LLVMContextImpl.h
lib/LTO/LTOCodeGenerator.cpp
lib/Transforms/Scalar/GVN.cpp
lib/Transforms/Vectorize/LoopVectorize.cpp
test/Transforms/GVN/opt-remarks.ll
tools/llc/llc.cpp
tools/llvm-dis/llvm-dis.cpp
tools/llvm-link/llvm-link.cpp
tools/llvm-lto/llvm-lto.cpp
tools/lto/lto.cpp