1 // This is a regression test on debug info to make sure we don't hit a compile
2 // unit size issue with gdb.
3 // RUN: %llvmgcc -S -O0 -g %s -o - | llvm-as | \
4 // RUN: llc --disable-fp-elim -o NoCompileUnit.s -f
5 // RUN: as NoCompileUnit.s -o NoCompileUnit.o
6 // RUN: g++ NoCompileUnit.o -o NoCompileUnit.exe
7 // RUN: echo {break main\nrun\np NoCompileUnit::pubname} > %t2
8 // RUN: gdb -q -batch -n -x %t2 NoCompileUnit.exe | \
9 // RUN: tee NoCompileUnit.out | not grep {"low == high"}
10 // XFAIL: alpha|ia64|arm
18 MamaDebugTest(int n) : N(n) {}
20 int getN() const { return N; }
24 class BabyDebugTest : public MamaDebugTest {
28 BabyDebugTest(int n) : MamaDebugTest(n) {}
38 for (int i = 0; i < N; ++i) {
42 for (int i = 0; i < N; ++i) {
52 int BabyDebugTest::doh;
55 int main(int argc, const char *argv[]) {
56 BabyDebugTest BDT(20);