blob: 80dd4d45259dde733b45c93e79a957ecbb5ac3b5 [file] [log] [blame]
Devang Pateldcc0dce2010-01-15 01:12:22 +00001// This is a regression test on debug info to make sure that llvm emitted
2// debug info does not crash gdb.
3// RUN: %llvmgcc -S -O0 -g %s -o - | \
4// RUN: llc --disable-fp-elim -o %t.s -O0 -relocation-model=pic
5// RUN: %compile_c %t.s -o %t.o
6// RUN: echo {quit\n} > %t.in
7// RUN: gdb -q -batch -n -x %t.in %t.o > /dev/null
8
9int foo() {
10 static int i = 42;
11 return i;
12}