Alexey Samsonov | 897f2cf | 2013-02-08 14:34:33 +0000 | [diff] [blame] | 1 | #include "dwarfdump-inl-test.h" |
| 2 | static inline int inlined_f() { |
| 3 | volatile int x = inlined_g(); |
| 4 | return x; |
| 5 | } |
| 6 | |
| 7 | int main() { |
| 8 | return inlined_f(); |
| 9 | } |
| 10 | |
| 11 | // Built with Clang 3.2 |
| 12 | // $ mkdir -p /tmp/dbginfo |
| 13 | // $ cp dwarfdump-inl-test.* /tmp/dbginfo |
| 14 | // $ cd /tmp/dbginfo |
| 15 | // $ clang++ -O2 -gline-tables-only -fsanitize=address -fPIC -shared dwarfdump-inl-test.cc -o <output> |
Will Dietz | b67a714 | 2013-10-30 20:27:17 +0000 | [diff] [blame] | 16 | // |
| 17 | // And similarly with with gcc 4.8.2: |
| 18 | // $ gcc dwarfdump-inl-test.cc -o dwarfdump-inl-test.high_pc.elf-x86-64 -g -O2 -fPIC -shared |