Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 0 additions & 1 deletion clang/test/CodeGenCXX/debug-info-class-limited.test

This file was deleted.

File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ void instantiate(int x) {

// CHECK: !DIGlobalVariable(name: "c",{{.*}} file: [[FILE:.*]], line: 6,{{.*}} isLocal: true, isDefinition: true
// CHECK: !DIGlobalVariable(name: "d",{{.*}} file: [[FILE]], line: 6,{{.*}} isLocal: true, isDefinition: true
// CHECK: [[FILE]] = !DIFile(filename: "{{.*}}debug-info-anon-union-vars.cpp",
// CHECK: [[FILE]] = !DIFile(filename: "{{.*}}anon-union-vars.cpp",
// CHECK: !DIGlobalVariable(name: "a",{{.*}} file: [[FILE]], line: 6,{{.*}} isLocal: true, isDefinition: true
// CHECK: !DIGlobalVariable(name: "b",{{.*}} file: [[FILE]], line: 6,{{.*}} isLocal: true, isDefinition: true
// CHECK: !DIGlobalVariable(name: "result", {{.*}} isLocal: false, isDefinition: true
Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
RUN: %clang_cc1 -emit-llvm -debug-info-kind=limited -o - -load %llvmshlibdir/PrintFunctionNames%pluginext -add-plugin print-fns %S/Inputs/debug-info-class-limited.cpp 2>&1 | FileCheck %S/Inputs/debug-info-class-limited.cpp
RUN: %clang_cc1 -emit-llvm -debug-info-kind=limited -o - -load %llvmshlibdir/PrintFunctionNames%pluginext -add-plugin print-fns %S/Inputs/class-limited.cpp 2>&1 | FileCheck %S/Inputs/class-limited.cpp
REQUIRES: plugins, examples
1 change: 1 addition & 0 deletions clang/test/DebugInfo/CXX/class-limited.test
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
RUN: %clang_cc1 -emit-llvm -debug-info-kind=limited %S/Inputs/class-limited.cpp -o - | FileCheck %S/Inputs/class-limited.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// RUN: %clang_cc1 -emit-llvm -debug-info-kind=limited -triple x86_64-pc-linux-gnu %s -fdebug-compilation-dir=%S \
// RUN: -dwarf-version=5 -main-file-name debug-info-function-context.cpp -o - | FileCheck %s
// RUN: -dwarf-version=5 -main-file-name function-context.cpp -o - | FileCheck %s

struct C {
void member_function();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ int d(int x) { D y[10]; return [x,y] { return y[x].x; }(); }
// CHECK-SAME: line: [[VAR_LINE:[0-9]+]]
// CHECK-SAME: type: ![[VAR_T:[0-9]+]]

// CHECK: [[FILE:.*]] = !DIFile(filename: "{{.*}}debug-lambda-expressions.cpp",
// CHECK: [[FILE:.*]] = !DIFile(filename: "{{.*}}lambda-expressions.cpp",

// CVAR:
// CHECK: !DIGlobalVariable(name: "cvar"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,18 +70,18 @@ void f() {
// anything other than another unnamed class/struct.
auto Lambda = [] {};
f1<decltype(Lambda)>();
// CHECK: !DISubprogram(name: "f1<(lambda at {{.*}}debug-info-simple-template-names.cpp:[[# @LINE - 2]]:17)>",
// CHECK: !DISubprogram(name: "f1<(lambda at {{.*}}simple-template-names.cpp:[[# @LINE - 2]]:17)>",
f1<t1<t1<decltype(Lambda)>>>();
// CHECK: !DISubprogram(name: "f1<t1<t1<(lambda at {{.*}}> > >",
struct {
} unnamed_struct;
f1<decltype(unnamed_struct)>();
// CHECK: !DISubprogram(name: "f1<(unnamed struct at {{.*}}debug-info-simple-template-names.cpp:[[# @LINE - 3]]:3)>",
// CHECK: !DISubprogram(name: "f1<(unnamed struct at {{.*}}simple-template-names.cpp:[[# @LINE - 3]]:3)>",
f1<void (decltype(unnamed_struct))>();
// CHECK: !DISubprogram(name: "f1<void ((unnamed struct at {{.*}}debug-info-simple-template-names.cpp:[[# @LINE - 5]]:3))>",
// CHECK: !DISubprogram(name: "f1<void ((unnamed struct at {{.*}}simple-template-names.cpp:[[# @LINE - 5]]:3))>",
enum {} unnamed_enum;
f1<decltype(unnamed_enum)>();
// CHECK: !DISubprogram(name: "f1<(unnamed enum at {{.*}}debug-info-simple-template-names.cpp:[[# @LINE - 2]]:3)>",
// CHECK: !DISubprogram(name: "f1<(unnamed enum at {{.*}}simple-template-names.cpp:[[# @LINE - 2]]:3)>",

// Declarations can't readily be reversed as the value in the DWARF only
// contains the address of the value - we'd have to do symbol lookup to find
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

// CHECK: attributes #[[ATTR1]] = { cold {{.*}}}

// CHECK: ![[FILESCOPE:.*]] = !DIFile(filename: "{{.*}}debug-info-verbose-trap.cpp"
// CHECK: ![[FILESCOPE:.*]] = !DIFile(filename: "{{.*}}verbose-trap.cpp"

char const constCat[] = "category2";
char const constMsg[] = "hello";
Expand Down
9 changes: 9 additions & 0 deletions clang/test/DebugInfo/Generic/Inputs/stdio.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
struct FILE;
extern int vfprintf(struct FILE *s, const char *format, __builtin_va_list arg);
extern int vprintf(const char *format, __builtin_va_list arg);

extern __inline __attribute__((gnu_inline,always_inline)) int
vprintf(const char *x, __builtin_va_list y)
{
return vfprintf (0, 0, y);
}
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
// RUN: mkdir -p %t/UNIQUEISH_SENTINEL
// RUN: cp %s %t/UNIQUEISH_SENTINEL/debug-info-abspath.c
// RUN: cp %s %t/UNIQUEISH_SENTINEL/abspath.c

// RUN: %clang_cc1 -debug-info-kind=limited -triple %itanium_abi_triple \
// RUN: -fdebug-compilation-dir=%t/UNIQUEISH_SENTINEL/debug-info-abspath.c \
// RUN: %t/UNIQUEISH_SENTINEL/debug-info-abspath.c -emit-llvm -o - \
// RUN: -fdebug-compilation-dir=%t/UNIQUEISH_SENTINEL/abspath.c \
// RUN: %t/UNIQUEISH_SENTINEL/abspath.c -emit-llvm -o - \
// RUN: | FileCheck %s

// RUN: cp %s %t.c
Expand All @@ -18,8 +18,8 @@ void foo(void) {}

// CHECK: = distinct !DISubprogram({{.*}}file: ![[SPFILE:[0-9]+]]
// CHECK: ![[SPFILE]] = !DIFile(filename: "{{.*}}UNIQUEISH_SENTINEL
// CHECK-SAME: debug-info-abspath.c"
// CHECK-SAME: abspath.c"
// CHECK-NOT: directory: "{{.*}}UNIQUEISH_SENTINEL

// INTREE: = distinct !DISubprogram({{.*}}![[SPFILE:[0-9]+]]
// INTREE: DIFile({{.*}}directory: "{{.+}}CodeGen{{.*}}")
// INTREE: DIFile({{.*}}directory: "{{.+}}Generic{{.*}}")
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ int main(void) { return 42; }
// CHECK: Types (.debug$T)
// CHECK: ============================================================
// CHECK: 0x[[PWD:.+]] | LF_STRING_ID [size = {{.+}}] ID: <no type>, String: [[PWDVAL:.+]]
// CHECK: 0x[[FILEPATH:.+]] | LF_STRING_ID [size = {{.+}}] ID: <no type>, String: [[FILEPATHVAL:.+[\\/]debug-info-codeview-buildinfo.c]]
// CHECK: 0x[[FILEPATH:.+]] | LF_STRING_ID [size = {{.+}}] ID: <no type>, String: [[FILEPATHVAL:.+[\\/]codeview-buildinfo.c]]
// CHECK: 0x[[ZIPDB:.+]] | LF_STRING_ID [size = {{.+}}] ID: <no type>, String:
// CHECK: 0x[[TOOL:.+]] | LF_STRING_ID [size = {{.+}}] ID: <no type>, String: [[TOOLVAL:.+[\\/][clang|llvm].*]]
// CHECK: 0x[[CMDLINE:.+]] | LF_STRING_ID [size = {{.+}}] ID: <no type>, String: "-cc1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
// CHECK-NONSENSE: nonsense

// RUN: %clang_cc1 -emit-llvm -debug-info-kind=limited %s -o - | FileCheck -check-prefix=CHECK-DIR %s
// CHECK-DIR: CodeGen
// CHECK-DIR: Generic

/// Test path remapping.
// RUN: %clang_cc1 -fdebug-compilation-dir=%S -main-file-name %s -emit-llvm -debug-info-kind=limited %s -o - | FileCheck -check-prefix=CHECK-ABS %s
// CHECK-ABS: DIFile(filename: "{{.*}}debug-info-compilation-dir.c", directory: "{{.*}}CodeGen")
// CHECK-ABS: DIFile(filename: "{{.*}}compilation-dir.c", directory: "{{.*}}Generic")

// RUN: %clang_cc1 -main-file-name %s -emit-llvm -debug-info-kind=limited %s -o - | FileCheck -check-prefix=CHECK-NOMAP %s
// CHECK-NOMAP: DIFile(filename: "{{.*}}debug-info-compilation-dir.c", directory: "")
// CHECK-NOMAP: DIFile(filename: "{{.*}}compilation-dir.c", directory: "")

File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ using std::A; using ::A;
// CHECK: [[Imports]] = !{[[ImportedEntity:![0-9]+]]}
// CHECK: [[ImportedEntity]] = !DIImportedEntity(tag: DW_TAG_imported_declaration, scope: [[CompileUnit]], entity: [[STDA:![0-9]+]], file: [[FILE:![0-9]+]], line: 4)
// CHECK: [[STDA]] = !DICompositeType(tag: DW_TAG_class_type, name: "A",
// CHECK: [[FILE]] = !DIFile(filename: {{.*}}debug-info-imported-entity.cpp
// CHECK: [[FILE]] = !DIFile(filename: {{.*}}imported-entity.cpp
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
// PCH: [[Macros]] = !{[[MainMacroFile:![0-9]+]], [[DefineC1:![0-9]+]], [[DefineA:![0-9]+]], [[UndefC1:![0-9]+]]}

// CHECK: [[MainMacroFile]] = !DIMacroFile(file: [[MainFile:![0-9]+]], nodes: [[N1:![0-9]+]])
// CHECK: [[MainFile]] = !DIFile(filename: "{{.*}}debug-info-macro.c"
// CHECK: [[MainFile]] = !DIFile(filename: "{{.*}}macro.c"
// CHECK: [[N1]] = !{[[CommandLineInclude:![0-9]+]], [[DefineD1:![0-9]+]], [[FileInclude1:![0-9]+]], [[UndefD1:![0-9]+]], [[DefineD2:![0-9]+]], [[FileInclude2:![0-9]+]], [[UndefD2:![0-9]+]]}

// CHECK: [[CommandLineInclude]] = !DIMacroFile(file: [[HeaderFile:![0-9]+]], nodes: [[N2:![0-9]+]])
Expand Down
Loading