ASICs Wanted: The BM1387 and the Hardware Designed for Cryptocurrency Mining
Cryptocurrencies have been in and out of the news for a while now. Because "mining" is the only source of new cryptocurrency units, complex ASIC devices such as the BM1387 have been created to aid in the mining process. Here's a look at some ASICs that aims to make mining faster and more effective.
Mining a cryptocurrency like Bitcoin is, at its core, a guessing game. It is a process of solving hash problems, which is complex and must be done at scale. Therefore, it's imperative for Bitcoin miners to be able to simultaneously try different guesses when solving hash problems so that the time to solve can be reduced.
While multi-core CPUs can be good at this, they are limited to the number of cores that they contain (for example, a four core CPU can check a maximum of four hashes simultaneously). However, solving hash problems is very specific and can easily be done using a GPU. Since GPUs contain many individual processing cores, the hash rate from a GPU is often several orders of magnitude greater than that from CPUs.
But as the number of available Bitcoins to be mined reduces, the hash problem becomes harder to solve and even GPUs became too slow. This is where some manufacturers have found a gap in the market and now produce devices specifically for mining cryptocurrencies.
A cryptocurrency mining "farm" full of servers. Image courtesy of Marco Krohn [CC BY-SA 4.0]
Enter the ASIC
ASICs (application specific integrated circuits) devices are silicon ICs tailored by engineers to perform a specific function, unlike generic ICs meant to be useful in multiple applications. Designers of mining equipment would normally have to rely on devices such as FPGAs to create hardware that can mine efficiently, but ASICs offer a cheaper path. While cost and development of ASIC devices are considerably higher than that of FPGAs (by tens of millions of dollars), the individual ICs can be relatively inexpensive.
One company in particular, Bitmain, produce Bitcoin mining equipment containing ASIC miner ICs. Their latest product, the Antminer S9, is one of the world's smallest Bitcoin miner machines, as well as being the world's lowest-powered device of its kind. The S9 control board uses a Xilinx Zynq 7000 series FPGA, which also integrates a Dual ARM Cortex-A9 microprocessor. But the impressive hardware in the S9 is not the controller board or the use of an FPGA, but the 189 BM1387 ASIC miner ICs!
The BM1387. Image courtesy of Bitmain
The BM1387 is an ASIC designed to solve hash rates as fast as possible while keeping the energy consumption to a minimum. Power consumption is a pain point for cryptocurrency miners because the process of supporting the necessary servers is extremely power hungry. The BM1387 is designed as an upgrade for the older BM1385, but specifications for the newer ASIC are being held closely under wraps.
The designers of the BM1385 claim that the device consumes only 0.098J per giga hash and with an estimated has rate of 13TH/s for a power consumption of 1300W then the hash rate for each ASIC is approximately 68GH/s which would translate to an approximate energy consumption of 6.12W. But what does the datasheet say? The BM1385 datasheet has a table showing the typical hash rate and power for the BM1385.
Further reading of the datasheet shows a rather interesting pinout of the ASIC, which contains mostly power pins and a few I/O pins. But what is more interesting is that this device uses UART to communicate with a host at 115200 baud, The datasheet for the BM1385 also shows commands for the IC, as well as UART message formats, which talk about hash counting numbers, work counts, and ticket mask.
Security Issues in a Narrow Field
Bitmain, the producers of the BM1387 and BM1387, is one of two main companies producing ASIC-based miners for the Bitcoin community. With so many miners looking for stats on low energy consumption and high hash rates, Bitmain is arguably the most popular hardware producer in this space. For a currency that relies on decentralization, this is a real issue for security reasons.
When a hash problem has been solved, the ASIC devices detect this and report back to a program or other software package of the solution. Since these devices are incredibly complex and contain many hundreds of ICs, it would be very easy to integrate a processor that could very quickly relay the solution to a remote server that could claim the solved block instead. Miners are also used to verify blocks in the ledger from other users and a company controlling more than half of the verification machines on the network could potentially have full control over Bitcoin.
Given the enduring popularity of cryptocurrencies, there will almost certainly be more mining ASICs hitting the market in coming years and months.
The article says: “... that could very quickly relay the solution to a remote server that could claim the solved block instead.”
This is not how the blockchain works. The solution is a block that includes the address that wins the reward generated in that block. Relaying the solution to a remote server will not allow the bad guy to claim the reward, because changing the address starts the puzzle from the beginning.
Did anyone else notice the datasheet does not support the text just above? The datasheet shows almost twice the power utilized for about half the hashrate. Did I misread something?
I’m not sure the Bitcoin space is still viable for new ASIC development, but accelerators for multiple hash functions are extremely useful. I see a space for ISA extensions for, say MIPS, ARM (licensing may be an issue) or RISC-V where processor and cryptographic accelerator would be easily merged.
Communicating through an UART, however, is not a good idea for a general purpose accelerator - it’d need to have direct access to a memory bus.