Considering all the SCoPs in the program

21 views
Skip to first unread message

Arsalan

unread,
Feb 16, 2023, 5:09:33 AM2/16/23
to Polly Development
Hello

I want to do a bit of analysis and need to consider all of the scops of the program. Therefore, instead of using ScopPass, I have to use FunctionPass but now I can't get the polyhedral statement which contain the name, domain, Schedule, and access relation. I tried to use "ScopInfoWrapperPass" but no luck.
So, how can I extract the aforementioned parameters of polyhedral statement while using FunctionPass?

Michael Kruse

unread,
Feb 17, 2023, 12:43:23 AM2/17/23
to Arsalan, Polly Development
It depends on whether your are using the legacy or new pass manager. ScopInfoWrapperPass suggests you are using the legacy pass manager. Not that support for it is slowly being removed.

The legacy pass manager does not directly support using passes of smaller units (E.g. a ModulePass cannot depend on a FunctionPass). However, what can be done is to run your own pass manager within your own pass. See PollyCanonicalize::runOnModule on how this can be done. Then from that pass manager, add the ScopDetectionWrapperPass pass enumerate all SCoPs in the function.

ScopInfoWrapperPass should theoretically work as well to just enumerate the SCoPs, but all other passes assume the ScopPass-based approach, and won't work with the FunctionPass-based one. Unfortunately you did not write what did not work for you.

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/223e2155-a09e-46b7-988d-0a2d2d74571en%40googlegroups.com.


--
Tardyzentrismus verboten!

Arsalan

unread,
Feb 17, 2023, 3:08:34 AM2/17/23
to Polly Development
Yes, I used the legacy pass manager and that is why I tried ScopInfoWrapperPass.I had difficulties using ScopInfoWrapperPass and then using ScopInfo to get the Scop because it required the Region to return the Scop, but I wanted to consider all of the Scops in a program together. I try to use ScopDetectionWrapperPass.
Thank you, Michael

Arsalan

unread,
Feb 17, 2023, 7:32:27 AM2/17/23
to Polly Development
The reason that I want to consider all of the Scops together is that I want to count the number of accesses to each array element or memory location of all the Scops in a program. are there specific functions for this or should I implement it?
Reply all
Reply to author
Forward
0 new messages