diff options
Diffstat (limited to 'test/FrontendC++')
-rw-r--r-- | test/FrontendC++/2006-11-06-StackTrace.cpp | 2 | ||||
-rw-r--r-- | test/FrontendC++/2006-11-30-NoCompileUnit.cpp | 2 | ||||
-rw-r--r-- | test/FrontendC++/2006-11-30-Pubnames.cpp | 2 | ||||
-rw-r--r-- | test/FrontendC++/2009-07-15-LineNumbers.cpp | 4 | ||||
-rw-r--r-- | test/FrontendC++/weak-external.cpp | 17 |
5 files changed, 22 insertions, 5 deletions
diff --git a/test/FrontendC++/2006-11-06-StackTrace.cpp b/test/FrontendC++/2006-11-06-StackTrace.cpp index 24eeda8..3732cb9 100644 --- a/test/FrontendC++/2006-11-06-StackTrace.cpp +++ b/test/FrontendC++/2006-11-06-StackTrace.cpp @@ -1,6 +1,6 @@ // This is a regression test on debug info to make sure that we can get a // meaningful stack trace from a C++ program. -// RUN: %llvmgcc -S -O0 -g %s -o - | llvm-as | \ +// RUN: %llvmgcc -S -O0 -g %s -o - | \ // RUN: llc --disable-fp-elim -o %t.s -O0 -relocation-model=pic // RUN: %compile_c %t.s -o %t.o // RUN: %link %t.o -o %t.exe diff --git a/test/FrontendC++/2006-11-30-NoCompileUnit.cpp b/test/FrontendC++/2006-11-30-NoCompileUnit.cpp index cd8b988..242a37e 100644 --- a/test/FrontendC++/2006-11-30-NoCompileUnit.cpp +++ b/test/FrontendC++/2006-11-30-NoCompileUnit.cpp @@ -1,6 +1,6 @@ // This is a regression test on debug info to make sure we don't hit a compile // unit size issue with gdb. -// RUN: %llvmgcc -S -O0 -g %s -o - | llvm-as | \ +// RUN: %llvmgcc -S -O0 -g %s -o - | \ // RUN: llc --disable-fp-elim -o NoCompileUnit.s // RUN: %compile_c NoCompileUnit.s -o NoCompileUnit.o // RUN: %link NoCompileUnit.o -o NoCompileUnit.exe diff --git a/test/FrontendC++/2006-11-30-Pubnames.cpp b/test/FrontendC++/2006-11-30-Pubnames.cpp index 64214a8..3a08b3c 100644 --- a/test/FrontendC++/2006-11-30-Pubnames.cpp +++ b/test/FrontendC++/2006-11-30-Pubnames.cpp @@ -1,6 +1,6 @@ // This is a regression test on debug info to make sure that we can access // qualified global names. -// RUN: %llvmgcc -S -O0 -g %s -o - | llvm-as | \ +// RUN: %llvmgcc -S -O0 -g %s -o - | \ // RUN: llc --disable-fp-elim -o %t.s -O0 // RUN: %compile_c %t.s -o %t.o // RUN: %link %t.o -o %t.exe diff --git a/test/FrontendC++/2009-07-15-LineNumbers.cpp b/test/FrontendC++/2009-07-15-LineNumbers.cpp index d603aa7..a8eda77 100644 --- a/test/FrontendC++/2009-07-15-LineNumbers.cpp +++ b/test/FrontendC++/2009-07-15-LineNumbers.cpp @@ -1,7 +1,7 @@ // This is a regression test on debug info to make sure that we can // print line numbers in asm. -// RUN: %llvmgcc -S -O0 -g %s -o - | llvm-as | \ -// RUN: llc --disable-fp-elim -O0 -relocation-model=pic | grep {SrcLine 25} +// RUN: %llvmgcc -S -O0 -g %s -o - | \ +// RUN: llc --disable-fp-elim -O0 -relocation-model=pic | grep { 2009-07-15-LineNumbers.cpp:25$} #include <stdlib.h> diff --git a/test/FrontendC++/weak-external.cpp b/test/FrontendC++/weak-external.cpp new file mode 100644 index 0000000..94360c2 --- /dev/null +++ b/test/FrontendC++/weak-external.cpp @@ -0,0 +1,17 @@ +// RUN: %llvmgxx %s -S -emit-llvm -O2 -o - | not grep {_ZNSs12_S_constructIPKcEEPcT_S3_RKSaIcESt20forward_iterator_tag} +// PR4262 + +// The "basic_string" extern template instantiation declaration is supposed to +// suppress the implicit instantiation of non-inline member functions. Make sure +// that we suppress the implicit instantiation of non-inline member functions +// defined out-of-line. That we aren't instantiating the basic_string +// constructor when we shouldn't be. Such an instantiation forces the implicit +// instantiation of _S_construct<const char*>. Since _S_construct is a member +// template, it's instantiation is *not* suppressed (despite being in +// basic_string<char>), so we would emit it as a weak definition. + +#include <stdexcept> + +void dummysymbol() { + throw(std::runtime_error("string")); +} |