Re: [FFmpeg-devel] [PATCH 1/2] configure: disabled -mips64 option for loongson and remove redundant flags

2015-05-12 Thread 周晓勇
@@ -3937,7 +3937,6 @@ elif enabled mips; then
 enable fast_cmov
 enable fast_unaligned
 disable aligned_stack
-cpuflags=-march=$cpu
 ;;
 generic)
 disable mips32r5
@@ -4716,8 +4715,6 @@ elif enabled mips; then
  check_inline_asm mipsfpu   'madd.d $f0, $f2, $f4, $f6'
 enabled msacheck_cflags -mmsa  check_ldflags -mmsa 
  check_inline_asm msa   'addvi.b $w0, $w1, 1'
-enabled loongson3  add_cflags -mhard-float  add_asflags 
-mhard-float 
-check_inline_asm loongson3 'gsldxc1 $f0, 0($2, $3)'
 
 enabled mips32r5  add_asflags -mips32r5 -mfp64
 enabled mips64r6  add_asflags -mips64r6 -mfp64

they are redundant, so removed.

@@ -4691,7 +4690,7 @@ elif enabled mips; then
 if enabled mips64  (enabled mipsdspr1 || enabled mipsdspr2); then
 add_cflags -mips64r2
 add_asflags -mips64r2
-elif enabled mips64  enabled mipsfpu; then
+elif enabled mips64  enabled mipsfpu  disabled loongson3; then
 add_cflags -mips64
 add_asflags -mips64
 elif enabled mipsdspr1 || enabled mipsdspr2; then

on 64bit OS(run the configure on Loongson CentOS6.4) the mips64 will be 
enabled, so if not added disabled loongson3 the flags -mips64 will be added.
-mips64 conflicts with -march=loongson3a.

do you need our cross compiler gcc-4.8.3-d197-o32-loongson to verify?
my test has passed.

./configure --enable-gpl --enable-pthreads --samples=/home/coffeez/fate/ 
--enable-nonfree --enable-version3 --assert-level=2 --target-os=linux 
--cross-prefix='/home/xuchenghua/toolchain/cross-tools/gcc-4.8.3-d197-o32-loongson/usr/bin/'
 --cc='ccache mips64el-redhat-linux-gcc-4.8.3' --as='mips64el-redhat-linux-as' 
--ranlib='mips64el-redhat-linux-ranlib' --cxx='mips64el-redhat-linux-g++' 
--ar='mips64el-redhat-linux-ar' --nm='mips64el-redhat-linux-nm' --arch=mips 
--cpu=loongson3a --enable-doc --disable-stripping

install prefix/usr/local
source path   .
C compilerccache mips64el-redhat-linux-gcc-4.8.3
C library glibc
host C compiler   gcc
host C libraryglibc
ARCH  mips (loongson3a)
big-endianno
runtime cpu detection yes
MIPS FPU enabled  yes
MIPS32R5 enabled  no
MIPS64R6 enabled  no
MIPS DSP R1 enabled   no
MIPS DSP R2 enabled   no
MIPS MSA enabled  no
LOONGSON3 enabled yes
debug symbols yes
strip symbols no
optimize for size no
optimizations yes
staticyes
sharedno
postprocessing supportyes
new filter supportyes
network support   yes
threading support pthreads
safe bitstream reader yes
SDL support   no
opencl enabledno
texi2html enabled no
perl enabled  yes
pod2man enabled   yes
makeinfo enabled  yes
makeinfo supports HTMLyes

External libraries:
iconv

