Pages:
Author

Topic: VanitySearch (Yet another address prefix finder) - page 56. (Read 32072 times)

sr. member
Activity: 462
Merit: 701
Hello,

I added more details in the check function.
I also enabled the #define FULLCHECK (GPUEngine.cu:1163) which will perform individual test on hash function and ModularMult.
sr. member
Activity: 462
Merit: 701
771 lines of "Expected item not found"

This time all wrong.
sr. member
Activity: 462
Merit: 701
Tomorrow, I will add more details in the check function in order to try to understand what is going wrong.
As on my 2 config all is going fine, it is very difficult to debug.

legendary
Activity: 1932
Merit: 2077
What you can try is to remove the endomorphism for checking.

Comment the following code in GPUEngine.cu around line 1843 (in the Check() function)
...


Code:
....
ComputeKeys() found 262 items , CPU check...
Expected item not found 34122f9d f14a3cbe 9ccd69bb 1f2ca184 6a6af011
Expected item not found fefe9418 53b7af8e 4732d240 a4c622fe ea4e165b
Expected item not found 34127b76 f3171f36 6266178a 28d60ab9 c74f1e34
Expected item not found 3412f627 8526d571 6db1a559 e06e319b 50f6d82f
Expected item not found 34124611 47fdf70a b62736bf 59eaf92a 841a9436
.....
Expected item not found fefe2c39 82a05980 ad3d68cc c26a0515 3bc5b442
Expected item not found fefecd0e 739a1122 c74ab4c0 c4a88767 a4dcbae7
Expected item not found 3412583e 101f754d 513f121d e0c61e64 5f40e934
Expected item not found 3412b469 21478371 8cc44d6c 2fd40aa3 33d8a3e1
CPU found 771 items

771 lines of "Expected item not found"

An idea would also to noline the _ModInvGrouped (Line 594 GPUEngine.cu)

The errors remain.

sr. member
Activity: 462
Merit: 701
OK. That means that 1545 - 549 are ok.
An idea would also to noline the _ModInvGrouped (Line 594 GPUEngine.cu)
I committed GPUEngine.cu (I just removed unused functions) so the line number may be incorrect.
legendary
Activity: 1932
Merit: 2077
At the end of the list you have the number of items found by the CPU if this number is equal to 549, that means that all are wrong.


At the beginning there are 1534 items:
Code:
ComputeKeys() found 1534 items , CPU check...
Expected item not found fefebd83 328e08ab 3b17c5c2 1fdc223d e99919bf
Expected item not found fefe17af bdccaa14 b240f5d9 acf1b7a7 6d66f7d4
Expected item not found 34122cfd 49587610 4fbb18c9 be290471 8bbe55a8


At the end there is

Code:
Expected item not found fefe51d9 3a71e2cc 0ef81fa6 b2698f8f d1285ce7
Expected item not found fefea8a6 41257f76 b9671b37 cd183376 2ab546f5
Expected item not found 3412f47d 9ed13a0b c9d795d8 943d230f 010170e2
CPU found 1545 items

 I saved the output and with grep and wc I counted 549 "Expected item not found"
sr. member
Activity: 462
Merit: 701
What you can try is to remove the endomorphism for checking.

Comment the following code in GPUEngine.cu around line 1843 (in the Check() function)

