Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RFC] Defining an ELF attribute for RISC-V target profiles #409

Closed
wants to merge 1 commit into from

Commits on Nov 28, 2023

  1. Defining an ELF attribute for RISC-V target profiles

    This commit defines an ELF attribute which allows tools to set
    a RISC-V target profile.
    
    We already have a few ratified RISC-V profiles, but so far they are treated
    as "pretty names" (or non-canonical abbreviations) for an ISA base plus a
    set of extensions.
    
    Further, most of the extensions of a profile are irrelevant for toolchain
    components (e.g. supervisor mode extensions) and thus it is not clear how
    to decompose profiles into an tools-compatible arch string, that allows to
    reliably reconstruct the profile that a piece of software was written for
    (i.e., the profile that the execution environment is expected to implement).
    
    This commit attempts to resolve this situation by defining a new attribute
    that allows to store the target profile.
    
    The string representation is used to ensure a future-proof encoding.
    This should not be a performance issue, since profile names are
    typically very short (less than 10 characters).
    
    This commit also provides a few hints for linkers and run-times, but does
    not mandate anything.
    
    Signed-off-by: Christoph Müllner <[email protected]>
    cmuellner committed Nov 28, 2023
    Configuration menu
    Copy the full SHA
    1834afe View commit details
    Browse the repository at this point in the history