"Lower aggregate copies and memset, memcpy, and memmov intrinsics"?
"lower to" rather than "lower into"?
We don't actually have explicit code here for lowering aggregate copies; maybe we should change that bit.
From the impl we don't seem to "expand", "convert", or really do much of anything with ConvertedInst. Should we call it "InsertBefore/After"?
Seems like this one should be called createMemcpyLoop, createCopyLoop or something, while the other is called convertMemcpyToLoop. I would probably also swap the collation order.
Do we really need these utilities for creating memmov and memset loops? I guess they're kind of useful, but if nobody is using them our code isn't tested or anything, so maybe it's better to leave them out for now?
If you wanted, you could keep these functions as file-private in the cc file. This way if we ever want to make them public, it's straightforward.
I only left these because the NVPTX pass uses the memcpy function for the questionable handling of aggregate copies, and then kept it the same for the others. I can make them private.
NVPTX pass uses the memcpy function for the questionable handling of aggregate copies
lol, but tell me what you really think. :)
Reading it again, there are still some vestiges of where this file came from in this comment. Maybe