Hi Harish C,
the paper you are referring to does not use Polly. Did you consider
contacting the authors directly? If your question is how to do in isl
what the authors did in PolyLib, consider the isl mailing list
(https://groups.google.com/g/isl-development).
Michael
> --
> You received this message because you are subscribed to the Google Groups "Polly Development" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to polly-dev+...@googlegroups.com.
> To view this discussion on the web, visit https://groups.google.com/d/msgid/polly-dev/0e3503cb-6c9d-45f2-aebe-b0cced19c770n%40googlegroups.com.
--
Tardyzentrismus verboten!
:: isl ast :: main :: %for.body---%for.end if (1) for (int c0 = 0; c0 <= 1023; c0 += 4) { //loop1 for (int c1 = 0; c1 <= 3; c1 += 1) //loop2 Stmt0(c0 + c1); } else { /* original code */ }
Statements { Stmt6 Domain := { Stmt6[i0, i1] : 0 <= i0 <= 255 and 0 <= i1 <= 3 }; Schedule := { Stmt6[i0, i1] -> [i0, i1] }; MustWriteAccess := [Reduction Type: NONE] [Scalar: 0] { Stmt6[i0, i1] -> MemRef0[4i0 + i1] }; Instructions { %p_conv = sitofp i32 %2 to float store float %p_conv, float* %scevgep, align 4, !alias.scope !2, !noalias !4 } }
{ MemRef0[i0] : i0 >= 0 and i0 <= 1023 }
if (1) for (int c0 = 0; c0 <= 1023; c0 += 4) { //loop1 //calculate data access required for loop2
//{ MemRef0[i0] : i0 >= c0 and i0 <= c0+4 } for (int c1 = 0; c1 <= 3; c1 += 1) //loop2 Stmt0(c0 + c1); } else { /* original code */ }
Questions:
I've tried your suggestions and have a few more questions.1. Does isl_ast_build_expr_from_pw_aff work only on sets? When I tried it on the map, I got a "spaces don't match" error.
2. So, I tried to get bounds by just taking the range(MemRef0) of below map:{i0→MemRef0(o0)∣0≤i0≤255∧4i0≤o0≤3+4i0}Dump:{ [i0] -> MemRef0[o0] : i0 >= 0 and i0 <= 255 and o0 >= 4i0 and o0 <= 3 + 4i0 }
i64 0 ; lower bound
i64 1023 ; upper bound
3. I was expecting in terms of i0, something like below: Is it possible?lower bound : 4*i0upper bound : 3+4*i0
To give you more context, I'm writing a pass to utilize scratchpad memory. Since the capacity is limited, I planned to move just the required data for a single iteration. In the above example, I'll move data between MemRef0[4*i0] and MemRef0[3+4*i0] for the iteration i0.