diff options
author | Jim Laskey <jlaskey@mac.com> | 2006-11-30 15:25:59 +0000 |
---|---|---|
committer | Jim Laskey <jlaskey@mac.com> | 2006-11-30 15:25:59 +0000 |
commit | dd347eb87e1deaaddba59ac77c6ec08f47b94a86 (patch) | |
tree | 14d155dbf8b63432453f973577bb63509d1051af | |
parent | fe793815e07be38f7c7c52812bbc65e290037503 (diff) | |
download | external_llvm-dd347eb87e1deaaddba59ac77c6ec08f47b94a86.zip external_llvm-dd347eb87e1deaaddba59ac77c6ec08f47b94a86.tar.gz external_llvm-dd347eb87e1deaaddba59ac77c6ec08f47b94a86.tar.bz2 |
Pubnames test
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32038 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | test/DebugInfo/2006-11-30-Pubnames.cpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/test/DebugInfo/2006-11-30-Pubnames.cpp b/test/DebugInfo/2006-11-30-Pubnames.cpp new file mode 100644 index 0000000..e836f46 --- /dev/null +++ b/test/DebugInfo/2006-11-30-Pubnames.cpp @@ -0,0 +1,19 @@ +// 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 | llc --disable-fp-elim -o Output/Pubnames.s -f +// RUN: as Output/Pubnames.s -o Output/Pubnames.o +// RUN: g++ Output/Pubnames.o -o Output/Pubnames.exe +// RUN: ( echo "break main"; echo "run" ; echo "p Pubnames::pubname" ) > Output/Pubnames.gdbin +// RUN: gdb -q -batch -n -x Output/Pubnames.gdbin Output/Pubnames.exe | tee Output/Pubnames.out | grep '10' +// XFAIL: i[1-9]86|alpha|ia64|arm + +struct Pubnames { + static int pubname; +}; + +int Pubnames::pubname = 10; + +int main (int argc, char** argv) { + Pubnames p; + return 0; +} |