projects
/
ghc-hetmet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3dca032
)
Vectorise case of unit correctly
author
Roman Leshchinskiy
<rl@cse.unsw.edu.au>
Wed, 5 Dec 2007 22:13:05 +0000
(22:13 +0000)
committer
Roman Leshchinskiy
<rl@cse.unsw.edu.au>
Wed, 5 Dec 2007 22:13:05 +0000
(22:13 +0000)
compiler/vectorise/Vectorise.hs
patch
|
blob
|
history
diff --git
a/compiler/vectorise/Vectorise.hs
b/compiler/vectorise/Vectorise.hs
index
d85ef6a
..
1b7bca0
100644
(file)
--- a/
compiler/vectorise/Vectorise.hs
+++ b/
compiler/vectorise/Vectorise.hs
@@
-337,6
+337,14
@@
vectAlgCase tycon ty_args scrut bndr ty [(DEFAULT, [], body)]
(vbndr, vbody) <- vectBndrIn bndr (vectExpr body)
return $ vCaseDEFAULT vscrut vbndr vty lty vbody
+vectAlgCase tycon ty_args scrut bndr ty [(DataAlt dc, [], body)]
+ = do
+ vscrut <- vectExpr scrut
+ vty <- vectType ty
+ lty <- mkPArrayType vty
+ (vbndr, vbody) <- vectBndrIn bndr (vectExpr body)
+ return $ vCaseDEFAULT vscrut vbndr vty lty vbody
+
vectAlgCase tycon ty_args scrut bndr ty [(DataAlt dc, bndrs, body)]
= do
vect_tc <- maybeV (lookupTyCon tycon)