[PATCH v4 10/12] RISC-V/gas: warn about non-power-of-2 stack-align attribute

Project / Subsystem

binutils / risc-v/gas

Date

2026-07-24

Proposer

Jan Beulich <jbeulich@suse.com>

Source type

public_inbox

Consensus

Proposed

Sentiment

/10

Technical tradeoffs

  • Adds a runtime check (warning) in the assembler for a specific attribute.
  • Does not reject non-power-of-2 values outright, allowing for later BFD handling or user ignorance.

All attributes

project
binutils
subsystem
risc-v/gas
patch_id
discussion_id
6f5e4577-ec5e-4393-9df0-3b9c50de7d81@suse.com
source_type
public_inbox
title
[PATCH v4 10/12] RISC-V/gas: warn about non-power-of-2 stack-align attribute
headline
RISC-V/gas: warn about non-power-of-2 stack-align attribute
tldr
Warn about non-power-of-2 values for the RISC-V stack_align attribute in the assembler.
proposer
Jan Beulich <jbeulich@suse.com>
consensus
Proposed
outcome
ready
sentiment_score
technical_tradeoffs
  • Adds a runtime check (warning) in the assembler for a specific attribute.
  • Does not reject non-power-of-2 values outright, allowing for later BFD handling or user ignorance.
series_id
binutils:risc-v/gas: warn about non-power-of-2 stack-align attribute
series_role
reply
series_parts
[]
tags
  • binutils
  • risc-v
  • gas
  • attribute
  • warning
bugzilla_url
date
2026-07-24T00:00:00.000Z

[PATCH v4 10/12] RISC-V/gas: warn about non-power-of-2 stack-align attribute

This patch adds a warning to the RISC-V GNU Assembler (gas) when the .attribute stack_align directive is used with a non-power-of-2 value. This ensures that developers are informed about potentially invalid alignment settings, which could lead to incorrect behavior or performance issues.