pet_expr_extract_affine: cache result in pet_context
commit4467c0315917854658c1db7756dc67adc93465a7
authorSven Verdoolaege <skimo@kotnet.org>
Fri, 26 Feb 2016 11:18:27 +0000 (26 12:18 +0100)
committerSven Verdoolaege <skimo@kotnet.org>
Mon, 7 Mar 2016 11:13:53 +0000 (7 12:13 +0100)
tree72dec46fb52bd8d584279d9d1f52d96424afc4a3
parentfffb08848f29d6ba71126f2d6700cbdb75ec7de7
pet_expr_extract_affine: cache result in pet_context

pet_expr_extract_affine may be called several times on the same
pet_expr within the same context.  This is even more likely to
happen after changing pet to also look for affine expressions
outside accesses.
Store the result in the pet_context for later use.
The results are invalidated whenever the pet_context is changed.

Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
context.c
context.h
expr.c