1 void f1() {} 2 __attribute__((always_inline)) inline void f2() { 3 f1(); 4 } 5 // throw a gap in the address range to force use of DW_AT_ranges, ranges_base, 6 // range contribution in the .dwo file, etc. 7 __attribute__((nodebug)) void gap() { 8 } 9 int main() { 10 f2(); 11 } 12 13 // To produce split-dwarf-dwp.o{,dwp}, Create another file that has ranges, so 14 // the ranges_base of the CU for split-dwarf-dwp.cpp is non-zero. 15 // 16 // $ cat > other.cpp 17 // void other1() {} 18 // __attribute__((nodebug)) void other2() {} 19 // void other3() {} 20 // $ clang++ other.cpp split-dwarf-dwp.cpp -gsplit-dwarf -c -Xclang -fdebug-compilation-dir -Xclang . -fno-split-dwarf-inlining 21 // $ llvm-dwp other.dwo split-dwarf-dwp.dwo -o test/DebugInfo/Inputs/split-dwarf-dwp.o.dwp 22 // $ ld -r other.o split-dwarf-dwp.o -o test/DebugInfo/Inputs/split-dwarf-dwp.o 23