Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use 0 for empty value #34

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open

Use 0 for empty value #34

wants to merge 5 commits into from

Commits on Jul 4, 2024

  1. Extract simd source to a submodule

    Avo documentation requires version to be pinned in order to be used in
    production, however there was no reference to avo in the modules here,
    so it's not possible to reproduce the build.
    
    This extracts avo source to a submodule, in order to prevent it from
    being downloaded as a transitive dependency when dolthub/swiss is
    required, and adds a go:generate directive to simplify the build
    process.
    
    Signed-off-by: Oleg Zaytsev <mail@olegzaytsev.com>
    colega committed Jul 4, 2024
    Configuration menu
    Copy the full SHA
    d217e89 View commit details
    Browse the repository at this point in the history
  2. h2 as uint8

    This doesn't change the logic, but by defining h2 as uint8, and using
    uint8 elsewhere, we can work properly with higher bits (and define empty
    in it's binary form, instead of having to use the negative value and a
    comment). This will also allow us future changes without having to play
    with overflows.
    
    Signed-off-by: Oleg Zaytsev <mail@olegzaytsev.com>
    colega committed Jul 4, 2024
    Configuration menu
    Copy the full SHA
    e8b76af View commit details
    Browse the repository at this point in the history
  3. Benchmark map instantiation and growing

    Signed-off-by: Oleg Zaytsev <mail@olegzaytsev.com>
    colega committed Jul 4, 2024
    Configuration menu
    Copy the full SHA
    8ccae17 View commit details
    Browse the repository at this point in the history
  4. Use 0 as empty metadata to allocate faster

    Current value has to be written for all metadata values when we're
    instantiating a new map or growing.
    
    This changes empty to be the zero byte, and tombstone to be byte 1, by
    adding 2 (h2Offset) to all hashes.
    
    Signed-off-by: Oleg Zaytsev <mail@olegzaytsev.com>
    colega committed Jul 4, 2024
    Configuration menu
    Copy the full SHA
    8098dea View commit details
    Browse the repository at this point in the history
  5. Generate a specific simd.MatchEmpty()

    Signed-off-by: Oleg Zaytsev <mail@olegzaytsev.com>
    colega committed Jul 4, 2024
    Configuration menu
    Copy the full SHA
    efda023 View commit details
    Browse the repository at this point in the history