Hacker News new | ask | show | jobs
by seibelj 2661 days ago
A million CPUs would not be as efficient mining Bitcoin as a single ASIC. There are no coins where CPU mining is as good as GPU. JavaScript is also inefficient compared to native programs.

Overall, it probably didn't generate very much money. Mining is a commodity. An ad click is worth orders of magnitude more.

3 comments

I believe Coinhive was actually webassembly, with a fallback to JavaScript.
They were mining Monero, not Bitcoin.
CPU mining XMR is similarly not efficient compared to GPU
As Monero currently has ASICs running on the network no they're not.

But without them yes they are profitable especially if you're not paying for electricity as in this case.

I thought Monero was designed to be resistant to ASICs? Please correct me if I'm wrong, I don't have that much knowledge about crypto₹.
There is no such thing as ASIC-proof. You can make an ASIC for any deterministic algorithm.

"ASIC-resistance", in this context, only means that ASICs can be held to a low multiple of CPU/GPU efficiency. So ASICs can be 10x as efficient as a CPU/GPU, but not 10k-1m times as efficient like they can on something like SHA.

Unfortunately, profit trends towards zero (towards cost of production) until prices change, so having a 10x advantage is still actually quite big. That means you're making at least a small profit when everyone else is forced to turn off their rigs.

In practice this means that ASIC-resistance, as a method of decentralizing control of the network, doesn't work. Big farms pay cheaper rates for electricity (in China, sometimes zero, by stealing it or bribing local officials), and have insider access to much more efficient ASIC hardware than the general public does. So when profit declines to zero, they inherit the network by virtue of being the only miners who remain profitable.

There is no such thing as ASIC-proof. You can make an ASIC for any deterministic algorithm.

True. Although you could probably design an algorithm which requires so many of the capabilities of a CPU, like a fast 64-bit FPU and a lot of cache, that the transistor count of an ASIC would approach that of a general-purpose CPU produced in much greater volume. This would make special-purpose hardware not cost effective.

That's one of the goals yes.

However efficient ASICs were able to be constructed for the current (and previous) algorithms.

Monero will make a hardfork, right now actually, to brick the existing ASICs. The new algorithm isn't sufficiently different to prevent them however and we will probably see efficient ASICs in under 6 months.

The long term hope instead lies on a new algorithm[0] which tries to change the POW algorithm all the time. Will it hold up or will someone manage to create efficient ASICs? Your guess is as good as mine.

[0]: https://github.com/tevador/RandomX

The issue is that anything that changes the POW has to be to be deterministic, so we'll just see programmable ASICs make a return... so invest in Cisco?
Back in the days when GPU mining was a thing, CPU mining was reasonably efficient. This was actually a design goal, it was seen as promoting decentralization.

Now, obviously a rig full of Vega cards put out a lot higher hash rate than an 8C CPU, but the CPU was actually reasonably efficient in terms of wattage. At the time, building quad-CPU rigs on older architectures was actually a reasonably efficient build.

At least in times past (2015-2017) there wasn't a huge discrepancy. My i5 3750k at default low clocks would do 40 H/s per core while my AMD 7950 did about 400 H/s going all out. Trying to do it in javascript in a browser is a real performance killer though.
So why didn't they use GPU? Could you build something like that for WebGL?
No compute shader support in WebGL. Have to wait for WebGPU for that.