Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Debug info: Fixed faulty debug locations for attributed statements
Summary: As the attributed statements are considered simple statements no stoppoint was generated before emitting attributed do/while/for/range- statement. This lead to faulty debug locations. Reviewers: echristo, aaron.ballman, dblaikie Reviewed By: dblaikie Subscribers: bjope, aprantl, cfe-commits Differential Revision: https://reviews.llvm.org/D37428 llvm-svn: 312623
- Loading branch information
Showing
3 changed files
with
24 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
// RUN: %clang_cc1 -triple x86_64-unk-unk -debug-info-kind=limited -emit-llvm %s -o - | FileCheck %s | ||
|
||
void f(_Bool b) | ||
{ | ||
#pragma nounroll | ||
while (b); | ||
} | ||
|
||
// CHECK: br label %while.cond, !dbg ![[NUM:[0-9]+]] | ||
// CHECK: br i1 %tobool, label %while.body, label %while.end, !dbg ![[NUM]] | ||
// CHECK: br label %while.cond, !dbg ![[NUM]], !llvm.loop | ||
// CHECK: ![[NUM]] = !DILocation(line: 6, |