J. Nick Koston
c09d5d783c
[api] Fix immediate benchmark to set batch_delay=0
...
should_send_immediately_ requires both should_try_send_immediately
flag AND batch_delay==0. Without setting batch_delay to 0, all
sends were falling back to the batch path.
2026-04-01 09:00:59 -10:00
J. Nick Koston
d717c7b46c
[api] Use large socket buffers and remove mid-loop draining
...
Increase socket buffer to 16MB so benchmarks never hit WOULD_BLOCK
during an inner loop iteration. Remove per-iteration drain_socket
calls that were adding noise and causing the immediate path to
fall back to batching. Drain only between outer iterations.
2026-04-01 08:54:30 -10:00
J. Nick Koston
f469a7ced2
[api] Add process_batch benchmarks for single and multi-sensor
...
Add ProcessBatch_SingleSensor and ProcessBatch_5Sensors benchmarks
that measure the full batch processing path: queue → process_batch_ →
dispatch → encode → frame → TCP write.
2026-04-01 08:49:33 -10:00
J. Nick Koston
3a4a88df29
[api] Add warm batch benchmark and bench_clear_batch friend
...
Add SendSensorState_Batch_Warm that pre-warms the deferred batch vector
before benchmarking to isolate steady-state cost from allocation.
2026-04-01 08:43:38 -10:00
J. Nick Koston
d3f3f89c59
[api] Extract shared TCP loopback helper for API benchmarks
...
Deduplicate the TCP loopback socket setup between bench_plaintext_frame
and bench_send_sensor_state into a shared bench_helpers.h header.
2026-04-01 07:48:12 -10:00
J. Nick Koston
dcac526a34
[api] Add send_sensor_state benchmarks
...
Add benchmarks for the full send_sensor_state path covering both
immediate send and batch paths. This measures the end-to-end cost
of sending a sensor state update through an APIConnection including
entity field population, proto encode, framing, and TCP write.
2026-04-01 07:42:58 -10:00
J. Nick Koston
8688ef7125
[benchmark] Fix decode benchmarks being optimized away by compiler ( #15293 )
2026-03-30 08:24:48 -10:00
J. Nick Koston
8a802ca666
[benchmark] Add BLE raw advertisement proto encode benchmarks ( #15289 )
2026-03-29 11:54:07 -10:00
J. Nick Koston
240e53afce
[fan] Add benchmarks for fan component ( #15210 )
2026-03-26 14:35:09 -10:00
J. Nick Koston
02e23eb386
[benchmark] Add light call and publish benchmarks ( #15176 )
2026-03-26 07:33:10 -10:00
J. Nick Koston
6898284361
[benchmark] Add cover publish_state and call benchmarks ( #15179 )
2026-03-26 07:32:54 -10:00
J. Nick Koston
f3a31be6d0
[benchmark] Add climate publish_state and call benchmarks ( #15180 )
2026-03-26 07:32:39 -10:00
J. Nick Koston
010516aef2
[benchmark] Add sensor publish_state benchmarks ( #15034 )
2026-03-25 07:33:17 -10:00
J. Nick Koston
690dc324c9
[logger] Move task log buffer storage to BSS ( #15153 )
2026-03-25 00:52:37 +00:00
J. Nick Koston
a0d0516b22
[benchmark] Add noise handshake benchmark ( #15039 )
2026-03-23 13:40:41 -10:00
J. Nick Koston
597bb18543
[benchmark] Add binary sensor publish and sensor filter benchmarks ( #15035 )
2026-03-23 16:30:57 +13:00
J. Nick Koston
593dbc9e67
[logger] Fix unit test and benchmark Logger constructor calls ( #15085 )
2026-03-23 09:50:58 +13:00
J. Nick Koston
86ec218f75
[benchmark] Add plaintext API frame write benchmarks ( #15036 )
2026-03-21 13:15:35 -10:00
J. Nick Koston
1920d8a887
[benchmark] Add noise encryption benchmarks ( #15037 )
2026-03-20 17:35:17 -10:00
0c5f055d45
[core] cpp tests: Allow customizing code generation during tests ( #14681 )
...
Co-authored-by: J. Nick Koston <nick@home-assistant.io >
Co-authored-by: J. Nick Koston <nick@koston.org >
2026-03-18 00:16:01 +00:00
J. Nick Koston
1670f04a87
[core] Add CodSpeed C++ benchmarks for protobuf, main loop, and helpers ( #14878 )
2026-03-17 12:29:38 -10:00