Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(133)

Side by Side Diff: bfd/elf32-h8300.c

Issue 11969036: Merge GDB 7.5.1 (Closed) Base URL: http://git.chromium.org/native_client/nacl-gdb.git@master
Patch Set: Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « bfd/elf32-frv.c ('k') | bfd/elf32-hppa.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
None
OLDNEW
1 /* BFD back-end for Renesas H8/300 ELF binaries. 1 /* BFD back-end for Renesas H8/300 ELF binaries.
2 Copyright 1993, 1995, 1998, 1999, 2001, 2002, 2003, 2004, 2005, 2006, 2 Copyright 1993, 1995, 1998, 1999, 2001, 2002, 2003, 2004, 2005, 2006,
3 2007, 2009, 2010 Free Software Foundation, Inc. 3 2007, 2008, 2009, 2010, 2012 Free Software Foundation, Inc.
4 4
5 This file is part of BFD, the Binary File Descriptor library. 5 This file is part of BFD, the Binary File Descriptor library.
6 6
7 This program is free software; you can redistribute it and/or modify 7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by 8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 3 of the License, or 9 the Free Software Foundation; either version 3 of the License, or
10 (at your option) any later version. 10 (at your option) any later version.
11 11
12 This program is distributed in the hope that it will be useful, 12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of 13 but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 bfd_byte *, bfd_boolean, asymbol **); 45 bfd_byte *, bfd_boolean, asymbol **);
46 static bfd_reloc_status_type elf32_h8_final_link_relocate 46 static bfd_reloc_status_type elf32_h8_final_link_relocate
47 (unsigned long, bfd *, bfd *, asection *, 47 (unsigned long, bfd *, bfd *, asection *,
48 bfd_byte *, bfd_vma, bfd_vma, bfd_vma, 48 bfd_byte *, bfd_vma, bfd_vma, bfd_vma,
49 struct bfd_link_info *, asection *, int); 49 struct bfd_link_info *, asection *, int);
50 static bfd_boolean elf32_h8_relocate_section 50 static bfd_boolean elf32_h8_relocate_section
51 (bfd *, struct bfd_link_info *, bfd *, asection *, 51 (bfd *, struct bfd_link_info *, bfd *, asection *,
52 bfd_byte *, Elf_Internal_Rela *, 52 bfd_byte *, Elf_Internal_Rela *,
53 Elf_Internal_Sym *, asection **); 53 Elf_Internal_Sym *, asection **);
54 static bfd_reloc_status_type special 54 static bfd_reloc_status_type special
55 (bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **); 55 (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **);
56 56
57 /* This does not include any relocation information, but should be 57 /* This does not include any relocation information, but should be
58 good enough for GDB or objdump to read the file. */ 58 good enough for GDB or objdump to read the file. */
59 59
60 static reloc_howto_type h8_elf_howto_table[] = { 60 static reloc_howto_type h8_elf_howto_table[] =
61 {
61 #define R_H8_NONE_X 0 62 #define R_H8_NONE_X 0
62 HOWTO (R_H8_NONE, /* type */ 63 HOWTO (R_H8_NONE, /* type */
63 0, /* rightshift */ 64 0, /* rightshift */
64 0, /* size (0 = byte, 1 = short, 2 = long) */ 65 0, /* size (0 = byte, 1 = short, 2 = long) */
65 0, /* bitsize */ 66 0, /* bitsize */
66 FALSE, /* pc_relative */ 67 FALSE, /* pc_relative */
67 0, /* bitpos */ 68 0, /* bitpos */
68 complain_overflow_dont,/* complain_on_overflow */ 69 complain_overflow_dont,/* complain_on_overflow */
69 special, /* special_function */ 70 special, /* special_function */
70 "R_H8_NONE", /* name */ 71 "R_H8_NONE", /* name */
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after
297 } 298 }
298 299
299 /* Special handling for H8/300 relocs. 300 /* Special handling for H8/300 relocs.
300 We only come here for pcrel stuff and return normally if not an -r link. 301 We only come here for pcrel stuff and return normally if not an -r link.
301 When doing -r, we can't do any arithmetic for the pcrel stuff, because 302 When doing -r, we can't do any arithmetic for the pcrel stuff, because
302 we support relaxing on the H8/300 series chips. */ 303 we support relaxing on the H8/300 series chips. */
303 static bfd_reloc_status_type 304 static bfd_reloc_status_type
304 special (bfd *abfd ATTRIBUTE_UNUSED, 305 special (bfd *abfd ATTRIBUTE_UNUSED,
305 arelent *reloc_entry ATTRIBUTE_UNUSED, 306 arelent *reloc_entry ATTRIBUTE_UNUSED,
306 asymbol *symbol ATTRIBUTE_UNUSED, 307 asymbol *symbol ATTRIBUTE_UNUSED,
307 » PTR data ATTRIBUTE_UNUSED, 308 » void * data ATTRIBUTE_UNUSED,
308 asection *input_section ATTRIBUTE_UNUSED, 309 asection *input_section ATTRIBUTE_UNUSED,
309 bfd *output_bfd, 310 bfd *output_bfd,
310 char **error_message ATTRIBUTE_UNUSED) 311 char **error_message ATTRIBUTE_UNUSED)
311 { 312 {
312 if (output_bfd == (bfd *) NULL) 313 if (output_bfd == (bfd *) NULL)
313 return bfd_reloc_continue; 314 return bfd_reloc_continue;
314 315
315 /* Adjust the reloc address to that in the output section. */ 316 /* Adjust the reloc address to that in the output section. */
316 reloc_entry->address += input_section->output_offset; 317 reloc_entry->address += input_section->output_offset;
317 return bfd_reloc_ok; 318 return bfd_reloc_ok;
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
450 sym = local_syms + r_symndx; 451 sym = local_syms + r_symndx;
451 sec = local_sections[r_symndx]; 452 sec = local_sections[r_symndx];
452 relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel); 453 relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel);
453 } 454 }
454 else 455 else
455 { 456 {
456 bfd_boolean unresolved_reloc, warned; 457 bfd_boolean unresolved_reloc, warned;
457 458
458 RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel, 459 RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
459 r_symndx, symtab_hdr, sym_hashes, 460 r_symndx, symtab_hdr, sym_hashes,

error: old chunk mismatch

OLDNEW
« no previous file with comments | « bfd/elf32-frv.c ('k') | bfd/elf32-hppa.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698