diff options
Diffstat (limited to 'libs/androidfw/AssetManager.cpp')
-rw-r--r-- | libs/androidfw/AssetManager.cpp | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/libs/androidfw/AssetManager.cpp b/libs/androidfw/AssetManager.cpp index 6913f43a87c3..715c875d064d 100644 --- a/libs/androidfw/AssetManager.cpp +++ b/libs/androidfw/AssetManager.cpp @@ -34,9 +34,7 @@ #include <utils/String8.h> #include <utils/threads.h> #include <utils/Timers.h> -#ifdef __ANDROID__ -#include <cutils/trace.h> -#endif +#include <utils/Trace.h> #include <assert.h> #include <dirent.h> @@ -54,14 +52,6 @@ _rc; }) #endif -#ifdef __ANDROID__ -#define MY_TRACE_BEGIN(x) ATRACE_BEGIN(x) -#define MY_TRACE_END() ATRACE_END() -#else -#define MY_TRACE_BEGIN(x) -#define MY_TRACE_END() -#endif - using namespace android; static const bool kIsDebug = false; @@ -623,7 +613,7 @@ bool AssetManager::appendPathToResTable(const asset_path& ap, bool appAsLib) con ResTable* sharedRes = NULL; bool shared = true; bool onlyEmptyResources = true; - MY_TRACE_BEGIN(ap.path.string()); + ATRACE_NAME(ap.path.string()); Asset* idmap = openIdmapLocked(ap); size_t nextEntryIdx = mResources->getTableCount(); ALOGV("Looking for resource asset in '%s'\n", ap.path.string()); @@ -703,8 +693,6 @@ bool AssetManager::appendPathToResTable(const asset_path& ap, bool appAsLib) con if (idmap != NULL) { delete idmap; } - MY_TRACE_END(); - return onlyEmptyResources; } @@ -752,6 +740,7 @@ const ResTable* AssetManager::getResTable(bool required) const void AssetManager::updateResourceParamsLocked() const { + ATRACE_CALL(); ResTable* res = mResources; if (!res) { return; |