Enabled decoders:
aac binkh263i
aac_latmbinkaudio_dct   h263p
aascbinkaudio_rdft  h264
ac3 bintext hevc
ac3_fixed   bmp hnm4_video
adpcm_4xm   bmv_audio   hq_hqa
adpcm_adx   bmv_video   hqx
adpcm_afc   brender_pix huffyuv
adpcm_ctc93 iac
adpcm_dtk   cavsidcin
adpcm_eaccaptionidf
adpcm_ea_maxis_xa   cdgraphics  iff_byterun1
adpcm_ea_r1 cdxliff_ilbm
adpcm_ea_r2 cinepak imc
adpcm_ea_r3 cljrindeo2
adpcm_ea_xascllcindeo3
adpcm_g722  comfortnoiseindeo4
adpcm_g726  cookindeo5
adpcm_g726lecpiainterplay_dpcm
adpcm_ima_amv   cscdinterplay_video
adpcm_ima_apc   cyuvjacosub
adpcm_ima_dk3   dca jpeg2000
adpcm_ima_dk4   dfa jpegls
adpcm_ima_ea_eacs   dirac   jv
adpcm_ima_ea_sead   dnxhd   kgv1
adpcm_ima_iss   dpx kmvc
adpcm_ima_oki   dsd_lsbflagarith
adpcm_ima_qtdsd_lsbf_planar loco
adpcm_ima_rad   dsd_msbfmace3
adpcm_ima_smjpegdsd_msbf_planar mace6
adpcm_ima_wav   dsicinaudio mdec
adpcm_ima_wsdsicinvideo metasound
adpcm_msdss_sp  microdvd
adpcm_sbpro_2   dvbsub  mimic
adpcm_sbpro_3   dvdsub  

Re: [FFmpeg-devel] [PATCH 1/2] configure: disabled -mips64 option for loongson and remove redundant flags

2015-05-12 Thread Michael Niedermayer
On Wed, May 13, 2015 at 10:16:26AM +0800, 周晓勇 wrote:
[...]
 @@ -4716,8 +4715,6 @@ elif enabled mips; then
   check_inline_asm mipsfpu   'madd.d $f0, $f2, $f4, $f6'
  enabled msacheck_cflags -mmsa  check_ldflags -mmsa 
   check_inline_asm msa   'addvi.b $w0, $w1, 1'
 -enabled loongson3  add_cflags -mhard-float  add_asflags 
 -mhard-float 
 -check_inline_asm loongson3 'gsldxc1 $f0, 0($2, $3)'

[...]


the patch removes the code which disabled loongson3 so longson3 is
enabled even on imgtec mips
that is the patch breaks building for imgtec mips

you can probably reproduce it with a cross compiler from
http://emdebian.org/

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The bravest are surely those who have the clearest vision
of what is before them, glory and danger alike, and yet
notwithstanding go out to meet it. -- Thucydides


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 1/2] configure: disabled -mips64 option for loongson and remove redundant flags

2015-05-12 Thread 周晓勇



 -原始邮件-
 发件人: Michael Niedermayer michae...@gmx.at
 发送时间: 2015年5月12日 星期二
 收件人: FFmpeg development discussions and patches ffmpeg-devel@ffmpeg.org
 抄送: 
 主题: Re: [FFmpeg-devel] [PATCH 1/2] configure: disabled -mips64 option for 
 loongson and remove redundant flags
 
 On Tue, May 12, 2015 at 10:32:19AM +0800, 周晓勇 wrote:
  
  
  
   -原始邮件-
   发件人: Michael Niedermayer michae...@gmx.at
   发送时间: 2015年5月11日 星期一
   收件人: FFmpeg development discussions and patches 
   ffmpeg-devel@ffmpeg.org
   抄送: 
   主题: Re: [FFmpeg-devel] [PATCH 1/2] configure: disabled -mips64 option for 
   loongson and remove redundant flags
   
   On Mon, May 11, 2015 at 12:38:46PM +0800, 周晓勇 wrote:
From 9837274dcee5e1900160901cf28d883246a7ecfb Mon Sep 17 00:00:00 2001
From: Zhou Xiaoyong zhouxiaoy...@loongson.cn
Date: Mon, 11 May 2015 03:28:52 -0400
Subject: [PATCH 1/2] configure: disabled -mips64 option for loongson 
and remove redundant flags

1.Option -march=loongson3a conflicts with -mips64 or -mips64r2.
2.Option -mhard-float has been added.

Signed-off-by: Zhou Xiaoyong zhouxiaoy...@loongson.cn
---
 configure |5 +
 1 files changed, 1 insertions(+), 4 deletions(-)

diff --git a/configure b/configure
index 1b41367..7716e66 100755
--- a/configure
+++ b/configure
@@ -3937,7 +3937,6 @@ elif enabled mips; then
 enable fast_cmov
 enable fast_unaligned
 disable aligned_stack
