Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f1efa3ee authored by Narayan Kamath's avatar Narayan Kamath Committed by Android (Google) Code Review
Browse files

Merge "resolved conflicts for merge of 22d07464 to master"

parents ddaba436 ecd07216
Loading
Loading
Loading
Loading
+5 −5
Original line number Diff line number Diff line
@@ -70,7 +70,7 @@ void TextLayoutCache::operator()(TextLayoutCacheKey& text, sp<TextLayoutValue>&
    size_t totalSizeToDelete = text.getSize() + desc->getSize();
    mSize -= totalSizeToDelete;
    if (mDebugEnabled) {
        ALOGD("Cache value %p deleted, size = %d", desc.get(), totalSizeToDelete);
        ALOGD("Cache value %p deleted, size = %zu", desc.get(), totalSizeToDelete);
    }
}

@@ -130,7 +130,7 @@ sp<TextLayoutValue> TextLayoutCache::getValue(const SkPaint* paint,
                    bool removedOne = mCache.removeOldest();
                    LOG_ALWAYS_FATAL_IF(!removedOne, "The cache is non-empty but we "
                            "failed to remove the oldest entry.  "
                            "mSize = %u, size = %u, mMaxSize = %u, mCache.size() = %u",
                            "mSize = %u, size = %zu, mMaxSize = %u, mCache.size() = %zu",
                            mSize, size, mMaxSize, mCache.size());
                }
            }
@@ -149,7 +149,7 @@ sp<TextLayoutValue> TextLayoutCache::getValue(const SkPaint* paint,
                nsecs_t totalTime = systemTime(SYSTEM_TIME_MONOTONIC) - startTime;
                ALOGD("CACHE MISS: Added entry %p "
                        "with start = %d, count = %d, contextCount = %d, "
                        "entry size %d bytes, remaining space %d bytes"
                        "entry size %zu bytes, remaining space %d bytes"
                        " - Compute time %0.6f ms - Put time %0.6f ms - Text = '%s'",
                        value.get(), start, count, contextCount, size, mMaxSize - mSize,
                        value->getElapsedTime() * 0.000001f,
@@ -160,7 +160,7 @@ sp<TextLayoutValue> TextLayoutCache::getValue(const SkPaint* paint,
            if (mDebugEnabled) {
                ALOGD("CACHE MISS: Calculated but not storing entry because it is too big "
                        "with start = %d, count = %d, contextCount = %d, "
                        "entry size %d bytes, remaining space %d bytes"
                        "entry size %zu bytes, remaining space %d bytes"
                        " - Compute time %0.6f ms - Text = '%s'",
                        start, count, contextCount, size, mMaxSize - mSize,
                        value->getElapsedTime() * 0.000001f,
@@ -205,7 +205,7 @@ void TextLayoutCache::dumpCacheStats() {
    ALOGD("------------------------------------------------");
    ALOGD("pid       : %d", getpid());
    ALOGD("running   : %.0f seconds", timeRunningInSec);
    ALOGD("entries   : %d", cacheSize);
    ALOGD("entries   : %zu", cacheSize);
    ALOGD("max size  : %d bytes", mMaxSize);
    ALOGD("used      : %d bytes according to mSize", mSize);
    ALOGD("remaining : %d bytes or %2.2f percent", mMaxSize - mSize, remainingPercent);
+3 −3
Original line number Diff line number Diff line
@@ -111,7 +111,7 @@ socket_bind_local (JNIEnv *env, jobject object, jobject fileDescriptor,

/* private native void listen_native(int fd, int backlog) throws IOException; */
static void
socket_listen (JNIEnv *env, jobject object, jobject fileDescriptor, int backlog)
socket_listen (JNIEnv *env, jobject object, jobject fileDescriptor, jint backlog)
{
    int ret;
    int fd;
@@ -231,7 +231,7 @@ java_opt_to_real(int optID, int* opt, int* level)
}

static jint
socket_getOption(JNIEnv *env, jobject object, jobject fileDescriptor, int optID)
socket_getOption(JNIEnv *env, jobject object, jobject fileDescriptor, jint optID)
{
    int ret, value;
    int opt, level;
@@ -279,7 +279,7 @@ socket_getOption(JNIEnv *env, jobject object, jobject fileDescriptor, int optID)
}

static void socket_setOption(
        JNIEnv *env, jobject object, jobject fileDescriptor, int optID,
        JNIEnv *env, jobject object, jobject fileDescriptor, jint optID,
        jint boolValue, jint intValue) {
    int ret;
    int optname;
+1 −1
Original line number Diff line number Diff line
@@ -37,7 +37,7 @@ void* android::nio_getPointer(JNIEnv *_env, jobject buffer, jarray *array) {
                                         gNioJNI.getBasePointerID, buffer);
    if (pointer != 0L) {
        *array = NULL;
        return (void *) (jint) pointer;
        return reinterpret_cast<void *>(pointer);
    }

    *array = (jarray) _env->CallStaticObjectMethod(gNioJNI.nioAccessClass,
+5 −1
Original line number Diff line number Diff line
@@ -800,7 +800,7 @@ static void dumpNativeHeap(FILE* fp)
    fprintf(fp, "Total memory: %zu\n", totalMemory);
    fprintf(fp, "Allocation records: %zd\n", recordCount);
    if (backtraceSize != BACKTRACE_SIZE) {
        fprintf(fp, "WARNING: mismatched backtrace sizes (%d vs. %d)\n",
        fprintf(fp, "WARNING: mismatched backtrace sizes (%zu vs. %d)\n",
            backtraceSize, BACKTRACE_SIZE);
    }
    fprintf(fp, "\n");
@@ -823,7 +823,11 @@ static void dumpNativeHeap(FILE* fp)
            if (backtrace[bt] == 0) {
                break;
            } else {
#ifdef __LP64__
                fprintf(fp, " %016x", backtrace[bt]);
#else
                fprintf(fp, " %08x", backtrace[bt]);
#endif
            }
        }
        fprintf(fp, "\n");
+2 −2
Original line number Diff line number Diff line
@@ -47,7 +47,7 @@ static jint QTagUid_tagSocketFd(JNIEnv* env, jclass,
  return (jint)res;
}

static int QTagUid_untagSocketFd(JNIEnv* env, jclass,
static jint QTagUid_untagSocketFd(JNIEnv* env, jclass,
                                  jobject fileDescriptor) {
  int userFd = jniGetFDFromFileDescriptor(env, fileDescriptor);

Loading