diff options
-rw-r--r-- | apps/codecs/libspc/spc_dsp.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/apps/codecs/libspc/spc_dsp.c b/apps/codecs/libspc/spc_dsp.c index 0d07e5f04e..b4fc57158b 100644 --- a/apps/codecs/libspc/spc_dsp.c +++ b/apps/codecs/libspc/spc_dsp.c | |||
@@ -836,9 +836,9 @@ void DSP_run_( struct Spc_Dsp* this, long count, int32_t* out_buf ) | |||
836 | "ldr %[_3], [%[rev]] \r\n" /* _3=r0r1 */ | 836 | "ldr %[_3], [%[rev]] \r\n" /* _3=r0r1 */ |
837 | "smuad %[out], %[_0], %[_2] \r\n" /* out=f0*i0 + f1*i1 */ | 837 | "smuad %[out], %[_0], %[_2] \r\n" /* out=f0*i0 + f1*i1 */ |
838 | "smladx %[out], %[_1], %[_3], %[out] \r\n" /* out+=r1*i2 + r0*i3 */ | 838 | "smladx %[out], %[_1], %[_3], %[out] \r\n" /* out+=r1*i2 + r0*i3 */ |
839 | : [out]"=&r"(output), | 839 | : [out]"=r"(output), |
840 | [_0]"=&r"(amp_0), [_1]"=&r"(amp_1), | 840 | [_0]"=&r"(amp_0), [_1]"=&r"(amp_1), |
841 | [_2]"=&r"(_2), [_3]"=&r"(_3) | 841 | [_2]"=&r"(_2), [_3]"=r"(_3) |
842 | : [fwd]"r"(fwd), [rev]"r"(rev), | 842 | : [fwd]"r"(fwd), [rev]"r"(rev), |
843 | [interp]"r"(interp)); | 843 | [interp]"r"(interp)); |
844 | /* Apply voice envelope */ | 844 | /* Apply voice envelope */ |
@@ -852,7 +852,7 @@ void DSP_run_( struct Spc_Dsp* this, long count, int32_t* out_buf ) | |||
852 | "smulwb %[amp_0], %[out], %[vvol_0] \r\n" /* (32x16->48)[47:16]->[31:0] */ | 852 | "smulwb %[amp_0], %[out], %[vvol_0] \r\n" /* (32x16->48)[47:16]->[31:0] */ |
853 | "smulwb %[amp_1], %[out], %[vvol_1] \r\n" | 853 | "smulwb %[amp_1], %[out], %[vvol_1] \r\n" |
854 | : [out]"+r"(output), | 854 | : [out]"+r"(output), |
855 | [amp_0]"=r"(amp_0), [amp_1]"=r"(amp_1) | 855 | [amp_0]"=&r"(amp_0), [amp_1]"=r"(amp_1) |
856 | : [vvol_0]"r"(voice->volume[0]), | 856 | : [vvol_0]"r"(voice->volume[0]), |
857 | [vvol_1]"r"(voice->volume[1])); | 857 | [vvol_1]"r"(voice->volume[1])); |
858 | 858 | ||
@@ -889,7 +889,7 @@ void DSP_run_( struct Spc_Dsp* this, long count, int32_t* out_buf ) | |||
889 | "mul %[amp_0], %[out], %[vvol_0] \r\n" | 889 | "mul %[amp_0], %[out], %[vvol_0] \r\n" |
890 | "mul %[amp_1], %[out], %[vvol_1] \r\n" | 890 | "mul %[amp_1], %[out], %[vvol_1] \r\n" |
891 | : [out]"+r"(output), | 891 | : [out]"+r"(output), |
892 | [amp_0]"=r"(amp_0), [amp_1]"=r"(amp_1) | 892 | [amp_0]"=&r"(amp_0), [amp_1]"=r"(amp_1) |
893 | : [vvol_0]"r"((int)voice->volume[0]), | 893 | : [vvol_0]"r"((int)voice->volume[0]), |
894 | [vvol_1]"r"((int)voice->volume[1])); | 894 | [vvol_1]"r"((int)voice->volume[1])); |
895 | 895 | ||
@@ -930,7 +930,7 @@ void DSP_run_( struct Spc_Dsp* this, long count, int32_t* out_buf ) | |||
930 | "smultb %[_3], %[_1], %[_3] \r\n" /* _3=r0*i3 */ | 930 | "smultb %[_3], %[_1], %[_3] \r\n" /* _3=r0*i3 */ |
931 | : [out]"=r"(output), | 931 | : [out]"=r"(output), |
932 | [_0]"=&r"(amp_0), [_1]"=&r"(amp_1), | 932 | [_0]"=&r"(amp_0), [_1]"=&r"(amp_1), |
933 | [_2]"=&r"(_2), [_3]"=&r"(_3) | 933 | [_2]"=&r"(_2), [_3]"=r"(_3) |
934 | : [fwd]"r"(fwd), [rev]"r"(rev), | 934 | : [fwd]"r"(fwd), [rev]"r"(rev), |
935 | [interp]"r"(interp)); | 935 | [interp]"r"(interp)); |
936 | asm volatile ( | 936 | asm volatile ( |
@@ -956,7 +956,7 @@ void DSP_run_( struct Spc_Dsp* this, long count, int32_t* out_buf ) | |||
956 | "mul %[amp_0], %[out], %[vvol_0] \r\n" | 956 | "mul %[amp_0], %[out], %[vvol_0] \r\n" |
957 | "mul %[amp_1], %[out], %[vvol_1] \r\n" | 957 | "mul %[amp_1], %[out], %[vvol_1] \r\n" |
958 | : [out]"+r"(output), | 958 | : [out]"+r"(output), |
959 | [amp_1]"=r"(amp_1), [amp_0]"=r"(amp_0) | 959 | [amp_0]"=&r"(amp_0), [amp_1]"=r"(amp_1) |
960 | : [vvol_0]"r"((int)voice->volume[0]), | 960 | : [vvol_0]"r"((int)voice->volume[0]), |
961 | [vvol_1]"r"((int)voice->volume[1])); | 961 | [vvol_1]"r"((int)voice->volume[1])); |
962 | 962 | ||
@@ -989,7 +989,7 @@ void DSP_run_( struct Spc_Dsp* this, long count, int32_t* out_buf ) | |||
989 | "mov %[_3], %[_3], asr #12 \r\n" | 989 | "mov %[_3], %[_3], asr #12 \r\n" |
990 | "mov %[_3], %[_3], asl #1 \r\n" | 990 | "mov %[_3], %[_3], asl #1 \r\n" |
991 | "add %[out], %[_3], %[_2], asr #16 \r\n" | 991 | "add %[out], %[_3], %[_2], asr #16 \r\n" |
992 | : [out]"=r"(output), | 992 | : [out]"=&r"(output), |
993 | [_0]"=&r"(amp_0), [_1]"=&r"(amp_1), | 993 | [_0]"=&r"(amp_0), [_1]"=&r"(amp_1), |
994 | [_2]"=&r"(_2), [_3]"=&r"(_3) | 994 | [_2]"=&r"(_2), [_3]"=&r"(_3) |
995 | : [fwd]"r"(fwd), [rev]"r"(rev), | 995 | : [fwd]"r"(fwd), [rev]"r"(rev), |
@@ -1008,8 +1008,8 @@ void DSP_run_( struct Spc_Dsp* this, long count, int32_t* out_buf ) | |||
1008 | "bic %[out], %[out], #0x1 \r\n" | 1008 | "bic %[out], %[out], #0x1 \r\n" |
1009 | "mul %[amp_0], %[out], %[vvol_0] \r\n" | 1009 | "mul %[amp_0], %[out], %[vvol_0] \r\n" |
1010 | "mul %[amp_1], %[out], %[vvol_1] \r\n" | 1010 | "mul %[amp_1], %[out], %[vvol_1] \r\n" |
1011 | : [out]"+r"(output), [amp_0]"+r"(amp_0), | 1011 | : [out]"+r"(output), |
1012 | [amp_1]"=r"(amp_1) | 1012 | [amp_0]"+r"(amp_0), [amp_1]"=r"(amp_1) |
1013 | : [vvol_0]"r"((int)voice->volume[0]), | 1013 | : [vvol_0]"r"((int)voice->volume[0]), |
1014 | [vvol_1]"r"((int)voice->volume[1])); | 1014 | [vvol_1]"r"((int)voice->volume[1])); |
1015 | 1015 | ||
@@ -1137,7 +1137,7 @@ void DSP_run_( struct Spc_Dsp* this, long count, int32_t* out_buf ) | |||
1137 | "mul %[amp_1], %[amp_0], %[envx] \r\n" | 1137 | "mul %[amp_1], %[amp_0], %[envx] \r\n" |
1138 | "mov %[amp_0], %[amp_1], asr #11 \r\n" | 1138 | "mov %[amp_0], %[amp_1], asr #11 \r\n" |
1139 | "mov %[amp_1], %[amp_0], asr #8 \r\n" | 1139 | "mov %[amp_1], %[amp_0], asr #8 \r\n" |
1140 | : [amp_0]"+r"(amp_0), [amp_1]"=&r"(amp_1) | 1140 | : [amp_0]"+r"(amp_0), [amp_1]"=r"(amp_1) |
1141 | : [envx]"r"(voice->envx)); | 1141 | : [envx]"r"(voice->envx)); |
1142 | 1142 | ||
1143 | prev_outx = amp_0; | 1143 | prev_outx = amp_0; |
@@ -1146,7 +1146,7 @@ void DSP_run_( struct Spc_Dsp* this, long count, int32_t* out_buf ) | |||
1146 | asm volatile( | 1146 | asm volatile( |
1147 | "mul %[amp_1], %[amp_0], %[vol_1] \r\n" | 1147 | "mul %[amp_1], %[amp_0], %[vol_1] \r\n" |
1148 | "mul %[amp_0], %[vol_0], %[amp_0] \r\n" | 1148 | "mul %[amp_0], %[vol_0], %[amp_0] \r\n" |
1149 | : [amp_0]"+r"(amp_0), [amp_1]"+r"(amp_1) | 1149 | : [amp_0]"+r"(amp_0), [amp_1]"=&r"(amp_1) |
1150 | : [vol_0]"r"((int)voice->volume[0]), | 1150 | : [vol_0]"r"((int)voice->volume[0]), |
1151 | [vol_1]"r"((int)voice->volume[1])); | 1151 | [vol_1]"r"((int)voice->volume[1])); |
1152 | #else /* Unoptimized CPU */ | 1152 | #else /* Unoptimized CPU */ |
@@ -1385,7 +1385,7 @@ void DSP_run_( struct Spc_Dsp* this, long count, int32_t* out_buf ) | |||
1385 | asm volatile ( | 1385 | asm volatile ( |
1386 | "mul %[amp_0], %[gvol_0], %[chans_0] \r\n" | 1386 | "mul %[amp_0], %[gvol_0], %[chans_0] \r\n" |
1387 | "mul %[amp_1], %[gvol_1], %[chans_1] \r\n" | 1387 | "mul %[amp_1], %[gvol_1], %[chans_1] \r\n" |
1388 | : [amp_0]"=&r"(amp_0), [amp_1]"=&r"(amp_1) | 1388 | : [amp_0]"=&r"(amp_0), [amp_1]"=r"(amp_1) |
1389 | : [gvol_0]"r"(global_vol_0), [gvol_1]"r"(global_vol_1), | 1389 | : [gvol_0]"r"(global_vol_0), [gvol_1]"r"(global_vol_1), |
1390 | [chans_0]"r"(chans_0), [chans_1]"r"(chans_1)); | 1390 | [chans_0]"r"(chans_0), [chans_1]"r"(chans_1)); |
1391 | asm volatile ( | 1391 | asm volatile ( |