Commit 8eff75e0 by Richard Sandiford Committed by Richard Sandiford

Use CONST_VECTOR_ELT instead of XVECEXP

This patch replaces target-independent uses of XVECEXP with uses
of CONST_VECTOR_ELT.  This kind of replacement isn't necessary
for code specific to targets other than AArch64.

2018-01-02  Richard Sandiford  <richard.sandiford@linaro.org>

gcc/
	* simplify-rtx.c (simplify_const_binary_operation): Use
	CONST_VECTOR_ELT instead of XVECEXP.

From-SVN: r256101
parent b00cb3bf
2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
* simplify-rtx.c (simplify_const_binary_operation): Use
CONST_VECTOR_ELT instead of XVECEXP.
2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
* tree-cfg.c (verify_gimple_assign_ternary): Allow the size of
the selector elements to be different from the data elements
if the selector is a VECTOR_CST.
......@@ -4071,9 +4071,9 @@ simplify_const_binary_operation (enum rtx_code code, machine_mode mode,
gcc_assert (op0_n_elts + op1_n_elts == n_elts);
for (i = 0; i < op0_n_elts; ++i)
RTVEC_ELT (v, i) = XVECEXP (op0, 0, i);
RTVEC_ELT (v, i) = CONST_VECTOR_ELT (op0, i);
for (i = 0; i < op1_n_elts; ++i)
RTVEC_ELT (v, op0_n_elts+i) = XVECEXP (op1, 0, i);
RTVEC_ELT (v, op0_n_elts+i) = CONST_VECTOR_ELT (op1, i);
}
return gen_rtx_CONST_VECTOR (mode, v);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment