Commit 945ea1b7 authored by Frank Barchard's avatar Frank Barchard

mips switch sgtu to sltu for clang in ndk r14

The verion of clang in ndk r14 (3.9) has a built in llvm assembler
that does not have the sgtu pseudo instruction.
sltu is the actual instruction, so switch the 2 operands and use
the instruction instead of the pseudo op.

BUG=libyuv:700
TEST=try bots build mips without error.

Change-Id: I2d5f94f81acbd56cdedea011e7d9308979e19079
Reviewed-on: https://chromium-review.googlesource.com/494026Reviewed-by: 's avatarHenrik Kjellander <kjellander@chromium.org>
parent 54289f1b
......@@ -47,11 +47,6 @@ LOCAL_SRC_FILES := \
source/video_common.cc
common_CFLAGS := -Wall -fexceptions
# Mips builds on NDK r14+ require -no-integrated-as to properly compile inline
# assembly.
ifneq ($(findstring mips, $(TARGET_ARCH_ABI)),)
common_CFLAGS += -no-integrated-as
endif
ifneq ($(LIBYUV_DISABLE_JPEG), "yes")
LOCAL_SRC_FILES += \
source/convert_jpeg.cc \
......
Name: libyuv
URL: http://code.google.com/p/libyuv/
Version: 1654
Version: 1655
License: BSD
License File: LICENSE
......
......@@ -11,6 +11,6 @@
#ifndef INCLUDE_LIBYUV_VERSION_H_
#define INCLUDE_LIBYUV_VERSION_H_
#define LIBYUV_VERSION 1654
#define LIBYUV_VERSION 1655
#endif // INCLUDE_LIBYUV_VERSION_H_
......@@ -68,7 +68,7 @@ void CopyRow_MIPS(const uint8* src, uint8* dst, int count) {
"pref 0, 64(%[src]) \n"
"pref 30, 32(%[dst]) \n"
// In case the a1 > t9 don't use "pref 30" at all
"sgtu $v1, %[dst], $t9 \n"
"sltu $v1, $t9, %[dst] \n"
"bgtz $v1, $loop16w \n"
"nop \n"
// otherwise, start with using pref30
......@@ -119,7 +119,7 @@ void CopyRow_MIPS(const uint8* src, uint8* dst, int count) {
"sw $t7, 60(%[dst]) \n"
"addiu %[dst], %[dst], 64 \n" // adding 64 to dest
"sgtu $v1, %[dst], $t9 \n"
"sltu $v1, $t9, %[dst] \n"
"bne %[dst], $a3, $loop16w \n"
" addiu %[src], %[src], 64 \n" // adding 64 to src
"move %[count], $t8 \n"
......@@ -221,7 +221,7 @@ void CopyRow_MIPS(const uint8* src, uint8* dst, int count) {
"pref 30, 32(%[dst]) \n"
// safe, as we have at least 64 bytes ahead
// In case the a1 > t9 don't use "pref 30" at all
"sgtu $v1, %[dst], $t9 \n"
"sltu $v1, $t9, %[dst] \n"
"bgtz $v1, $ua_loop16w \n"
// skip "pref 30,64(a1)" for too short arrays
" nop \n"
......@@ -292,7 +292,7 @@ void CopyRow_MIPS(const uint8* src, uint8* dst, int count) {
"sw $t7, 60(%[dst]) \n"
"addiu %[dst],%[dst],64 \n" // adding 64 to dest
"sgtu $v1,%[dst],$t9 \n"
"sltu $v1,$t9,%[dst] \n"
"bne %[dst],$a3,$ua_loop16w \n"
" addiu %[src],%[src],64 \n" // adding 64 to src
"move %[count],$t8 \n"
......
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