/* tc-rx.h - header file for Renesas RX
- Copyright (C) 2008-2019 Free Software Foundation, Inc.
+ Copyright (C) 2008-2021 Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
#define md_end rx_md_end
extern void rx_md_end (void);
-#define md_relax_frag rx_relax_frag
-extern int rx_relax_frag (segT, fragS *, long);
+/* Note - the definition of MD_RELAX_FRAG here includes a reference to the
+ MAX_ITERATIONS variable which is defined locally in write.c:relax_segment()
+ but which is not normally passed to target specific relaxing code. This
+ reference is needed however as the number of iterations of the RX relaxing
+ code needs to be constrained by the maximum number of iterations allowed
+ by relax_segment(). See PR 24464 for more details. */
+#define md_relax_frag(SEG, FRAGP, STRETCH) \
+ rx_relax_frag ((SEG), (FRAGP), (STRETCH), max_iterations)
+extern int rx_relax_frag (segT, fragS *, long, unsigned long);
#define TC_FRAG_TYPE struct rx_bytesT *
-#define TC_FRAG_INIT rx_frag_init
+#define TC_FRAG_INIT(fragp, max_bytes) rx_frag_init (fragp)
extern void rx_frag_init (fragS *);
/* Call md_pcrel_from_section(), not md_pcrel_from(). */
#define MD_PCREL_FROM_SECTION(FIXP, SEC) md_pcrel_from_section (FIXP, SEC)
-extern long md_pcrel_from_section (struct fix *, segT);
/* RX doesn't have a 32 bit PCREL relocations. */
#define TC_FORCE_RELOCATION_SUB_LOCAL(FIX, SEG) 1
#define elf_tc_final_processing rx_elf_final_processing
extern void rx_elf_final_processing (void);
-extern bfd_boolean rx_use_conventional_section_names;
+extern bool rx_use_conventional_section_names;
#define TEXT_SECTION_NAME (rx_use_conventional_section_names ? ".text" : "P")
#define DATA_SECTION_NAME (rx_use_conventional_section_names ? ".data" : "D_1")
#define BSS_SECTION_NAME (rx_use_conventional_section_names ? ".bss" : "B_1")