isl_union_map.c: un_op: implement in terms of cond_un_op and rename to total
commitd3bdeba6553fd2e8b97e4c3f41a4580ba68fd9ba
authorSven Verdoolaege <skimo@kotnet.org>
Wed, 1 Mar 2017 17:47:44 +0000 (1 18:47 +0100)
committerSven Verdoolaege <sven.verdoolaege@gmail.com>
Wed, 17 May 2017 08:15:52 +0000 (17 10:15 +0200)
treee1d849018597f441677f298cebc7b077945ac492
parent6dd3a044b77f58997f0cc70e479f5f80fe6041fc
isl_union_map.c: un_op: implement in terms of cond_un_op and rename to total

un_op is used for functions that can be applied in-place, provided
there is only a single reference.  The original implementation of un_op
makes sure there is a single reference and then applies the transformation
in-place.  Since cond_un_op supports both in-place modification and
creating a new union map, they can both be exploited by un_op depending
on whether the original union map only had one reference.
That is, instead of calling isl_union_map_cow, cond_un_op checks
whether there is only a single references and, if so, performance
the computation in-place.
The name is changed because the original name did not clearly
reflect the difference with cond_un_op.  Besides, now that cond_un_op
handles all cases, it will be renamed to un_op in the next commit.

Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
isl_union_map.c