Browse Source

lyra2: Translate japanese comments into english (#40)

* Revert "lyra2: fix compilation on japanese windows (#38)"

This reverts commit 30db7d2433.

* Restore comments removed in #38, translate them into English

The original line says "allocate XXXX bytes to adjust for X Warp."
Remove the number from comment since they are trivial

* Translate Japanese comments
pull/2/head
hakemimi 7 years ago committed by Tanguy Pruvot
parent
commit
50781f00eb
  1. 8
      lyra2/cuda_lyra2.cu
  2. 10
      lyra2/cuda_lyra2Z.cu
  3. 18
      lyra2/cuda_lyra2Z_sm5.cuh
  4. 16
      lyra2/cuda_lyra2_sm5.cuh

8
lyra2/cuda_lyra2.cu

@ -274,7 +274,7 @@ void reduceDuplexRowSetup(const int rowIn, const int rowInOut, const int rowOut,
ST4S(rowOut, Ncol - i - 1, state1, thread, threads); ST4S(rowOut, Ncol - i - 1, state1, thread, threads);
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -311,7 +311,7 @@ void reduceDuplexRowt(const int rowIn, const int rowInOut, const int rowOut, uin
round_lyra(state); round_lyra(state);
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -356,7 +356,7 @@ void reduceDuplexRowt_8(const int rowInOut, uint2* state, const uint32_t thread,
round_lyra(state); round_lyra(state);
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -555,8 +555,10 @@ void lyra2_cpu_hash_32(int thr_id, uint32_t threads, uint32_t startNounce, uint6
size_t shared_mem = 0; size_t shared_mem = 0;
if (gtx750ti) if (gtx750ti)
// suitable amount to adjust for 8warp
shared_mem = 8192; shared_mem = 8192;
else else
// suitable amount to adjust for 10warp
shared_mem = 6144; shared_mem = 6144;
lyra2_gpu_hash_32_1_sm5 <<< grid2, block2 >>> (threads, startNounce, (uint2*)d_hash); lyra2_gpu_hash_32_1_sm5 <<< grid2, block2 >>> (threads, startNounce, (uint2*)d_hash);

10
lyra2/cuda_lyra2Z.cu

@ -510,7 +510,7 @@ void reduceDuplexRowSetup(const int rowIn, const int rowInOut, const int rowOut,
ST4S(rowOut, Ncol - i - 1, state1, thread, threads); ST4S(rowOut, Ncol - i - 1, state1, thread, threads);
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -547,7 +547,7 @@ void reduceDuplexRowt(const int rowIn, const int rowInOut, const int rowOut, uin
round_lyra(state); round_lyra(state);
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -593,7 +593,7 @@ void reduceDuplexRowt_8(const int rowInOut, uint2* state, const uint32_t thread,
round_lyra(state); round_lyra(state);
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -649,7 +649,7 @@ void reduceDuplexRowt_8_v2(const int rowIn, const int rowOut, const int rowInOut
round_lyra(state); round_lyra(state);
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -950,8 +950,10 @@ uint32_t lyra2Z_cpu_hash_32(int thr_id, uint32_t threads, uint32_t startNounce,
size_t shared_mem = 0; size_t shared_mem = 0;
if (gtx750ti) if (gtx750ti)
// suitable amount to adjust for 8warp
shared_mem = 8192; shared_mem = 8192;
else else
// suitable amount to adjust for 10warp
shared_mem = 6144; shared_mem = 6144;
lyra2Z_gpu_hash_32_1_sm5 <<< grid2, block2 >>> (threads, startNounce, (uint2*)d_hash); lyra2Z_gpu_hash_32_1_sm5 <<< grid2, block2 >>> (threads, startNounce, (uint2*)d_hash);

18
lyra2/cuda_lyra2Z_sm5.cuh

@ -225,7 +225,7 @@ void reduceDuplexV5(uint2 state[4], const uint32_t thread, const uint32_t thread
for (int j = 0; j < 3; j++) for (int j = 0; j < 3; j++)
*(DMatrix + s2 + j*threads*blockDim.x) = state1[j] ^ state[j]; *(DMatrix + s2 + j*threads*blockDim.x) = state1[j] ^ state[j];
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -271,7 +271,7 @@ void reduceDuplexV5(uint2 state[4], const uint32_t thread, const uint32_t thread
for (int j = 0; j < 3; j++) for (int j = 0; j < 3; j++)
*(DMatrix + s3 + j*threads*blockDim.x) = state1[j] ^ state[j]; *(DMatrix + s3 + j*threads*blockDim.x) = state1[j] ^ state[j];
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -316,7 +316,7 @@ void reduceDuplexV5(uint2 state[4], const uint32_t thread, const uint32_t thread
for (int j = 0; j < 3; j++) for (int j = 0; j < 3; j++)
*(DMatrix + s4 + j*threads*blockDim.x) = state1[j] ^ state[j]; *(DMatrix + s4 + j*threads*blockDim.x) = state1[j] ^ state[j];
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -360,7 +360,7 @@ void reduceDuplexV5(uint2 state[4], const uint32_t thread, const uint32_t thread
for (int j = 0; j < 3; j++) for (int j = 0; j < 3; j++)
*(DMatrix + s5 + j*threads*blockDim.x) = state1[j] ^ state[j]; *(DMatrix + s5 + j*threads*blockDim.x) = state1[j] ^ state[j];
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -406,7 +406,7 @@ void reduceDuplexV5(uint2 state[4], const uint32_t thread, const uint32_t thread
for (int j = 0; j < 3; j++) for (int j = 0; j < 3; j++)
*(DMatrix + s6 + j*threads*blockDim.x) = state1[j] ^ state[j]; *(DMatrix + s6 + j*threads*blockDim.x) = state1[j] ^ state[j];
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -452,7 +452,7 @@ void reduceDuplexV5(uint2 state[4], const uint32_t thread, const uint32_t thread
for (int j = 0; j < 3; j++) for (int j = 0; j < 3; j++)
*(DMatrix + s7 + j*threads*blockDim.x) = state1[j] ^ state[j]; *(DMatrix + s7 + j*threads*blockDim.x) = state1[j] ^ state[j];
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -505,7 +505,7 @@ void reduceDuplexRowV50(const int rowIn, const int rowInOut, const int rowOut, u
round_lyra(state); round_lyra(state);
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -554,7 +554,7 @@ void reduceDuplexRowV50_8(const int rowInOut, uint2 state[4], const uint32_t thr
round_lyra(state); round_lyra(state);
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -618,7 +618,7 @@ void reduceDuplexRowV50_8_v2(const int rowIn, const int rowOut,const int rowInOu
round_lyra(state); round_lyra(state);
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];

16
lyra2/cuda_lyra2_sm5.cuh

@ -216,7 +216,7 @@ void reduceDuplexV5(uint2 state[4], const uint32_t thread, const uint32_t thread
for (int j = 0; j < 3; j++) for (int j = 0; j < 3; j++)
*(DMatrix + s2 + j*threads*blockDim.x) = state1[j] ^ state[j]; *(DMatrix + s2 + j*threads*blockDim.x) = state1[j] ^ state[j];
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -262,7 +262,7 @@ void reduceDuplexV5(uint2 state[4], const uint32_t thread, const uint32_t thread
for (int j = 0; j < 3; j++) for (int j = 0; j < 3; j++)
*(DMatrix + s3 + j*threads*blockDim.x) = state1[j] ^ state[j]; *(DMatrix + s3 + j*threads*blockDim.x) = state1[j] ^ state[j];
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -307,7 +307,7 @@ void reduceDuplexV5(uint2 state[4], const uint32_t thread, const uint32_t thread
for (int j = 0; j < 3; j++) for (int j = 0; j < 3; j++)
*(DMatrix + s4 + j*threads*blockDim.x) = state1[j] ^ state[j]; *(DMatrix + s4 + j*threads*blockDim.x) = state1[j] ^ state[j];
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -351,7 +351,7 @@ void reduceDuplexV5(uint2 state[4], const uint32_t thread, const uint32_t thread
for (int j = 0; j < 3; j++) for (int j = 0; j < 3; j++)
*(DMatrix + s5 + j*threads*blockDim.x) = state1[j] ^ state[j]; *(DMatrix + s5 + j*threads*blockDim.x) = state1[j] ^ state[j];
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -397,7 +397,7 @@ void reduceDuplexV5(uint2 state[4], const uint32_t thread, const uint32_t thread
for (int j = 0; j < 3; j++) for (int j = 0; j < 3; j++)
*(DMatrix + s6 + j*threads*blockDim.x) = state1[j] ^ state[j]; *(DMatrix + s6 + j*threads*blockDim.x) = state1[j] ^ state[j];
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -443,7 +443,7 @@ void reduceDuplexV5(uint2 state[4], const uint32_t thread, const uint32_t thread
for (int j = 0; j < 3; j++) for (int j = 0; j < 3; j++)
*(DMatrix + s7 + j*threads*blockDim.x) = state1[j] ^ state[j]; *(DMatrix + s7 + j*threads*blockDim.x) = state1[j] ^ state[j];
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -496,7 +496,7 @@ void reduceDuplexRowV50(const int rowIn, const int rowInOut, const int rowOut, u
round_lyra(state); round_lyra(state);
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];
@ -545,7 +545,7 @@ void reduceDuplexRowV50_8(const int rowInOut, uint2 state[4], const uint32_t thr
round_lyra(state); round_lyra(state);
//一個手前のスレッドからデータを貰う(同時に一個先のスレッドにデータを送る) // simultaneously receive data from preceding thread and send data to following thread
uint2 Data0 = state[0]; uint2 Data0 = state[0];
uint2 Data1 = state[1]; uint2 Data1 = state[1];
uint2 Data2 = state[2]; uint2 Data2 = state[2];

Loading…
Cancel
Save