repo.or.cz
/
llvm-project.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Bump version to 19.1.0-rc3
[llvm-project.git]
/
llvm
/
test
/
Analysis
/
ScalarEvolution
/
undefined.ll
blob
93ecf28dc65b23cdb2fb2494d0b53ea04373d0eb
1
; RUN: opt -disable-output "-passes=print<scalar-evolution>" < %s 2>&1 | FileCheck %s
2
3
; ScalarEvolution shouldn't attempt to interpret expressions which have
4
; undefined results.
5
6
define void @foo(i64 %x) {
7
8
%a = udiv i64 %x, 0
9
; CHECK: --> (%x /u 0)
10
11
%B = shl i64 %x, 64
12
; CHECK: --> %B
13
14
%b = ashr i64 %B, 64
15
; CHECK: --> %b
16
17
%c = lshr i64 %x, 64
18
; CHECK: --> %c
19
20
%d = shl i64 %x, 64
21
; CHECK: --> %d
22
23
%E = shl i64 %x, -1
24
; CHECK: --> %E
25
26
%e = ashr i64 %E, -1
27
; CHECK: --> %e
28
29
%f = lshr i64 %x, -1
30
; CHECK: --> %f
31
32
%g = shl i64 %x, -1
33
; CHECK: --> %g
34
35
%h = bitcast i64 undef to i64
36
; CHECK: --> undef
37
38
ret void
39
}