Code Monkey home page Code Monkey logo

Comments (1)

keyboardsurfer avatar keyboardsurfer commented on May 11, 2024

Thanks for this input. You are mixing two different approaches for installing an app with a baseline profile.
When a baseline profile is provided within the app, and the app is installed via local development tools you won't see the speed profile reported correctly.
The expected status of status=speed-profile instead of status=run-from-apk is visible for apps installed from the Play Store instead.

The Profile Installer library takes on the installation of the baseline profile. In order to verify the difference startup or runtime duration, use the Macrobenchmark library. We have included a set of startup benchmarks in Now in Android.

You can also load the development apk into Android Studio's APK Analyzer and check whether the profile is included as /assets/dexopt/baseline.prof{m}.

Lastly, you can verify the installation by triggering a broadcast to force synchronous installation of the baseline profile, the same way that the benchmarking library does.
For a release build of Now in Android this broadcast is

adb shell am broadcast -a androidx.profileinstaller.action.INSTALL_PROFILE com.google.samples.apps.nowinandroid.demo/androidx.profileinstaller.ProfileInstallReceiver

If that returns 1, the profile has been successfully installed.

Thanks for highlighting this potentially confusing section in our guidance. We will take a closer look and see how this can be improved by streamlining the guidance provided.

from nowinandroid.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.