android-macrobenchmark

android-macrobenchmark is a skill for Claude Code, Codex from prasad-vennam/Awesome-Android-AI-Agent-Skills. It costs 21 tokens per session (502 once invoked), scanned A, original, MIT.

Guidance for measuring Android app startup and interface speed with Macrobenchmark, a testing tool for complete user journeys such as launching or scrolling. It also covers Baseline Profiles, which tell Android which code to prepare early.

In plain words
What is it for?
Use it to create separate benchmark tests, measure app launch or scrolling, inspect frame timing, and generate or apply Baseline Profiles.
Why use it?
It replaces guesses about performance with repeatable measurements and helps improve startup and frame timing.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to create separate benchmark tests, measure app launch or scrolling, inspect frame timing, and generate or apply Baseline Profiles.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/prasad-vennam/awesome-android-ai-agent-skills/android-macrobenchmark
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add prasad-vennam/Awesome-Android-AI-Agent-Skills --skill android-macrobenchmark
Clone the repo
git clone --depth 1 https://github.com/prasad-vennam/Awesome-Android-AI-Agent-Skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for android-macrobenchmark

README.md
[![agentmods](https://agentmods.dev/badge/skills/prasad-vennam/awesome-android-ai-agent-skills/android-macrobenchmark/github.svg)](https://agentmods.dev/skills/prasad-vennam/awesome-android-ai-agent-skills/android-macrobenchmark)
Your own site
<a href="https://agentmods.dev/skills/prasad-vennam/awesome-android-ai-agent-skills/android-macrobenchmark"><img src="https://agentmods.dev/badge/skills/prasad-vennam/awesome-android-ai-agent-skills/android-macrobenchmark/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for android-macrobenchmark

Your own site · 80×15
<a href="https://agentmods.dev/skills/prasad-vennam/awesome-android-ai-agent-skills/android-macrobenchmark"><img src="https://agentmods.dev/badge/skills/prasad-vennam/awesome-android-ai-agent-skills/android-macrobenchmark.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 21 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 502 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00021 $0.00502
Opus 5 $0.00010 $0.00251
Sonnet 5 $0.00004 $0.00100
Haiku 4.5 $0.00002 $0.00050

Measured 11d ago against content hash 6cfe8092f1a0, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

android-macrobenchmark scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/android-macrobenchmark/SKILL.md · 65 lines

What it actually says

Android Macrobenchmark & Baseline Profiles 🏎️

App Startup Time and UI performance are crucial. Macrobenchmark allows us to write standard JUnit 4 tests to measure end-to-end user journeys (like app startup or scrolling a list) and automatically generate Baseline Profiles that Android's ART uses to pre-compile critical code.

⚡ When to Use

  • When the prompt mentions "speeding up app startup time"
  • When writing a Macrobenchmark module
  • When generating or applying Baseline Profiles (baseline-prof.txt)

🏗️ Core Rules / Pillars

1. Separate Macrobenchmark Module

  • Pattern: Macrobenchmarks MUST be in a separate com.android.test module. They launch your application by its applicationId externally.
  • Anti-Pattern: Do NOT attempt to run Macrobenchmark tests inside the standard app/src/androidTest directory.

2. Writing a Scrolling Benchmark

  • Implementation:
    @RunWith(AndroidJUnit4::class)
    class ScrollBenchmark {
        @get:Rule
        val benchmarkRule = MacrobenchmarkRule()
    
        @Test
        fun scrollTimeline() = benchmarkRule.measureRepeated(
            packageName = "com.example.app",
            metrics = listOf(FrameTimingMetric()),
            iterations = 5,
            startupMode = StartupMode.COLD
        ) {
            pressHome()
            startActivityAndWait()
            
            // Using UIAutomator to find the scrollable list and scroll
            val list = device.findObject(By.res("com.example.app", "timeline_list"))
            list.setGestureMargin(device.displayWidth / 5)
            list.fling(Direction.DOWN)
        }
    }
    

🚧 Critical Anti-Hallucination Guards

  • Trap: Baseline Profiles generation requires a rooted device OR a device running Android 13 (API 33)+.
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 65 lines · 21 tokens per session scan A 6cfe8092f1a0

Subscribe to this mod's changes

android-macrobenchmark is a skill published in the GitHub repository prasad-vennam/Awesome-Android-AI-Agent-Skills (9 stars, last pushed 5mo ago), licensed MIT. It adds 21 tokens to every session and 502 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

android_ui_verification

Automated end-to-end UI testing and verification on an Android Emulator using ADB.

sickn33/agentic-awesome-skills · 22 tokens

dogfood

Systematically explore and test a mobile app on iOS/Android with agent-device to find bugs, UX issues, and other problems. Use when asked to dogfood, QA, exploratory test, find issues, bug hunt, or test this app on mobile.

callstack/agent-device · 55 tokens

ios-simulator

Verify and debug native, React Native, Expo, or Flutter apps on an iOS Simulator with agent-device. Use when an agent needs to launch an app, inspect its live UI, tap, type, scroll, validate a code change, collect failure evidence, or reproduce a workflow on an iPhone or iPad Simulator.

callstack/agent-device · 69 tokens

solopi-ai

A command-line framework for testing Android apps and devices with SoloPi, including on-device or cloud AI decision models. It manages devices, test cases, recorded interactions, replays, performance history, and evidence.

alipay/SoloPi · 127 tokens

eas-simulator

EAS service (paid). Run and control a user's app on a remote iOS/Android simulator hosted on EAS cloud. Read before running any eas simulator: commands - it has the current syntax for this experimental API. Use whenever the user needs a simulator they can't run locally - 'run my app on a cloud simulator', 'use eas…

expo/skills · 249 tokens

flutter-add-widget-test

Implement a component-level test using WidgetTester to verify UI rendering and user interactions (tapping, scrolling, entering text). Use when validating that a specific widget displays correct data and responds to events as expected.

flutter/agent-plugins · 48 tokens