# DP: On mips, pass -mfix-loongson2f-nop to as, if -mno-fix-loongson2f-nop
# DP: is not passed.

--- a/src/gcc/config/mips/mips.h
+++ b/src/gcc/config/mips/mips.h
@@ -1142,6 +1142,7 @@
 %{mshared} %{mno-shared} \
 %{msym32} %{mno-sym32} \
 %{mtune=*} \
+%{!mno-fix-loongson2f-nop:-mfix-loongson2f-nop} \
 %(subtarget_asm_spec)"
 
 /* Extra switches sometimes passed to the linker.  */
