On 14/12/11 21:38, Bryan Galusha wrote:
Having an issue compiling libav for the ARM cortex-a8.
The compiler is choking on the R and Q operand codes that appear in both
intmath.h and intreadwrite.h, which it errors out on saying the Q and R
operand codes are "invalid operand"

Here is the error in intmath.h:
error: invalid operand in inline asm: 'adds   $1, ${1:Q}, ${2:Q}, lsr #31
     itet   ne
     mvnne  $1, #1<<31
     moveq  $0, ${1:Q}
     eorne  $0, $1,  ${1:Q}, asr #31
     '
Which corresponds to this function from intmath.h
#define av_clipl_int32 av_clipl_int32_arm
static av_always_inline av_const int32_t av_clipl_int32_arm(int64_t a)
{
     int x, y;
     __asm__ ("adds   %1, %R2, %Q2, lsr #31  \n\t"
              "itet   ne                     \n\t"
              "mvnne  %1, #1<<31             \n\t"
              "moveq  %0, %Q2                \n\t"
              "eorne  %0, %1,  %R2, asr #31  \n\t"
              : "=r"(x), "=&r"(y) : "r"(a));
     return x;
}

Removing the R and Q operand codes makes the compiler happy, but obviously
the code won't function correctly

Any help with this issue would be greatly appreciated, version and
./configure information below,
Bryan


i686-apple-darwin11-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build
5658) (LLVM build 2336.1.00)

That version Clang/llvm-gcc is know to miscompile at least librtmp. You might try to update to the head clang or to revert to the not so new gcc-4.2 apple.

lu

--

Luca Barbato
Gentoo/linux
http://dev.gentoo.org/~lu_zero

_______________________________________________
libav-tools mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-tools

Reply via email to