UrbitGrants

Tune slaw/scot Jets

Grantee(s):
May 6, 2022

• ID:

B0137

Bounty
Core Dev

slaw/scot

We need to generally speed up common parsing and serialization operations. A large part of Urbit's UX is sending data in and out of Urbit for display in the UI, and the functions inside Urbit that handle this are all significant performance bottlenecks.

slaw parses strings to atoms, and scot serializes atoms to strings. They both are used heavily throughout the codebase.

Completing this bounty will have an immediate impact on the perceived speed of the system in frontends like Landscape.

Examples

slaw

> `(unit @p)`(slaw %p '~pillyt')
[~ ~pillyt]
> `(unit @p)`(slaw %p '~pillam')
~
> `(unit @ux)`(slaw %ux '0x12')
[~ 0x12]
> `(unit @ux)`(slaw %ux '0b10')

scot

> `@t`(scot %p ~pillyt)
'~pillyt'
> (scot %ux 0x12)
~.0x12

Code

Requirements

  • Knowledge of C
  • Experience memory profiling to prevent leaks
  • Hoon knowledge nice but not necessary

Resources

Milestone: Completion, 1 star

  • jet is implemented and passes all tests
  • Tlon engineer gives final approval on merging jet into core