-cpuflags=-march=$cpu
 ;;
 generic)
 disable mips32r5
@@ -4691,7 +4690,7 @@ elif enabled mips; then
 if enabled mips64  (enabled mipsdspr1 || enabled mipsdspr2); then
 add_cflags -mips64r2
 add_asflags -mips64r2
-elif enabled mips64  enabled mipsfpu; then
+elif enabled mips64  enabled mipsfpu  disabled loongson3; then
   
   this breaks build on mips:
   CC  libavcodec/ac3dec_fixed.o
   In file included from ffmpeg/libavcodec/ac3dec_fixed.c:169:
   ffmpeg/libavcodec/ac3dec.c: In function ‘ac3_decode_init’:
   ffmpeg/libavcodec/ac3dec.c:213: warning: ‘request_channels’ is deprecated 
   (declared at ffmpeg/libavcodec/avcodec.h:2038)
   ffmpeg/libavcodec/ac3dec.c:215: warning: ‘request_channels’ is deprecated 
   (declared at ffmpeg/libavcodec/avcodec.h:2038)
   /tmp/ccgKabta.s: Assembler messages:
   /tmp/ccgKabta.s:5229: Error: opcode not supported on this processor: 
   mips32r2 (mips32r2) `dmult $25,$24'
   /tmp/ccgKabta.s:5231: Error: opcode not supported on this processor: 
   mips32r2 (mips32r2) `dsrl $25,$25,32'
   
   [...]
   
  
  weird, i have no problem with this patch. all pass except some fate.
  ./configure --enable-gpl --cc='ccache gcc' --enable-pthreads 
  --samples=/home/loongson/fate/ --enable-nonfree --enable-version3 
  --assert-level=2 --cpu=loongson3a
 
 above was cross build for non loongson MIPS
 with mips-linux-gnu-gcc-4.4 (Debian 4.4.5-8) 4.4.5
 it works before the patch but not afterwards
 
 
 after the patch
 HAVE_LOONGSON3=yes
 
 [...]

mips-linux-gnu-gcc-4.4 is not compatible with loongson OS FC-19, because the 
FC-19's API is O32. you could not use odd register of loongson cpu in O32 mode.
i do the test of cross-build in my x86 using our cross-compiler 
gcc-4.8.3-d197-o32-loongson with configure below:

./configure --enable-gpl --enable-pthreads --samples=/home/coffeez/fate/ 
--enable-nonfree --enable-version3 --assert-level=2 --enable-cross-compile 
--target-os=linux 
--cc=/home/xuchenghua/toolchain/cross-tools/gcc-4.8.3-d197-o32-loongson/usr/bin/mips64el-redhat-linux-gcc
 --host-cc=/usr/bin/gcc 
--host-ld=/home/xuchenghua/toolchain/cross-tools/gcc-4.8.3-d197-o32-loongson/usr/bin/mips64el-redhat-linux-ld
 --arch=mips --cpu=loongson3a --disable-doc

it pass all only at the end report ffserver error.

why disable doc?
it reported ld doc/print_option.o error.

what configure do you use when cross build?
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 1/2] configure: disabled -mips64 option for loongson and remove redundant flags

2015-05-11 Thread Michael Niedermayer
On Mon, May 11, 2015 at 12:38:46PM +0800, 周晓勇 wrote:
 From 9837274dcee5e1900160901cf28d883246a7ecfb Mon Sep 17 00:00:00 2001
 From: Zhou Xiaoyong zhouxiaoy...@loongson.cn
 Date: Mon, 11 May 2015 03:28:52 -0400
 Subject: [PATCH 1/2] configure: disabled -mips64 option for loongson and 
 remove redundant flags
 
 1.Option -march=loongson3a conflicts with -mips64 or -mips64r2.
 2.Option -mhard-float has been added.
 
 Signed-off-by: Zhou Xiaoyong zhouxiaoy...@loongson.cn
 ---
  configure |5 +
  1 files changed, 1 insertions(+), 4 deletions(-)
 
 diff --git a/configure b/configure
 index 1b41367..7716e66 100755
 --- a/configure
 +++ b/configure
 @@ -3937,7 +3937,6 @@ elif enabled mips; then
  enable fast_cmov
  enable fast_unaligned
  disable aligned_stack
 -cpuflags=-march=$cpu
  ;;
  generic)
  disable mips32r5
 @@ -4691,7 +4690,7 @@ elif enabled mips; then
  if enabled mips64  (enabled mipsdspr1 || enabled mipsdspr2); then
  add_cflags -mips64r2
  add_asflags -mips64r2
 -elif enabled mips64  enabled mipsfpu; then
 +elif enabled mips64  enabled mipsfpu  disabled loongson3; then

