Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add basic microbenchmarks for algorithm #2285

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

alexvanyo
Copy link
Owner

Fixes #1761

Copy link

codecov bot commented Jan 2, 2025

❌ 10 Tests Failed:

Tests completed Failed Passed Skipped
15971 10 15961 0
View the top 3 failed tests by shortest run time
com.alexvanyo.composelife.algorithm.GameOfLifeAlgorithmBenchmarks generations_100[Naive Algorithm,Flip across y-axis]
Stack Traces | 0.006s run time
java.lang.IllegalStateException: Unable to start perfetto tracing
Please report a bug, and include a logcat capture of the test run and failure.
DeviceInfo(Brand=Android, Model=Android SDK built for x86, SDK=23, BuildFp=Android/sdk_phone_x86/generic_x86:6.0/MASTER/4174734:userdebug/test-keys)
	at d.j.c(SourceFile:34)
	at d.j.d(SourceFile:617)
	at d.g.a(SourceFile:117)
	at c.b.evaluate(SourceFile:52)
	at androidx.test.rule.GrantPermissionRule$RequestPermissionStatement.evaluate(SourceFile:12)
	at org.junit.rules.RunRules.evaluate(SourceFile:3)
	at com.google.testing.junit.testparameterinjector.PluggableTestRunner$ContextMethodRule$1.evaluate(PluggableTestRunner.java:414)
	at org.junit.runners.ParentRunner$3.evaluate(SourceFile:3)
	at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(SourceFile:9)
	at org.junit.runners.ParentRunner.runLeaf(SourceFile:9)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(SourceFile:6)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(SourceFile:1)
	at org.junit.runners.ParentRunner$4.run(SourceFile:7)
	at org.junit.runners.ParentRunner$1.schedule(SourceFile:1)
	at org.junit.runners.ParentRunner.runChildren(SourceFile:26)
	at org.junit.runners.ParentRunner.access$100(SourceFile:1)
	at org.junit.runners.ParentRunner$2.evaluate(SourceFile:5)
	at org.junit.runners.ParentRunner$3.evaluate(SourceFile:3)
	at org.junit.runners.ParentRunner.run(SourceFile:17)
	at org.junit.runners.Suite.runChild(SourceFile:2)
	at org.junit.runners.Suite.runChild(SourceFile:1)
	at org.junit.runners.ParentRunner$4.run(SourceFile:7)
	at org.junit.runners.ParentRunner$1.schedule(SourceFile:1)
	at org.junit.runners.ParentRunner.runChildren(SourceFile:26)
	at org.junit.runners.ParentRunner.access$100(SourceFile:1)
	at org.junit.runners.ParentRunner$2.evaluate(SourceFile:5)
	at org.junit.runners.ParentRunner$3.evaluate(SourceFile:3)
	at org.junit.runners.ParentRunner.run(SourceFile:17)
	at org.junit.runner.JUnitCore.run(SourceFile:9)
	at org.junit.runner.JUnitCore.run(SourceFile:3)
	at androidx.test.internal.runner.TestExecutor.execute(SourceFile:7)
	at androidx.test.internal.runner.TestExecutor.execute(SourceFile:2)
	at androidx.test.runner.AndroidJUnitRunner.onStart(SourceFile:139)
	at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1879)
Caused by: java.io.FileNotFoundException: tracebox_x86
	at android.content.res.AssetManager.openAsset(Native Method)
	at android.content.res.AssetManager.open(AssetManager.java:313)
	at android.content.res.AssetManager.open(AssetManager.java:287)
	at d.i.invoke(SourceFile:211)
	at kotlin.h.getValue(SourceFile:21)
	at k.c.x(SourceFile:471)
	at d.j.d(SourceFile:36)
	... 32 more
com.alexvanyo.composelife.algorithm.GameOfLifeAlgorithmBenchmarks generations_100[Naive Algorithm,Flip across x-axis]
Stack Traces | 0.016s run time
java.lang.IllegalStateException: Unable to start perfetto tracing
Please report a bug, and include a logcat capture of the test run and failure.
DeviceInfo(Brand=Android, Model=Android SDK built for x86, SDK=23, BuildFp=Android/sdk_phone_x86/generic_x86:6.0/MASTER/4174734:userdebug/test-keys)
	at d.j.c(SourceFile:34)
	at d.j.d(SourceFile:617)
	at d.g.a(SourceFile:117)
	at c.b.evaluate(SourceFile:52)
	at androidx.test.rule.GrantPermissionRule$RequestPermissionStatement.evaluate(SourceFile:12)
	at org.junit.rules.RunRules.evaluate(SourceFile:3)
	at com.google.testing.junit.testparameterinjector.PluggableTestRunner$ContextMethodRule$1.evaluate(PluggableTestRunner.java:414)
	at org.junit.runners.ParentRunner$3.evaluate(SourceFile:3)
	at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(SourceFile:9)
	at org.junit.runners.ParentRunner.runLeaf(SourceFile:9)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(SourceFile:6)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(SourceFile:1)
	at org.junit.runners.ParentRunner$4.run(SourceFile:7)
	at org.junit.runners.ParentRunner$1.schedule(SourceFile:1)
	at org.junit.runners.ParentRunner.runChildren(SourceFile:26)
	at org.junit.runners.ParentRunner.access$100(SourceFile:1)
	at org.junit.runners.ParentRunner$2.evaluate(SourceFile:5)
	at org.junit.runners.ParentRunner$3.evaluate(SourceFile:3)
	at org.junit.runners.ParentRunner.run(SourceFile:17)
	at org.junit.runners.Suite.runChild(SourceFile:2)
	at org.junit.runners.Suite.runChild(SourceFile:1)
	at org.junit.runners.ParentRunner$4.run(SourceFile:7)
	at org.junit.runners.ParentRunner$1.schedule(SourceFile:1)
	at org.junit.runners.ParentRunner.runChildren(SourceFile:26)
	at org.junit.runners.ParentRunner.access$100(SourceFile:1)
	at org.junit.runners.ParentRunner$2.evaluate(SourceFile:5)
	at org.junit.runners.ParentRunner$3.evaluate(SourceFile:3)
	at org.junit.runners.ParentRunner.run(SourceFile:17)
	at org.junit.runner.JUnitCore.run(SourceFile:9)
	at org.junit.runner.JUnitCore.run(SourceFile:3)
	at androidx.test.internal.runner.TestExecutor.execute(SourceFile:7)
	at androidx.test.internal.runner.TestExecutor.execute(SourceFile:2)
	at androidx.test.runner.AndroidJUnitRunner.onStart(SourceFile:139)
	at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1879)
