c-typeck.c (c_build_vec_shuffle_expr): Fix uninitialized variable.
* c-typeck.c (c_build_vec_shuffle_expr): Fix uninitialized variable. Avoid save_expr unless two_arguments. From-SVN: r179525
This commit is contained in:
parent
73f0503101
commit
75799b9884
|
@ -1,3 +1,8 @@
|
|||
2011-10-04 Richard Henderson <rth@redhat.com>
|
||||
|
||||
* c-typeck.c (c_build_vec_shuffle_expr): Fix uninitialized variable.
|
||||
Avoid save_expr unless two_arguments.
|
||||
|
||||
2011-10-04 Ozkan Sezer <sezeroz@gmail.com>
|
||||
|
||||
* config/i386/mingw-w64.h (CPP_SPEC): Rename _REENTRANCE to
|
||||
|
|
|
@ -2859,10 +2859,10 @@ build_function_call_vec (location_t loc, tree function, VEC(tree,gc) *params,
|
|||
tree
|
||||
c_build_vec_shuffle_expr (location_t loc, tree v0, tree v1, tree mask)
|
||||
{
|
||||
tree vec_shuffle, tmp;
|
||||
tree vec_shuffle;
|
||||
bool wrap = true;
|
||||
bool maybe_const = false;
|
||||
bool two_arguments;
|
||||
bool two_arguments = false;
|
||||
|
||||
if (v1 == NULL_TREE)
|
||||
{
|
||||
|
@ -2916,17 +2916,16 @@ c_build_vec_shuffle_expr (location_t loc, tree v0, tree v1, tree mask)
|
|||
}
|
||||
|
||||
/* Avoid C_MAYBE_CONST_EXPRs inside VEC_SHUFFLE_EXPR. */
|
||||
tmp = c_fully_fold (v0, false, &maybe_const);
|
||||
v0 = save_expr (tmp);
|
||||
v0 = c_fully_fold (v0, false, &maybe_const);
|
||||
wrap &= maybe_const;
|
||||
|
||||
if (!two_arguments)
|
||||
if (two_arguments)
|
||||
v1 = v0 = save_expr (v0);
|
||||
else
|
||||
{
|
||||
v1 = c_fully_fold (v1, false, &maybe_const);
|
||||
wrap &= maybe_const;
|
||||
}
|
||||
else
|
||||
v1 = v0;
|
||||
|
||||
mask = c_fully_fold (mask, false, &maybe_const);
|
||||
wrap &= maybe_const;
|
||||
|
|
Loading…
Reference in New Issue