Hacker News

Top stories

Live mirror
30 storiesupdated just nowView source snapshot
  1. OpenJev(openjev.com ↗)
    15comments
  2. Jemalloc 5.4.0(github.com/jemalloc ↗)
    45comments
  3. The scourge of x86 emulation(fex-emu.com ↗)
    27comments
  4. Astra for Law(openai.com ↗)
    578comments
  5. Bonsai 2 27B: Near-Lossless Compression in a 9x Smaller Footprint(prismml.com ↗)
    135comments
  6. Bend – A language that blocks AI mistakes via proof, on CPU and GPU(bend-lang.com ↗)
    222comments
  7. Qwen 3.8 Omni Flash(qwen.ai ↗)
    82comments
  8. Hister: A private search engine for the pages you visit and the files you keep(github.com/asciimoo ↗)
    170comments
  9. Replacing Pull Requests with Delta(zed.dev ↗)
    4comments
  10. Pre-Greek: The lost language hidden within Ancient Greek(linguisticdiscovery.com ↗)
    38comments
  11. Wax motor(wikipedia.org ↗)
    70comments
  12. Fujitsu launches made-in-Japan next-generation CPU FUJITSU-MONAKA(global.fujitsu ↗)
    234comments
  13. When the fractional part of a float fixes your shader(crocidb.com ↗)
    1comments
  14. Microsoft exec called AI scraping 'the largest theft of labor in human history'(techcrunch.com ↗)
    12comments
  15. A heap overflow and SSO misconfiguration to compromise OpenAI internal repos(hacktron.ai ↗)
    155comments
  16. Shapelearn Qwen 3.8 27B (13.1 GB VRAM)(byteshape.com ↗)
    11comments
  17. How to Write with an LLM(sockpuppet.org ↗)
    104comments
  18. Ask A Monk – A digital wilderness for thoughts with no immediate answer(askamonk.online ↗)
    24comments
  19. Flet 1.0 – Build cross-platform apps in Python(flet.dev ↗)
    59comments
  20. Telstra outage: The night a network decided the year was 2006(netnod.se ↗)
    27comments
  21. Why Does the Universe Expand?(cosmicave.org ↗)
    57comments
  22. Speeding up gearhash on ARM64(sam.dev ↗)
    discuss
  23. Diplodocus, Long Thought Exclusively American, Turns Up in Spain(sci.news ↗)
    42comments
  24. Why I didn’t sign the Fields medallists’ letter(gowers.wordpress.com ↗)
    370comments
  25. Apple detectives solved mystery of ancient tree and rewrote the history of fruit(scientificamerican.com ↗)
    12comments
  26. How do we prevent mathemathics from devolving into the Medieval Era of secrecy?(mathoverflow.net ↗)
    108comments
  27. The most important product decision is what you don't build(liamnugent.me ↗)
    39comments
  28. CrowdSec Source Code Leak(crowdsec.net ↗)
    49comments
  29. How Uber Protects Against Retry Storms(uber.com ↗)
    44comments
  30. Show HN: Snapdrop: Instantly share files between devices. No setup, no signup(snapdrop.me ↗)
    37comments

Rr records nondeterministic executions and debugs them deterministically

91 pointsby 11y agorr-project.org
9 comments
11y agoHN ↗

Wow. That's impressive. Only a factor of 1.2 slowdown for full capture of execution history on a program the size of Firefox. This could, if properly used, eliminate the closing of bug reports as "can't reproduce". It may mean sending in gigabytes of bug trace data, though.

11y agoHN ↗

This is awesome! Is it a drop-in replacement for gdb? The docs seem to suggest so but just wanted to know if there are any fine prints.

11y agoHN ↗

You use it with GDB, it wraps it and makes the execution under gdb deterministic, so you can set breakpoints earlier in your execution by going back to the start and replaying up to your breakpoint. This sounds a bit inefficient, but compared to reversible debugging it works quite well.

You should watch the videos

11y agoHN ↗

This is great - something I always wished I have as a tool.

I haven't found it explicitly, but this is Linux-only, right? And I guess porting to other platforms is not too trivial.

Btw., why is this not written in Rust?

I took a fast look at the code - very modern and nice C++11 code. And quite a few Linux dependencies (Linux headers + /proc usage).

11y agoHN ↗

record/playback tools are immensely useful for debugging.

For instance, with rr, you can easily playback the same run through valgrind to isolate complex memory issues that would be very hard to debug by looking just at the final state.

You can easily use rr -g and gdb to debug issues that couldn't be stepped back using gdb's (limited) reverse execution.

All of this in the same development environment and negligible impact. If that's not enough, with qemu+kvm+gdb you can push it even further, though at a higher speed penalty.

rr recently got amd64 support, and it's in debian as well.

In the same vein, for OpenGL there's vogl from Valve: https://github.com/ValveSoftware/vogl

(hint: if some debian maintainer is reading this, a package of vogl would also be nice!)

11y agoHN ↗

What other languages/frameworks have similar tools?

I wrote something like this for cgi-bin scripts in 1996. Problem: you don't necessarily see everything happening in the browser, especially someone else's, especially if they're remote (or unknown), and the only evidence might be a a line in the error log. "playback <script>" would create a wrapper script that saved all environment/server variables and POST data to a file (for later playback) and then call the original script. When run from the command line or debugger, a file containing the selected playback info would be "re-hydrated" into the proper settings, and then call the original script, and it would run as it had previously on the server.

There was a library to extend this to arbitrary data (within the framework). The idiom was something like (after some initial setup):

  if ( $PLAYBACK_MODE ) {
    $result1 = get_playback_value('result1');
  } else {
     $result1 = normal_function_call();
     save_playback_value('result1', $result1);
  }

Which is pretty much portable to any language. If your language supports it, maybe automagically wrap normal_function_call so the caller doesn't have to--if you want this for every call. Recording multiple values could be done by appending something to the identifier (e.g. "result1:$i"). Generally, too much data collected in tight loops (or every db request, etc.), but you could programmatically turn it on in certain cases, only save after an assertion has failed, etc.

Playback use can be great for debugging, somewhere in between unit tests and end-to-end testing, kind of like a mock for medium-level complexity. Decouple data, events, etc. from the context in which they occur ("the real world") for later examination in a more controlled environment. Helping make irreproducible results more produceable.