Caused by: java.io.FileNotFoundException: tracebox_x86
	at android.content.res.AssetManager.openAsset(Native Method)
	at android.content.res.AssetManager.open(AssetManager.java:313)
	at android.content.res.AssetManager.open(AssetManager.java:287)
	at d.i.invoke(SourceFile:211)
	at kotlin.h.getValue(SourceFile:21)
	at k.c.x(SourceFile:471)
	at d.j.d(SourceFile:36)
	... 32 more
com.alexvanyo.composelife.algorithm.GameOfLifeAlgorithmBenchmarks generations_100[HashLife Algorithm,Flip across x-axis]
Stack Traces | 0.018s run time
java.lang.IllegalStateException: Unable to start perfetto tracing
Please report a bug, and include a logcat capture of the test run and failure.
DeviceInfo(Brand=Android, Model=Android SDK built for x86, SDK=23, BuildFp=Android/sdk_phone_x86/generic_x86:6.0/MASTER/4174734:userdebug/test-keys)
	at d.j.c(SourceFile:34)
	at d.j.d(SourceFile:617)
	at d.g.a(SourceFile:117)
	at c.b.evaluate(SourceFile:52)
	at androidx.test.rule.GrantPermissionRule$RequestPermissionStatement.evaluate(SourceFile:12)
	at org.junit.rules.RunRules.evaluate(SourceFile:3)
	at com.google.testing.junit.testparameterinjector.PluggableTestRunner$ContextMethodRule$1.evaluate(PluggableTestRunner.java:414)
	at org.junit.runners.ParentRunner$3.evaluate(SourceFile:3)
	at org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(SourceFile:9)
	at org.junit.runners.ParentRunner.runLeaf(SourceFile:9)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(SourceFile:6)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(SourceFile:1)
	at org.junit.runners.ParentRunner$4.run(SourceFile:7)
	at org.junit.runners.ParentRunner$1.schedule(SourceFile:1)
	at org.junit.runners.ParentRunner.runChildren(SourceFile:26)
	at org.junit.runners.ParentRunner.access$100(SourceFile:1)
	at org.junit.runners.ParentRunner$2.evaluate(SourceFile:5)
	at org.junit.runners.ParentRunner$3.evaluate(SourceFile:3)
	at org.junit.runners.ParentRunner.run(SourceFile:17)
	at org.junit.runners.Suite.runChild(SourceFile:2)
	at org.junit.runners.Suite.runChild(SourceFile:1)
	at org.junit.runners.ParentRunner$4.run(SourceFile:7)
	at org.junit.runners.ParentRunner$1.schedule(SourceFile:1)
	at org.junit.runners.ParentRunner.runChildren(SourceFile:26)
	at org.junit.runners.ParentRunner.access$100(SourceFile:1)
	at org.junit.runners.ParentRunner$2.evaluate(SourceFile:5)
	at org.junit.runners.ParentRunner$3.evaluate(SourceFile:3)
	at org.junit.runners.ParentRunner.run(SourceFile:17)
	at org.junit.runner.JUnitCore.run(SourceFile:9)
	at org.junit.runner.JUnitCore.run(SourceFile:3)
	at androidx.test.internal.runner.TestExecutor.execute(SourceFile:7)
	at androidx.test.internal.runner.TestExecutor.execute(SourceFile:2)
	at androidx.test.runner.AndroidJUnitRunner.onStart(SourceFile:139)
	at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1879)
Caused by: java.io.FileNotFoundException: tracebox_x86
	at android.content.res.AssetManager.openAsset(Native Method)
	at android.content.res.AssetManager.open(AssetManager.java:313)
	at android.content.res.AssetManager.open(AssetManager.java:287)
	at d.i.invoke(SourceFile:211)
	at kotlin.h.getValue(SourceFile:21)
	at k.c.x(SourceFile:471)
	at d.j.d(SourceFile:36)
	... 32 more

To view more test analytics, go to the Test Analytics Dashboard
📢 Thoughts on this report? Let us know!

@alexvanyo alexvanyo force-pushed the av/algorithm-microbenchmark branch 3 times, most recently from 3be275a to 925d340 Compare January 4, 2025 20:55
@alexvanyo alexvanyo force-pushed the av/algorithm-microbenchmark branch from 925d340 to 6a66e23 Compare January 5, 2025 18:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add microbenchmarking to algorithms
1 participant