Code:
     /*
      secp.GetHash160(p1, searchComp, h);
      pr = *(prefix_t *)h;
      if (pr == 0xFEFE || pr == 0x1234) {
        nbFoundCPU++;
        ok &= CheckHash(h, found);
      }
      secp.GetHash160(p2, searchComp, h);
      pr = *(prefix_t *)h;
      if (pr == 0xFEFE || pr == 0x1234) {
        nbFoundCPU++;
        ok &= CheckHash(h, found);
      }
      */

      // Symetrics
      pt.y.ModNeg();
      p1.y.ModNeg();
      p2.y.ModNeg();

      secp.GetHash160(pt, searchComp, h);
      pr = *(prefix_t *)h;
      if (pr == 0xFEFE || pr == 0x1234) {
        nbFoundCPU++;
        ok &= CheckHash(h, found);
      }
      /*
      secp.GetHash160(p1, searchComp, h);
      pr = *(prefix_t *)h;
      if (pr == 0xFEFE || pr == 0x1234) {
        nbFoundCPU++;
        ok &= CheckHash(h, found);
      }
      secp.GetHash160(p2, searchComp, h);
      pr = *(prefix_t *)h;
      if (pr == 0xFEFE || pr == 0x1234) {
        nbFoundCPU++;
        ok &= CheckHash(h, found);
      }
      */

And the following in GPUCompute.h around line 78 (jn the CheckHashComp() function)

Code:
 _GetHash160Comp(px, py, (uint8_t *)h);
  CHECK_POINT(h, incr, 0);
  /*
  _ModMult(pe1x, px, _beta);
  _GetHash160Comp(pe1x, py, (uint8_t *)h);
  CHECK_POINT(h, incr, 1);
  _ModMult(pe2x, px, _beta2);
  _GetHash160Comp(pe2x, py, (uint8_t *)h);
  CHECK_POINT(h, incr, 2);
  */

  ModNeg256(py);

  _GetHash160Comp(px, py, (uint8_t *)h);
  CHECK_POINT(h, -incr, 0);
  /*
  _GetHash160Comp(pe1x, py, (uint8_t *)h);
  CHECK_POINT(h, -incr, 1);
  _GetHash160Comp(pe2x, py, (uint8_t *)h);
  CHECK_POINT(h, -incr, 2);
  */


And then make gpu=1 clean and make gpu=1 all
sr. member
Activity: 462
Merit: 701
At the end of the list you have the number of items found by the CPU if this number is equal to 549, that means that all are wrong.
legendary
Activity: 1932
Merit: 2077
Output of current version (vanitygensearch -check):
Code:
ComputeKeys() found 1563 items , CPU check...
Expected item not found fefebd83 328e08ab 3b17c5c2 1fdc223d e99919bf
Expected item not found fefe17af bdccaa14 b240f5d9 acf1b7a7 6d66f7d4
Expected item not found 34122cfd 49587610 4fbb18c9 be290471 8bbe55a8
Expected item not found fefe2e06 e7430d2e 8dd6b425 26ff1d5e 57c9a8d6
.................

The list of item not found has 549 elements. Does it mean that 549 over 1563 are wrong?

there are still errors:
Code:
~/VanitySearch$ ./VanitySearch -stop  -t 7 -gpu  1Want
Start Sat Mar 16 19:17:24 2019
Difficulty: 264104224
Search: 1Want
Base Key:4C521F50F3A619FB59ED594ABAD7243B7266F5A0E4ED1850306A4523CF18283C
Number of CPU thread: 7
GPU: GPU #0 Quadro M2200 (8x128 cores) Grid(64x128)

Pub Addr: 1WantmvzmXjLYrMbs7WccKgdus2FgWu66
Prv Addr: 5JadqmMLiBnwNW1w8i1xwEJ3WjRkmSTTsjA7jDWtDYsBqC34sEt
Prv Key : 0x64B3566DF6454B047C32CE2E665C23F6092B8CCD9A88E3E3877045CAAFC14EFD
Check   : 136kVCwRzYyBSfykqncpRsX378LxkCQ1Fd
Check   : 1JunfTKznR17uaRw5svvRy4a2XiB3DEbLR (comp)



Output of the working version (vanitygensearch -check):
Code:
~/VanitySearch_old2$ ./VanitySearch -check
...
ComputeKeys() found 539 items , CPU check...
GPU/CPU check OK
sr. member
Activity: 462
Merit: 701
They are not compile errors, it is the verbose ouput of nvcc, the _Z10CheckPointPjiiPtjS_S_ is a mangled name of the function CheckPoint in GPUCompute.h that I added in the last release.

