diff options
author | Tobias Grosser <tobias@grosser.es> | 2014-05-01 14:06:01 +0000 |
---|---|---|
committer | Tobias Grosser <tobias@grosser.es> | 2014-05-01 14:06:01 +0000 |
commit | 86a85678f2a793dd2e82025f3af25ba45d6bbec1 (patch) | |
tree | c60dd9329203815ddef4aaf0326ad1dacede14b7 /clang/test/Frontend/optimization-remark.c | |
parent | 10961c0eab6bf294818470708625a5d4e786a015 (diff) | |
download | bcm5719-llvm-86a85678f2a793dd2e82025f3af25ba45d6bbec1.tar.gz bcm5719-llvm-86a85678f2a793dd2e82025f3af25ba45d6bbec1.zip |
Support 'remark' in VerifyDiagnosticConsumer
After Diego added support for -Rpass=inliner we have now in-tree remarks which
we can use to properly test this feature.
llvm-svn: 207765
Diffstat (limited to 'clang/test/Frontend/optimization-remark.c')
-rw-r--r-- | clang/test/Frontend/optimization-remark.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/clang/test/Frontend/optimization-remark.c b/clang/test/Frontend/optimization-remark.c index 03bb8f875ac..3a62db0db02 100644 --- a/clang/test/Frontend/optimization-remark.c +++ b/clang/test/Frontend/optimization-remark.c @@ -2,8 +2,7 @@ // designed to always trigger the inliner, so it should be independent // of the optimization level. -// RUN: %clang -c %s -Rpass=inline -O0 -gline-tables-only -S -o /dev/null 2> %t.err -// RUN: FileCheck < %t.err %s --check-prefix=INLINE +// RUN: %clang_cc1 %s -Rpass=inline -O0 -gline-tables-only -emit-obj -verify -S -o /dev/null 2> %t.err // RUN: %clang -c %s -Rpass=inline -O0 -S -o /dev/null 2> %t.err // RUN: FileCheck < %t.err %s --check-prefix=INLINE-NO-LOC @@ -11,9 +10,9 @@ int foo(int x, int y) __attribute__((always_inline)); int foo(int x, int y) { return x + y; } -int bar(int j) { return foo(j, j - 2); } -// INLINE: remark: foo inlined into bar [-Rpass=inline] +// expected-remark@+1 {{foo inlined into bar}} +int bar(int j) { return foo(j, j - 2); } // INLINE-NO-LOC: {{^remark: foo inlined into bar}} // INLINE-NO-LOC: note: use -gline-tables-only -gcolumn-info to track |