FluidFramework
FluidFramework copied to clipboard
Sharedstring memory tests
Description
Basic memory profiling tests for SharedString.
Any relevant logs or outputs
Output of the tests:
/workspaces/FluidFramework/packages/dds/sequence $ npm run test:memory
> @fluidframework/[email protected] test:memory /workspaces/FluidFramework/packages/dds/sequence
> mocha --config src/test/memory/.mocharc.js
SharedString memory usage
status name Heap Used Avg Heap Used StdDev Margin of Error Relative Margin of Error Samples
------ --------------------------------------------- ------------- ---------------- --------------- ------------------------ -------
✔ Create empty SharedString 65,374.15 2,783.12 ±172.50 ±0.26% 1000
✔ Insert and remove text 100 times 1,371,062.40 46,539.06 ±33,289.73 ±2.43% 10
✔ Replace text 100 times 1,353,343.27 149,654.13 ±33,427.16 ±2.47% 77
✔ Get text annotation 100 times 104,595.00 2,852.82 ±2,385.40 ±2.28% 8
✔ Get marker 100 times 84,862.86 2,171.39 ±2,008.27 ±2.37% 7
✔ Annotate marker 100 times with same options 240,756.80 4,509.96 ±5,598.96 ±2.33% 5
✔ Insert and remove text 1000 times 12,275,104.00 300,861.04 ±278,260.08 ±2.27% 7
✔ Replace text 1000 times 12,503,838.40 232,024.87 ±288,050.74 ±2.30% 5
✔ Get text annotation 1000 times 341,097.07 14,464.98 ±8,011.24 ±2.35% 15
✔ Get marker 1000 times 85,046.40 360.07 ±447.01 ±0.53% 5
✔ Annotate marker 1000 times with same options 1,598,728.00 17,304.18 ±21,482.53 ±1.34% 5
✔ Insert and remove text 10000 times 15,289,363.20 93,635.18 ±116,244.79 ±0.76% 5
✔ Replace text 10000 times 14,641,096.46 2,819,085.66 ±933,964.40 ±6.38% 35
✔ Get text annotation 10000 times 2,144,424.84 109,028.14 ±52,551.83 ±2.45% 19
✔ Get marker 10000 times 85,679.00 2,484.01 ±2,077.01 ±2.42% 8
✔ Annotate marker 10000 times with same options 11,902,705.60 92,819.58 ±115,232.25 ±0.97% 5
Waiting for https://github.com/microsoft/FluidFramework/pull/11299 to be merged, that should take care of the "client packages" failed check about different versions between the new dependency on @fluid-tools/benchmark in the sequence package, and the one hoisted by Lerna based on the dependencies other packages have on it as well.
This commit is queued for merging with the next
branch! Please ignore this PR for now. Contact @microsoft/fluid-cr-infra for help.