This patch is intended as a preparation to teach polly interprocedural analysis.
The reason we want to have polly passes run in CGSCC scope instead of function scope is the deterministic iteration order over functions: To be able to "look into" a region's callees, we ideally want ScopInfo to be already available for every callee. The CGSCC AnalysisManager ensures this - except for callees which are part of the analyzed function's SCC. But we aren't interested in those anyways. For that matter, the differential's most important part is the change from FunctionToScopPassAdaptor to CGSCCToScopPassAdaptor and buildDefaultPollyPipeline taking a CGSCC-AM now instead of a Function-AM.
However, this differential also includes some further CGSCC-related changes to prepare for upcoming patches: In RegisterPasses.cpp we add a parseCGSCCPipeline callback, allowing us to run the ScopInfoPrinterPass in a CGSCC-pipeline as well (making no difference at the moment, but using the CGSCC_PASS macro in PollyPasses.def).
Regarding tests: @philip.pfaffe is currently working on porting the existing lit test-suite to the new passmanager. I would suggest waiting for this effort to be complete before I add any more tests to the repo. That being said, I am not opposed to doing so if asked.
I apologize for the seemingly unnecessary small changes (e.g. renaming FAM->AM), but we had a lot of code churn while developing our IPO changes, and I didn't think it important enough to waste time reverting them again.
Unrelated change