-
Notifications
You must be signed in to change notification settings - Fork 15.1k
Closed as not planned
Labels
bugzillaIssues migrated from bugzillaIssues migrated from bugzillaincompleteIssue not complete (e.g. missing a reproducer, build arguments, etc.)Issue not complete (e.g. missing a reproducer, build arguments, etc.)llvm:optimizations
Description
| Bugzilla Link | 11241 |
| Version | trunk |
| OS | Linux |
| Attachments | Testcase |
| CC | @chandlerc,@nlewycky |
Extended Description
This IR:
%alloc2 = tail call noalias i8* @​_Znwm(i64 8) nounwind
%add = getelementptr inbounds i8* %alloc2, i64 4
%always_false = icmp eq i8* %add, null
ret i1 %always_false
... is collapsed to "ret i1 0". However, this IR:
%alloc2 = tail call noalias i8* @​_Znwm(i64 8) nounwind
%add = getelementptr inbounds i8* %alloc2, i64 4
%always_false = icmp eq i8* %add, null
br i1 %always_false, label %skipinit2, label %init2
init2: ; preds = %entry
store i8 1, i8* %alloc2, align 1
ret void
skipinit2: ; preds = %entry
ret void
... is not optimized any further.
Metadata
Metadata
Assignees
Labels
bugzillaIssues migrated from bugzillaIssues migrated from bugzillaincompleteIssue not complete (e.g. missing a reproducer, build arguments, etc.)Issue not complete (e.g. missing a reproducer, build arguments, etc.)llvm:optimizations