Repository navigation
Conversation
🎉 All green!🧪 All tests passed 🔗 Commit SHA: 7045fe6 | Docs | View more details | Give us feedback! |
sbarrio
marked this pull request as ready for review
October 5, 2026 13:19
sbarrio
force-pushed
the
sbarrio/RUM-18282/add-profiling-scenario-to-benchmark-app
branch
from
October 16, 2026 10:01
7738127 to
ffe1dce
Compare
jeff-morgan-dd
approved these changes
Oct 16, 2026
sbarrio
force-pushed
the
sbarrio/RUM-18282/add-profiling-scenario-to-benchmark-app
branch
from
October 27, 2026 13:46
ffe1dce to
b1e0dc8
Compare
sbarrio
force-pushed
the
sbarrio/RUM-18282/add-profiling-scenario-to-benchmark-app
branch
from
October 27, 2026 13:53
b1e0dc8 to
7641d9c
Compare
Co-authored-by: jeff-morgan-dd <jeff.morgan@datadoghq.com>
Co-authored-by: jeff-morgan-dd <jeff.morgan@datadoghq.com>
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Credential logging and unresolved RUM view, initialization, and busy-state issues compromise secure and reliable profiling runs.
4 open issues
What changed in this PR
Adds a native profiling scenario to the benchmark app to measure profiling overhead on iOS and Android.
Changes:
- Adds a profiling run type, scenario routing, and native profiling dependencies.
- Provides sorting, Fibonacci, prime-counting, and JS long-task workloads.
- Enables JS long-task reporting and documents profiling launch commands.
| File | Description |
|---|---|
yarn.lock |
Records the benchmark profiling dependency. |
benchmarks/src/testSetup/types/testConfig.ts |
Defines the profiling scenario and native-profiling run type. |
benchmarks/src/testSetup/testUtils.ts |
Enables JS long-task reporting at 200 ms. |
benchmarks/src/scenario/Profiling/types.ts |
Defines profiling scenario props. |
benchmarks/src/scenario/Profiling/profilingUtils.ts |
Adds CPU-intensive workload helpers. |
benchmarks/src/scenario/Profiling/profilingScenario.tsx |
Adds profiler setup, workload controls, and timing results. |
benchmarks/src/App.tsx |
Routes the profiling scenario. |
benchmarks/README.md |
Documents launch commands and Android requirements. |
benchmarks/package.json |
Adds the profiling workspace dependency. |
benchmarks/ios/Podfile.lock |
Records native iOS profiling pods. |
Review effort: Balanced
| const [lastResult, setLastResult] = useState<string>(''); | ||
|
|
||
| useEffect(() => { | ||
| console.log(props.testConfig); |
Comment on lines
+42
to
+43
| instrument().then(async () => { | ||
| if (runType === RunType.INSTRUMENTED_PROFILING_NATIVE) { |
Comment on lines
+45
to
+48
| await DdProfiling.enable({ | ||
| applicationLaunchSampleRate: 100, | ||
| continuousSampleRate: 100, | ||
| }); |
Comment on lines
+58
to
+63
| const startTime = performance.now(); | ||
| work(); | ||
| const durationMs = performance.now() - startTime; | ||
|
|
||
| setLastResult(`${label} took ${durationMs.toFixed(0)}ms`); | ||
| setIsRunning(false); |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


What does this PR do?
It adds a new profiling scenario to the benchmark app. Allowing benchmark runs that enable the Profiling module and configure the native iOS/Android profilers. It then offers 3 stress test buttons to create CPU work for the test to send profiles.
Motivation
We should be able to monitor the performance impact of the profiling module.
Additional notes
Review checklist (to be filled by reviewers)