aboutsummaryrefslogtreecommitdiff
path: root/gcc/print-rtl.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/print-rtl.c')
-rw-r--r--gcc/print-rtl.c32
1 files changed, 31 insertions, 1 deletions
diff --git a/gcc/print-rtl.c b/gcc/print-rtl.c
index c7982bc..081fc50 100644
--- a/gcc/print-rtl.c
+++ b/gcc/print-rtl.c
@@ -370,6 +370,10 @@ rtx_writer::print_rtx_operand_codes_E_and_V (const_rtx in_rtx, int idx)
print_rtx_head, m_indent * 2, "");
m_sawclose = 0;
}
+ if (GET_CODE (in_rtx) == CONST_VECTOR
+ && !GET_MODE_NUNITS (GET_MODE (in_rtx)).is_constant ()
+ && CONST_VECTOR_DUPLICATE_P (in_rtx))
+ fprintf (m_outfile, " repeat");
fputs (" [", m_outfile);
if (XVEC (in_rtx, idx) != NULL)
{
@@ -377,12 +381,32 @@ rtx_writer::print_rtx_operand_codes_E_and_V (const_rtx in_rtx, int idx)
if (XVECLEN (in_rtx, idx))
m_sawclose = 1;
+ int barrier = XVECLEN (in_rtx, idx);
+ if (GET_CODE (in_rtx) == CONST_VECTOR
+ && !GET_MODE_NUNITS (GET_MODE (in_rtx)).is_constant ())
+ barrier = CONST_VECTOR_NPATTERNS (in_rtx);
+
for (int j = 0; j < XVECLEN (in_rtx, idx); j++)
{
int j1;
+ if (j == barrier)
+ {
+ fprintf (m_outfile, "\n%s%*s",
+ print_rtx_head, m_indent * 2, "");
+ if (!CONST_VECTOR_STEPPED_P (in_rtx))
+ fprintf (m_outfile, "repeat [");
+ else if (CONST_VECTOR_NPATTERNS (in_rtx) == 1)
+ fprintf (m_outfile, "stepped [");
+ else
+ fprintf (m_outfile, "stepped (interleave %d) [",
+ CONST_VECTOR_NPATTERNS (in_rtx));
+ m_indent += 2;
+ }
+
print_rtx (XVECEXP (in_rtx, idx, j));
- for (j1 = j + 1; j1 < XVECLEN (in_rtx, idx); j1++)
+ int limit = MIN (barrier, XVECLEN (in_rtx, idx));
+ for (j1 = j + 1; j1 < limit; j1++)
if (XVECEXP (in_rtx, idx, j) != XVECEXP (in_rtx, idx, j1))
break;
@@ -393,6 +417,12 @@ rtx_writer::print_rtx_operand_codes_E_and_V (const_rtx in_rtx, int idx)
}
}
+ if (barrier < XVECLEN (in_rtx, idx))
+ {
+ m_indent -= 2;
+ fprintf (m_outfile, "\n%s%*s]", print_rtx_head, m_indent * 2, "");
+ }
+
m_indent -= 2;
}
if (m_sawclose)