From 8558c2e8babef01ff8c40f841b7ca59a5610f033 Mon Sep 17 00:00:00 2001 From: Sven Verdoolaege Date: Fri, 4 Oct 2013 16:40:18 +0200 Subject: [PATCH] add isl_map_preimage_range_multi_aff Signed-off-by: Sven Verdoolaege --- doc/user.pod | 3 +++ include/isl/map.h | 2 ++ isl_map.c | 12 ++++++++++++ 3 files changed, 17 insertions(+) diff --git a/doc/user.pod b/doc/user.pod index c42dbfe1..506adcf2 100644 --- a/doc/user.pod +++ b/doc/user.pod @@ -3084,6 +3084,9 @@ a parametric set as well. __isl_give isl_map *isl_map_preimage_domain_multi_aff( __isl_take isl_map *map, __isl_take isl_multi_aff *ma); + __isl_give isl_map *isl_map_preimage_range_multi_aff( + __isl_take isl_map *map, + __isl_take isl_multi_aff *ma); __isl_give isl_map * isl_map_preimage_domain_pw_multi_aff( __isl_take isl_map *map, diff --git a/include/isl/map.h b/include/isl/map.h index 465e7244..787fa156 100644 --- a/include/isl/map.h +++ b/include/isl/map.h @@ -354,6 +354,8 @@ __isl_give isl_map *isl_map_apply_range( __isl_take isl_map *map2); __isl_give isl_map *isl_map_preimage_domain_multi_aff(__isl_take isl_map *map, __isl_take isl_multi_aff *ma); +__isl_give isl_map *isl_map_preimage_range_multi_aff(__isl_take isl_map *map, + __isl_take isl_multi_aff *ma); __isl_give isl_map *isl_map_preimage_domain_pw_multi_aff( __isl_take isl_map *map, __isl_take isl_pw_multi_aff *pma); __isl_give isl_map *isl_map_preimage_range_pw_multi_aff( diff --git a/isl_map.c b/isl_map.c index fc00e865..c29edce7 100644 --- a/isl_map.c +++ b/isl_map.c @@ -12184,6 +12184,18 @@ __isl_give isl_map *isl_map_preimage_domain_multi_aff(__isl_take isl_map *map, return isl_map_preimage_multi_aff(map, isl_dim_in, ma); } +/* Compute the preimage of the range of "map" under the function + * represented by "ma". + * In other words, plug in "ma" in the range of "map". + * The result is a map that lives in the same space as "map" + * except that the range has been replaced by the domain space of "ma". + */ +__isl_give isl_map *isl_map_preimage_range_multi_aff(__isl_take isl_map *map, + __isl_take isl_multi_aff *ma) +{ + return isl_map_preimage_multi_aff(map, isl_dim_out, ma); +} + /* Compute the preimage of "map" under the function represented by "pma". * In other words, plug in "pma" in the domain or range of "map". * The result is a map that lives in the same space as "map", -- 2.11.4.GIT