summaryrefslogtreecommitdiff
path: root/test/Feature/newcasts.ll
diff options
context:
space:
mode:
authorReid Spencer <rspencer@reidspencer.com>2006-12-18 01:11:46 +0000
committerReid Spencer <rspencer@reidspencer.com>2006-12-18 01:11:46 +0000
commit0be3ed886c9c22f48f16694268e01cc9ab8d6f0f (patch)
tree508de8f6652db0c8d23a506855234ead31714538 /test/Feature/newcasts.ll
parentd54d8fa45a1f189580934259fcac3fc3c663810e (diff)
downloadllvm-0be3ed886c9c22f48f16694268e01cc9ab8d6f0f.tar.gz
llvm-0be3ed886c9c22f48f16694268e01cc9ab8d6f0f.tar.bz2
llvm-0be3ed886c9c22f48f16694268e01cc9ab8d6f0f.tar.xz
Add a couple little tests for SExt/ZExt of constants of a sign that doesn't
match. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32647 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Feature/newcasts.ll')
-rw-r--r--test/Feature/newcasts.ll7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/Feature/newcasts.ll b/test/Feature/newcasts.ll
index 6b297961aa..00919d180d 100644
--- a/test/Feature/newcasts.ll
+++ b/test/Feature/newcasts.ll
@@ -19,3 +19,10 @@ void "NewCasts" (short %x) {
}
+ushort "ZExtConst" () {
+ ret ushort trunc ( uint zext ( short 42 to uint) to ushort )
+}
+
+short "SExtConst" () {
+ ret short trunc (int sext (ushort 42 to int) to short )
+}