summaryrefslogtreecommitdiff
path: root/lib/IR/LLVMContextImpl.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/IR/LLVMContextImpl.cpp')
-rw-r--r--lib/IR/LLVMContextImpl.cpp12
1 files changed, 1 insertions, 11 deletions
diff --git a/lib/IR/LLVMContextImpl.cpp b/lib/IR/LLVMContextImpl.cpp
index 50740a0c34..2bccd2a091 100644
--- a/lib/IR/LLVMContextImpl.cpp
+++ b/lib/IR/LLVMContextImpl.cpp
@@ -73,22 +73,12 @@ namespace {
/// LLVMContext::emitOptimizationRemark.
static Regex *OptimizationRemarkPattern = nullptr;
-/// \brief String to hold all the values passed via -pass-remarks. Every
-/// instance of -pass-remarks on the command line will be concatenated
-/// to this string. Values are stored inside braces and concatenated with
-/// the '|' operator. This implements the expected semantics that multiple
-/// -pass-remarks are additive.
-static std::string OptimizationRemarkExpr;
-
struct PassRemarksOpt {
void operator=(const std::string &Val) const {
// Create a regexp object to match pass names for emitOptimizationRemark.
if (!Val.empty()) {
- if (!OptimizationRemarkExpr.empty())
- OptimizationRemarkExpr += "|";
- OptimizationRemarkExpr += "(" + Val + ")";
delete OptimizationRemarkPattern;
- OptimizationRemarkPattern = new Regex(OptimizationRemarkExpr);
+ OptimizationRemarkPattern = new Regex(Val);
std::string RegexError;
if (!OptimizationRemarkPattern->isValid(RegexError))
report_fatal_error("Invalid regular expression '" + Val +