[llvm] r242387 - Make ExecutionEngine owning a DataLayout

İsmail Dönmez ismail at donmez.ws
Thu Jul 16 03:12:34 PDT 2015


Hi,

On Thu, Jul 16, 2015 at 9:17 AM, Mehdi Amini <mehdi.amini at apple.com> wrote:
> Author: mehdi_amini
> Date: Thu Jul 16 01:17:14 2015
> New Revision: 242387
>
> URL: http://llvm.org/viewvc/llvm-project?rev=242387&view=rev
> Log:
> Make ExecutionEngine owning a DataLayout
>
> Summary:
> This change is part of a series of commits dedicated to have a single
> DataLayout during compilation by using always the one owned by the
> module.
>
> The ExecutionEngine will act as an exception and will be unsafe to
> be reused across context. We don't enforce this rule but undefined
> behavior can occurs if the user tries to do it.
>
> Reviewers: lhames
>
> Subscribers: echristo, llvm-commits, rafael, yaron.keren
>
> Differential Revision: http://reviews.llvm.org/D11110
>
> From: Mehdi Amini <mehdi.amini at apple.com>
>
> Modified:
>     llvm/trunk/include/llvm/ExecutionEngine/ExecutionEngine.h
>     llvm/trunk/lib/ExecutionEngine/ExecutionEngine.cpp
>     llvm/trunk/lib/ExecutionEngine/ExecutionEngineBindings.cpp
>     llvm/trunk/lib/ExecutionEngine/Interpreter/Execution.cpp
>     llvm/trunk/lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp
>     llvm/trunk/lib/ExecutionEngine/Interpreter/Interpreter.cpp
>     llvm/trunk/lib/ExecutionEngine/Interpreter/Interpreter.h
>     llvm/trunk/lib/ExecutionEngine/MCJIT/MCJIT.cpp
>     llvm/trunk/lib/ExecutionEngine/Orc/OrcMCJITReplacement.h

On Linux x86-64:

../lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp:277:21:
error: no matching function for call to 'ffiInvoke'
  if (RawFn != 0 && ffiInvoke(RawFn, F, ArgVals, getDataLayout(), Result))
                               ^~~~~~~~~
../lib/ExecutionEngine/Interpreter/ExternalFunctions.cpp:180:13: note:
candidate function not viable: no known conversion from 'const
llvm::DataLayout' to 'const llvm::DataLayout *' for 4th argument; take
the address of the argument with &
static bool ffiInvoke(RawFunc Fn, Function *F, ArrayRef<GenericValue> ArgVals,
                 ^
1 error generated.



More information about the llvm-commits mailing list