diff options
author | Trevor Saunders <tbsaunde@tbsaunde.org> | 2021-07-12 02:55:17 -0400 |
---|---|---|
committer | Trevor Saunders <tbsaunde@tbsaunde.org> | 2021-07-15 01:10:47 -0400 |
commit | 8d76ff99220c7aa428516e93998457dbe299f037 (patch) | |
tree | d45fe4868eed25ad00ab6be6167b613c84134ae4 /gcc/cfgexpand.c | |
parent | 329769b72001dcca18a120ab751f58de1b716ff8 (diff) | |
download | gcc-8d76ff99220c7aa428516e93998457dbe299f037.zip gcc-8d76ff99220c7aa428516e93998457dbe299f037.tar.gz gcc-8d76ff99220c7aa428516e93998457dbe299f037.tar.bz2 |
pass location to md_asm_adjust
So the hook can use it as the location of diagnostics.
gcc/ChangeLog:
* cfgexpand.c (expand_asm_loc): Adjust.
(expand_asm_stmt): Likewise.
* config/arm/aarch-common-protos.h (arm_md_asm_adjust): Likewise.
* config/arm/aarch-common.c (arm_md_asm_adjust): Likewise.
* config/arm/arm.c (thumb1_md_asm_adjust): Likewise.
* config/avr/avr.c (avr_md_asm_adjust): Likewise.
* config/cris/cris.c (cris_md_asm_adjust): Likewise.
* config/i386/i386.c (ix86_md_asm_adjust): Likewise.
* config/mn10300/mn10300.c (mn10300_md_asm_adjust): Likewise.
* config/nds32/nds32.c (nds32_md_asm_adjust): Likewise.
* config/pdp11/pdp11.c (pdp11_md_asm_adjust): Likewise.
* config/rs6000/rs6000.c (rs6000_md_asm_adjust): Likewise.
* config/s390/s390.c (s390_md_asm_adjust): Likewise.
* config/vax/vax.c (vax_md_asm_adjust): Likewise.
* config/visium/visium.c (visium_md_asm_adjust): Likewise.
* doc/tm.texi: Regenerate.
* target.def: Add location argument to md_asm_adjust.
Signed-off-by: Trevor Saunders <tbsaunde@tbsaunde.org>
Diffstat (limited to 'gcc/cfgexpand.c')
-rw-r--r-- | gcc/cfgexpand.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/gcc/cfgexpand.c b/gcc/cfgexpand.c index 7dd1225..8183280 100644 --- a/gcc/cfgexpand.c +++ b/gcc/cfgexpand.c @@ -2897,7 +2897,8 @@ expand_asm_loc (tree string, int vol, location_t locus) if (targetm.md_asm_adjust) targetm.md_asm_adjust (output_rvec, input_rvec, input_mode, - constraints, clobber_rvec, clobbered_regs); + constraints, clobber_rvec, clobbered_regs, + locus); asm_op = body; nclobbers = clobber_rvec.length (); @@ -3074,8 +3075,7 @@ expand_asm_stmt (gasm *stmt) return; } - /* There are some legacy diagnostics in here, and also avoids an extra - parameter to targetm.md_asm_adjust. */ + /* There are some legacy diagnostics in here. */ save_input_location s_i_l(locus); unsigned noutputs = gimple_asm_noutputs (stmt); @@ -3456,7 +3456,8 @@ expand_asm_stmt (gasm *stmt) if (targetm.md_asm_adjust) after_md_seq = targetm.md_asm_adjust (output_rvec, input_rvec, input_mode, - constraints, clobber_rvec, clobbered_regs); + constraints, clobber_rvec, clobbered_regs, + locus); /* Do not allow the hook to change the output and input count, lest it mess up the operand numbering. */ |