legendary
Activity: 1932
Merit: 2077
The check works flawlessly on my configs, both linux and windows. It should work.
There is something wrong somewhere but where...


vanitygen -check works with a old version, this is the only compile error I got:
Code:
g++ -DWITHGPU -m64  -Wno-write-strings -O2 -I. -I/usr/local/cuda-8.0/include -o obj/hash/sha256_sse.o -c hash/sha256_sse.cpp
/usr/local/cuda-8.0/bin/nvcc -maxrregcount=0 --ptxas-options=-v --compile --compiler-options -fPIC -ccbin g++ -m64 -O2 -I/usr/local/cuda-8.0/include -gencode=arch=compute_50,code=sm_50 -o obj/GPU/GPUEngine.o -c GPU/GPUEngine.cu
ptxas info    : 0 bytes gmem, 16872 bytes cmem[3]
ptxas info    : Compiling entry function '_Z9comp_keysjPtPjPmS0_' for 'sm_50'
ptxas info    : Function properties for _Z9comp_keysjPtPjPmS0_
    16712 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info    : Used 128 registers, 360 bytes cmem[0], 116 bytes cmem[2]
ptxas info    : Function properties for _Z11_GetHash160PmS_Ph
    0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info    : Function properties for _Z15_GetHash160CompPmS_Ph
    0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info    : Function properties for _Z7_ModInvPm
    0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info    : Function properties for _Z9CheckHashjPtPmS0_ijPjS1_
    0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads



vanitygen -check deosn't works with the current version, this is the  compile error I got:
Code:
/usr/local/cuda-8.0/bin/nvcc -maxrregcount=0 --ptxas-options=-v --compile --compiler-options -fPIC -ccbin g++ -m64 -O2 -I/usr/local/cuda-8.0/include -gencode=arch=compute_50,code=sm_50 -o obj/GPU/GPUEngine.o -c GPU/GPUEngine.cu
ptxas info    : 0 bytes gmem, 33320 bytes cmem[3]
ptxas info    : Compiling entry function '_Z9comp_keysjPtPjPmS0_' for 'sm_50'
ptxas info    : Function properties for _Z9comp_keysjPtPjPmS0_
    32936 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info    : Used 126 registers, 360 bytes cmem[0], 116 bytes cmem[2]
ptxas info    : Function properties for _Z10CheckPointPjiiPtjS_S_
    0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info    : Function properties for _Z11_GetHash160PmS_Ph
    0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info    : Function properties for _Z13CheckHashCompPtPmS0_ijPjS1_
    0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info    : Function properties for _Z15CheckHashUncompPtPmS0_ijPjS1_
    0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info    : Function properties for _Z15_GetHash160CompPmS_Ph
    0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info    : Function properties for _Z7_ModInvPm
    0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads
ptxas info    : Function properties for _Z9CheckHashjPtPmS0_ijPjS1_
    0 bytes stack frame, 0 bytes spill stores, 0 bytes spill loads

As you can see, in the last there is a different error:  Function properties for _Z10CheckPointPjiiPtjS_S_

sr. member
Activity: 462
Merit: 701
The check works flawlessly on my configs, both linux and windows. It should work.
There is something wrong somewhere but where...
legendary
Activity: 1932
Merit: 2077
I found out an illegal memory access.
I committed a fix on git source.
Thanks to test if it is better or not...


The error remains.

EDIT:
to be precise, now it seems that the results are correct (I made 10 tries) but vanitysearch -check produces the same error: maybe there is something wrong with -check function?

