aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf32-xtensa.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2017-12-06 09:26:00 +1030
committerAlan Modra <amodra@gmail.com>2017-12-06 17:51:43 +1030
commit07d6d2b8345ef3dc82eab49635acac9ee67dbb18 (patch)
tree380d1e08ae32b2a37d5f9610f1811bb98299ac09 /bfd/elf32-xtensa.c
parent65281396861dfcfa993eb5af4769d6837104890d (diff)
downloadgdb-07d6d2b8345ef3dc82eab49635acac9ee67dbb18.zip
gdb-07d6d2b8345ef3dc82eab49635acac9ee67dbb18.tar.gz
gdb-07d6d2b8345ef3dc82eab49635acac9ee67dbb18.tar.bz2
BFD whitespace fixes
Binutils is supposed to use tabs. In my git config I have whitespace = indent-with-non-tab,space-before-tab,trailing-space and I got annoyed enough seeing red in "git diff" output to fix the problems. * doc/header.sed: Trim trailing space when splitting lines. * aix386-core.c, * aout-adobe.c, * aout-arm.c, * aout-cris.c, * aout-ns32k.c, * aout-target.h, * aout-tic30.c, * aoutf1.h, * aoutx.h, * arc-got.h, * arc-plt.def, * arc-plt.h, * archive.c, * archive64.c, * archures.c, * armnetbsd.c, * bfd-in.h, * bfd.c, * bfdio.c, * binary.c, * bout.c, * cache.c, * cisco-core.c, * coff-alpha.c, * coff-apollo.c, * coff-arm.c, * coff-h8300.c, * coff-i386.c, * coff-i860.c, * coff-i960.c, * coff-m68k.c, * coff-m88k.c, * coff-mcore.c, * coff-mips.c, * coff-ppc.c, * coff-rs6000.c, * coff-sh.c, * coff-stgo32.c, * coff-tic4x.c, * coff-tic54x.c, * coff-tic80.c, * coff-we32k.c, * coff-x86_64.c, * coff-z80.c, * coff-z8k.c, * coff64-rs6000.c, * coffcode.h, * coffgen.c, * cofflink.c, * coffswap.h, * compress.c, * corefile.c, * cpu-alpha.c, * cpu-arm.c, * cpu-avr.c, * cpu-bfin.c, * cpu-cr16.c, * cpu-cr16c.c, * cpu-crx.c, * cpu-d10v.c, * cpu-frv.c, * cpu-ft32.c, * cpu-i370.c, * cpu-i960.c, * cpu-ia64-opc.c, * cpu-ip2k.c, * cpu-lm32.c, * cpu-m32r.c, * cpu-mcore.c, * cpu-microblaze.c, * cpu-mips.c, * cpu-moxie.c, * cpu-mt.c, * cpu-nios2.c, * cpu-ns32k.c, * cpu-or1k.c, * cpu-powerpc.c, * cpu-pru.c, * cpu-sh.c, * cpu-spu.c, * cpu-v850.c, * cpu-v850_rh850.c, * cpu-xgate.c, * cpu-z80.c, * dwarf1.c, * dwarf2.c, * ecoff.c, * ecofflink.c, * ecoffswap.h, * elf-bfd.h, * elf-eh-frame.c, * elf-hppa.h, * elf-m10200.c, * elf-m10300.c, * elf-s390-common.c, * elf-strtab.c, * elf-vxworks.c, * elf.c, * elf32-am33lin.c, * elf32-arc.c, * elf32-arm.c, * elf32-avr.c, * elf32-avr.h, * elf32-bfin.c, * elf32-cr16.c, * elf32-cr16c.c, * elf32-cris.c, * elf32-crx.c, * elf32-d10v.c, * elf32-d30v.c, * elf32-dlx.c, * elf32-epiphany.c, * elf32-fr30.c, * elf32-frv.c, * elf32-ft32.c, * elf32-h8300.c, * elf32-hppa.c, * elf32-i386.c, * elf32-i860.c, * elf32-i960.c, * elf32-ip2k.c, * elf32-lm32.c, * elf32-m32c.c, * elf32-m32r.c, * elf32-m68hc11.c, * elf32-m68hc12.c, * elf32-m68hc1x.c, * elf32-m68hc1x.h, * elf32-m68k.c, * elf32-m88k.c, * elf32-mcore.c, * elf32-mep.c, * elf32-metag.c, * elf32-microblaze.c, * elf32-mips.c, * elf32-moxie.c, * elf32-msp430.c, * elf32-mt.c, * elf32-nds32.c, * elf32-nds32.h, * elf32-nios2.c, * elf32-or1k.c, * elf32-pj.c, * elf32-ppc.c, * elf32-ppc.h, * elf32-pru.c, * elf32-rl78.c, * elf32-rx.c, * elf32-s390.c, * elf32-score.c, * elf32-score.h, * elf32-score7.c, * elf32-sh-symbian.c, * elf32-sh.c, * elf32-sh64.c, * elf32-sparc.c, * elf32-spu.c, * elf32-tic6x.c, * elf32-tilegx.c, * elf32-tilegx.h, * elf32-tilepro.c, * elf32-tilepro.h, * elf32-v850.c, * elf32-vax.c, * elf32-wasm32.c, * elf32-xc16x.c, * elf32-xgate.c, * elf32-xgate.h, * elf32-xstormy16.c, * elf32-xtensa.c, * elf64-alpha.c, * elf64-hppa.c, * elf64-ia64-vms.c, * elf64-mips.c, * elf64-mmix.c, * elf64-ppc.c, * elf64-s390.c, * elf64-sh64.c, * elf64-sparc.c, * elf64-tilegx.c, * elf64-tilegx.h, * elf64-x86-64.c, * elfcore.h, * elflink.c, * elfn32-mips.c, * elfnn-aarch64.c, * elfnn-ia64.c, * elfnn-riscv.c, * elfxx-aarch64.c, * elfxx-aarch64.h, * elfxx-ia64.c, * elfxx-ia64.h, * elfxx-mips.c, * elfxx-riscv.c, * elfxx-sparc.c, * elfxx-tilegx.c, * elfxx-x86.c, * elfxx-x86.h, * freebsd.h, * hash.c, * host-aout.c, * hp300hpux.c, * hppabsd-core.c, * hpux-core.c, * i386aout.c, * i386linux.c, * i386lynx.c, * i386mach3.c, * i386msdos.c, * i386netbsd.c, * ieee.c, * ihex.c, * irix-core.c, * libaout.h, * libbfd-in.h, * libbfd.c, * libcoff-in.h, * libnlm.h, * libpei.h, * libxcoff.h, * linker.c, * lynx-core.c, * m68k4knetbsd.c, * m68klinux.c, * m68knetbsd.c, * m88kmach3.c, * mach-o-aarch64.c, * mach-o-arm.c, * mach-o-i386.c, * mach-o-target.c, * mach-o-x86-64.c, * mach-o.c, * mach-o.h, * merge.c, * mipsbsd.c, * mmo.c, * netbsd.h, * netbsd-core.c, * newsos3.c, * nlm-target.h, * nlm32-ppc.c, * nlm32-sparc.c, * nlmcode.h, * ns32k.h, * ns32knetbsd.c, * oasys.c, * opncls.c, * pc532-mach.c, * pdp11.c, * pe-arm.c, * pe-i386.c, * pe-mcore.c, * pe-mips.c, * pe-x86_64.c, * peXXigen.c, * pef.c, * pef.h, * pei-arm.c, * pei-i386.c, * pei-mcore.c, * pei-x86_64.c, * peicode.h, * plugin.c, * ppcboot.c, * ptrace-core.c, * reloc.c, * riscix.c, * rs6000-core.c, * section.c, * som.c, * som.h, * sparclinux.c, * sparcnetbsd.c, * srec.c, * stabs.c, * sunos.c, * syms.c, * targets.c, * tekhex.c, * trad-core.c, * vax1knetbsd.c, * vaxnetbsd.c, * verilog.c, * versados.c, * vms-alpha.c, * vms-lib.c, * vms-misc.c, * wasm-module.c, * wasm-module.h, * xcofflink.c, * xsym.c, * xsym.h: Whitespace fixes. * bfd-in2.h, * libbfd.h, * libcoff.h: Regenerate.
Diffstat (limited to 'bfd/elf32-xtensa.c')
-rw-r--r--bfd/elf32-xtensa.c90
1 files changed, 45 insertions, 45 deletions
diff --git a/bfd/elf32-xtensa.c b/bfd/elf32-xtensa.c
index 3c7de9b..65aebd7 100644
--- a/bfd/elf32-xtensa.c
+++ b/bfd/elf32-xtensa.c
@@ -214,11 +214,11 @@ static reloc_howto_type elf_howto_table[] =
/* GNU extension to record C++ vtable hierarchy. */
HOWTO (R_XTENSA_GNU_VTINHERIT, 0, 2, 0, FALSE, 0, complain_overflow_dont,
- NULL, "R_XTENSA_GNU_VTINHERIT",
+ NULL, "R_XTENSA_GNU_VTINHERIT",
FALSE, 0, 0, FALSE),
/* GNU extension to record C++ vtable member usage. */
HOWTO (R_XTENSA_GNU_VTENTRY, 0, 2, 0, FALSE, 0, complain_overflow_dont,
- _bfd_elf_rel_vtable_reloc_fn, "R_XTENSA_GNU_VTENTRY",
+ _bfd_elf_rel_vtable_reloc_fn, "R_XTENSA_GNU_VTENTRY",
FALSE, 0, 0, FALSE),
/* Relocations for supporting difference of symbols. */
@@ -912,7 +912,7 @@ xtensa_read_table_entries (bfd *abfd,
property_table_compare);
/* Check that the table contents are valid. Problems may occur,
- for example, if an unrelocated object file is stripped. */
+ for example, if an unrelocated object file is stripped. */
for (blk = 1; blk < block_count; blk++)
{
/* The only circumstance where two entries may legitimately
@@ -1211,19 +1211,19 @@ elf_xtensa_check_relocs (bfd *abfd,
static void
elf_xtensa_make_sym_local (struct bfd_link_info *info,
- struct elf_link_hash_entry *h)
+ struct elf_link_hash_entry *h)
{
if (bfd_link_pic (info))
{
if (h->plt.refcount > 0)
- {
+ {
/* For shared objects, there's no need for PLT entries for local
symbols (use RELATIVE relocs instead of JMP_SLOT relocs). */
- if (h->got.refcount < 0)
- h->got.refcount = 0;
- h->got.refcount += h->plt.refcount;
- h->plt.refcount = 0;
- }
+ if (h->got.refcount < 0)
+ h->got.refcount = 0;
+ h->got.refcount += h->plt.refcount;
+ h->plt.refcount = 0;
+ }
}
else
{
@@ -1236,8 +1236,8 @@ elf_xtensa_make_sym_local (struct bfd_link_info *info,
static void
elf_xtensa_hide_symbol (struct bfd_link_info *info,
- struct elf_link_hash_entry *h,
- bfd_boolean force_local)
+ struct elf_link_hash_entry *h,
+ bfd_boolean force_local)
{
/* For a shared link, move the plt refcount to the got refcount to leave
space for RELATIVE relocs. */
@@ -1859,7 +1859,7 @@ elf_xtensa_do_reloc (reloc_howto_type *howto,
case R_XTENSA_ASM_SIMPLIFY:
{
- /* Convert the L32R/CALLX to CALL. */
+ /* Convert the L32R/CALLX to CALL. */
bfd_reloc_status_type retval =
elf_xtensa_do_asm_simplify (contents, address, input_size,
error_message);
@@ -2400,7 +2400,7 @@ replace_tls_insn (Elf_Internal_Rela *rel,
xtensa_format_set_slot (isa, fmt, 0, ibuff, sbuff);
xtensa_insnbuf_to_chars (isa, ibuff, contents + rel->r_offset,
- input_size - rel->r_offset);
+ input_size - rel->r_offset);
return TRUE;
}
@@ -5232,23 +5232,23 @@ add_value_map (value_map_hash_table *map,
/* The following text actions are generated:
- "ta_remove_insn" remove an instruction or instructions
- "ta_remove_longcall" convert longcall to call
+ "ta_remove_insn" remove an instruction or instructions
+ "ta_remove_longcall" convert longcall to call
"ta_convert_longcall" convert longcall to nop/call
- "ta_narrow_insn" narrow a wide instruction
- "ta_widen" widen a narrow instruction
- "ta_fill" add fill or remove fill
+ "ta_narrow_insn" narrow a wide instruction
+ "ta_widen" widen a narrow instruction
+ "ta_fill" add fill or remove fill
removed < 0 is a fill; branches to the fill address will be
changed to address + fill size (e.g., address - removed)
removed >= 0 branches to the fill address will stay unchanged
- "ta_remove_literal" remove a literal; this action is
+ "ta_remove_literal" remove a literal; this action is
indicated when a literal is removed
- or replaced.
- "ta_add_literal" insert a new literal; this action is
- indicated when a literal has been moved.
- It may use a virtual_offset because
+ or replaced.
+ "ta_add_literal" insert a new literal; this action is
+ indicated when a literal has been moved.
+ It may use a virtual_offset because
multiple literals can be placed at the
- same location.
+ same location.
For each of these text actions, we also record the number of bytes
removed by performing the text action. In the case of a "ta_widen"
@@ -5261,12 +5261,12 @@ typedef enum text_action_enum_t text_action_t;
enum text_action_enum_t
{
ta_none,
- ta_remove_insn, /* removed = -size */
- ta_remove_longcall, /* removed = -size */
- ta_convert_longcall, /* removed = 0 */
- ta_narrow_insn, /* removed = -1 */
- ta_widen_insn, /* removed = +1 */
- ta_fill, /* removed = +size */
+ ta_remove_insn, /* removed = -size */
+ ta_remove_longcall, /* removed = -size */
+ ta_convert_longcall, /* removed = 0 */
+ ta_narrow_insn, /* removed = -1 */
+ ta_widen_insn, /* removed = +1 */
+ ta_fill, /* removed = +size */
ta_remove_literal,
ta_add_literal
};
@@ -6964,7 +6964,7 @@ find_relaxable_sections (bfd *abfd,
continue;
/* Count PC-relative operand relocations against the target section.
- Note: The conditions tested here must match the conditions under
+ Note: The conditions tested here must match the conditions under
which init_source_reloc is called in collect_source_relocs(). */
is_l32r_reloc = FALSE;
if (is_operand_relocation (ELF32_R_TYPE (irel->r_info)))
@@ -7411,7 +7411,7 @@ build_reloc_ranges (bfd *abfd, asection *sec,
reloc[i].irel = irel;
/* Every relocation won't possibly be checked in the optimized version of
- check_section_ebb_pcrels_fit, so this needs to be done here. */
+ check_section_ebb_pcrels_fit, so this needs to be done here. */
if (is_alt_relocation (ELF32_R_TYPE (irel->r_info)))
{
/* None of the current alternate relocs are PC-relative,
@@ -8991,7 +8991,7 @@ relocations_reach (source_reloc *reloc,
continue;
/* The original and new output section for these must be the same
- in order to coalesce. */
+ in order to coalesce. */
if (r_reloc_get_section (&reloc[i].r_rel)->output_section
!= sec->output_section)
return FALSE;
@@ -9361,7 +9361,7 @@ relax_section (bfd *abfd, asection *sec, struct bfd_link_info *link_info)
/* Update the action so that the code that moves
the contents will do the right thing. */
/* ta_remove_longcall and ta_remove_insn actions are
- grouped together in the tree as well as
+ grouped together in the tree as well as
ta_convert_longcall and ta_none, so that changes below
can be done w/o removing and reinserting action into
the tree. */
@@ -10345,7 +10345,7 @@ relax_property_section (bfd *abfd,
predef_flags = xtensa_get_property_predef_flags (sec);
/* Walk over memory and relocations at the same time.
- This REQUIRES that the internal_relocs be sorted by offset. */
+ This REQUIRES that the internal_relocs be sorted by offset. */
qsort (internal_relocs, sec->reloc_count, sizeof (Elf_Internal_Rela),
internal_reloc_compare);
@@ -10768,8 +10768,8 @@ get_elf_r_symndx_section (bfd *abfd, unsigned long r_symndx)
struct elf_link_hash_entry *h = elf_sym_hashes (abfd)[indx];
while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
switch (h->root.type)
{
@@ -10833,10 +10833,10 @@ get_elf_r_symndx_offset (bfd *abfd, unsigned long r_symndx)
elf_sym_hashes (abfd)[indx];
while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
+ || h->root.type == bfd_link_hash_warning)
h = (struct elf_link_hash_entry *) h->root.u.i.link;
if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
+ || h->root.type == bfd_link_hash_defweak)
offset = h->root.u.def.value;
}
return offset;
@@ -11006,9 +11006,9 @@ xtensa_property_section_name (asection *sec, const char *base_name)
suffix = sec->name + linkonce_len;
/* For backward compatibility, replace "t." instead of inserting
- the new linkonce_kind (but not for "prop" sections). */
+ the new linkonce_kind (but not for "prop" sections). */
if (CONST_STRNEQ (suffix, "t.") && linkonce_kind[1] == '.')
- suffix += 2;
+ suffix += 2;
strcat (prop_sec_name + linkonce_len, suffix);
}
else
@@ -11185,9 +11185,9 @@ static const struct bfd_elf_special_section elf_xtensa_special_sections[] =
{
{ STRING_COMMA_LEN (".fini.literal"), 0, SHT_PROGBITS, SHF_ALLOC + SHF_EXECINSTR },
{ STRING_COMMA_LEN (".init.literal"), 0, SHT_PROGBITS, SHF_ALLOC + SHF_EXECINSTR },
- { STRING_COMMA_LEN (".literal"), 0, SHT_PROGBITS, SHF_ALLOC + SHF_EXECINSTR },
- { STRING_COMMA_LEN (".xtensa.info"), 0, SHT_NOTE, 0 },
- { NULL, 0, 0, 0, 0 }
+ { STRING_COMMA_LEN (".literal"), 0, SHT_PROGBITS, SHF_ALLOC + SHF_EXECINSTR },
+ { STRING_COMMA_LEN (".xtensa.info"), 0, SHT_NOTE, 0 },
+ { NULL, 0, 0, 0, 0 }
};
#define ELF_TARGET_ID XTENSA_ELF_DATA