Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
chjj
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
14 ms
·
91.
▲
by
chjj
5y ago
Do you mind elaborating? I obsess over clean code, so any criticism is appreciated.
92.
▲
by
chjj
5y ago
Yeah, I'm embarrassed about that. It's way behind on tests. The past 2 months of limited sleep were a massive scramble just trying to get everything implemented and trying to get the damn thing to sync properly. Things seem to wor
93.
▲
Show HN: Mako – a full Bitcoin implementation in C
(github.com)
239 points
by
chjj
5y ago
|
124 comments
94.
▲
by
chjj
5y ago
DMR on `restrict` (originally proposed for C89 as `noalias`): http://port70.net/~nsz/c/c89/dmr-on-noalias.html
95.
▲
by
chjj
6y ago
The 2-by-1 and 3-by-2 division functions described in the paper result in a very measurable speedup in my code. I think you're confusing those with the reciprocal calculation itself (which can be computed with a lookup table). I agree
96.
▲
by
chjj
6y ago
I'd encourage people to also read Niels Möller and Torbjörn Granlund's division paper: https://gmplib.org/~tege/division-paper.pdf It offers a modification to Knuth's algorithm D which avoids all hardwar
97.
▲
by
chjj
6y ago
DMCA takedowns are filed under penalty of perjury: "Under penalty of perjury, we submit that the RIAA is authorized to act on behalf of its member companies on matters involving the infringement of their sound recordings, audiovisual w
98.
▲
by
chjj
6y ago
After some googling, I managed to find the public key corresponding to that selector in a github repo: https://github.com/PaloAltoNetworks/aws-elb-autoscaling/blob... edit: Seems to be an old test vector for dnsli
99.
▲
by
chjj
6y ago
Oh, that's interesting. I think the main thing that turned me away from more typical persistent data structures was my assumption that the proof size would be unacceptably large (also that branch rewrites during insertion would cause t
100.
▲
by
chjj
6y ago
Very cool. I haven't seen a very many implementations of the SMT aside from Google's. The SMT was one of my original considerations, but I found my proof-of-concept implementation required far too much hashing for insertions. It r
101.
▲
Urkel – authenticated key-value store written in C
(github.com)
114 points
by
chjj
6y ago
|
14 comments
102.
▲
by
chjj
6y ago
I agree it still is signficant, but this is not how wasm is being touted. Look at wikipedia: https://en.wikipedia.org/wiki/WebAssembly#History They even say asm.js is supposed to be "near-native code execution spe
103.
▲
by
chjj
6y ago
Yeah, hashing in WASM seems to be fine in terms of speed, though 60x faster does still sound surprising to me. Hashes with 32 bit words (e.g. sha256) can be optimized fairly well in javascript due to the SMI optimization in engines like v8.
104.
▲
by
chjj
6y ago
No, but I've been meaning to test this. I did notice it was available in node.js with --experimental-wasm-simd. I hope this proves me wrong about wasm, but I'll have to try it.
105.
▲
by
chjj
6y ago
No. I've just been building with the WASI SDK and running the resulting binary with a small node.js wrapper script. So, I've only tested v8's WASM implementation so far. Does firefox have a headless mode, a standalone impleme
106.
▲
by
chjj
6y ago
> webassembly is faster than javascript Everyone says this, but I would dispute it as misleading in a lot of cases. I've been experimenting a lot with wasm lately. Yes, it is faster than javascript, but not by all that much. It'
107.
▲
by
chjj
10y ago
More specifically, it chooses by cumulative work. Bitcoin needs that behavior because of retargetting (a lesser height chain may have required more proof of work to build than a higher height one). If your custom blockchain has a static tar
108.
▲
by
chjj
10y ago
I love stuff like this. Some source code was shipped with the Ultima Online Demo in 1998. It was encrypted, but a few private UO server hackers cracked it and reverse engineered their internal scripting language. Really interesting stuff:
109.
▲
by
chjj
10y ago
> When I ssh to my servers, it uses ChaCha20 by default. OpenSSH, when using ChaCha20, also uses Poly1305 (also designed by djb) as its MAC for the AEAD. Also, some good news: ChaCha20+Poly1305 will soon be the default cipher+mac for the
110.
▲
by
chjj
10y ago
You're not the devil's advocate here. I remember talking about EME on here before and when it was being spec'd. The general attitude was, "I hate DRM! ...but then again, I DO like netflix!" It was pathetic to watch
111.
▲
by
chjj
10y ago
The project itself an alternative bitcoin full node, one of the few (along with btcd, bitcoinj, etc), and the only one that runs in the browser: http://bcoin.io/browser.html . I've posted it here before but no one seeme
112.
▲
by
chjj
10y ago
It's possible, but it was a very simple database layout. Pretty hard to screw up. Then again, I screw up simple things all the time. But whatever I screwed up would likely have been duplicated on the postgres side since the sqlite and
113.
▲
by
chjj
10y ago
I'll clarify here: these weren't very scientific benchmarks, as I alluded to. So, don't take my word for it. I didn't measure ops per second, I didn't take into account system load or cpu usage, etc. This is all ane
114.
▲
by
chjj
10y ago
Premature optimization is evil, but preemptive optimization is necessary unless you want to paint yourself into a corner. I realized this after implementing a bitcoin full node. In my bitcoin implementation, as an experiment, I tried stor
115.
▲
Show HN: A Bitcoin full node in your browser
(bcoin.io)
6 points
by
chjj
10y ago
|
0 comments
116.
▲
by
chjj
10y ago
I like the old getters better (__defineGetter__).
117.
▲
by
chjj
10y ago
> is that the real Satoshi has not put out a statement calling this guy out as a fraud And what about the inverse? If he is Satoshi, why didn't he just put out a signed statement saying he is Craig? Satoshi seemed perfectly capabl
118.
▲
by
chjj
10y ago
That piece of code likely gathers all the key recovery candidates it can from the signature, hashes and tests each one against the hash in the address to find the correct key. Then it performs the verification. Obviously the verification wo
119.
▲
by
chjj
10y ago
Yes. Satoshi wouldn't publish bullshit evidence of him being Satoshi.
120.
▲
by
chjj
10y ago
This is absolutely fake and already debunked, as mentioned on the bitcointalk forums: https://bitcointalk.org/index.php?topic=1457039.msg14728531#... The signature Wright posted is a signature from a transaction on the bloc
More ›