[Beignet] [PATCH] Fix a scalarize pass bug.

Zhigang Gong zhigang.gong at linux.intel.com
Wed May 22 19:31:59 PDT 2013


Thanks for the quick fix, I will push it soon.

It seems this fix is also valid for the original project. It forget
to clear those per function/kernel objects.


On Wed, May 22, 2013 at 04:49:06PM +0800, Yang Rong wrote:
> Need to clear vectors and maps after finish one function.
> 
> Signed-off-by: Yang Rong <rong.r.yang at intel.com>
> ---
>  backend/src/llvm/llvm_scalarize.cpp |    3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/backend/src/llvm/llvm_scalarize.cpp b/backend/src/llvm/llvm_scalarize.cpp
> index f71401f..f7ef375 100644
> --- a/backend/src/llvm/llvm_scalarize.cpp
> +++ b/backend/src/llvm/llvm_scalarize.cpp
> @@ -798,6 +798,9 @@ namespace gbe {
>  
>      dce();
>  
> +    incompletePhis.clear();
> +    vectorVals.clear();
> +
>      delete builder;
>      builder = 0;
>  
> -- 
> 1.7.9.5
> 
> _______________________________________________
> Beignet mailing list
> Beignet at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/beignet


More information about the Beignet mailing list