Skip to content

arch/arm: remove duplicate .globl for up_saveusercontext#19220

Merged
acassis merged 7 commits into
apache:masterfrom
Junbo-Zheng:arm
Jun 26, 2026
Merged

arch/arm: remove duplicate .globl for up_saveusercontext#19220
acassis merged 7 commits into
apache:masterfrom
Junbo-Zheng:arm

Conversation

@Junbo-Zheng

Copy link
Copy Markdown
Contributor

Summary

Each arm_saveusercontext.S under arch/arm/src/ declared the
up_saveusercontext symbol with .globl on two consecutive, identical lines.
The .globl directive is idempotent, so the second declaration is a no-op that
has no effect on the generated object — it is just dead text that diverges from
the single-declaration convention used by every other .S file in these
directories.

This PR removes the redundant .globl up_saveusercontext line from each of the
seven affected ARM sub-architectures (one commit per file):

  • arch/arm/src/arm/arm_saveusercontext.S
  • arch/arm/src/armv6-m/arm_saveusercontext.S
  • arch/arm/src/armv7-a/arm_saveusercontext.S
  • arch/arm/src/armv7-m/arm_saveusercontext.S
  • arch/arm/src/armv7-r/arm_saveusercontext.S
  • arch/arm/src/armv8-m/arm_saveusercontext.S
  • arch/arm/src/armv8-r/arm_saveusercontext.S

Impact

  • Users: None. No API, behavior, or symbol-table change.
  • Build: None. The emitted object is byte-for-byte identical because
    .globl is idempotent.
  • Hardware: None.
  • Documentation: None.
  • Security / Compatibility: None.

This is a pure source-cleanup change with no functional effect.

Testing

This is a no-op source cleanup: .globl is idempotent, so removing the
duplicate declaration cannot change the generated object — the symbol table for
up_saveusercontext is identical before and after.

Verified only that the affected sub-architectures still build cleanly
(tools/configure.sh <board>:nsh + make -j22)

The up_saveusercontext symbol was declared with .globl twice in a
row. The .globl directive is idempotent, so the duplicate line has
no effect on the generated object; drop it to match the single
declaration used by the other .S files in this directory.

Signed-off-by: Junbo Zheng <zhengjunbo1@xiaomi.com>
The up_saveusercontext symbol was declared with .globl twice in a
row. The .globl directive is idempotent, so the duplicate line has
no effect on the generated object; drop it to match the single
declaration used by the other .S files in this directory.

Signed-off-by: Junbo Zheng <zhengjunbo1@xiaomi.com>
The up_saveusercontext symbol was declared with .globl twice in a
row. The .globl directive is idempotent, so the duplicate line has
no effect on the generated object; drop it to match the single
declaration used by the other .S files in this directory.

Signed-off-by: Junbo Zheng <zhengjunbo1@xiaomi.com>
The up_saveusercontext symbol was declared with .globl twice in a
row. The .globl directive is idempotent, so the duplicate line has
no effect on the generated object; drop it to match the single
declaration used by the other .S files in this directory.

Signed-off-by: Junbo Zheng <zhengjunbo1@xiaomi.com>
The up_saveusercontext symbol was declared with .globl twice in a
row. The .globl directive is idempotent, so the duplicate line has
no effect on the generated object; drop it to match the single
declaration used by the other .S files in this directory.

Signed-off-by: Junbo Zheng <zhengjunbo1@xiaomi.com>
The up_saveusercontext symbol was declared with .globl twice in a
row. The .globl directive is idempotent, so the duplicate line has
no effect on the generated object; drop it to match the single
declaration used by the other .S files in this directory.

Signed-off-by: Junbo Zheng <zhengjunbo1@xiaomi.com>
The up_saveusercontext symbol was declared with .globl twice in a
row. The .globl directive is idempotent, so the duplicate line has
no effect on the generated object; drop it to match the single
declaration used by the other .S files in this directory.

Signed-off-by: Junbo Zheng <zhengjunbo1@xiaomi.com>
@github-actions github-actions Bot added Arch: arm Issues related to ARM (32-bit) architecture Size: XS The size of the change in this PR is very small labels Jun 26, 2026
@github-actions

Copy link
Copy Markdown

MemBrowse Memory Report

No memory changes detected for:

@acassis acassis merged commit 578b303 into apache:master Jun 26, 2026
38 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Arch: arm Issues related to ARM (32-bit) architecture Size: XS The size of the change in this PR is very small

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants