This pass converts multiple consecutive loads and stores inside a loop to memcpy operation.
For example, the stores and loads in the below code can be converted to a memcpy .
struct foo
{
int a; int b;
} f,g;
for(int i=0;i<n;i++)
{
f[i].a = g[i].a; f[i].b = g[i].b;
}
Worked in collaboration with Sebastian Pop and Aditya Kumar.