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

Commit d003428f authored by Manisha Jajoo's avatar Manisha Jajoo
Browse files

Benchmark: Use threadpool for multiple iterations

Test: atest com.android.media.benchmark.tests \
      -- --enable-module-dynamic-download=true
Bug: 140128505

Change-Id: I1fe64181972b917a541f09a25f918287a0860ec4
parent 333cf07d
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -69,7 +69,6 @@ android_library {
java_defaults {
    name: "MediaBenchmark-defaults",

    sdk_version: "system_current",
    min_sdk_version: "28",
    target_sdk_version: "29",
    target_sdk_version: "30",
}
+10 −10
Original line number Diff line number Diff line
@@ -17,21 +17,21 @@
buildscript {
    repositories {
        google()
        jcenter()
        mavenCentral()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:3.5.0'
        classpath 'com.android.tools.build:gradle:4.2.1'
    }
}

apply plugin: 'com.android.application'

android {
    compileSdkVersion 29
    compileSdkVersion 30
    defaultConfig {
        applicationId "com.android.media.benchmark"
        minSdkVersion 28
        targetSdkVersion 29
        targetSdkVersion 30
        versionCode 1
        versionName "1.0"
        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
@@ -57,20 +57,20 @@ android {
    externalNativeBuild {
        cmake {
            path "src/main/cpp/CMakeLists.txt"
            version "3.10.2"
            version "3.18.1"
        }
    }
}

repositories {
    google()
    jcenter()
    mavenCentral()
}

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    implementation 'androidx.appcompat:appcompat:1.1.0'
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'androidx.test:runner:1.2.0'
    androidTestImplementation 'androidx.test.ext:junit:1.1.1'
    implementation 'androidx.appcompat:appcompat:1.3.0'
    testImplementation 'junit:junit:4.13.2'
    androidTestImplementation 'androidx.test:runner:1.3.0'
    androidTestImplementation 'androidx.test.ext:junit:1.1.2'
}
 No newline at end of file
+0 −1
Original line number Diff line number Diff line
@@ -9,7 +9,6 @@ package {

cc_test_library {
    name: "libmediabenchmark_jni",
    sdk_version: "current",

    defaults: [
        "libmediabenchmark_common-defaults",
+0 −1
Original line number Diff line number Diff line
@@ -55,7 +55,6 @@ cc_defaults {

cc_defaults {
    name: "libmediabenchmark-defaults",
    sdk_version: "current",
    stl: "c++_shared",

    shared_libs: [
+1 −3
Original line number Diff line number Diff line
@@ -124,9 +124,7 @@ void Extractor::deInitExtractor() {

    int64_t sTime = mStats->getCurTime();
    if (mExtractor) {
        // TODO: (b/140128505) Multiple calls result in DoS.
        // Uncomment call to AMediaExtractor_delete() once this is resolved
        // AMediaExtractor_delete(mExtractor);
        AMediaExtractor_delete(mExtractor);
        mExtractor = nullptr;
    }
    int64_t eTime = mStats->getCurTime();
Loading