This patch adds a new Ir-Ir pass in the PPC back-end that expands memcpy calls. There are 2 types of expansion added:
- calls where the size is a known compile time constant, but are large enough that we either don't want to or wont expand them with the straight line expansion.
- Expand calls where the size isn't a compile time constant.
This patch is to be followed up with a subsequent patch which will leverage pgo profiling data to make better decisions about when and under what conditions to actually perform these expansions.
I really think the debug type and the options should reflect what this pass does. Naming something lower-mem-intrinsics suggests that without it we don't lower these, which isn't entirely the case. Also, no real information is gained from statements such as "extra memcpy expansions". On the other hand, saying what this thing does is useful - such as "Expand memcpy calls into loops under specified conditions". And respectively, an option such as ppc-enable-memcpy-loops.