On 6/3/2026 2:14 AM, Kito Cheng wrote:
The syntax of multilib-generator was defined as below:

```
<primary arch>-<abi>-<additional arches>-<extensions>
```

And now extend with one more optional argument:

```
<primary arch>-<abi>-<additional arches>-<extensions>[-<extra-options>]
```

Detail syntax of `<extra-option>`:
```
<extra-options> := <extra-option> ',' <extra-options>
                  | <extra-option>

<extra-option> := <option> '/' <multi-lib-folder>
```

NOTE: Dash ('-') in the option name must replace with underline ('_'),
       and leading dash should skip, e.g. `-fcf-protection=full` become
       `fcf_protection=full`.

e.g.

rv64imafdc_zicfiss_zicfilp-lp64d---fcf_protection=full/cfi

It will build a multilib with
`-march=rv64imafdc_zicfiss_zicfilp -mabi=lp64d -fcf-protection=full`

And will use `rv64imafdc_zicfiss_zicfilp/lp64d/cfi` as multilib folder.

gcc/ChangeLog:

        * config/riscv/multilib-generator: Support extra options in the
        multilib config string.
        * doc/install.texi (--with-multilib-generator): Document the extra
        options syntax.
Given you know this code better than anyone, happy to step aside and let you self-approve :-)

jeff

Reply via email to