projects
/
platform
/
upstream
/
isl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7200ec9
)
isl_mat_scale_down: avoid trampling over aliased matrices
author
Sven Verdoolaege
<skimo@kotnet.org>
Fri, 3 Jun 2011 17:20:00 +0000
(19:20 +0200)
committer
Sven Verdoolaege
<skimo@kotnet.org>
Sat, 4 Jun 2011 11:05:34 +0000
(13:05 +0200)
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
isl_mat.c
patch
|
blob
|
history
diff --git
a/isl_mat.c
b/isl_mat.c
index
90e981f
..
4e6315c
100644
(file)
--- a/
isl_mat.c
+++ b/
isl_mat.c
@@
-1441,6
+1441,10
@@
__isl_give isl_mat *isl_mat_scale_down(__isl_take isl_mat *mat, isl_int m)
{
int i;
+ if (isl_int_is_one(m))
+ return mat;
+
+ mat = isl_mat_cow(mat);
if (!mat)
return NULL;