Code:
~/VanitySearch$ ./VanitySearch -check
GetBase10() Results OK
Add() Results OK : 125.000 MegaAdd/sec
Mult() Results OK : 24.272 MegaMult/sec
Div() Results OK : 4.566 MegaDiv/sec
ModInv()/ModExp() Results OK
ModInv() : 342.807 KiloInv/sec
IntGroup.ModInv() : 8.920 MegaInv/sec
ModMulK1() : 12.700 MegaMult/sec
ModSqrt() OK !
Check Generator :OK
Check Double :OK
Check Add :OK
Check GenKey :OK
Adress : 15t3Nt1zyMETkHbjJTTshxLnqPzQvAtdCe OK!
Adress : 1BoatSLRHtKNngkdXEeobR76b53LETtpyT OK!
Adress : 1JeanLucgidKHxfY5gkqGmoVjo1yaU4EDt OK(comp)!
Adress : 1Test6BNjSJC5qwYXsjwKVLvz7DpfLehy OK!
Adress : 1BitcoinP7vnLpsUHWbzDALyJKnNo16Qms OK(comp)!
Check Calc PubKey (full) 1ViViGLEawN27xRzGrEhhYPQrZiTKvKLo :OK
Check Calc PubKey (even) 1Gp7rQ4GdooysEAEJAS2o4Ktjvf1tZCihp:OK
Check Calc PubKey (odd) 18aPiLmTow7Xgu96msrDYvSSWweCvB9oBA:OK
GPU: GPU #0 Quadro M2200 (8x128 cores) Grid(64x128)
Seed: 902291
143.116 MegaKey/sec
ComputeKeys() found 1514 items , CPU check...
Expected item not found 3412af62 86300235 849853ea d298b73d d56bb672
Expected item not found 3412bc7b f1296ba0 afb84655 82130792 85bd7f54
Expected item not found 341232ca dd9bc221 4a9664ea 50c352fd 44addb30
Expected item not found 3412366e b3b688bc 7fe3a7bc 967677f8 6ac14eb9
Expected item not found 34128851 1ec60338 7c2f3643 fd5f4e86 0034f632
Expected item not found 34126703 5f43f06a d3b47d48 d70219e9 f208ba14
Expected item not found 3412d097 91788b71 ad6b2e75 308fdaf9 5a992844
Expected item not found fefedc03 fffe2da5 f492467d 154c8931 256f1442
Expected item not found fefe8106 2b806056 b0a46a1f d3969aea 5fb333bd
Expected item not found 341241b9 59581e9f ba6e39f4 f510d1a9 db8901d4
Expected item not found fefec45f 234faf04 cf53b66e 27307904 ffe364f3
Expected item not found 34120d3f 6c2613f4 71dbd886 c88e267a 586fc692
Expected item not found 3412780f a040e2a5 a16a1705 38480789 316b57af
Expected item not found fefe9a98 be3ac140 c7c35aef b088b405 42ee825a
Expected item not found 341253c0 29f92e0f 4b1f60f5 05363c5a 7c1972d2
Expected item not found 34129ee6 10e0641e c1b79be2 512466be 675e2b3a
sr. member
Activity: 462
Merit: 701
I found out an illegal memory access.
I committed a fix on git source.
Thanks to test if it is better or not...
sr. member
Activity: 462
Merit: 701
Good news.
But restoring the group size, and get back in my linux git repo the problem appears.
I will try to debug this.
sr. member
Activity: 462
Merit: 701
The 1111 is not a problem difficult to solve.
But the other concerning the GPU, f...ing hell !

And all work fine on my 8 years old quadro 600 !
legendary
Activity: 1932
Merit: 2077
I confirm that there is a problem with difficulty calculation when searching prefix like 1111something...

For this prefix vanitygen
vanitygen.exe 11111
Difficulty: 4294967296
[353.08 Kkey/s][total 20853248][Prob 0.5%][50% in 2.8h]

and for

vanitygen.exe 111111
Difficulty: 1099511627776
[326.68 Kkey/s][total 987648][Prob 0.0%][50% in 27.0d]


256**4 = 4294967296

