diff options
author | Miao Wang <miaowang@google.com> | 2017-02-27 17:36:40 -0800 |
---|---|---|
committer | Miao Wang <miaowang@google.com> | 2017-02-28 14:40:55 -0800 |
commit | 2a61168a777ee434ce2c28945aa74f6a6bcf2820 (patch) | |
tree | d063999ac4c5d9bd9873928ed765a8ab26375ee9 /cpu_ref | |
parent | 2f0aa81ec84c3cc3acac82f4e57e135f2b8a2414 (diff) | |
download | rs-2a61168a777ee434ce2c28945aa74f6a6bcf2820.tar.gz |
Remove libcutils dependency.
- Implement property_get using __system_property_get, remove
dependencies on cutils/properties.h.
- remove rsCompatibilityLib.cpp since it only contains propery_get, and
it is now in rsCppUtils.cpp.
- Disable ATRACE. The systrace is current done in Java level. If we
want to do it in the driver, we need to have our own implementation
similar to native/utils/trace.cc
- Remove CC_LIKELY macro.
Bug: 34396220
Test: build
Change-Id: I6a6cbcfb2ca15b9d1f09b9ce0579d39fdbe98727
Diffstat (limited to 'cpu_ref')
-rw-r--r-- | cpu_ref/Android.mk | 2 | ||||
-rw-r--r-- | cpu_ref/rsCpuExecutable.cpp | 3 | ||||
-rw-r--r-- | cpu_ref/rsCpuScript.cpp | 7 |
3 files changed, 6 insertions, 6 deletions
diff --git a/cpu_ref/Android.mk b/cpu_ref/Android.mk index ed72ad21..5d1b223c 100644 --- a/cpu_ref/Android.mk +++ b/cpu_ref/Android.mk @@ -83,7 +83,7 @@ ifeq ($(ARCH_X86_HAVE_SSSE3),true) rsCpuIntrinsics_x86.cpp endif -LOCAL_SHARED_LIBRARIES += libRS_internal libc++ libcutils liblog libutils libz +LOCAL_SHARED_LIBRARIES += libRS_internal libc++ liblog libutils libz LOCAL_SHARED_LIBRARIES += libbcinfo libblas LOCAL_STATIC_LIBRARIES := libbnnmlowp diff --git a/cpu_ref/rsCpuExecutable.cpp b/cpu_ref/rsCpuExecutable.cpp index 84456273..426d89e2 100644 --- a/cpu_ref/rsCpuExecutable.cpp +++ b/cpu_ref/rsCpuExecutable.cpp @@ -5,9 +5,10 @@ #include <set> #include <memory> +#include <sys/stat.h> + #ifdef RS_COMPATIBILITY_LIB #include <stdio.h> -#include <sys/stat.h> #include <unistd.h> #else #include "bcc/Config.h" diff --git a/cpu_ref/rsCpuScript.cpp b/cpu_ref/rsCpuScript.cpp index b04e1d28..5bd24240 100644 --- a/cpu_ref/rsCpuScript.cpp +++ b/cpu_ref/rsCpuScript.cpp @@ -27,7 +27,6 @@ #include <bcc/Config.h> #include <bcinfo/MetadataExtractor.h> - #include <cutils/properties.h> #include <zlib.h> #include <sys/file.h> @@ -62,13 +61,13 @@ static bool is_force_recompile() { char buf[PROPERTY_VALUE_MAX]; // Re-compile if floating point precision has been overridden. - property_get("debug.rs.precision", buf, ""); + android::renderscript::property_get("debug.rs.precision", buf, ""); if (buf[0] != '\0') { return true; } // Re-compile if debug.rs.forcerecompile is set. - property_get("debug.rs.forcerecompile", buf, "0"); + android::renderscript::property_get("debug.rs.forcerecompile", buf, "0"); if ((::strcmp(buf, "1") == 0) || (::strcmp(buf, "true") == 0)) { return true; } else { @@ -178,7 +177,7 @@ bool isChecksumNeeded(const char *cacheDir) { (::strcmp(SYSLIBPATH_VENDOR, cacheDir) == 0)) return false; char buf[PROPERTY_VALUE_MAX]; - property_get("ro.debuggable", buf, ""); + android::renderscript::property_get("ro.debuggable", buf, ""); return (buf[0] == '1'); } |