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

--- Comment #2 from Matteo Perotti <mperotti at iis dot ee.ethz.ch> ---
(In reply to Andrew Pinski from comment #1)
> You can't use vsetivli this way. That is you can't set it via inline-asm.
> 
> MAybe this should be documented.

1) Do you mean that it's not allowed to use vsetvl-like instructions in the
inline assembly in general? Or am I just doing it the wrong way?

2) If it's not allowed, does it mean that the only way I can write RVV assembly
is by writing a separate assembly file?

3) If this is the case, isn't there a way to target -march=rv64gcv without
allowing the compiler to insert new RVV instructions other than the ones in
inline assembly? This "hack" would allow easier porting of legacy code since
older gcc versions did not insert any "alien" RVV instruction in addition to
the ones already present as inline-asm.

I agree though; documenting this would be great.

Thanks a lot for the answer btw.

Reply via email to