this breaks build on mips:
CC  libavcodec/ac3dec_fixed.o
In file included from ffmpeg/libavcodec/ac3dec_fixed.c:169:
ffmpeg/libavcodec/ac3dec.c: In function ‘ac3_decode_init’:
ffmpeg/libavcodec/ac3dec.c:213: warning: ‘request_channels’ is deprecated 
(declared at ffmpeg/libavcodec/avcodec.h:2038)
ffmpeg/libavcodec/ac3dec.c:215: warning: ‘request_channels’ is deprecated 
(declared at ffmpeg/libavcodec/avcodec.h:2038)
/tmp/ccgKabta.s: Assembler messages:
/tmp/ccgKabta.s:5229: Error: opcode not supported on this processor: mips32r2 
(mips32r2) `dmult $25,$24'
/tmp/ccgKabta.s:5231: Error: opcode not supported on this processor: mips32r2 
(mips32r2) `dsrl $25,$25,32'

[...]

-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Breaking DRM is a little like attempting to break through a door even
though the window is wide open and the only thing in the house is a bunch
of things you dont want and which you would get tomorrow for free anyway


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 1/2] configure: disabled -mips64 option for loongson and remove redundant flags

2015-05-11 Thread Michael Niedermayer
On Tue, May 12, 2015 at 10:32:19AM +0800, 周晓勇 wrote:
 
 
 
  -原始邮件-
  发件人: Michael Niedermayer michae...@gmx.at
  发送时间: 2015年5月11日 星期一
  收件人: FFmpeg development discussions and patches ffmpeg-devel@ffmpeg.org
  抄送: 
  主题: Re: [FFmpeg-devel] [PATCH 1/2] configure: disabled -mips64 option for 
  loongson and remove redundant flags
  
  On Mon, May 11, 2015 at 12:38:46PM +0800, 周晓勇 wrote:
   From 9837274dcee5e1900160901cf28d883246a7ecfb Mon Sep 17 00:00:00 2001
   From: Zhou Xiaoyong zhouxiaoy...@loongson.cn
   Date: Mon, 11 May 2015 03:28:52 -0400
   Subject: [PATCH 1/2] configure: disabled -mips64 option for loongson and 
   remove redundant flags
   
   1.Option -march=loongson3a conflicts with -mips64 or -mips64r2.
   2.Option -mhard-float has been added.
   
   Signed-off-by: Zhou Xiaoyong zhouxiaoy...@loongson.cn
   ---
configure |5 +
1 files changed, 1 insertions(+), 4 deletions(-)
   
   diff --git a/configure b/configure
   index 1b41367..7716e66 100755
   --- a/configure
   +++ b/configure
   @@ -3937,7 +3937,6 @@ elif enabled mips; then
enable fast_cmov
enable fast_unaligned
disable aligned_stack
   -cpuflags=-march=$cpu
;;
generic)
disable mips32r5
   @@ -4691,7 +4690,7 @@ elif enabled mips; then
