40 lines · plain
1# Test the ${function.is-inlined} frame-format variable.2 3# Windows' link.exe does not preserve DWARF information, and we cannot get4# inlining information from PDB at this time, see:5# https://github.com/llvm/llvm-project/issues/1431046# REQUIRES: (system-windows && lld) || !system-windows7 8# RUN: split-file %s %t9# RUN: %clangxx_host -g -gdwarf %t/main.cpp -o %t.out %if system-windows %{-fuse-ld=lld%}10# RUN: %lldb -x -b -s %t/commands.input %t.out -o exit 2>&1 \11# RUN: | FileCheck %s12 13#--- main.cpp14 15void regular();16 17[[clang::always_inline]] void inlined1() {18 regular();19}20void regular() {inlined1();}21[[clang::always_inline]] void inlined2() {regular();}22 23int main() {24 inlined2();25 return 0;26}27 28#--- commands.input29 30settings set frame-format "frame '${function.name}{${function.is-inlined} (Inlined)}'\n"31breakpoint set -n inlined132run33bt34 35# CHECK: (lldb) bt36# CHECK: frame '{{.*}}inlined1({{.*}}) (Inlined)'37# CHECK-NEXT: frame '{{.*}}regular({{.*}})'38# CHECK-NEXT: frame '{{.*}}inlined2({{.*}}) (Inlined)'39# CHECK-NEXT: frame 'main'40