Skip to content
  1. Jan 15, 2013
    • Jack Carter's avatar
      This patch fixes a Mips specific bug where · f238510c
      Jack Carter authored
      we need to generate a N64 compound relocation
      R_MIPS_GPREL_32/R_MIPS_64/R_MIPS_NONE.
      
      The bug was exposed by the SingleSourcetest case 
      DuffsDevice.c.
      
      Contributer: Jack Carter
      llvm-svn: 172496
      f238510c
  2. Nov 22, 2012
    • Jack Carter's avatar
      Mips direct object xgot support · b05cb67b
      Jack Carter authored
      This patch provides support for the MIPS relocations:
      
          *)  R_MIPS_GOT_HI16
          *)  R_MIPS_GOT_LO16
          *)  R_MIPS_CALL_HI16
          *)  R_MIPS_CALL_LO16
      
      These are used for large GOT instruction sequences.
      
      Contributer: Jack Carter
      llvm-svn: 168471
      b05cb67b
  3. Aug 22, 2012
    • Jack Carter's avatar
      For mips64 switch statements in subroutines could generate · 77064c05
      Jack Carter authored
      within the codegen EK_GPRel64BlockAddress. This was not 
      supported for direct object output and resulted in an assertion.
      
      This change adds support for EK_GPRel64BlockAddress for 
      direct object.
      
      One fallout from this is to turn on rela relocations 
      for mips64 to match gas.
      
      llvm-svn: 162334
      77064c05
  4. Aug 17, 2012
  5. Aug 07, 2012
  6. Aug 06, 2012
    • Jack Carter's avatar
      Mips relocations R_MIPS_HIGHER and R_MIPS_HIGHEST. · 84491abb
      Jack Carter authored
      These 2 relocations gain access to the 
      highest and the second highest 16 bits
      of a 64 bit object.
      
      R_MIPS_HIGHER %higher(A+S)
      The %higher(x) function is [ (((long long) x + 0x80008000LL) >> 32) & 0xffff ]. 
      
      R_MIPS_HIGHEST %highest(A+S)
      The %highest(x) function is [ (((long long) x + 0x800080008000LL) >> 48) & 0xffff ]. 
      
      llvm-svn: 161348
      84491abb
  7. Jul 13, 2012
    • Jack Carter's avatar
      The Mips specific relocation R_MIPS_GOT_DISP · 5ddcfda8
      Jack Carter authored
      is used in cases where global symbols are 
      directly represented in the GOT and we use an 
      offset into the global offset table.
      
      This patch adds direct object support for R_MIPS_GOT_DISP.
      
      llvm-svn: 160183
      5ddcfda8
  8. Jun 28, 2012
    • Jack Carter's avatar
      This allows hello world to be compiled for Mips 64 direct object. · b9f9de93
      Jack Carter authored
      It takes advantage of r159299 which introduces relocation support for N64. 
      elf-dump needed to be upgraded to support N64 relocations as well.
      
      This passes make check.
      
      Jack
      
      llvm-svn: 159301
      b9f9de93
    • Jack Carter's avatar
      The ELF relocation record format is different for N64 · 8ad0c272
      Jack Carter authored
      which many Mips 64 ABIs use than for O64 which many 
      if not all other target ABIs use.
      
      Most architectures have the following 64 bit relocation record format:
      
        typedef struct
        {
          Elf64_Addr   r_offset; /* Address of reference */
          Elf64_Xword  r_info;   /* Symbol index and type of relocation */
        } Elf64_Rel;
      
        typedef struct
        {
          Elf64_Addr    r_offset;
          Elf64_Xword   r_info;
          Elf64_Sxword  r_addend;
        } Elf64_Rela;
      
      Whereas N64 has the following format:
      
        typedef struct
        {
          Elf64_Addr    r_offset;/* Address of reference */
          Elf64_Word  r_sym;     /* Symbol index */
          Elf64_Byte  r_ssym;    /* Special symbol */
          Elf64_Byte  r_type3;   /* Relocation type */
          Elf64_Byte  r_type2;   /* Relocation type */
          Elf64_Byte  r_type;    /* Relocation type */
        } Elf64_Rel;
      
        typedef struct
        {
          Elf64_Addr    r_offset;/* Address of reference */
          Elf64_Word  r_sym;     /* Symbol index */
          Elf64_Byte  r_ssym;    /* Special symbol */
          Elf64_Byte  r_type3;   /* Relocation type */
          Elf64_Byte  r_type2;   /* Relocation type */
          Elf64_Byte  r_type;    /* Relocation type */
          Elf64_Sxword  r_addend;
        } Elf64_Rela;
      
      The structure is the same size, but the r_info data element 
      is now 5 separate elements. Besides the content aspects, 
      endian byte reordering will be different for the area with 
      each element being endianized separately.
      
      I treat this as generic and continue to pass r_type as 
      an integer masking and unmasking the byte sized N64 
      values for N64 mode. I've implemented this and it causes no 
      affect on other current targets.
      
      This passes make check.
      
      Jack
      
      llvm-svn: 159299
      8ad0c272
  9. Jun 14, 2012
  10. Apr 02, 2012
    • Akira Hatanaka's avatar
      Initial 64 bit direct object support. · b1f68f96
      Akira Hatanaka authored
      This patch allows llvm to recognize that a 64 bit object file is being produced
      and that the subsequently generated ELF header has the correct information.
      
      The test case checks for both big and little endian flavors.
      
      Patch by Jack Carter.
      
      llvm-svn: 153889
      b1f68f96
  11. Mar 28, 2012
  12. Mar 01, 2012
  13. Feb 17, 2012
  14. Jan 28, 2012
  15. Dec 22, 2011
Loading