bfd/
[binutils.git] / gold / reloc.h
blob2229421bbb024a81ae2190056aa6ab42d4335fad
1 // reloc.h -- relocate input files for gold -*- C++ -*-
3 // Copyright 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
4 // Written by Ian Lance Taylor <iant@google.com>.
6 // This file is part of gold.
8 // This program is free software; you can redistribute it and/or modify
9 // it under the terms of the GNU General Public License as published by
10 // the Free Software Foundation; either version 3 of the License, or
11 // (at your option) any later version.
13 // This program is distributed in the hope that it will be useful,
14 // but WITHOUT ANY WARRANTY; without even the implied warranty of
15 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 // GNU General Public License for more details.
18 // You should have received a copy of the GNU General Public License
19 // along with this program; if not, write to the Free Software
20 // Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
21 // MA 02110-1301, USA.
23 #ifndef GOLD_RELOC_H
24 #define GOLD_RELOC_H
26 #include <vector>
27 #ifdef HAVE_BYTESWAP_H
28 #include <byteswap.h>
29 #endif
31 #include "elfcpp.h"
32 #include "workqueue.h"
34 namespace gold
37 class General_options;
38 class Object;
39 class Relobj;
40 class Read_relocs_data;
41 class Symbol;
42 class Layout;
43 class Output_data;
44 class Output_section;
46 template<int size>
47 class Sized_symbol;
49 template<int size, bool big_endian>
50 class Sized_relobj;
52 template<int size>
53 class Symbol_value;
55 template<int sh_type, bool dynamic, int size, bool big_endian>
56 class Output_data_reloc;
58 // A class to read the relocations for an object file, and then queue
59 // up a task to see if they require any GOT/PLT/COPY relocations in
60 // the symbol table.
62 class Read_relocs : public Task
64 public:
65 // SYMTAB_LOCK is used to lock the symbol table. BLOCKER should be
66 // unblocked when the Scan_relocs task completes.
67 Read_relocs(const General_options& options, Symbol_table* symtab,
68 Layout* layout, Relobj* object, Task_token* symtab_lock,
69 Task_token* blocker)
70 : options_(options), symtab_(symtab), layout_(layout), object_(object),
71 symtab_lock_(symtab_lock), blocker_(blocker)
72 { }
74 // The standard Task methods.
76 Task_token*
77 is_runnable();
79 void
80 locks(Task_locker*);
82 void
83 run(Workqueue*);
85 std::string
86 get_name() const;
88 private:
89 const General_options& options_;
90 Symbol_table* symtab_;
91 Layout* layout_;
92 Relobj* object_;
93 Task_token* symtab_lock_;
94 Task_token* blocker_;
97 // Process the relocs to figure out which sections are garbage.
98 // Very similar to scan relocs.
100 class Gc_process_relocs : public Task
102 public:
103 // SYMTAB_LOCK is used to lock the symbol table. BLOCKER should be
104 // unblocked when the task completes.
105 Gc_process_relocs(const General_options& options, Symbol_table* symtab,
106 Layout* layout, Relobj* object, Read_relocs_data* rd,
107 Task_token* symtab_lock, Task_token* blocker)
108 : options_(options), symtab_(symtab), layout_(layout), object_(object),
109 rd_(rd), symtab_lock_(symtab_lock), blocker_(blocker)
112 // The standard Task methods.
114 Task_token*
115 is_runnable();
117 void
118 locks(Task_locker*);
120 void
121 run(Workqueue*);
123 std::string
124 get_name() const;
126 private:
127 const General_options& options_;
128 Symbol_table* symtab_;
129 Layout* layout_;
130 Relobj* object_;
131 Read_relocs_data* rd_;
132 Task_token* symtab_lock_;
133 Task_token* blocker_;
136 // Scan the relocations for an object to see if they require any
137 // GOT/PLT/COPY relocations.
139 class Scan_relocs : public Task
141 public:
142 // SYMTAB_LOCK is used to lock the symbol table. BLOCKER should be
143 // unblocked when the task completes.
144 Scan_relocs(const General_options& options, Symbol_table* symtab,
145 Layout* layout, Relobj* object, Read_relocs_data* rd,
146 Task_token* symtab_lock, Task_token* blocker)
147 : options_(options), symtab_(symtab), layout_(layout), object_(object),
148 rd_(rd), symtab_lock_(symtab_lock), blocker_(blocker)
151 // The standard Task methods.
153 Task_token*
154 is_runnable();
156 void
157 locks(Task_locker*);
159 void
160 run(Workqueue*);
162 std::string
163 get_name() const;
165 private:
166 const General_options& options_;
167 Symbol_table* symtab_;
168 Layout* layout_;
169 Relobj* object_;
170 Read_relocs_data* rd_;
171 Task_token* symtab_lock_;
172 Task_token* blocker_;
175 // A class to perform all the relocations for an object file.
177 class Relocate_task : public Task
179 public:
180 Relocate_task(const General_options& options, const Symbol_table* symtab,
181 const Layout* layout, Relobj* object, Output_file* of,
182 Task_token* input_sections_blocker,
183 Task_token* output_sections_blocker, Task_token* final_blocker)
184 : options_(options), symtab_(symtab), layout_(layout), object_(object),
185 of_(of), input_sections_blocker_(input_sections_blocker),
186 output_sections_blocker_(output_sections_blocker),
187 final_blocker_(final_blocker)
190 // The standard Task methods.
192 Task_token*
193 is_runnable();
195 void
196 locks(Task_locker*);
198 void
199 run(Workqueue*);
201 std::string
202 get_name() const;
204 private:
205 const General_options& options_;
206 const Symbol_table* symtab_;
207 const Layout* layout_;
208 Relobj* object_;
209 Output_file* of_;
210 Task_token* input_sections_blocker_;
211 Task_token* output_sections_blocker_;
212 Task_token* final_blocker_;
215 // During a relocatable link, this class records how relocations
216 // should be handled for a single input reloc section. An instance of
217 // this class is created while scanning relocs, and it is used while
218 // processing relocs.
220 class Relocatable_relocs
222 public:
223 // We use a vector of unsigned char to indicate how the input relocs
224 // should be handled. Each element is one of the following values.
225 // We create this vector when we initially scan the relocations.
226 enum Reloc_strategy
228 // Copy the input reloc. Don't modify it other than updating the
229 // r_offset field and the r_sym part of the r_info field.
230 RELOC_COPY,
231 // Copy the input reloc which is against an STT_SECTION symbol.
232 // Update the r_offset and r_sym part of the r_info field. Adjust
233 // the addend by subtracting the value of the old local symbol and
234 // adding the value of the new local symbol. The addend is in the
235 // SHT_RELA reloc and the contents of the data section do not need
236 // to be changed.
237 RELOC_ADJUST_FOR_SECTION_RELA,
238 // Like RELOC_ADJUST_FOR_SECTION_RELA but the addend should not be
239 // adjusted.
240 RELOC_ADJUST_FOR_SECTION_0,
241 // Like RELOC_ADJUST_FOR_SECTION_RELA but the contents of the
242 // section need to be changed. The number indicates the number of
243 // bytes in the addend in the section contents.
244 RELOC_ADJUST_FOR_SECTION_1,
245 RELOC_ADJUST_FOR_SECTION_2,
246 RELOC_ADJUST_FOR_SECTION_4,
247 RELOC_ADJUST_FOR_SECTION_8,
248 // Discard the input reloc--process it completely when relocating
249 // the data section contents.
250 RELOC_DISCARD,
251 // An input reloc which is not discarded, but which requires
252 // target specific processing in order to update it.
253 RELOC_SPECIAL
256 Relocatable_relocs()
257 : reloc_strategies_(), output_reloc_count_(0), posd_(NULL)
260 // Record the number of relocs.
261 void
262 set_reloc_count(size_t reloc_count)
263 { this->reloc_strategies_.reserve(reloc_count); }
265 // Record what to do for the next reloc.
266 void
267 set_next_reloc_strategy(Reloc_strategy strategy)
269 this->reloc_strategies_.push_back(static_cast<unsigned char>(strategy));
270 if (strategy != RELOC_DISCARD)
271 ++this->output_reloc_count_;
274 // Record the Output_data associated with this reloc section.
275 void
276 set_output_data(Output_data* posd)
278 gold_assert(this->posd_ == NULL);
279 this->posd_ = posd;
282 // Return the Output_data associated with this reloc section.
283 Output_data*
284 output_data() const
285 { return this->posd_; }
287 // Return what to do for reloc I.
288 Reloc_strategy
289 strategy(unsigned int i) const
291 gold_assert(i < this->reloc_strategies_.size());
292 return static_cast<Reloc_strategy>(this->reloc_strategies_[i]);
295 // Return the number of relocations to create in the output file.
296 size_t
297 output_reloc_count() const
298 { return this->output_reloc_count_; }
300 private:
301 typedef std::vector<unsigned char> Reloc_strategies;
303 // The strategies for the input reloc. There is one entry in this
304 // vector for each relocation in the input section.
305 Reloc_strategies reloc_strategies_;
306 // The number of relocations to be created in the output file.
307 size_t output_reloc_count_;
308 // The output data structure associated with this relocation.
309 Output_data* posd_;
312 // Standard relocation routines which are used on many targets. Here
313 // SIZE and BIG_ENDIAN refer to the target, not the relocation type.
315 template<int size, bool big_endian>
316 class Relocate_functions
318 private:
319 // Do a simple relocation with the addend in the section contents.
320 // VALSIZE is the size of the value.
321 template<int valsize>
322 static inline void
323 rel(unsigned char* view,
324 typename elfcpp::Swap<valsize, big_endian>::Valtype value)
326 typedef typename elfcpp::Swap<valsize, big_endian>::Valtype Valtype;
327 Valtype* wv = reinterpret_cast<Valtype*>(view);
328 Valtype x = elfcpp::Swap<valsize, big_endian>::readval(wv);
329 elfcpp::Swap<valsize, big_endian>::writeval(wv, x + value);
332 // Do a simple relocation using a Symbol_value with the addend in
333 // the section contents. VALSIZE is the size of the value to
334 // relocate.
335 template<int valsize>
336 static inline void
337 rel(unsigned char* view,
338 const Sized_relobj<size, big_endian>* object,
339 const Symbol_value<size>* psymval)
341 typedef typename elfcpp::Swap<valsize, big_endian>::Valtype Valtype;
342 Valtype* wv = reinterpret_cast<Valtype*>(view);
343 Valtype x = elfcpp::Swap<valsize, big_endian>::readval(wv);
344 x = psymval->value(object, x);
345 elfcpp::Swap<valsize, big_endian>::writeval(wv, x);
348 // Do a simple relocation with the addend in the relocation.
349 // VALSIZE is the size of the value.
350 template<int valsize>
351 static inline void
352 rela(unsigned char* view,
353 typename elfcpp::Swap<valsize, big_endian>::Valtype value,
354 typename elfcpp::Swap<valsize, big_endian>::Valtype addend)
356 typedef typename elfcpp::Swap<valsize, big_endian>::Valtype Valtype;
357 Valtype* wv = reinterpret_cast<Valtype*>(view);
358 elfcpp::Swap<valsize, big_endian>::writeval(wv, value + addend);
361 // Do a simple relocation using a symbol value with the addend in
362 // the relocation. VALSIZE is the size of the value.
363 template<int valsize>
364 static inline void
365 rela(unsigned char* view,
366 const Sized_relobj<size, big_endian>* object,
367 const Symbol_value<size>* psymval,
368 typename elfcpp::Swap<valsize, big_endian>::Valtype addend)
370 typedef typename elfcpp::Swap<valsize, big_endian>::Valtype Valtype;
371 Valtype* wv = reinterpret_cast<Valtype*>(view);
372 Valtype x = psymval->value(object, addend);
373 elfcpp::Swap<valsize, big_endian>::writeval(wv, x);
376 // Do a simple PC relative relocation with the addend in the section
377 // contents. VALSIZE is the size of the value.
378 template<int valsize>
379 static inline void
380 pcrel(unsigned char* view,
381 typename elfcpp::Swap<valsize, big_endian>::Valtype value,
382 typename elfcpp::Elf_types<size>::Elf_Addr address)
384 typedef typename elfcpp::Swap<valsize, big_endian>::Valtype Valtype;
385 Valtype* wv = reinterpret_cast<Valtype*>(view);
386 Valtype x = elfcpp::Swap<valsize, big_endian>::readval(wv);
387 elfcpp::Swap<valsize, big_endian>::writeval(wv, x + value - address);
390 // Do a simple PC relative relocation with a Symbol_value with the
391 // addend in the section contents. VALSIZE is the size of the
392 // value.
393 template<int valsize>
394 static inline void
395 pcrel(unsigned char* view,
396 const Sized_relobj<size, big_endian>* object,
397 const Symbol_value<size>* psymval,
398 typename elfcpp::Elf_types<size>::Elf_Addr address)
400 typedef typename elfcpp::Swap<valsize, big_endian>::Valtype Valtype;
401 Valtype* wv = reinterpret_cast<Valtype*>(view);
402 Valtype x = elfcpp::Swap<valsize, big_endian>::readval(wv);
403 x = psymval->value(object, x);
404 elfcpp::Swap<valsize, big_endian>::writeval(wv, x - address);
407 // Do a simple PC relative relocation with the addend in the
408 // relocation. VALSIZE is the size of the value.
409 template<int valsize>
410 static inline void
411 pcrela(unsigned char* view,
412 typename elfcpp::Swap<valsize, big_endian>::Valtype value,
413 typename elfcpp::Swap<valsize, big_endian>::Valtype addend,
414 typename elfcpp::Elf_types<size>::Elf_Addr address)
416 typedef typename elfcpp::Swap<valsize, big_endian>::Valtype Valtype;
417 Valtype* wv = reinterpret_cast<Valtype*>(view);
418 elfcpp::Swap<valsize, big_endian>::writeval(wv, value + addend - address);
421 // Do a simple PC relative relocation with a Symbol_value with the
422 // addend in the relocation. VALSIZE is the size of the value.
423 template<int valsize>
424 static inline void
425 pcrela(unsigned char* view,
426 const Sized_relobj<size, big_endian>* object,
427 const Symbol_value<size>* psymval,
428 typename elfcpp::Swap<valsize, big_endian>::Valtype addend,
429 typename elfcpp::Elf_types<size>::Elf_Addr address)
431 typedef typename elfcpp::Swap<valsize, big_endian>::Valtype Valtype;
432 Valtype* wv = reinterpret_cast<Valtype*>(view);
433 Valtype x = psymval->value(object, addend);
434 elfcpp::Swap<valsize, big_endian>::writeval(wv, x - address);
437 typedef Relocate_functions<size, big_endian> This;
439 public:
440 // Do a simple 8-bit REL relocation with the addend in the section
441 // contents.
442 static inline void
443 rel8(unsigned char* view, unsigned char value)
444 { This::template rel<8>(view, value); }
446 static inline void
447 rel8(unsigned char* view,
448 const Sized_relobj<size, big_endian>* object,
449 const Symbol_value<size>* psymval)
450 { This::template rel<8>(view, object, psymval); }
452 // Do an 8-bit RELA relocation with the addend in the relocation.
453 static inline void
454 rela8(unsigned char* view, unsigned char value, unsigned char addend)
455 { This::template rela<8>(view, value, addend); }
457 static inline void
458 rela8(unsigned char* view,
459 const Sized_relobj<size, big_endian>* object,
460 const Symbol_value<size>* psymval,
461 unsigned char addend)
462 { This::template rela<8>(view, object, psymval, addend); }
464 // Do a simple 8-bit PC relative relocation with the addend in the
465 // section contents.
466 static inline void
467 pcrel8(unsigned char* view, unsigned char value,
468 typename elfcpp::Elf_types<size>::Elf_Addr address)
469 { This::template pcrel<8>(view, value, address); }
471 static inline void
472 pcrel8(unsigned char* view,
473 const Sized_relobj<size, big_endian>* object,
474 const Symbol_value<size>* psymval,
475 typename elfcpp::Elf_types<size>::Elf_Addr address)
476 { This::template pcrel<8>(view, object, psymval, address); }
478 // Do a simple 8-bit PC relative RELA relocation with the addend in
479 // the reloc.
480 static inline void
481 pcrela8(unsigned char* view, unsigned char value, unsigned char addend,
482 typename elfcpp::Elf_types<size>::Elf_Addr address)
483 { This::template pcrela<8>(view, value, addend, address); }
485 static inline void
486 pcrela8(unsigned char* view,
487 const Sized_relobj<size, big_endian>* object,
488 const Symbol_value<size>* psymval,
489 unsigned char addend,
490 typename elfcpp::Elf_types<size>::Elf_Addr address)
491 { This::template pcrela<8>(view, object, psymval, addend, address); }
493 // Do a simple 16-bit REL relocation with the addend in the section
494 // contents.
495 static inline void
496 rel16(unsigned char* view, elfcpp::Elf_Half value)
497 { This::template rel<16>(view, value); }
499 static inline void
500 rel16(unsigned char* view,
501 const Sized_relobj<size, big_endian>* object,
502 const Symbol_value<size>* psymval)
503 { This::template rel<16>(view, object, psymval); }
505 // Do an 16-bit RELA relocation with the addend in the relocation.
506 static inline void
507 rela16(unsigned char* view, elfcpp::Elf_Half value, elfcpp::Elf_Half addend)
508 { This::template rela<16>(view, value, addend); }
510 static inline void
511 rela16(unsigned char* view,
512 const Sized_relobj<size, big_endian>* object,
513 const Symbol_value<size>* psymval,
514 elfcpp::Elf_Half addend)
515 { This::template rela<16>(view, object, psymval, addend); }
517 // Do a simple 16-bit PC relative REL relocation with the addend in
518 // the section contents.
519 static inline void
520 pcrel16(unsigned char* view, elfcpp::Elf_Half value,
521 typename elfcpp::Elf_types<size>::Elf_Addr address)
522 { This::template pcrel<16>(view, value, address); }
524 static inline void
525 pcrel16(unsigned char* view,
526 const Sized_relobj<size, big_endian>* object,
527 const Symbol_value<size>* psymval,
528 typename elfcpp::Elf_types<size>::Elf_Addr address)
529 { This::template pcrel<16>(view, object, psymval, address); }
531 // Do a simple 16-bit PC relative RELA relocation with the addend in
532 // the reloc.
533 static inline void
534 pcrela16(unsigned char* view, elfcpp::Elf_Half value,
535 elfcpp::Elf_Half addend,
536 typename elfcpp::Elf_types<size>::Elf_Addr address)
537 { This::template pcrela<16>(view, value, addend, address); }
539 static inline void
540 pcrela16(unsigned char* view,
541 const Sized_relobj<size, big_endian>* object,
542 const Symbol_value<size>* psymval,
543 elfcpp::Elf_Half addend,
544 typename elfcpp::Elf_types<size>::Elf_Addr address)
545 { This::template pcrela<16>(view, object, psymval, addend, address); }
547 // Do a simple 32-bit REL relocation with the addend in the section
548 // contents.
549 static inline void
550 rel32(unsigned char* view, elfcpp::Elf_Word value)
551 { This::template rel<32>(view, value); }
553 static inline void
554 rel32(unsigned char* view,
555 const Sized_relobj<size, big_endian>* object,
556 const Symbol_value<size>* psymval)
557 { This::template rel<32>(view, object, psymval); }
559 // Do an 32-bit RELA relocation with the addend in the relocation.
560 static inline void
561 rela32(unsigned char* view, elfcpp::Elf_Word value, elfcpp::Elf_Word addend)
562 { This::template rela<32>(view, value, addend); }
564 static inline void
565 rela32(unsigned char* view,
566 const Sized_relobj<size, big_endian>* object,
567 const Symbol_value<size>* psymval,
568 elfcpp::Elf_Word addend)
569 { This::template rela<32>(view, object, psymval, addend); }
571 // Do a simple 32-bit PC relative REL relocation with the addend in
572 // the section contents.
573 static inline void
574 pcrel32(unsigned char* view, elfcpp::Elf_Word value,
575 typename elfcpp::Elf_types<size>::Elf_Addr address)
576 { This::template pcrel<32>(view, value, address); }
578 static inline void
579 pcrel32(unsigned char* view,
580 const Sized_relobj<size, big_endian>* object,
581 const Symbol_value<size>* psymval,
582 typename elfcpp::Elf_types<size>::Elf_Addr address)
583 { This::template pcrel<32>(view, object, psymval, address); }
585 // Do a simple 32-bit PC relative RELA relocation with the addend in
586 // the relocation.
587 static inline void
588 pcrela32(unsigned char* view, elfcpp::Elf_Word value,
589 elfcpp::Elf_Word addend,
590 typename elfcpp::Elf_types<size>::Elf_Addr address)
591 { This::template pcrela<32>(view, value, addend, address); }
593 static inline void
594 pcrela32(unsigned char* view,
595 const Sized_relobj<size, big_endian>* object,
596 const Symbol_value<size>* psymval,
597 elfcpp::Elf_Word addend,
598 typename elfcpp::Elf_types<size>::Elf_Addr address)
599 { This::template pcrela<32>(view, object, psymval, addend, address); }
601 // Do a simple 64-bit REL relocation with the addend in the section
602 // contents.
603 static inline void
604 rel64(unsigned char* view, elfcpp::Elf_Xword value)
605 { This::template rel<64>(view, value); }
607 static inline void
608 rel64(unsigned char* view,
609 const Sized_relobj<size, big_endian>* object,
610 const Symbol_value<size>* psymval)
611 { This::template rel<64>(view, object, psymval); }
613 // Do a 64-bit RELA relocation with the addend in the relocation.
614 static inline void
615 rela64(unsigned char* view, elfcpp::Elf_Xword value,
616 elfcpp::Elf_Xword addend)
617 { This::template rela<64>(view, value, addend); }
619 static inline void
620 rela64(unsigned char* view,
621 const Sized_relobj<size, big_endian>* object,
622 const Symbol_value<size>* psymval,
623 elfcpp::Elf_Xword addend)
624 { This::template rela<64>(view, object, psymval, addend); }
626 // Do a simple 64-bit PC relative REL relocation with the addend in
627 // the section contents.
628 static inline void
629 pcrel64(unsigned char* view, elfcpp::Elf_Xword value,
630 typename elfcpp::Elf_types<size>::Elf_Addr address)
631 { This::template pcrel<64>(view, value, address); }
633 static inline void
634 pcrel64(unsigned char* view,
635 const Sized_relobj<size, big_endian>* object,
636 const Symbol_value<size>* psymval,
637 typename elfcpp::Elf_types<size>::Elf_Addr address)
638 { This::template pcrel<64>(view, object, psymval, address); }
640 // Do a simple 64-bit PC relative RELA relocation with the addend in
641 // the relocation.
642 static inline void
643 pcrela64(unsigned char* view, elfcpp::Elf_Xword value,
644 elfcpp::Elf_Xword addend,
645 typename elfcpp::Elf_types<size>::Elf_Addr address)
646 { This::template pcrela<64>(view, value, addend, address); }
648 static inline void
649 pcrela64(unsigned char* view,
650 const Sized_relobj<size, big_endian>* object,
651 const Symbol_value<size>* psymval,
652 elfcpp::Elf_Xword addend,
653 typename elfcpp::Elf_types<size>::Elf_Addr address)
654 { This::template pcrela<64>(view, object, psymval, addend, address); }
657 // Track relocations while reading a section. This lets you ask for
658 // the relocation at a certain offset, and see how relocs occur
659 // between points of interest.
661 template<int size, bool big_endian>
662 class Track_relocs
664 public:
665 Track_relocs()
666 : prelocs_(NULL), len_(0), pos_(0), reloc_size_(0)
669 // Initialize the Track_relocs object. OBJECT is the object holding
670 // the reloc section, RELOC_SHNDX is the section index of the reloc
671 // section, and RELOC_TYPE is the type of the reloc section
672 // (elfcpp::SHT_REL or elfcpp::SHT_RELA). This returns false if
673 // something went wrong.
674 bool
675 initialize(Object* object, unsigned int reloc_shndx,
676 unsigned int reloc_type);
678 // Return the offset in the data section to which the next reloc
679 // applies. THis returns -1 if there is no next reloc.
680 off_t
681 next_offset() const;
683 // Return the symbol index of the next reloc. This returns -1U if
684 // there is no next reloc.
685 unsigned int
686 next_symndx() const;
688 // Advance to OFFSET within the data section, and return the number
689 // of relocs which would be skipped.
691 advance(off_t offset);
693 private:
694 // The contents of the input object's reloc section.
695 const unsigned char* prelocs_;
696 // The length of the reloc section.
697 section_size_type len_;
698 // Our current position in the reloc section.
699 section_size_type pos_;
700 // The size of the relocs in the section.
701 int reloc_size_;
704 } // End namespace gold.
706 #endif // !defined(GOLD_RELOC_H)