if enabled mips64  (enabled mipsdspr1 || enabled mipsdspr2); then
add_cflags -mips64r2
add_asflags -mips64r2
   -elif enabled mips64  enabled mipsfpu; then
   +elif enabled mips64  enabled mipsfpu  disabled loongson3; then
  
  this breaks build on mips:
  CC  libavcodec/ac3dec_fixed.o
  In file included from ffmpeg/libavcodec/ac3dec_fixed.c:169:
  ffmpeg/libavcodec/ac3dec.c: In function ‘ac3_decode_init’:
  ffmpeg/libavcodec/ac3dec.c:213: warning: ‘request_channels’ is deprecated 
  (declared at ffmpeg/libavcodec/avcodec.h:2038)
  ffmpeg/libavcodec/ac3dec.c:215: warning: ‘request_channels’ is deprecated 
  (declared at ffmpeg/libavcodec/avcodec.h:2038)
  /tmp/ccgKabta.s: Assembler messages:
  /tmp/ccgKabta.s:5229: Error: opcode not supported on this processor: 
  mips32r2 (mips32r2) `dmult $25,$24'
  /tmp/ccgKabta.s:5231: Error: opcode not supported on this processor: 
  mips32r2 (mips32r2) `dsrl $25,$25,32'
  
  [...]
  
 
 weird, i have no problem with this patch. all pass except some fate.
 ./configure --enable-gpl --cc='ccache gcc' --enable-pthreads 
 --samples=/home/loongson/fate/ --enable-nonfree --enable-version3 
 --assert-level=2 --cpu=loongson3a

above was cross build for non loongson MIPS
with mips-linux-gnu-gcc-4.4 (Debian 4.4.5-8) 4.4.5
it works before the patch but not afterwards


after the patch
HAVE_LOONGSON3=yes

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Its not that you shouldnt use gotos but rather that you should write
readable code and code with gotos often but not always is less readable


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 1/2] configure: disabled -mips64 option for loongson and remove redundant flags

2015-05-11 Thread 周晓勇



 -原始邮件-
 发件人: Michael Niedermayer michae...@gmx.at
 发送时间: 2015年5月11日 星期一
 收件人: FFmpeg development discussions and patches ffmpeg-devel@ffmpeg.org
 抄送: 
 主题: Re: [FFmpeg-devel] [PATCH 1/2] configure: disabled -mips64 option for 
 loongson and remove redundant flags
 
 On Mon, May 11, 2015 at 12:38:46PM +0800, 周晓勇 wrote:
  From 9837274dcee5e1900160901cf28d883246a7ecfb Mon Sep 17 00:00:00 2001
  From: Zhou Xiaoyong zhouxiaoy...@loongson.cn
  Date: Mon, 11 May 2015 03:28:52 -0400
  Subject: [PATCH 1/2] configure: disabled -mips64 option for loongson and 
  remove redundant flags
  
  1.Option -march=loongson3a conflicts with -mips64 or -mips64r2.
  2.Option -mhard-float has been added.
  
  Signed-off-by: Zhou Xiaoyong zhouxiaoy...@loongson.cn
  ---
   configure |5 +
   1 files changed, 1 insertions(+), 4 deletions(-)
  
  diff --git a/configure b/configure
  index 1b41367..7716e66 100755
  --- a/configure
  +++ b/configure
  @@ -3937,7 +3937,6 @@ elif enabled mips; then
   enable fast_cmov
   enable fast_unaligned
   disable aligned_stack
  -cpuflags=-march=$cpu
   ;;
   generic)
   disable mips32r5
  @@ -4691,7 +4690,7 @@ elif enabled mips; then
   if enabled mips64  (enabled mipsdspr1 || enabled mipsdspr2); then
   add_cflags -mips64r2
   add_asflags -mips64r2
  -elif enabled mips64  enabled mipsfpu; then
  +elif enabled mips64  enabled mipsfpu  disabled loongson3; then
 
 this breaks build on mips:
 CC  libavcodec/ac3dec_fixed.o
 In file included from ffmpeg/libavcodec/ac3dec_fixed.c:169:
 ffmpeg/libavcodec/ac3dec.c: In function ‘ac3_decode_init’:
 ffmpeg/libavcodec/ac3dec.c:213: warning: ‘request_channels’ is deprecated 
 (declared at ffmpeg/libavcodec/avcodec.h:2038)
 ffmpeg/libavcodec/ac3dec.c:215: warning: ‘request_channels’ is deprecated 
 (declared at ffmpeg/libavcodec/avcodec.h:2038)
 /tmp/ccgKabta.s: Assembler messages:
 /tmp/ccgKabta.s:5229: Error: opcode not supported on this processor: mips32r2 
 (mips32r2) `dmult $25,$24'
 /tmp/ccgKabta.s:5231: Error: opcode not supported on this processor: mips32r2 
 (mips32r2) `dsrl $25,$25,32'
 
 [...]
 

