This reworks the func/endfunc macros to support any number of ISA extension
as parameters.
---
libavutil/riscv/asm.S | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/libavutil/riscv/asm.S b/libavutil/riscv/asm.S
index 2cf4f7b7ab..78e9defbd4 100644
--- a/libavutil/riscv/asm.S
+++ b/libavutil/riscv/asm.S
@@ -36,17 +36,18 @@
#define HWD
#endif
- .macro func sym, ext1=, ext2=
+ .macro archadd ext=, more:vararg
+ .ifnb \ext
+ .option arch, +\ext
+ archadd \more
+ .endif
+ .endm
+
+ .macro func sym, exts:vararg
.text
.align 2
-
.option push
- .ifnb \ext1
- .option arch, +\ext1
- .ifnb \ext2
- .option arch, +\ext2
- .endif
- .endif
+ archadd \exts
.global \sym
.hidden \sym
--
2.45.2
_______________________________________________
ffmpeg-devel mailing list
[email protected]
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
[email protected] with subject "unsubscribe".