| Index: lib/Transforms/NaCl/ExpandVarArgs.cpp
|
| diff --git a/lib/Transforms/NaCl/ExpandVarArgs.cpp b/lib/Transforms/NaCl/ExpandVarArgs.cpp
|
| index cbafbc275741af9a60b8fc59715cd01131412c6e..d3a271627319474dbc6fa7a8636793420ee02b88 100644
|
| --- a/lib/Transforms/NaCl/ExpandVarArgs.cpp
|
| +++ b/lib/Transforms/NaCl/ExpandVarArgs.cpp
|
| @@ -87,6 +87,11 @@ static void ExpandVarArgFunc(Function *Func) {
|
| NewFunc->getBasicBlockList().splice(NewFunc->begin(),
|
| Func->getBasicBlockList());
|
|
|
| + // Declare the new argument as "noalias".
|
| + NewFunc->setAttributes(
|
| + Func->getAttributes().addAttribute(
|
| + Func->getContext(), FTy->getNumParams() + 1, Attribute::NoAlias));
|
| +
|
| // Move the arguments across to the new function.
|
| for (Function::arg_iterator Arg = Func->arg_begin(), E = Func->arg_end(),
|
| NewArg = NewFunc->arg_begin();
|
|
|