weird, i have no problem with this patch. all pass except some fate.
./configure --enable-gpl --cc='ccache gcc' --enable-pthreads 
--samples=/home/loongson/fate/ --enable-nonfree --enable-version3 
--assert-level=2 --cpu=loongson3a

1.when testing on FC19-O32 system, config.mak list as:

CC_IDENT=gcc 4.8.3 (GCC) 20140624 (Red Hat 4.8.3-1)
ARCH=mips
CPPFLAGS= -D_ISOC99_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE 
-D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -DPIC -DZLIB_CONST
CFLAGS=   -march=loongson3a -std=c99 -fomit-frame-pointer -fPIC -mhard-float 
-pthread -D_GNU_SOURCE=1 -D_REENTRANT -I/usr/include/SDL  -g 
-Wdeclaration-after-statement -Wall -Wdisabled-optimization -Wpointer-arith 
-Wredundant-decls -Wwrite-strings -Wtype-limits -Wundef -Wmissing-prototypes 
-Wno-pointer-to-int-cast -Wstrict-prototypes -Wempty-body -Wno-parentheses 
-Wno-switch -Wno-format-zero-length -Wno-pointer-sign -O3 -fno-math-errno 
-fno-signed-zeros -fno-tree-vectorize -Werror=format-security 
-Werror=implicit-function-declaration -Werror=missing-prototypes 
-Werror=return-type -Werror=vla -Wformat -fdiagnostics-color=auto 
-Wno-maybe-uninitialized
CXXFLAGS=  -D__STDC_CONSTANT_MACROS
ASFLAGS=   -march=loongson3a -fPIC -mhard-float -g
ARCH_MIPS=yes
!ARCH_MIPS64=yes
HAVE_MIPSFPU=yes
!HAVE_MIPS32R2=yes
!HAVE_MIPS32R5=yes
!HAVE_MIPS64R6=yes
!HAVE_MIPSDSPR1=yes
!HAVE_MIPSDSPR2=yes
!HAVE_MSA=yes
HAVE_LOONGSON3=yes
!HAVE_ALIGNED_STACK=yes
HAVE_FAST_64BIT=yes
HAVE_FAST_CLZ=yes
HAVE_FAST_CMOV=yes
HAVE_LOCAL_ALIGNED_8=yes
HAVE_LOCAL_ALIGNED_16=yes
!HAVE_LOCAL_ALIGNED_32=yes
HAVE_SIMD_ALIGN_16=yes

2.when testing on CentOS-N64 system, config.mak list as:

CC_IDENT=gcc 4.4.7 (GCC) 20120313 (Red Hat 4.4.7-3.1)
ARCH=mips
CPPFLAGS= -D_ISOC99_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE 
-D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -DPIC -DZLIB_CONST
CFLAGS=   -march=loongson3a -std=c99 -fomit-frame-pointer -fPIC -mhard-float 
-pthread  -g -Wdeclaration-after-statement -Wall -Wdisabled-optimization 
-Wpointer-arith -Wredundant-decls -Wwrite-strings -Wtype-limits -Wundef 
-Wmissing-prototypes -Wno-pointer-to-int-cast -Wstrict-prototypes -Wempty-body 
-Wno-parentheses -Wno-switch -Wno-format-zero-length -Wno-pointer-sign -O3 
-fno-math-errno -fno-signed-zeros -fno-tree-vectorize -Werror=format-security 
-Werror=implicit-function-declaration -Werror=missing-prototypes 
-Werror=return-type -Werror=vla -Wformat
CXXFLAGS=  -D__STDC_CONSTANT_MACROS
ASFLAGS=   -march=loongson3a -fPIC -mhard-float -g
ARCH_MIPS=yes
ARCH_MIPS64=yes
HAVE_MIPSFPU=yes
!HAVE_MIPS32R2=yes
!HAVE_MIPS32R5=yes
!HAVE_MIPS64R6=yes
!HAVE_MIPSDSPR1=yes
!HAVE_MIPSDSPR2=yes
!HAVE_MSA=yes
HAVE_LOONGSON3=yes
!HAVE_ALIGNED_STACK=yes
HAVE_FAST_64BIT=yes
HAVE_FAST_CLZ=yes
HAVE_FAST_CMOV=yes