Commit 79414257 authored by Justin Ruggles's avatar Justin Ruggles

mathops: fix MULL() when the compiler does not inline the function.

If the function is not inlined, an immmediate cannot be used for the
shift parameter, so the %cl register must be used instead in that case.

This fixes compilation for x86-32 using gcc with --disable-optimizations.
parent 56e2ac6b
...@@ -35,7 +35,7 @@ static av_always_inline av_const int MULL(int a, int b, unsigned shift) ...@@ -35,7 +35,7 @@ static av_always_inline av_const int MULL(int a, int b, unsigned shift)
"imull %3 \n\t" "imull %3 \n\t"
"shrdl %4, %%edx, %%eax \n\t" "shrdl %4, %%edx, %%eax \n\t"
:"=a"(rt), "=d"(dummy) :"=a"(rt), "=d"(dummy)
:"a"(a), "rm"(b), "i"(shift) :"a"(a), "rm"(b), "ci"((uint8_t)shift)
); );
return rt; return rt;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment