This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[vms/committed]: Write linkage index from relocs


Hi,

while writing the conditional reloc entries, linkage index was simply incremented instead of being
written from the reloc entries.  This was wrong, but may have worked by chance.

Now fixed.

Tristan.

bfd/
2011-06-28  Tristan Gingold  <gingold@adacore.com>

	* vms-alpha.c (vms_private_data_struct): Make vms_linkage_index
	unsigned int.
	(_bfd_vms_write_etir): Write linkage index from reloc.


RCS file: /cvs/src/src/bfd/vms-alpha.c,v
retrieving revision 1.49
diff -c -r1.49 vms-alpha.c
*** vms-alpha.c	27 Jun 2011 13:03:15 -0000	1.49
--- vms-alpha.c	28 Jun 2011 08:39:12 -0000
***************
*** 330,336 ****
    struct vms_internal_eisd_map *gbl_eisd_tail;
  
    /* linkage index counter used by conditional store commands */
!   int vms_linkage_index;
  
    /* see tc-alpha.c of gas for a description.  */
    int flag_hash_long_names;	/* -+, hash instead of truncate */
--- 330,336 ----
    struct vms_internal_eisd_map *gbl_eisd_tail;
  
    /* linkage index counter used by conditional store commands */
!   unsigned int vms_linkage_index;
  
    /* see tc-alpha.c of gas for a description.  */
    int flag_hash_long_names;	/* -+, hash instead of truncate */
***************
*** 3947,3954 ****
  		  etir_output_check (abfd, section, curr_addr, 64);
  		  _bfd_vms_output_begin_subrec (recwr, ETIR__C_STC_LP_PSB);
  		  _bfd_vms_output_long
! 		    (recwr, (unsigned long) PRIV (vms_linkage_index));
! 		  PRIV (vms_linkage_index) += 2;
  		  hash = _bfd_vms_length_hash_symbol
                      (abfd, sym->name, EOBJ__C_SYMSIZ);
  		  _bfd_vms_output_counted (recwr, hash);
--- 3947,3955 ----
  		  etir_output_check (abfd, section, curr_addr, 64);
  		  _bfd_vms_output_begin_subrec (recwr, ETIR__C_STC_LP_PSB);
  		  _bfd_vms_output_long
! 		    (recwr, (unsigned long) rptr->addend);
!                   if (rptr->addend > PRIV (vms_linkage_index))
!                     PRIV (vms_linkage_index) = rptr->addend;
  		  hash = _bfd_vms_length_hash_symbol
                      (abfd, sym->name, EOBJ__C_SYMSIZ);
  		  _bfd_vms_output_counted (recwr, hash);


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]