13,486 karma · joined Jun 1, 2016 (10y ago) · 4,896 submissions
comment 4y ago · link · parent
comment 4y ago · link · parent
Not always. Mutexes can be really fast (10-20ns), especially since they often optimistically spin, and Arc in Rust is (often) relatively low cost since you can hand out "free" refs without touching the atomic.
If removing the Arc/Mutex would require allocations the Arc/Mutex could easily be faster.
comment 4y ago · link · parent
These are synthetic benchmarks but it's quite significant in them.
From a different tweet:
> It's the total time for 32 threads each doing 10'000 lock+unlocks (on a 64C/128T threadripper). So, the numbers you quoted correspond to a lock+unlock operation going from 8.75ns to 2.45ns, under low contention.
> The numbers can vary a lot in different situations/hardware though.
comment 4y ago · link · parent
A single entity being capable of significant or total disruption of the network.
> As for privacy, the technology has come a long way in the last decade due to the development of Zero-Knowlege Proofs. I can share a few links if you are interested.
I am interested. I'm aware of some progress being made here theoretically, but I have not seen implementations (I do not follow closely at this point).
comment 4y ago · link · parent
> Centralized systems work great... until they don't.
There has yet to be a decentralized cryptocurrency. We can't even say things like "decentralized systems work great until they don't" because so far they don't exist, and what does has been less than "great".
> Our grandchildren will wonder why we allowed the free world to export the means of surveillance to the third world.
I don't even know what you're going for here? Crypto solves surveillance now? The global, distributed ledger that everyone can fundamentally access because that's the whole point?
comment 4y ago · link · parent
And as the article points out, the cache is in fact lower latency and does improve latency for a single request. The issue is with throttling.
The article is absolutely not suggesting disabling caching, nor does any information in the article indicate that that would be a good idea. Even with the issue pointed out by the article the cache is still lower latency for the majority of requests.
comment 4y ago · link · parent
inotify has a number of other relevant limitations, like not being able to create recursive notifications or handle "move" operations. Implementation effort is going to be way higher for an inotify-based system, and of course that's made far worse by the numerous file systems in linux - I imagine any implementation would probably start first with ext4.
I suspect an ideal solution would be via ebpf, but I'm not sure.
comment 4y ago · link · parent
Seems like a huge pain to think about tbh. Seems like part of the problem would be solved by compiling everything into a single file that supported streaming execution.
comment 4y ago · link · parent
> It is about "network" vs "the (usually antiquated) file-backed database your browser calls a cache."
It's actually nothing to do with the design of the cache itself as far as I can tell. If you finish reading the article you'll see that it's about a throttling behavior that interacts poorly with the common optimization advice for HTTP 1.1+, exposed by caching.
> The latter is kind of self-evident: the browser cache is there to save bandwidth, not to be faster.
I don't think that's something you can just state definitively. I suspect most people do in fact view the cache as an optimization for latency. Especially since right at the start of the article, the first sentence, the "race the cache" optimization is introduced - an optimization that is clearly for latency and not bandwidth purposes.
comment 4y ago · link · parent
https://docs.google.com/document/d/1Aa7OKFRdtmn4IFzgHYfqeqk5...
comment 4y ago · link · parent
Yes that is the subject of this post.
https://simonhearne.com/2020/network-faster-than-cache/#the-...
comment 4y ago · link · parent
> It turns out that Chrome actively throttles requests, including those to cached resources, to reduce I/O contention. This generally improves performance, but will mean that pages with a large number of cached resources will see a slower retrieval time for each resource.
comment 4y ago · link · parent
comment 4y ago · link · parent
You have the same restrictions in C++ except with worse consequences.