Symbols with GOT relocatios do not fix adjustbale
authormengqinggang <mengqinggang@loongson.cn>
Tue, 18 Apr 2023 10:49:21 +0000 (11:49 +0100)
committerNick Clifton <nickc@redhat.com>
Tue, 18 Apr 2023 10:49:21 +0000 (11:49 +0100)
  gas
    * config/tc-loongarch.c (loongarch_fix_adjustable): Symbols with GOT relocatios do not fix adjustbale.
    * testsuite/gas/loongarch/macro_op_large_abs.d: Regenerated.
    * testsuite/gas/loongarch/macro_op_large_pc.d: Regenerated.
  ld
     * testsuite/ld-loongarch-elf/macro_op.d: Regenerated. -

gas/ChangeLog
gas/config/tc-loongarch.c
gas/testsuite/gas/loongarch/macro_op_large_abs.d
gas/testsuite/gas/loongarch/macro_op_large_pc.d
ld/ChangeLog
ld/testsuite/ld-loongarch-elf/macro_op.d

index 760230dc7b6e76c83c850f659ec6a8ac00c32048..80548d24ba641d596b63e70442e3fb3a1a792723 100644 (file)
@@ -1,3 +1,10 @@
+2023-04-18  mengqinggang  <mengqinggang@loongson.cn>
+
+       * config/tc-loongarch.c (loongarch_fix_adjustable): Symbols with
+       GOT relocatios do not fix adjustbale.
+       * testsuite/gas/loongarch/macro_op_large_abs.d: Regenerated.
+       * testsuite/gas/loongarch/macro_op_large_pc.d: Regenerated.
+
 2023-04-18  Thomas Koenig  <tkoenig@netcologne.de>
 
        * doc/internals.texi (Relaxing with a table): Describe handling of
index dd47581ed7ac2be22628d300a111a3b7a00b041a..7d8749c59516102832bedb17d6afe6708c03883c 100644 (file)
@@ -1270,6 +1270,21 @@ loongarch_fix_adjustable (fixS *fix)
       || S_FORCE_RELOC (fix->fx_addsy, true))
     return 0;
 
+  /* Loongarch loads extern symbols by GOT, and if there are embedded
+     asm(".local S"), gcc just output ".local S" to assembly file.
+     For a local symbol with GOT relocations, this adjustments will make
+     GOT relocation's addend not equal to zero. So this adjustments is
+     forbidden for got relocs.  */
+  if(fix->fx_r_type == BFD_RELOC_LARCH_GOT_PC_HI20
+      || fix->fx_r_type == BFD_RELOC_LARCH_GOT_PC_LO12
+      || fix->fx_r_type == BFD_RELOC_LARCH_GOT64_PC_LO20
+      || fix->fx_r_type == BFD_RELOC_LARCH_GOT64_PC_HI12
+      || fix->fx_r_type == BFD_RELOC_LARCH_GOT_HI20
+      || fix->fx_r_type == BFD_RELOC_LARCH_GOT_LO12
+      || fix->fx_r_type == BFD_RELOC_LARCH_GOT64_LO20
+      || fix->fx_r_type == BFD_RELOC_LARCH_GOT64_HI12)
+    return 0;
+
   return 1;
 }
 
index c3214a859e6c92b496f2b71fbebae07f70bd09a9..c0b98dbbea2e8f72f93137f4829945fdae3efa81 100644 (file)
@@ -1,4 +1,4 @@
-#as:
+#as: -mla-global-with-abs
 #objdump: -dr
 #skip: loongarch32-*-*
 
@@ -7,7 +7,7 @@
 
 Disassembly of section .text:
 
-00000000.* <.text>:
+00000000.* <.L1>:
 [      ]+0:[   ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
 [      ]+0:[   ]+R_LARCH_PCALA_HI20[   ]+.text
 [      ]+4:[   ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
@@ -17,61 +17,61 @@ Disassembly of section .text:
 [      ]+c:[   ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
 [      ]+c:[   ]+R_LARCH_PCALA64_HI12[         ]+.text
 [      ]+10:[  ]+00109484[     ]+add.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
-[      ]+14:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+14:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
-[      ]+18:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
-[      ]+18:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
-[      ]+1c:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
-[      ]+1c:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.text
-[      ]+20:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
-[      ]+20:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.text
-[      ]+24:[  ]+380c1484[     ]+ldx.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
-[      ]+28:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+28:[  ]+R_LARCH_PCALA_HI20[   ]+.text
-[      ]+2c:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
-[      ]+2c:[  ]+R_LARCH_PCALA_LO12[   ]+.text
-[      ]+30:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
-[      ]+30:[  ]+R_LARCH_PCALA64_LO20[         ]+.text
-[      ]+34:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
-[      ]+34:[  ]+R_LARCH_PCALA64_HI12[         ]+.text
-[      ]+38:[  ]+00109484[     ]+add.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
-[      ]+3c:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+3c:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
-[      ]+40:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
-[      ]+40:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
-[      ]+44:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
-[      ]+44:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.text
-[      ]+48:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
-[      ]+48:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.text
-[      ]+4c:[  ]+380c1484[     ]+ldx.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
-[      ]+50:[  ]+14000004[     ]+lu12i.w[      ]+\$a0,[        ]+0
-[      ]+50:[  ]+R_LARCH_TLS_LE_HI20[  ]+TLS1
-[      ]+54:[  ]+03800084[     ]+ori[  ]+\$a0,[        ]+\$a0,[        ]+0x0
-[      ]+54:[  ]+R_LARCH_TLS_LE_LO12[  ]+TLS1
-[      ]+58:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+58:[  ]+R_LARCH_TLS_IE_PC_HI20[       ]+TLS1
-[      ]+5c:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
-[      ]+5c:[  ]+R_LARCH_TLS_IE_PC_LO12[       ]+TLS1
-[      ]+60:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
-[      ]+60:[  ]+R_LARCH_TLS_IE64_PC_LO20[     ]+TLS1
-[      ]+64:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
-[      ]+64:[  ]+R_LARCH_TLS_IE64_PC_HI12[     ]+TLS1
-[      ]+68:[  ]+380c1484[     ]+ldx.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
-[      ]+6c:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+6c:[  ]+R_LARCH_TLS_LD_PC_HI20[       ]+TLS1
-[      ]+70:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
-[      ]+70:[  ]+R_LARCH_GOT_PC_LO12[  ]+TLS1
-[      ]+74:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
-[      ]+74:[  ]+R_LARCH_GOT64_PC_LO20[        ]+TLS1
-[      ]+78:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
-[      ]+78:[  ]+R_LARCH_GOT64_PC_HI12[        ]+TLS1
-[      ]+7c:[  ]+00109484[     ]+add.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
-[      ]+80:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+80:[  ]+R_LARCH_TLS_GD_PC_HI20[       ]+TLS1
-[      ]+84:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
-[      ]+84:[  ]+R_LARCH_GOT_PC_LO12[  ]+TLS1
-[      ]+88:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
-[      ]+88:[  ]+R_LARCH_GOT64_PC_LO20[        ]+TLS1
-[      ]+8c:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
-[      ]+8c:[  ]+R_LARCH_GOT64_PC_HI12[        ]+TLS1
-[      ]+90:[  ]+00109484[     ]+add.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
+[      ]+14:[  ]+14000004[     ]+lu12i.w[      ]+\$a0,[        ]+0
+[      ]+14:[  ]+R_LARCH_MARK_LA[      ]+\*ABS\*
+[      ]+14:[  ]+R_LARCH_ABS_HI20[     ]+.text
+[      ]+18:[  ]+03800084[     ]+ori[  ]+\$a0,[        ]+\$a0,[        ]+0x0
+[      ]+18:[  ]+R_LARCH_ABS_LO12[     ]+.text
+[      ]+1c:[  ]+16000004[     ]+lu32i.d[      ]+\$a0,[        ]+0
+[      ]+1c:[  ]+R_LARCH_ABS64_LO20[   ]+.text
+[      ]+20:[  ]+03000084[     ]+lu52i.d[      ]+\$a0,[        ]+\$a0,[        ]+0
+[      ]+20:[  ]+R_LARCH_ABS64_HI12[   ]+.text
+[      ]+24:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
+[      ]+24:[  ]+R_LARCH_PCALA_HI20[   ]+.text
+[      ]+28:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
+[      ]+28:[  ]+R_LARCH_PCALA_LO12[   ]+.text
+[      ]+2c:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
+[      ]+2c:[  ]+R_LARCH_PCALA64_LO20[         ]+.text
+[      ]+30:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
+[      ]+30:[  ]+R_LARCH_PCALA64_HI12[         ]+.text
+[      ]+34:[  ]+00109484[     ]+add.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
+[      ]+38:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
+[      ]+38:[  ]+R_LARCH_GOT_PC_HI20[  ]+.L1
+[      ]+3c:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
+[      ]+3c:[  ]+R_LARCH_GOT_PC_LO12[  ]+.L1
+[      ]+40:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
+[      ]+40:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.L1
+[      ]+44:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
+[      ]+44:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.L1
+[      ]+48:[  ]+380c1484[     ]+ldx.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
+[      ]+4c:[  ]+14000004[     ]+lu12i.w[      ]+\$a0,[        ]+0
+[      ]+4c:[  ]+R_LARCH_TLS_LE_HI20[  ]+TLS1
+[      ]+50:[  ]+03800084[     ]+ori[  ]+\$a0,[        ]+\$a0,[        ]+0x0
+[      ]+50:[  ]+R_LARCH_TLS_LE_LO12[  ]+TLS1
+[      ]+54:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
+[      ]+54:[  ]+R_LARCH_TLS_IE_PC_HI20[       ]+TLS1
+[      ]+58:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
+[      ]+58:[  ]+R_LARCH_TLS_IE_PC_LO12[       ]+TLS1
+[      ]+5c:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
+[      ]+5c:[  ]+R_LARCH_TLS_IE64_PC_LO20[     ]+TLS1
+[      ]+60:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
+[      ]+60:[  ]+R_LARCH_TLS_IE64_PC_HI12[     ]+TLS1
+[      ]+64:[  ]+380c1484[     ]+ldx.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
+[      ]+68:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
+[      ]+68:[  ]+R_LARCH_TLS_LD_PC_HI20[       ]+TLS1
+[      ]+6c:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
+[      ]+6c:[  ]+R_LARCH_GOT_PC_LO12[  ]+TLS1
+[      ]+70:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
+[      ]+70:[  ]+R_LARCH_GOT64_PC_LO20[        ]+TLS1
+[      ]+74:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
+[      ]+74:[  ]+R_LARCH_GOT64_PC_HI12[        ]+TLS1
+[      ]+78:[  ]+00109484[     ]+add.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
+[      ]+7c:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
+[      ]+7c:[  ]+R_LARCH_TLS_GD_PC_HI20[       ]+TLS1
+[      ]+80:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
+[      ]+80:[  ]+R_LARCH_GOT_PC_LO12[  ]+TLS1
+[      ]+84:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
+[      ]+84:[  ]+R_LARCH_GOT64_PC_LO20[        ]+TLS1
+[      ]+88:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
+[      ]+88:[  ]+R_LARCH_GOT64_PC_HI12[        ]+TLS1
+[      ]+8c:[  ]+00109484[     ]+add.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
index c3214a859e6c92b496f2b71fbebae07f70bd09a9..3b532755b6ccbce141b1d5ebd29494784a42cba3 100644 (file)
@@ -7,7 +7,7 @@
 
 Disassembly of section .text:
 
-00000000.* <.text>:
+00000000.* <.L1>:
 [      ]+0:[   ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
 [      ]+0:[   ]+R_LARCH_PCALA_HI20[   ]+.text
 [      ]+4:[   ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
@@ -18,13 +18,13 @@ Disassembly of section .text:
 [      ]+c:[   ]+R_LARCH_PCALA64_HI12[         ]+.text
 [      ]+10:[  ]+00109484[     ]+add.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
 [      ]+14:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+14:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
+[      ]+14:[  ]+R_LARCH_GOT_PC_HI20[  ]+.L1
 [      ]+18:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
-[      ]+18:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
+[      ]+18:[  ]+R_LARCH_GOT_PC_LO12[  ]+.L1
 [      ]+1c:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
-[      ]+1c:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.text
+[      ]+1c:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.L1
 [      ]+20:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
-[      ]+20:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.text
+[      ]+20:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.L1
 [      ]+24:[  ]+380c1484[     ]+ldx.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
 [      ]+28:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
 [      ]+28:[  ]+R_LARCH_PCALA_HI20[   ]+.text
@@ -36,13 +36,13 @@ Disassembly of section .text:
 [      ]+34:[  ]+R_LARCH_PCALA64_HI12[         ]+.text
 [      ]+38:[  ]+00109484[     ]+add.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
 [      ]+3c:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+3c:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
+[      ]+3c:[  ]+R_LARCH_GOT_PC_HI20[  ]+.L1
 [      ]+40:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
-[      ]+40:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
+[      ]+40:[  ]+R_LARCH_GOT_PC_LO12[  ]+.L1
 [      ]+44:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
-[      ]+44:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.text
+[      ]+44:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.L1
 [      ]+48:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
-[      ]+48:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.text
+[      ]+48:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.L1
 [      ]+4c:[  ]+380c1484[     ]+ldx.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
 [      ]+50:[  ]+14000004[     ]+lu12i.w[      ]+\$a0,[        ]+0
 [      ]+50:[  ]+R_LARCH_TLS_LE_HI20[  ]+TLS1
index b829befb08e2222a96bd4fa2a8a5cd79a03c49cd..c4de32767843e9f7a38461e3529cf604055dc672 100644 (file)
@@ -1,3 +1,7 @@
+2023-04-18  mengqinggang  <mengqinggang@loongson.cn>
+
+       * testsuite/ld-loongarch-elf/macro_op.d: Regenerated.
+
 2023-04-17  Nick Clifton  <nickc@redhat.com>
 
        PR 30354
index a1c64fcf00fececdd92744c072eaf4e5cdf46028..39aa1fb929ff6cb2af079fc9ea139957dff2a6d5 100644 (file)
@@ -6,53 +6,53 @@
 
 Disassembly of section .text:
 
-00000000.* <.text>:
+00000000.* <.L1>:
 [      ]+0:[   ]+00150004[     ]+move[         ]+\$a0,[        ]+\$zero
 [      ]+4:[   ]+02bffc04[     ]+addi.w[       ]+\$a0,[        ]+\$zero,[      ]+-1\(0xfff\)
 [      ]+8:[   ]+00150004[     ]+move[         ]+\$a0,[        ]+\$zero
 [      ]+c:[   ]+02bffc04[     ]+addi.w[       ]+\$a0,[        ]+\$zero,[      ]+-1\(0xfff\)
 [      ]+10:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+10:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
+[      ]+10:[  ]+R_LARCH_GOT_PC_HI20[  ]+.L1
 [      ]+14:[  ]+28c00084[     ]+ld.d[         ]+\$a0,[        ]+\$a0,[        ]+0
-[      ]+14:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
+[      ]+14:[  ]+R_LARCH_GOT_PC_LO12[  ]+.L1
 [      ]+18:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+18:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
+[      ]+18:[  ]+R_LARCH_GOT_PC_HI20[  ]+.L1
 [      ]+1c:[  ]+28c00084[     ]+ld.d[         ]+\$a0,[        ]+\$a0,[        ]+0
-[      ]+1c:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
+[      ]+1c:[  ]+R_LARCH_GOT_PC_LO12[  ]+.L1
 [      ]+20:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+20:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
+[      ]+20:[  ]+R_LARCH_GOT_PC_HI20[  ]+.L1
 [      ]+24:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
-[      ]+24:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
+[      ]+24:[  ]+R_LARCH_GOT_PC_LO12[  ]+.L1
 [      ]+28:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
-[      ]+28:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.text
+[      ]+28:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.L1
 [      ]+2c:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
-[      ]+2c:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.text
+[      ]+2c:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.L1
 [      ]+30:[  ]+380c1484[     ]+ldx.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
 [      ]+34:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+34:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
+[      ]+34:[  ]+R_LARCH_GOT_PC_HI20[  ]+.L1
 [      ]+38:[  ]+28c00084[     ]+ld.d[         ]+\$a0,[        ]+\$a0,[        ]+0
-[      ]+38:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
+[      ]+38:[  ]+R_LARCH_GOT_PC_LO12[  ]+.L1
 [      ]+3c:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+3c:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
+[      ]+3c:[  ]+R_LARCH_GOT_PC_HI20[  ]+.L1
 [      ]+40:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
-[      ]+40:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
+[      ]+40:[  ]+R_LARCH_GOT_PC_LO12[  ]+.L1
 [      ]+44:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
-[      ]+44:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.text
+[      ]+44:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.L1
 [      ]+48:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
-[      ]+48:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.text
+[      ]+48:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.L1
 [      ]+4c:[  ]+380c1484[     ]+ldx.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
 [      ]+50:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+50:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
+[      ]+50:[  ]+R_LARCH_GOT_PC_HI20[  ]+.L1
 [      ]+54:[  ]+28c00084[     ]+ld.d[         ]+\$a0,[        ]+\$a0,[        ]+0
-[      ]+54:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
+[      ]+54:[  ]+R_LARCH_GOT_PC_LO12[  ]+.L1
 [      ]+58:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+58:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
+[      ]+58:[  ]+R_LARCH_GOT_PC_HI20[  ]+.L1
 [      ]+5c:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
-[      ]+5c:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
+[      ]+5c:[  ]+R_LARCH_GOT_PC_LO12[  ]+.L1
 [      ]+60:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
-[      ]+60:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.text
+[      ]+60:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.L1
 [      ]+64:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
-[      ]+64:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.text
+[      ]+64:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.L1
 [      ]+68:[  ]+380c1484[     ]+ldx.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
 [      ]+6c:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
 [      ]+6c:[  ]+R_LARCH_PCALA_HI20[   ]+.text
@@ -107,17 +107,17 @@ Disassembly of section .text:
 [      ]+d0:[  ]+R_LARCH_PCALA64_HI12[         ]+.text
 [      ]+d4:[  ]+00109484[     ]+add.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
 [      ]+d8:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+d8:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
+[      ]+d8:[  ]+R_LARCH_GOT_PC_HI20[  ]+.L1
 [      ]+dc:[  ]+28c00084[     ]+ld.d[         ]+\$a0,[        ]+\$a0,[        ]+0
-[      ]+dc:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
+[      ]+dc:[  ]+R_LARCH_GOT_PC_LO12[  ]+.L1
 [      ]+e0:[  ]+1a000004[     ]+pcalau12i[    ]+\$a0,[        ]+0
-[      ]+e0:[  ]+R_LARCH_GOT_PC_HI20[  ]+.text
+[      ]+e0:[  ]+R_LARCH_GOT_PC_HI20[  ]+.L1
 [      ]+e4:[  ]+02c00005[     ]+addi.d[       ]+\$a1,[        ]+\$zero,[      ]+0
-[      ]+e4:[  ]+R_LARCH_GOT_PC_LO12[  ]+.text
+[      ]+e4:[  ]+R_LARCH_GOT_PC_LO12[  ]+.L1
 [      ]+e8:[  ]+16000005[     ]+lu32i.d[      ]+\$a1,[        ]+0
-[      ]+e8:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.text
+[      ]+e8:[  ]+R_LARCH_GOT64_PC_LO20[        ]+.L1
 [      ]+ec:[  ]+030000a5[     ]+lu52i.d[      ]+\$a1,[        ]+\$a1,[        ]+0
-[      ]+ec:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.text
+[      ]+ec:[  ]+R_LARCH_GOT64_PC_HI12[        ]+.L1
 [      ]+f0:[  ]+380c1484[     ]+ldx.d[        ]+\$a0,[        ]+\$a0,[        ]+\$a1
 [      ]+f4:[  ]+14000004[     ]+lu12i.w[      ]+\$a0,[        ]+0
 [      ]+f4:[  ]+R_LARCH_TLS_LE_HI20[  ]+TLS1