diff options
author | Richard Sandiford <richard.sandiford@linaro.org> | 2017-08-21 09:51:14 +0000 |
---|---|---|
committer | Richard Sandiford <rsandifo@gcc.gnu.org> | 2017-08-21 09:51:14 +0000 |
commit | 9f33a5d9acbed950bf446849e9d6968cf22cb9a2 (patch) | |
tree | a9ed53967318f72eaa0abd88f2b9a81fcd2a139e /gcc/read-md.h | |
parent | 38fbc003332134ef0a04d319fb71b297f67c6988 (diff) | |
download | gcc-9f33a5d9acbed950bf446849e9d6968cf22cb9a2.zip gcc-9f33a5d9acbed950bf446849e9d6968cf22cb9a2.tar.gz gcc-9f33a5d9acbed950bf446849e9d6968cf22cb9a2.tar.bz2 |
Pass rtx and index to read-md.c iterator routines
The read-md.c iterator callbacks previously used a void * to record the
position at which the iterator value should be installed. This doesn't
scale easily to the SUBREG_BYTE representation used by a later patch,
so this patch replaces the void * with both an rtx and an operand
number. The operand number is ignored for modes and codes.
2017-08-21 Richard Sandiford <richard.sandiford@linaro.org>
Alan Hayward <alan.hayward@arm.com>
David Sherwood <david.sherwood@arm.com>
gcc/
* read-md.h (md_reader::record_potential_iterator_use): Replace
pointer argument with an rtx and an index.
* read-rtl.c (iterator_group::apply_iterator): Likewise.
(apply_mode_iterator): Likewise.
(apply_code_iterator): Likewise.
(apply_int_iterator): Likewise.
(apply_subst_iterator): Likewise.
(record_iterator_use): Likewise.
(record_attribute_use): Likewise.
(md_reader::record_potential_iterator_use): Likewise. Update calls
to record_iterator_use and apply_iterator.
(iterator_use): Replace ptr with x and index.
(attribute_use): Likewise.
(apply_attribute_uses): Update calls to apply_iterator.
(apply_iterators): Likewise. Update initialization of iterator_use.
(rtx_reader::read_rtx_code): Update calls to record_iterator_use
and record_potential_iterator_use.
(rtx_reader::read_rtx_operand): Likewise.
Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r251219
Diffstat (limited to 'gcc/read-md.h')
-rw-r--r-- | gcc/read-md.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/read-md.h b/gcc/read-md.h index fea7011..9791ac2 100644 --- a/gcc/read-md.h +++ b/gcc/read-md.h @@ -162,7 +162,8 @@ class md_reader rtx copy_rtx_for_iterators (rtx original); void read_conditions (); void record_potential_iterator_use (struct iterator_group *group, - void *ptr, const char *name); + rtx x, unsigned int index, + const char *name); struct mapping *read_mapping (struct iterator_group *group, htab_t table); const char *get_top_level_filename () const { return m_toplevel_fname; } |