Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[SCCP] Fold constants as we build them whne visiting cast instructions.
This should be slightly more efficient and could avoid spurious overdefined markings, as Eli pointed out. Differential Revision: http://reviews.llvm.org/D22122 llvm-svn: 274905
- Loading branch information
Showing
2 changed files
with
13 additions
and
2 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
; RUN: opt < %s -ipsccp -S | FileCheck %s | ||
|
||
define i128 @vector_to_int_cast() { | ||
%A = bitcast <4 x i32> <i32 1073741824, i32 1073741824, i32 1073741824, i32 1073741824> to i128 | ||
ret i128 %A | ||
} | ||
|
||
; CHECK: define i128 @vector_to_int_cast( | ||
; CHECK-NEXT: ret i128 85070591750041656499021422275829170176 |