Skip to contentSkip to conversation

package/ffmpeg: fix build on mips_32

PATCH Superseded Giulio Benetti 2 participants 2 messages Sep 13, 2021 – Sep 22, 2021

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/ffmpeg: fix build on mips_32

mips_32 is not supported by ffmpeg and it tries to build with loongson3
SIMD support that leads to build failure due to:
/tmp/ccFO2LRa.s: Assembler messages:
/tmp/ccFO2LRa.s:15314: Error: opcode not supported on this processor: mips32 (mips32) dmult $2,$6' /tmp/ccFO2LRa.s:15316: Error: opcode not supported on this processor: mips32 (mips32) dsrl $2,$2,32'

So let's --disable-asm to prevent using those unsupported opcodes.

Fixes:
http://autobuild.buildroot.net/results/f01/f01d9cedec8e1b371308d0f7af561a75883fa27c/

---
 package/ffmpeg/ffmpeg.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
package/ffmpeg/ffmpeg.mk +1 -1
index 8ff8ea8c6c..5e405d0f60 100644
@@ -508,7 +508,7 @@ FFMPEG_CONF_OPTS += --enable-mipsfpu
 endif
 
 # Fix build failure on "addi opcode not supported"
-ifeq ($(BR2_mips_32r6)$(BR2_mips_64r6),y)
+ifeq ($(BR2_mips_32)$(BR2_mips_32r6)$(BR2_mips_64r6),y)
 FFMPEG_CONF_OPTS += --disable-asm
 endif
 endif # MIPS
Signature · 6 lines
2.25.1

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
#1 lore raw
Quoted 5 lines · Giulio Benetti

mips_32 is not supported by ffmpeg and it tries to build with loongson3
SIMD support that leads to build failure due to:
/tmp/ccFO2LRa.s: Assembler messages:
/tmp/ccFO2LRa.s:15314: Error: opcode not supported on this processor: mips32 (mips32) dmult $2,$6' /tmp/ccFO2LRa.s:15316: Error: opcode not supported on this processor: mips32 (mips32) dsrl $2,$2,32'

I don't think *any* of the archs we define in Config.in.mips supports these
instructions... It's just that these are the only ones we test in the autobuilders.

Quoted 16 lines

So let's --disable-asm to prevent using those unsupported opcodes.

Fixes:
http://autobuild.buildroot.net/results/f01/f01d9cedec8e1b371308d0f7af561a75883fa27c/

---
  package/ffmpeg/ffmpeg.mk | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
package/ffmpeg/ffmpeg.mk +0 -0
index 8ff8ea8c6c..5e405d0f60 100644

package/ffmpeg/ffmpeg.mk FFMPEG_CONF_OPTS += --enable-mipsfpu · line 512

Quoted 6 lines
package/ffmpeg/ffmpeg.mk +1 -1
@@ -508,7 +508,7 @@ FFMPEG_CONF_OPTS += --enable-mipsfpu
  endif
 
  # Fix build failure on "addi opcode not supported"
-ifeq ($(BR2_mips_32r6)$(BR2_mips_64r6),y)
+ifeq ($(BR2_mips_32)$(BR2_mips_32r6)$(BR2_mips_64r6),y)
  FFMPEG_CONF_OPTS += --disable-asm

Given that mips seems so problematic, I think it's best to disable asm on mips
in general, not even for specific subarches.

If someone needs some specific subarch to be optimized, they can give us a
(tested!) patch that enables asm again for that specific subarch.

Regards,
Arnout

package/ffmpeg/ffmpeg.mk FFMPEG_CONF_OPTS += --enable-mipsfpu · line 514

Quoted 3 lines
package/ffmpeg/ffmpeg.mk +0 -0
  endif
  endif # MIPS

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot