brintos

brintos / llvm-project-archived public Read only

0
0
Text · 948 B · 3d7de32 Raw
28 lines · cpp
1// clang-format off2// REQUIRES: lld, x863 4// Test that we can set simple breakpoints using PDB on any platform.5// RUN: %clang_cl --target=x86_64-windows-msvc -Od -Z7 -c /Fo%t.obj -- %s6// RUN: lld-link -debug:full -nodefaultlib -entry:main %t.obj -out:%t.exe -pdb:%t.pdb7// RUN: %lldb -f %t.exe -s \8// RUN:     %p/Inputs/break-by-line.lldbinit | FileCheck %s9 10// This is a separate test from break-by-function.cpp because this test is11// sensitive to edits in the source file.12 13namespace NS {14  int NamespaceFn(int X) {15    return X + 42;16  }17}18 19int main(int argc, char **argv) {20  return NS::NamespaceFn(argc);21}22 23 24// CHECK:      (lldb) target create "{{.*}}break-by-line.cpp.tmp.exe"25// CHECK:      Current executable set to '{{.*}}break-by-line.cpp.tmp.exe'26// CHECK:      (lldb) break set -f break-by-line.cpp -l 1527// CHECK:      Breakpoint 1: where = break-by-line.cpp.tmp.exe`int NS::NamespaceFn(int) + {{[0-9]+}} at break-by-line.cpp:1528