[C++] Fix __builtin_shuffle

Jason Merrill jason@redhat.com
Wed Jun 26 20:56:00 GMT 2013


On 06/09/2013 07:09 AM, Marc Glisse wrote:
> +      arg0 = build_non_dependent_expr (arg0);
> +      arg1 = build_non_dependent_expr (arg1);
> +      arg2 = build_non_dependent_expr (arg2);
> +    }
> +  return c_build_vec_perm_expr (loc, arg0, arg1, arg2, complain & tf_error);

This is wrong; the places in the compiler that currently use 
build_non_dependent_expr only use the result temporarily for determining 
the type of the expression, but then use the original arguments for 
building the return value.

Jason



More information about the Gcc-patches mailing list