Mehdi Akiki

Posts tagged "rust"

  • Published on

    Investigation · Part 11 of 20 · What survives a crash

    Recovery Code Must Survive a Crash Too

    A recovery that writes files can crash too, and then a second recovery must give the same result. I killed my store 500 times during its own recovery: one design always recovered correctly, the other doubled a counter 53 times. The fix is one number in the snapshot.
  • Published on

    Investigation · Part 10 of 20 · When the benchmark lies

    Which Clock to Use When You Measure Time

    I measured eight of the clocks that clock_gettime can read, and on my laptop two of them disagreed by 43,257 ns after 20 seconds. I measured their resolution, their cost, which ones enter the kernel, and which clocks Rust and Python use.
  • Published on

    Investigation · Part 10 of 20 · From source to a running process

    The Code That Runs Before main: _start, Constructors and init_array

    With gdb I followed what calls main, where constructors are called from, and in which order init_array and fini_array run. A program without libc starts in 56 microseconds instead of 143, and Rust std has its own function in init_array.
  • Published on
    A prefilter can skip most automaton work, but it is heuristic rather than free. I show how candidate frequency and pattern shape decide whether it helps a Rust search.