Better HN
topnewbestaskshowjobs
Log inSign up

sbahra

331 karma · joined Jan 29, 2011 (15y ago) · 112 submissions

[ my public key: https://keybase.io/sbahra; my proof: https://keybase.io/sbahra/sigs/SLZoPS63iUZ33agKdi_4d0zHk1KhYRjk-OAVke4o4uA ]
Submissions

1.

Squeezing Performance Out of eBPF(bitbison.io ↗)

6 points · by sbahra · 2mo ago · discuss

2.

Shai-Hulud rebuilt as a standalone stealer(bitbison.io ↗)

3 points · by sbahra · 3mo ago · discuss

comment 5y ago · link · parent

Also up on https://engineering.backtrace.io/2021-01-11-stuff-your-logs/

4.

New Method of Electrical Production That Does Not Require Fossil Fuels(prnewswire.com ↗)

1 points · by sbahra · 6y ago · 3 comments

5.

Umash: A fast and universal enough hash(engineering.backtrace.io ↗)

4 points · by sbahra · 6y ago · discuss

6.

Learning from Failures: Better Crash Reporting for Better Incident Response(circonus.com ↗)

3 points · by sbahra · 6y ago · discuss

comment 6y ago · link · parent

Thanks for sharing!

For single-writer multi-reader scenario this requires no atomic fences or operations on TSO: http://concurrencykit.org/presentations/lpc2015.pdf

Works on any open-addressed scheme (there is also a robin hood implementation).

8.

Public virtual event about systems and low-level topics this Thursday(adhoc.community ↗)

1 points · by sbahra · 6y ago · discuss

9.

Test case generation for native applications from Python with branch coverage(engineering.backtrace.io ↗)

2 points · by sbahra · 6y ago · discuss

10.

Google's Internal TCMalloc is now open-source(github.com ↗)

3 points · by sbahra · 6y ago · discuss

comment 7y ago · link · parent

overthewire.org

comment 7y ago · link · parent

Give us a spin! Would absolutely love more feedback, it has had a big impact for us already. It’s free for open-source projects.

The tool for ASAN/etc... is just a few weeks old but we have been doing crash / error reporting and custom debuggers (built-in static analysis) for the last 5 years.

Welcome to also shoot me a mail at sbahra@backtrace.io.

13.

Our Workflows with Address Sanitizer and Valgrind(engineering.backtrace.io ↗)

4 points · by sbahra · 7y ago · 2 comments

14.

Compile Once, Debug Twice: Picking a Compiler for Debbugability(backtrace.io ↗)

2 points · by sbahra · 7y ago · discuss

15.

Concurrency Kit: An open-source library for modern concurrent software(concurrencykit.org ↗)

1 points · by sbahra · 8y ago · discuss

16.

A Pragmatic Introduction to Multicore Synchronization [Talk](youtube.com ↗)

2 points · by sbahra · 8y ago · discuss

17.

The Stale Pointer(backtrace.io ↗)

12 points · by sbahra · 8y ago · 2 comments

18.

Analzying Heap Corruption in the Post-Mortem(backtrace.io ↗)

1 points · by sbahra · 8y ago · discuss

19.

Parallel Sections: Scaling System-Level Data-Structures [pdf](pdfs.semanticscholar.org ↗)

2 points · by sbahra · 8y ago · discuss

comment 9y ago · link · parent

Whoops, good catch! I will fix, thanks.

21.

Debug Information Is Huge and What to Do About It(documentation.backtrace.io ↗)

76 points · by sbahra · 9y ago · 20 comments

22.

CPPCon: Optimizations and Debug Quality [pdf](schd.ws ↗)

1 points · by sbahra · 9y ago · discuss

comment 9y ago · link · parent

I'm referring to the FIFO implementation. On the definition of QSBR though, frankly, I think the term gets overloaded in some of the more recent literature in this area. Both EBR and QSBR require that no hazardous references get carried over across "protected sections" (EBR is explicit read-side protected sections and in QSBR, across a quiescent point).

comment 9y ago · link · parent

Great write-up! A few notes worth mentioning (IMO) below:

Garbage collection: This is only true in absence of garbage collection. If you're paying garbage collection cost to begin with, this is not an issue. Also, note things such as http://web.mit.edu/willtor/www/res/threadscan-spaa-15.pdf

This only applies to dynamic lock-free data structures: Or, data structures requiring memory allocation. If you're using bounded buffers and don't require memory allocation, this isn't an issue.

Taxonomy: Not all passive schemes are quiescent-state-based. In QSBR, quiescent points are a first-class entity while that is not the case in EBR (you have only 3 distinct states). Absent extensions you are unable to differentiate one quiescent point from another, which has real implications on being able to implement things like deferred / non-blocking reclamation efficiently. There are some advantages to this, a while ago Paul Khuong contributed a reference counting scheme to epoch reclamation allowing for overlapping protected sections (bounded epoch makes reference counting practical, something you can't do with unbounded quiescent points). It's pretty great and note, it doesn't require a strict notion of quiescence! You'll find this in Concurrency Kit.

It is also worth noting the HP, etc... (pointer-based schemes) can be used to implement QSBR.

For these reasons, I prefer to classify these techniques into two primary families (based on the semantics of the interface rather than the implementation): "passive schemes" and "active schemes". Passive schemes do not require cooperation from the algorithms requiring safe memory reclamation (EBR, QSBR, etc...) while "active schemes" do (HP, PTB, etc... in their textbook form require modification to the algorithm).

On blocking for passive schemes: It is worth noting that QSBR, EBR and other "passive schemes" do have "non-blocking" (informally) interfaces (rcu_call, text-book EBR utilizes limbo lists, etc...) such that writers do not have to block on the fast path, but of course, there is the cost of memory accumulating until a grace period is detected (so, not non-blocking in the formal sense but if you've the memory to spare and sufficient forward progress, becomes a non-issue). In my implementations, I typically use a dedicated thread for forward progress / epoch detection, ensuring the writer has forward progress.

You have much higher granularity and the lock-free progress guarantee in hazard pointers, because it is pointer-based (tied to the forward progress guarantees of the underlying algorithm).

Under-appreciated recent development: An interesting thing to note here is there are schemes such as https://www2.seas.gwu.edu/~seotest/publications/eurosys16ps.... which do not necessitate the same heavy-weight barriers in the presence of invariant TSC+TSO and with a sufficiently high granularity TSC, can provide the same forward progress guarantees as hazard pointers.

On hazard pointers being slow: One interesting thing to note is hazard pointers can also be used to implement "passive" schemes such as proxy collection, to give similar performance properties as EBR and QSBR.

On real world implementations: It is worth mentioning http://concurrencykit.org :-P

comment 9y ago · link · parent

This is quiescent-state-based reclamation, other implementations exist that are cheap. I have seen the technique you're talking about used in K42 (after I had also thought I invented something novel, when I used the same approach as you :-P).

26.

Comparing the Bias in Telemetry Data vs. The Typical Firefox User(blog.mozilla.org ↗)

1 points · by sbahra · 9y ago · discuss

27.

Optimizations and their impact on Debuggers(backtrace.io ↗)

2 points · by sbahra · 9y ago · discuss

1234