Allow diagnostic handlers to check for optimization remarks.
authorDiego Novillo <dnovillo@google.com>
Wed, 16 Apr 2014 16:53:41 +0000 (16:53 +0000)
committerDiego Novillo <dnovillo@google.com>
Wed, 16 Apr 2014 16:53:41 +0000 (16:53 +0000)
commitb902acb16cdcac7a13599ce2948046b565ea1748
tree5cebccdf050742b39df8e47e36208a2bd0b08749
parent685d6998701dd3693b26d091570231bf51c95bdb
Allow diagnostic handlers to check for optimization remarks.

Summary:
When optimization remarks are enabled via the driver flag -Rpass, we
should allow the FE diagnostic handler to check if the given pass name
needs a diagnostic.

We were unconditionally checking the pattern defined in opt's
-pass-remarks flag. This was causing the FE to not emit any diagnostics.

Reviewers: qcolombet

CC: llvm-commits
Differential Revision: http://reviews.llvm.org/D3362

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@206400 91177308-0d34-0410-b5e6-96231b3b80d8
lib/IR/LLVMContext.cpp