/* BFD back-end for AMD 64 COFF files.
- Copyright (C) 2006-2015 Free Software Foundation, Inc.
+ Copyright (C) 2006-2017 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
case 4:
{
- long long x = bfd_get_64 (abfd, addr);
+ bfd_uint64_t x = bfd_get_64 (abfd, addr);
DOIT (x);
- bfd_put_64 (abfd, (bfd_vma) x, addr);
+ bfd_put_64 (abfd, x, addr);
}
break;
#if defined(COFF_WITH_PE)
if (howto->pc_relative)
{
- *addendp -= 4;
+#ifndef DONT_EXTEND_AMD64
+ if (rel->r_type == R_AMD64_PCRQUAD)
+ *addendp -= 8;
+ else
+#endif
+ *addendp -= 4;
/* If the symbol is defined, then the generic code is going to
add back the symbol value in order to cancel out an