spacemeshos / POET-OLD

Spacemesh POET service
MIT License
9 stars 9 forks source link

Hacker challenge: Execute 1 scrypt hash function on an AntMiner L3++ ASIC #16

Closed avive closed 5 years ago

avive commented 6 years ago

Motivation

We'd like to profile the sequential (not the parallel) hashing capabilities of POW ASICs designed for Litecoin miner (scrypt hash function with specific params) such as the AntMiner L3++.

This task requires access to an AntMiner L3++ unit, and some hacking for you to try to execute and benchmark 1 scrypt function call. Specifically, what we'd like to know is:

  1. Can a L3++ unit be used to execute and get results for 1 scrypt function call?
  2. Perf benchmark of this function

To complete this task, you will need to submit the code and config required to call the function, log its result and benchmark it so your hack can be verified independently. As an example, submit a python script that calls the function on the device on provided params, logs its result and output total execution time.

Winning the tip for this task

  1. Submit a working solution and the benchmark result
  2. We will try to verify your solution script with our reference miner unit
  3. If you submitted the fastest result in the bounty duration and we have verified your solution then you win the tip eth award

Summary

Bitmain claims ~580MH/s scrypt hashrate but this is for parallel execution of scrypt. The questions we are interested in is: Can this unit be used for sequential execution of scrypt? and if yes, what is the pref of a single call?

Technical Notes

Scrypt params

// These are the script params used in Litecoin
const ( 
    n = 1024
    r = 1
    p = 1
    k = 32   // key length
)

Scrypt hash function definition

Hash(data []byte) []byte 

Script Test Vectors

TBW