https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117565

            Bug ID: 117565
           Summary: RISC-V: Make ABI implicit for non-default march
           Product: gcc
           Version: 15.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: rdapp at gcc dot gnu.org
                CC: kito.cheng at gmail dot com, law at gcc dot gnu.org,
                    palmer at dabbelt dot com, vineetg at rivosinc dot com
  Target Milestone: ---
            Target: riscv

This is not really high priority but has been discussed several times and at
some point we agreed to at least open a bug.

Right now e.g. -march=rv64gc mandates -mabi=lp64d (similar to how -march=rv32gc
or -march=rv64e mandate ABIs).  We use the default ABI for the default -march,
so it's sufficient to say
 gcc -march=rv64gc
in order to obtain the lp64d ABI.

When using -march=rv32gc on an -march=rv64gc default compiler, however,
-mabi=ilp32d needs to be specified even though there is not actually a choice
in ABIs.

Couldn't we set a default for those cases as well?  Even if there were a choice
I'd say selecting the first one is sensible.

Reply via email to