[lld] [lld][ELF] Fix FileCheck RUN line in gc-sections-keep-shared-start.s. NFC (PR #207678)
Ying Chen via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 6 00:57:40 PDT 2026
https://github.com/punkyc created https://github.com/llvm/llvm-project/pull/207678
Fix a malformed multiline RUN line. The test previously executed llvm-readelf
but did not pipe its output to FileCheck, so the CHECK lines were not verified.
After enabling FileCheck, update the expected entry point, symbol addresses, and
section index for the current output.
>From 2a8fc9182f619ad0baad551c70507ea11e75a116 Mon Sep 17 00:00:00 2001
From: punkyc <chenying at inchitech.com>
Date: Mon, 6 Jul 2026 15:54:14 +0800
Subject: [PATCH] [lld][ELF] Fix FileCheck RUN line in
gc-sections-keep-shared-start.s. NFC
---
lld/test/ELF/gc-sections-keep-shared-start.s | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/lld/test/ELF/gc-sections-keep-shared-start.s b/lld/test/ELF/gc-sections-keep-shared-start.s
index 7eb3c6ce3b852..0d1fe703f1a78 100644
--- a/lld/test/ELF/gc-sections-keep-shared-start.s
+++ b/lld/test/ELF/gc-sections-keep-shared-start.s
@@ -2,12 +2,12 @@
# RUN: llvm-mc -filetype=obj -triple=x86_64-unknown-linux %s -o %t
# RUN: ld.lld -shared --gc-sections -o %t1 %t
-# RUN: llvm-readelf --file-headers --symbols %t1
-# | FileCheck %s
-# CHECK: Entry point address: 0x1000
-# CHECK: 0000000000001000 0 FUNC LOCAL HIDDEN 4 _start
-# CHECK: 0000000000001006 0 FUNC LOCAL HIDDEN 4 internal
-# CHECK: 0000000000001005 0 FUNC GLOBAL DEFAULT 4 foobar
+# RUN: llvm-readelf --file-headers --symbols %t1 \
+# RUN: | FileCheck %s
+# CHECK: Entry point address: 0x1238
+# CHECK: 0000000000001238 0 FUNC LOCAL HIDDEN 5 _start
+# CHECK: 000000000000123e 0 FUNC LOCAL HIDDEN 5 internal
+# CHECK: 000000000000123d 0 FUNC GLOBAL DEFAULT 5 foobar
.section .text.start,"ax"
.globl _start
More information about the llvm-commits
mailing list