From: Max Filippov Date: Thu, 18 Aug 2022 09:46:38 +0000 (-0700) Subject: xtensa: adjust expected output in ld TLS tests X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=1a51864b467c2d65bd37c3bc9cbab2cf1ee6a039;p=binutils-gdb.git xtensa: adjust expected output in ld TLS tests objdump output for l32r opcode was changed in commit b3ea76397a07 ("opcodes: xtensa: display loaded literal value"), but xtensa linker TLS relaxation tests weren't adjusted accordingly. readelf output was changed in commit 23356397449a ("Adjust readelf's output so that section symbols without a name as shown with their section name."), but xtensa linker TLS relaxation tests weren't adjusted accordingly. Fix expected output changes in xtensa ld TLS relaxation tests. ld/ * testsuite/ld-xtensa/tlsbin.dd: Adjust expected output for l32r opcodes. * testsuite/ld-xtensa/tlsbin.rd: Adjust expected output to allow for named section symbols. * testsuite/ld-xtensa/tlspic.dd: Adjust expected output for l32r opcodes. * testsuite/ld-xtensa/tlspic.rd: Adjust expected output to allow for named section symbols. --- diff --git a/ld/testsuite/ld-xtensa/tlsbin.dd b/ld/testsuite/ld-xtensa/tlsbin.dd index c3fad8bb31b..e13a3f91f35 100644 --- a/ld/testsuite/ld-xtensa/tlsbin.dd +++ b/ld/testsuite/ld-xtensa/tlsbin.dd @@ -12,54 +12,54 @@ Disassembly of section \.text: [0-9a-f]+: [0-9a-f]+[ ]+entry a1, 32 # GD -> IE because variable is not defined in executable [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a8 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 4001ec <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 4001ec <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a10, a10, a8 # GD -> IE because variable is not defined in executable where # the variable is referenced through IE too [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a8 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 4001f4 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 4001f4 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a10, a10, a8 # GD -> LE with global variable defined in executable [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a8 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 4001fc <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 4001fc <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a10, a10, a8 # GD -> LE with local variable defined in executable [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a8 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 400204 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 400204 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a10, a10, a8 # GD -> LE with hidden variable defined in executable [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a8 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 40020c <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 40020c <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a10, a10, a8 # LD -> LE [0-9a-f]+: [0-9a-f]+[ ]+nop.* [0-9a-f]+: [0-9a-f]+[ ]+nop.* [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a10 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a12, 400218 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a12, 400218 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a12, a12, a10 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a13, 40021c <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a13, 40021c <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a13, a13, a10 # LD -> LE against hidden variables - [0-9a-f]+: [0-9a-f]+[ ]+l32r a12, 400220 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a12, 400220 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a12, a12, a10 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a13, 400224 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a13, 400224 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a13, a13, a10 # # IE against global var [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a2 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a3, 400228 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a3, 400228 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a3, a3, a2 # IE -> LE against global var defined in exec [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a4 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a5, 40022c <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a5, 40022c <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a5, a5, a4 # IE -> LE against local var [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a6 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a7, 400230 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a7, 400230 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a7, a7, a6 # IE -> LE against hidden var [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a8 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a9, 400234 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a9, 400234 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a9, a9, a8 # [0-9a-f]+: [0-9a-f]+[ ]+retw.* diff --git a/ld/testsuite/ld-xtensa/tlsbin.rd b/ld/testsuite/ld-xtensa/tlsbin.rd index 09c6b215692..49e68c80afb 100644 --- a/ld/testsuite/ld-xtensa/tlsbin.rd +++ b/ld/testsuite/ld-xtensa/tlsbin.rd @@ -69,19 +69,19 @@ Symbol table '\.dynsym' contains [0-9]+ entries: Symbol table '\.symtab' contains [0-9]+ entries: +Num: +Value +Size +Type +Bind +Vis +Ndx +Name +[0-9]+: 0+ +0 +NOTYPE +LOCAL +DEFAULT +UND * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +1 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +2 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +3 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +4 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +5 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +6 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +7 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +8 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +9 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +10 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +11 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +12 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +13 * + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +1 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +2 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +3 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +4 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +5 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +6 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +7 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +8 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +9 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +10 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +11 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +12 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +13 .* +[0-9]+: [0-9a-f]+ +0 +FILE +LOCAL +DEFAULT +ABS .*tlsbin.o +[0-9]+: [0-9a-f]+ +0 +TLS +LOCAL +DEFAULT +8 sl1 +[0-9]+: [0-9a-f]+ +0 +TLS +LOCAL +DEFAULT +8 sl2 diff --git a/ld/testsuite/ld-xtensa/tlspic.dd b/ld/testsuite/ld-xtensa/tlspic.dd index 9f6e20ab81c..21edcc244a0 100644 --- a/ld/testsuite/ld-xtensa/tlspic.dd +++ b/ld/testsuite/ld-xtensa/tlspic.dd @@ -12,70 +12,70 @@ Disassembly of section \.text: 0+350 <_start>: [0-9a-f]+: [0-9a-f]+[ ]+entry a1, 32 # GD - [0-9a-f]+: [0-9a-f]+[ ]+l32r a8, 2e0 <.*> - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 2e4 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a8, 2e0 <.*> .* + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 2e4 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+callx8 a8 # GD -> IE because variable is referenced through IE too [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a8 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 2ec <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 2ec <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a10, a10, a8 # GD against local variable - [0-9a-f]+: [0-9a-f]+[ ]+l32r a8, 2f0 <.*> - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 2f4 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a8, 2f0 <.*> .* + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 2f4 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+callx8 a8 # GD -> IE against local variable referenced through IE too [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a8 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 2fc <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 2fc <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a10, a10, a8 # GD against hidden and local variable - [0-9a-f]+: [0-9a-f]+[ ]+l32r a8, 300 <.*> - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 304 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a8, 300 <.*> .* + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 304 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+callx8 a8 # GD -> IE against hidden and local variable referenced through IE too [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a8 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 30c <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 30c <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a10, a10, a8 # GD against hidden but not local variable - [0-9a-f]+: [0-9a-f]+[ ]+l32r a8, 310 <.*> - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 314 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a8, 310 <.*> .* + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 314 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+callx8 a8 # GD -> IE against hidden but not local variable referenced through IE too [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a8 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 31c <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 31c <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a10, a10, a8 # LD - [0-9a-f]+: [0-9a-f]+[ ]+l32r a8, 320 <.*> - [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 324 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a8, 320 <.*> .* + [0-9a-f]+: [0-9a-f]+[ ]+l32r a10, 324 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+callx8 a8 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a12, 328 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a12, 328 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a12, a12, a10 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a13, 32c <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a13, 32c <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a13, a13, a10 # LD against hidden and local variables - [0-9a-f]+: [0-9a-f]+[ ]+l32r a12, 330 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a12, 330 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a12, a12, a10 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a13, 334 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a13, 334 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a13, a13, a10 # LD against hidden but not local variables - [0-9a-f]+: [0-9a-f]+[ ]+l32r a12, 338 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a12, 338 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a12, a12, a10 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a13, 33c <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a13, 33c <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a13, a13, a10 # IE against global var [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a2 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a3, 340 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a3, 340 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a3, a3, a2 # IE against local var [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a4 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a5, 344 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a5, 344 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a5, a5, a4 # IE against hidden and local var [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a6 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a7, 348 <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a7, 348 <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a7, a7, a6 # IE against hidden but not local var [0-9a-f]+: [0-9a-f]+[ ]+rur.threadptr a8 - [0-9a-f]+: [0-9a-f]+[ ]+l32r a9, 34c <.*> + [0-9a-f]+: [0-9a-f]+[ ]+l32r a9, 34c <.*> .* [0-9a-f]+: [0-9a-f]+[ ]+add.* a9, a9, a8 # [0-9a-f]+: [0-9a-f]+[ ]+retw.* diff --git a/ld/testsuite/ld-xtensa/tlspic.rd b/ld/testsuite/ld-xtensa/tlspic.rd index 70d8ef43d41..bd24910adf6 100644 --- a/ld/testsuite/ld-xtensa/tlspic.rd +++ b/ld/testsuite/ld-xtensa/tlspic.rd @@ -87,19 +87,19 @@ Symbol table '\.dynsym' contains [0-9]+ entries: Symbol table '\.symtab' contains [0-9]+ entries: +Num: +Value +Size +Type +Bind +Vis +Ndx +Name +[0-9]+: 0+ +0 +NOTYPE +LOCAL +DEFAULT +UND * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +1 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +2 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +3 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +4 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +5 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +6 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +7 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +8 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +9 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +10 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +11 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +12 * - +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +13 * + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +1 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +2 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +3 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +4 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +5 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +6 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +7 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +8 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +9 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +10 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +11 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +12 .* + +[0-9]+: [0-9a-f]+ +0 +SECTION +LOCAL +DEFAULT +13 .* +[0-9]+: [0-9a-f]+ +0 +FILE +LOCAL +DEFAULT +ABS .*tlspic1.o +[0-9]+: 0+20 +0 +TLS +LOCAL +DEFAULT +7 sl1 +[0-9]+: 0+24 +0 +TLS +LOCAL +DEFAULT +7 sl2