256**5 = 1099511627776
member
Activity: 117
Merit: 32
I confirm that there is a problem with difficulty calculation when searching prefix like 1111something...

For this prefix vanitygen
vanitygen.exe 11111
Difficulty: 4294967296
[353.08 Kkey/s][total 20853248][Prob 0.5%][50% in 2.8h]

and for

vanitygen.exe 111111
Difficulty: 1099511627776
[326.68 Kkey/s][total 987648][Prob 0.0%][50% in 27.0d]
legendary
Activity: 1932
Merit: 2077
I confirm that there is a problem with difficulty calculation when searching prefix like 1111something...


Case 11111.. should be simple:

difficulty = 256^(# of 1 - 1)

Example:
1 --> difficulty 1
11 --> difficulty = 256^1
111 --> difficulty = 256^2



Same error for GPU. Now it's a little slower too.

Code:
./VanitySearch -stop  -t 7 -gpu  111111
Start Sat Mar 16 15:44:37 2019
Difficulty: 1961676049784709488574464
Search: 111111
Base Key:BB62B2E3C2AB0474AC27C72F337D14BB6679B66AB0D82FEC2592FF91C87E6F2F
Number of CPU thread: 7
GPU: GPU #0 Quadro M2200 (8x128 cores) Grid(64x128)
145.164 MK/s (GPU 128.957 MK/s) (2^32.37) [P 0.00%][50.00% in 2.97021e+08y][0]
Pub Addr: 111111KYoXqxKvZFofwTHWBoUydR9PvT
Prv Addr: 5KEp6PQmPqDjS4yzsouLGS7KC5kMNoBnQdGEh9KHscGHXFG7wuE
Prv Key : 0xBB62B2E3C2AB0474AC27C72F337D14BB66F9B66AB23E2FEC2592FF91C88005B9
Check   : 1EUCkw1FJmgH3SqvnimVhZv6X213hsXCX9
Check   : 17wrT4K44bsuVSPvbm3wGncoCz129SAH6m (comp)

EDIT:

the last version that works for me is the one without endomorhism (with speed 130 MKeys/s):

Code:
./VanitySearch -check
GetBase10() Results OK
Add() Results OK : 204.082 MegaAdd/sec
Mult() Results OK : 27.174 MegaMult/sec
Div() Results OK : 5.076 MegaDiv/sec
ModInv()/ModExp() Results OK
ModInv() : 340.947 KiloInv/sec
IntGroup.ModInv() : 9.077 MegaInv/sec
ModMulK1() : 12.966 MegaMult/sec
ModSqrt() OK !
Check Generator :OK
Check Double :OK
Check Add :OK
Check GenKey :OK
Adress : 15t3Nt1zyMETkHbjJTTshxLnqPzQvAtdCe OK!
Adress : 1BoatSLRHtKNngkdXEeobR76b53LETtpyT OK!
Adress : 1JeanLucgidKHxfY5gkqGmoVjo1yaU4EDt OK(comp)!
Adress : 1Test6BNjSJC5qwYXsjwKVLvz7DpfLehy OK!
Adress : 1BitcoinP7vnLpsUHWbzDALyJKnNo16Qms OK(comp)!
Check Calc PubKey (full) 1ViViGLEawN27xRzGrEhhYPQrZiTKvKLo :OK
Check Calc PubKey (even) 1Gp7rQ4GdooysEAEJAS2o4Ktjvf1tZCihp:OK
Check Calc PubKey (odd) 18aPiLmTow7Xgu96msrDYvSSWweCvB9oBA:OK
GPU: GPU #0 Quadro M2200 (8x128 cores) Grid(64x128)
Seed: 632257
103.313 MegaKey/sec
ComputeKeys() found 504 items , CPU check...
GPU/CPU check OK
sr. member
Activity: 462
Merit: 701
I confirm that there is a problem with difficulty calculation when searching prefix like 1111something...
Pages:
Jump to: