Thank you for your guidance,your opinion is very valuable。 I'll take your advice in version v3, I will remove ".cfi", ".file" and ".ident" things (and other unneeded things) from the test case, and the related code format modification. From: Xi Ruoyao Date: 2023-12-02 15:17:10 To: changjiachen ,binutils@sourceware.org Cc: xuchenghua@loongson.cn,chenglulu@loongson.cn,liuzhensong@loongson.cn,i.swmail@xen0n.name,maskray@google.com,cailulu@loongson.cn,luweining@loongson.cn,wanglei@loongson.cn,hejinyang@loongson.cn,Lazy_Linux@126.com,mengqinggang@loongson.cn Subject: Re: [PATCH v2 5/5] LoongArch: ld: Add support for tls le relax.>On Sat, 2023-12-02 at 14:53 +0800, changjiachen wrote: >> + .file "tls_relax_compatible_check_new.c" >> + .text >> + .globl new >> + .section .tbss,"awT",@nobits >> + .align 2 >> + .type new, @object >> + .size new, 4 >> +new: >> + .space 4 >> + .text >> + .align 2 >> + .globl main >> + .type main, @function >> +main: >> +.LFB0 = . >> + .cfi_startproc >> + addi.d $r3,$r3,-16 >> + .cfi_def_cfa_offset 16 >> + st.d $r1,$r3,8 >> + stptr.d $r22,$r3,0 >> + .cfi_offset 1, -8 >> + .cfi_offset 22, -16 >> + addi.d $r22,$r3,16 >> + .cfi_def_cfa 22, 0 >> + bl %plt(old) >> + lu12i.w $r12,%tls_le_hi20(new) >> + add.d $r12,$r12,$r2,%tprel_add(new) >> + addi.w $r13,$r0,2 # 0x2 >> + st.w $r13,$r12,%tls_le_lo12(new) >> + or $r12,$r0,$r0 >> + or $r4,$r12,$r0 >> + ld.d $r1,$r3,8 >> + .cfi_restore 1 >> + ldptr.d $r22,$r3,0 >> + .cfi_restore 22 >> + addi.d $r3,$r3,16 >> + .cfi_def_cfa_register 3 >> + jr $r1 >> + .cfi_endproc >> +.LFE0: >> + .size main, .-main >> + .ident "GCC: (GNU) 14.0.0 20230526 (experimental)" >> + .section .note.GNU-stack,"",@progbits > >Please remove ".cfi", ".file" and ".ident" things (and other unneeded >things) from the test case. > >-- >Xi Ruoyao >School of Aerospace Science and Technology, Xidian University