[llvm] r216427 - ExecutionEngine: address review comments
Eric Christopher
echristo at gmail.com
Tue Sep 2 10:33:51 PDT 2014
A more descriptive commit message is helpful here in the future.
Thanks!
-eric
On Mon, Aug 25, 2014 at 7:03 PM, Dylan Noblesmith <nobled at dreamwidth.org>
wrote:
> Author: nobled
> Date: Mon Aug 25 21:03:28 2014
> New Revision: 216427
>
> URL: http://llvm.org/viewvc/llvm-project?rev=216427&view=rev
> Log:
> ExecutionEngine: address review comments
>
> Modified:
> llvm/trunk/lib/ExecutionEngine/ExecutionEngine.cpp
>
> Modified: llvm/trunk/lib/ExecutionEngine/ExecutionEngine.cpp
> URL:
> http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/ExecutionEngine/ExecutionEngine.cpp?rev=216427&r1=216426&r2=216427&view=diff
>
> ==============================================================================
> --- llvm/trunk/lib/ExecutionEngine/ExecutionEngine.cpp (original)
> +++ llvm/trunk/lib/ExecutionEngine/ExecutionEngine.cpp Mon Aug 25 21:03:28
> 2014
> @@ -277,17 +277,16 @@ void *ArgvArray::reset(LLVMContext &C, E
>
> for (unsigned i = 0; i != InputArgv.size(); ++i) {
> unsigned Size = InputArgv[i].size()+1;
> - auto DestOwner = make_unique<char[]>(Size);
> - char *Dest = DestOwner.get();
> - Values.push_back(std::move(DestOwner));
> - DEBUG(dbgs() << "JIT: ARGV[" << i << "] = " << (void*)Dest << "\n");
> + auto Dest = make_unique<char[]>(Size);
> + DEBUG(dbgs() << "JIT: ARGV[" << i << "] = " << (void*)Dest.get() <<
> "\n");
>
> - std::copy(InputArgv[i].begin(), InputArgv[i].end(), Dest);
> + std::copy(InputArgv[i].begin(), InputArgv[i].end(), Dest.get());
> Dest[Size-1] = 0;
>
> // Endian safe: Array[i] = (PointerTy)Dest;
> - EE->StoreValueToMemory(PTOGV(Dest),
> (GenericValue*)(&Array[i*PtrSize]),
> - SBytePtr);
> + EE->StoreValueToMemory(PTOGV(Dest.get()),
> + (GenericValue*)(&Array[i*PtrSize]), SBytePtr);
> + Values.push_back(std::move(Dest));
> }
>
> // Null terminate it
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140902/6c94d8a2/attachment.html>
More information about the llvm-commits
mailing list