[Beignet] [PATCH V2 1/3] reset the SPIR target datalayout.

Zhigang Gong zhigang.gong at linux.intel.com
Sun Mar 15 19:26:12 PDT 2015


LGTM, pushed. Thanks.

On Fri, Mar 13, 2015 at 04:32:39PM +0800, xionghu.luo at intel.com wrote:
> From: Luo Xionghu <xionghu.luo at intel.com>
> 
> v2: split to a seperate patch.
> Signed-off-by: Luo Xionghu <xionghu.luo at intel.com>
> ---
>  backend/src/llvm/llvm_bitcode_link.cpp | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/backend/src/llvm/llvm_bitcode_link.cpp b/backend/src/llvm/llvm_bitcode_link.cpp
> index 17248c0..3bf9613 100644
> --- a/backend/src/llvm/llvm_bitcode_link.cpp
> +++ b/backend/src/llvm/llvm_bitcode_link.cpp
> @@ -237,6 +237,10 @@ namespace gbe
>        kernels.push_back(f);
>      }
>  
> +    /* the SPIR binary datalayout maybe different with beignet's bitcode */
> +    if(clonedLib->getDataLayout() != mod->getDataLayout())
> +      mod->setDataLayout(clonedLib->getDataLayout());
> +
>      /* We use beignet's bitcode as dst because it will have a lot of
>         lazy functions which will not be loaded. */
>      char* errorMsg;
> -- 
> 1.9.1
> 
> _______________________________________________
> Beignet mailing list
> Beignet at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/beignet


More information about the Beignet mailing list