| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
| |
commit_hash:54a07f0d411d0ece7af812a9fdf91509f25ee5cb
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Profile-driven optimizations of the `Format` hot path, benchmarked against a representative master debug log (structured `"Key: %v"` messages dominated by GUIDs, strings, integers, bools and durations). Median improvements of ~15-20% across the workload, measured on a dedicated host.
Changes:
- `string_builder`: use `resize_uninitialized` in `DoReserve` to avoid zero-filling the buffer on every `Format` call.
- `format`: replace the per-argument `memchr` (`spec.Contains('n')`) with an inline scan, force-inline `RunFormatterAt`, and add a `FormatString` fast path for the common plain `%v` / empty spec.
- `guid`: rewrite `WriteGuidToBuffer` using a `clz`-derived digit count and a back-to-front fill instead of the per-magnitude branch cascade (cut from ~26% to ~12% of a GUID-heavy line). Validated against an `%x` reference over 2M random GUIDs plus edge cases.
Also adds `library/cpp/yt/string/benchmark` to track `Format` performance.
### Benchmarks
Median ns/op (lower is better), pinned core on a dedicated Xeon E5-2650 v2, 9x1s repetitions. See `library/cpp/yt/string/benchmark`.
| Benchmark | What it formats | Before | After | Speedup |
| --- | --- | ---: | ---: | ---: |
| `ManyMixedArgs` | ~18 args: GUIDs, strings, duration, ints | 1030 | 833 | -19% |
| `StringAndTwoGuids` | literal prefix + two GUIDs | 233 | 185 | -21% |
| `IntAndGuid` | one int + one GUID | 205 | 179 | -13% |
| `ManyInts` | six integers | 389 | 340 | -13% |
| `Guid` | a single GUID | 156 | 131 | -16% |
| `String` | a single string | 139 | 104 | -25% |
| `Int` | a single integer | 142 | 120 | -15% |
| `NoArgs` | a literal with no arguments | 88.8 | 85.7 | -3% |
commit_hash:ce9957a06c3ff28b2889aa65fbbddf4ca444f9fe
|
| |
|
|
|
|
|
| |
многие либы тянут yt/string и получают транизитивно compact\_container, который в большинстве случаев не используется (и не собирается под 32 бита)
убираю это зависимость через forward decl (всё что делает string с compact\_container это задаёт концепты, которым не нужно полное определение)
commit_hash:611af702c90f87ab98e05df17ec992bd2a972488
|
| |
|
|
| |
commit_hash:fc31d2770ebeffeb513c4535bd146c731b7f78fb
|
| |
|
|
| |
commit_hash:1573c88f09db79bab2755c9c2c3ffd0bc219b2d2
|
| |
|
|
|
|
|
|
|
|
|
| |
We slightly rework inner workings of stat analysis. For almost any sane use case the behavior is identical, but should compile a little faster.
If you send string literals like `char[N]` or `const char*` make them constexpr. If you can't (e.g. `ex.what()` case) wrap it in `TStringBuf`, if you want the "by the book; 100% right" solution then wrap it in `TRuntimeFormat` instead.
`SetRequestInfo` methods now statically checks the format. Only one error was found -- hooray!
Some other internal stuff was added, a lot removed -- don't worry about it. You won't be able to see the difference
62050dfe8a9cedc1289f18e80397ff33a8e2ecdb
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
ref:ca7a95e8c9a9d780f96497136a152091d54e61b5
|
| | |
|
| | |
|
| | |
|
| | |
|
|
|
ref:cde9a383711a11544ce7e107a78147fb96cc4029
|