Remove references/use of ARCH_X86_HAVE_* in frameworks/rs.
Bug: 11048298
These SSE-related defines are unnecessary because all x86 Android devices
have these features. We switch all the checks to __i386__ instead.
This also fixes an issue where non-ARM bitcode files were being created with
the ARM defines present. This is problematic when we then try to do things
that would be arch-specific (i.e. the presence of SSE-enabled functions for
clamp(), ...).
This also cleans up the different target architecture specified in the x86
bitcode files so that they match the platform target (i686-unknown-linux).
Change-Id: I4776bbdce360de26e8a00e05d2cb19341d94a173
diff --git a/driver/runtime/rs_cl.c b/driver/runtime/rs_cl.c
index 7e8a574..8da343c 100755
--- a/driver/runtime/rs_cl.c
+++ b/driver/runtime/rs_cl.c
@@ -592,9 +592,9 @@
return 1.f / sqrt(v);
}
-#if !defined(ARCH_X86_HAVE_SSE2) && !defined(ARCH_X86_HAVE_SSE3)
+#if !defined(__i386__)
FN_FUNC_FN(sqrt)
-#endif // !defined(ARCH_X86_HAVE_SSE2) && !defined(ARCH_X86_HAVE_SSE3)
+#endif // !defined(__i386__)
FN_FUNC_FN(rsqrt)
@@ -902,7 +902,7 @@
return r;
}
-#if !defined(ARCH_X86_HAVE_SSE3)
+#if !defined(__i386__)
extern float __attribute__((overloadable)) dot(float lhs, float rhs) {
return lhs * rhs;