Skip to content

Conversation

@indietyp
Copy link
Member

@indietyp indietyp commented Feb 2, 2026

🌟 What is the purpose of this PR?

Reworks the HashQL symbol infrastructure to be faster and smaller by using a tagged pointer representation that distinguishes between compile-time constant symbols and runtime-interned symbols.

🔍 What does this change?

  • Introduces Repr, a tagged pointer representation for symbols:
    • Constant symbols: Index encoded in pointer bits, pointing into static SYMBOLS array ('static lifetime)
    • Runtime symbols: Pointer to bump-allocated RuntimeRepr with inline length + string data
  • Reworks SymbolTable from a generic ID→Symbol mapping to a string-interning hash table
  • Adds ConstantSymbol type for compile-time pattern matching against predefined symbols
  • Rewrites symbols! macro to generate:
    • SYMBOLS: Static slice for interner pre-population
    • Symbol constants with companion modules containing CONST: ConstantSymbol
    • LOOKUP: String→Repr mapping for fast runtime lookup
  • Adds SymbolLookup type for O(1) constant symbol detection during interning
  • Adds comprehensive benchmarks for symbol interning and lookup operations
  • Updates all symbol usages across HIR, MIR, and eval crates

Pre-Merge Checklist 🚀

🚢 Has this modified a publishable library?

This PR:

  • does not modify any publishable blocks or libraries, or modifications do not need publishing

📜 Does this require a change to the docs?

The changes in this PR:

  • are internal and do not require a docs change

🕸️ Does this require a change to the Turbo Graph?

The changes in this PR:

  • do not affect the execution graph

⚠️ Known issues

None.

🛡 What tests cover this?

  • Unit tests in symbol/repr.rs, symbol/table.rs, symbol/sym.rs
  • Existing HIR/MIR tests exercise the updated symbol infrastructure

❓ How to test this?

  1. cargo nextest run --package hashql-core
  2. cargo bench --package hashql-core -- symbol to verify performance

📊 Benchmarks

Operation Improvement
Intern unique -12–30% (-34% with local lock)
Intern repeated +2–4% (-32% with local lock)
Mixed workload within noise
Constant access -40%
Equality (constant + runtime) -20%
Hashing (constant + runtime) -50%
Constant as_str +100%
Runtime as_str +40%
Type checker simulation -64%

Type system benchmarks: -10–0% speedup

@vercel
Copy link

vercel bot commented Feb 2, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
hash Building Building Preview, Comment Feb 2, 2026 4:36pm
3 Skipped Deployments
Project Deployment Actions Updated (UTC)
hashdotdesign Ignored Ignored Preview Feb 2, 2026 4:36pm
hashdotdesign-tokens Ignored Ignored Preview Feb 2, 2026 4:36pm
petrinaut Skipped Skipped Feb 2, 2026 4:36pm

@cursor
Copy link

cursor bot commented Feb 2, 2026

PR Summary

High Risk
Touches core symbol representation and interning/reset invariants used across multiple compiler stages; subtle lifetime/reset-order or constant-lookup bugs could cause widespread correctness issues or UB in unsafe code paths.

Overview
Reworks hashql-core symbol infrastructure: Symbol is now a single-word tagged-pointer (Repr) that can represent either predefined constant symbols (index into a static table) or runtime-interned symbols (bump-allocated RuntimeRepr), plus a new ConstantSymbol for const pattern matching via Symbol::as_constant().

Replaces the old SymbolTable (ID→symbol mapping) with a hash-based string interner (SymbolTable in symbol/table.rs) and introduces SymbolLookup (new symbol/lookup.rs) for ID→symbol mappings; Heap now owns a LocalLock<SymbolTable> and resets/prime logic is updated to reset the symbol table before arena reset.

Updates symbol definitions and call sites: rewrites the symbols! macro in symbol/sym.rs to generate SYMBOLS/LOOKUP plus CONST modules, renames many symbol constants (e.g., assigneq, andampamp, orpipepipe, neexcleq), and migrates usages across AST/HIR/MIR/eval to use new paths and constant matching.

Adds extensive unit tests for the new repr/table behavior, adjusts literal APIs to take self by value for cheaper access, and introduces a new hashql-core benchmark suite (benches/symbol.rs) plus updates Miri/bench configuration.

Written by Cursor Bugbot for commit 1068059. This will update automatically on new commits. Configure here.

Copy link
Member Author

indietyp commented Feb 2, 2026

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

@codecov
Copy link

codecov bot commented Feb 2, 2026

Codecov Report

❌ Patch coverage is 89.66725% with 59 lines in your changes missing coverage. Please review.
✅ Project coverage is 75.00%. Comparing base (864f436) to head (1068059).

Files with missing lines Patch % Lines
libs/@local/hashql/core/src/heap/mod.rs 34.61% 17 Missing ⚠️
libs/@local/hashql/core/src/symbol/mod.rs 82.50% 14 Missing ⚠️
libs/@local/hashql/eval/src/graph/read/path.rs 33.33% 12 Missing ⚠️
libs/@local/hashql/core/src/symbol/lookup.rs 85.00% 6 Missing ⚠️
libs/@local/hashql/core/src/symbol/repr.rs 96.77% 4 Missing and 1 partial ⚠️
libs/@local/hashql/core/src/symbol/table.rs 98.95% 2 Missing ⚠️
libs/@local/hashql/hir/src/node/operation/unary.rs 0.00% 2 Missing ⚠️
libs/@local/hashql/hir/src/pretty.rs 92.85% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@                           Coverage Diff                            @@
##           bm/be-360-hashql-rework-compiletest    #8343       +/-   ##
========================================================================
- Coverage                                90.04%   75.00%   -15.04%     
========================================================================
  Files                                       37      233      +196     
  Lines                                     6709    35772    +29063     
  Branches                                   137      851      +714     
========================================================================
+ Hits                                      6041    26831    +20790     
- Misses                                     601     8651     +8050     
- Partials                                    67      290      +223     
Flag Coverage Δ
rust.harpc-net ?
rust.hash-graph-api 2.88% <ø> (?)
rust.hash-graph-types ?
rust.hashql-core 81.53% <91.66%> (?)
rust.hashql-eval 69.13% <33.33%> (?)
rust.hashql-hir 89.11% <88.00%> (?)
rust.hashql-syntax-jexpr 94.05% <ø> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@codspeed-hq
Copy link

codspeed-hq bot commented Feb 2, 2026

Merging this PR will improve performance by 15.93%

⚡ 3 improved benchmarks
✅ 18 untouched benchmarks
🆕 20 new benchmarks
🗄️ 12 archived benchmarks run1

Performance Changes

Benchmark BASE HEAD Efficiency
diamond 12.4 µs 10.7 µs +15.93%
linear 7.7 µs 7 µs +10.23%
complex 18.3 µs 16.2 µs +13.47%
🆕 as_constant N/A < 1 ns N/A
🆕 access N/A < 1 ns N/A
🆕 constant_equal N/A < 1 ns N/A
🆕 constant_not_equal N/A < 1 ns N/A
🆕 pattern_match_constant N/A 121.7 ns N/A
🆕 runtime_not_equal N/A < 1 ns N/A
🆕 constant N/A 29.7 ns N/A
🆕 repeated[100] N/A 231.9 µs N/A
🆕 repeated[1000] N/A 2.3 ms N/A
🆕 repeated[10000] N/A 22.1 ms N/A
🆕 runtime N/A 29.7 ns N/A
🆕 unique[1000] N/A 119.3 µs N/A
🆕 unique[100] N/A 20.1 µs N/A
🆕 type_checker_simulation N/A 480.8 ns N/A
🆕 runtime_equal N/A < 1 ns N/A
🆕 runtime N/A 375.6 ns N/A
🆕 constant N/A 404.7 ns N/A
... ... ... ... ...

ℹ️ Only the first 20 benchmarks are displayed. Go to the app to view all benchmarks.


Comparing bm/be-364-hashql-rework-symbol-to-be-faster-and-smaller (1068059) with bm/be-360-hashql-rework-compiletest (864f436)

Open in CodSpeed

Footnotes

  1. 12 benchmarks were run, but are now archived. If they were deleted in another branch, consider rebasing to remove them from the report. Instead if they were added back, click here to restore them.

@augmentcode
Copy link

augmentcode bot commented Feb 2, 2026

🤖 Augment PR Summary

Summary: Reworks HashQL symbol infrastructure to a compact tagged-pointer representation, improving speed and memory footprint while enabling efficient matching against predefined symbols.

Changes:

  • Introduces `Repr` (tagged pointer) for symbols: constants encode an index into a static table; runtime symbols point to bump-allocated `RuntimeRepr` with inline bytes.
  • Replaces heap string storage with a dedicated `SymbolTable` string interner that is primed from generated `sym::LOOKUP` entries.
  • Adds `ConstantSymbol` plus `Symbol::as_constant()` to support const-pattern matching via `sym::NAME::CONST`.
  • Rewrites the `symbols!` macro to generate `SYMBOLS`, symbol constants, and a runtime lookup table; adds a uniqueness test for predefined strings.
  • Adds `SymbolLookup` (dense/gapped/sparse) for ID→Symbol mappings and updates HIR to use it.
  • Updates symbol usages across AST/HIR/MIR/eval (including operator and path symbol renames) to work with the new representation.
  • Adds a `symbol` benchmark suite and wires it into Cargo/package scripts (including Miri coverage).

🤖 Was this summary useful? React with 👍 or 👎

Copy link

@augmentcode augmentcode bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review completed. 3 suggestions posted.

Fix All in Augment

Comment augment review to trigger a new review at any time.

@github-actions
Copy link
Contributor

github-actions bot commented Feb 2, 2026

Benchmark results

@rust/hash-graph-benches – Integrations

policy_resolution_large

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 2002 $$27.8 \mathrm{ms} \pm 175 \mathrm{μs}\left({\color{red}6.00 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$3.30 \mathrm{ms} \pm 14.3 \mathrm{μs}\left({\color{gray}3.02 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 1001 $$13.7 \mathrm{ms} \pm 90.1 \mathrm{μs}\left({\color{red}16.2 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: high, policies: 3314 $$44.7 \mathrm{ms} \pm 295 \mathrm{μs}\left({\color{red}6.24 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: low, policies: 1 $$15.2 \mathrm{ms} \pm 94.7 \mathrm{μs}\left({\color{red}11.4 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: medium, policies: 1526 $$25.1 \mathrm{ms} \pm 151 \mathrm{μs}\left({\color{red}9.57 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 2078 $$45.1 \mathrm{ms} \pm 202 \mathrm{μs}\left({\color{red}5.79 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$21.8 \mathrm{ms} \pm 102 \mathrm{μs}\left({\color{red}10.0 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 1033 $$30.2 \mathrm{ms} \pm 163 \mathrm{μs}\left({\color{gray}0.141 \mathrm{\%}}\right) $$ Flame Graph

policy_resolution_medium

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 102 $$3.69 \mathrm{ms} \pm 22.1 \mathrm{μs}\left({\color{gray}1.89 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$2.91 \mathrm{ms} \pm 18.3 \mathrm{μs}\left({\color{gray}2.94 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 51 $$3.29 \mathrm{ms} \pm 18.8 \mathrm{μs}\left({\color{gray}1.18 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: high, policies: 269 $$5.01 \mathrm{ms} \pm 31.0 \mathrm{μs}\left({\color{gray}0.887 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: low, policies: 1 $$3.55 \mathrm{ms} \pm 17.5 \mathrm{μs}\left({\color{red}5.64 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: medium, policies: 107 $$4.04 \mathrm{ms} \pm 26.9 \mathrm{μs}\left({\color{gray}2.88 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 133 $$4.03 \mathrm{ms} \pm 33.5 \mathrm{μs}\left({\color{gray}0.587 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$3.26 \mathrm{ms} \pm 16.0 \mathrm{μs}\left({\color{gray}0.413 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 63 $$3.99 \mathrm{ms} \pm 30.0 \mathrm{μs}\left({\color{gray}3.50 \mathrm{\%}}\right) $$ Flame Graph

policy_resolution_none

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 2 $$2.40 \mathrm{ms} \pm 12.7 \mathrm{μs}\left({\color{gray}1.08 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$2.34 \mathrm{ms} \pm 11.5 \mathrm{μs}\left({\color{gray}0.433 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 1 $$2.45 \mathrm{ms} \pm 11.9 \mathrm{μs}\left({\color{gray}0.869 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 8 $$2.68 \mathrm{ms} \pm 12.5 \mathrm{μs}\left({\color{gray}1.39 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$2.60 \mathrm{ms} \pm 19.2 \mathrm{μs}\left({\color{gray}3.94 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 3 $$2.77 \mathrm{ms} \pm 18.6 \mathrm{μs}\left({\color{gray}2.41 \mathrm{\%}}\right) $$ Flame Graph

policy_resolution_small

Function Value Mean Flame graphs
resolve_policies_for_actor user: empty, selectivity: high, policies: 52 $$2.85 \mathrm{ms} \pm 17.4 \mathrm{μs}\left({\color{gray}3.87 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: low, policies: 1 $$2.48 \mathrm{ms} \pm 8.95 \mathrm{μs}\left({\color{gray}2.32 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: empty, selectivity: medium, policies: 25 $$2.64 \mathrm{ms} \pm 10.5 \mathrm{μs}\left({\color{gray}1.22 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: high, policies: 94 $$3.22 \mathrm{ms} \pm 20.5 \mathrm{μs}\left({\color{gray}4.17 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: low, policies: 1 $$2.77 \mathrm{ms} \pm 15.1 \mathrm{μs}\left({\color{red}5.42 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: seeded, selectivity: medium, policies: 26 $$2.97 \mathrm{ms} \pm 20.9 \mathrm{μs}\left({\color{gray}3.61 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: high, policies: 66 $$3.11 \mathrm{ms} \pm 15.2 \mathrm{μs}\left({\color{gray}4.34 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: low, policies: 1 $$2.70 \mathrm{ms} \pm 14.4 \mathrm{μs}\left({\color{gray}2.46 \mathrm{\%}}\right) $$ Flame Graph
resolve_policies_for_actor user: system, selectivity: medium, policies: 29 $$2.94 \mathrm{ms} \pm 17.2 \mathrm{μs}\left({\color{gray}2.38 \mathrm{\%}}\right) $$ Flame Graph

read_scaling_complete

Function Value Mean Flame graphs
entity_by_id;one_depth 1 entities $$40.6 \mathrm{ms} \pm 181 \mathrm{μs}\left({\color{red}5.53 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 10 entities $$79.5 \mathrm{ms} \pm 404 \mathrm{μs}\left({\color{gray}4.67 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 25 entities $$45.0 \mathrm{ms} \pm 220 \mathrm{μs}\left({\color{gray}3.80 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 5 entities $$47.7 \mathrm{ms} \pm 201 \mathrm{μs}\left({\color{gray}4.97 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;one_depth 50 entities $$56.0 \mathrm{ms} \pm 272 \mathrm{μs}\left({\color{red}5.82 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 1 entities $$42.7 \mathrm{ms} \pm 217 \mathrm{μs}\left({\color{red}6.48 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 10 entities $$426 \mathrm{ms} \pm 1.08 \mathrm{ms}\left({\color{gray}2.23 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 25 entities $$99.0 \mathrm{ms} \pm 474 \mathrm{μs}\left({\color{red}11.8 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 5 entities $$86.6 \mathrm{ms} \pm 396 \mathrm{μs}\left({\color{gray}3.58 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;two_depth 50 entities $$291 \mathrm{ms} \pm 859 \mathrm{μs}\left({\color{gray}3.20 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 1 entities $$15.9 \mathrm{ms} \pm 108 \mathrm{μs}\left({\color{red}10.3 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 10 entities $$16.0 \mathrm{ms} \pm 84.4 \mathrm{μs}\left({\color{red}9.34 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 25 entities $$16.0 \mathrm{ms} \pm 77.8 \mathrm{μs}\left({\color{red}7.08 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 5 entities $$16.0 \mathrm{ms} \pm 78.4 \mathrm{μs}\left({\color{red}9.67 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id;zero_depth 50 entities $$19.1 \mathrm{ms} \pm 132 \mathrm{μs}\left({\color{red}7.67 \mathrm{\%}}\right) $$ Flame Graph

read_scaling_linkless

Function Value Mean Flame graphs
entity_by_id 1 entities $$15.8 \mathrm{ms} \pm 79.2 \mathrm{μs}\left({\color{red}9.12 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 10 entities $$15.6 \mathrm{ms} \pm 72.2 \mathrm{μs}\left({\color{red}6.95 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 100 entities $$15.7 \mathrm{ms} \pm 72.8 \mathrm{μs}\left({\color{red}8.35 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 1000 entities $$16.8 \mathrm{ms} \pm 111 \mathrm{μs}\left({\color{red}10.4 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id 10000 entities $$24.1 \mathrm{ms} \pm 171 \mathrm{μs}\left({\color{red}9.10 \mathrm{\%}}\right) $$ Flame Graph

representative_read_entity

Function Value Mean Flame graphs
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/block/v/1 $$30.5 \mathrm{ms} \pm 286 \mathrm{μs}\left({\color{gray}0.531 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/book/v/1 $$31.8 \mathrm{ms} \pm 310 \mathrm{μs}\left({\color{gray}4.01 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/building/v/1 $$31.7 \mathrm{ms} \pm 279 \mathrm{μs}\left({\color{red}7.16 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/organization/v/1 $$31.3 \mathrm{ms} \pm 269 \mathrm{μs}\left({\color{red}5.95 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/page/v/2 $$31.0 \mathrm{ms} \pm 329 \mathrm{μs}\left({\color{gray}3.15 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/person/v/1 $$30.0 \mathrm{ms} \pm 318 \mathrm{μs}\left({\color{gray}-1.542 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/playlist/v/1 $$32.4 \mathrm{ms} \pm 336 \mathrm{μs}\left({\color{red}9.36 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/song/v/1 $$29.6 \mathrm{ms} \pm 301 \mathrm{μs}\left({\color{gray}-4.645 \mathrm{\%}}\right) $$ Flame Graph
entity_by_id entity type ID: https://blockprotocol.org/@alice/types/entity-type/uk-address/v/1 $$32.0 \mathrm{ms} \pm 330 \mathrm{μs}\left({\color{red}6.00 \mathrm{\%}}\right) $$ Flame Graph

representative_read_entity_type

Function Value Mean Flame graphs
get_entity_type_by_id Account ID: bf5a9ef5-dc3b-43cf-a291-6210c0321eba $$8.33 \mathrm{ms} \pm 47.5 \mathrm{μs}\left({\color{gray}1.60 \mathrm{\%}}\right) $$ Flame Graph

representative_read_multiple_entities

Function Value Mean Flame graphs
entity_by_property traversal_paths=0 0 $$46.8 \mathrm{ms} \pm 316 \mathrm{μs}\left({\color{gray}-0.224 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=255 1,resolve_depths=inherit:1;values:255;properties:255;links:127;link_dests:126;type:true $$95.5 \mathrm{ms} \pm 462 \mathrm{μs}\left({\color{gray}1.87 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:0;link_dests:0;type:false $$55.2 \mathrm{ms} \pm 356 \mathrm{μs}\left({\color{red}6.95 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:1;link_dests:0;type:true $$62.3 \mathrm{ms} \pm 400 \mathrm{μs}\left({\color{gray}2.92 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:2;links:1;link_dests:0;type:true $$69.3 \mathrm{ms} \pm 350 \mathrm{μs}\left({\color{gray}0.912 \mathrm{\%}}\right) $$
entity_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:2;properties:2;links:1;link_dests:0;type:true $$75.8 \mathrm{ms} \pm 405 \mathrm{μs}\left({\color{gray}1.51 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=0 0 $$50.3 \mathrm{ms} \pm 284 \mathrm{μs}\left({\color{gray}2.42 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=255 1,resolve_depths=inherit:1;values:255;properties:255;links:127;link_dests:126;type:true $$78.0 \mathrm{ms} \pm 447 \mathrm{μs}\left({\color{gray}-1.559 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:0;link_dests:0;type:false $$58.6 \mathrm{ms} \pm 530 \mathrm{μs}\left({\color{red}5.20 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:0;links:1;link_dests:0;type:true $$63.9 \mathrm{ms} \pm 347 \mathrm{μs}\left({\color{gray}1.19 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:0;properties:2;links:1;link_dests:0;type:true $$67.5 \mathrm{ms} \pm 346 \mathrm{μs}\left({\color{gray}1.16 \mathrm{\%}}\right) $$
link_by_source_by_property traversal_paths=2 1,resolve_depths=inherit:0;values:2;properties:2;links:1;link_dests:0;type:true $$67.2 \mathrm{ms} \pm 375 \mathrm{μs}\left({\color{gray}0.987 \mathrm{\%}}\right) $$

scenarios

Function Value Mean Flame graphs
full_test query-limited $$130 \mathrm{ms} \pm 564 \mathrm{μs}\left({\color{gray}-3.660 \mathrm{\%}}\right) $$ Flame Graph
full_test query-unlimited $$130 \mathrm{ms} \pm 512 \mathrm{μs}\left({\color{gray}-3.067 \mathrm{\%}}\right) $$ Flame Graph
linked_queries query-limited $$84.7 \mathrm{ms} \pm 3.10 \mathrm{ms}\left({\color{lightgreen}-19.778 \mathrm{\%}}\right) $$ Flame Graph
linked_queries query-unlimited $$578 \mathrm{ms} \pm 1.46 \mathrm{ms}\left({\color{lightgreen}-5.538 \mathrm{\%}}\right) $$ Flame Graph

@indietyp indietyp force-pushed the bm/be-360-hashql-rework-compiletest branch from d7d7b06 to 864f436 Compare February 2, 2026 16:36
@indietyp indietyp force-pushed the bm/be-364-hashql-rework-symbol-to-be-faster-and-smaller branch from 237d423 to 1068059 Compare February 2, 2026 16:36
@vercel vercel bot temporarily deployed to Preview – petrinaut February 2, 2026 16:36 Inactive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/libs Relates to first-party libraries/crates/packages (area) type/eng > backend Owned by the @backend team

Development

Successfully merging this pull request may close these issues.

2 participants