Fix memcpy mishandling in parameter SROA. (#2281)
LowerMemcpy tries to see if a variable is only written to by a single memcpy. There is a special case for llvm::Arguments, since arguments have an implicit first write for their initialization in addition to whatever memcpy they might have. During parameter SROA, aggregate arguments get broken down into their constituing elements as plateholder AllocaInsts, and at the end of the pass they'll get promoted back into llvm::Arguments of the SROA'd function. In the intermediate steps, however, a test for isa<Argument> will fail to detect that an AllocaInst is a placeholder for a future argument, and so its implicit initialization will not be taken into account. This would cause a bad ReplaceMemcpy, yielding reads from uninitialized locals, causing undefs and all of that fun stuff.