VanitySearch another tool for finding address prefixes

19 replies 286 views
coldmaxiMember
Posts: 21 · Reputation: 238
#1Feb 16, 2020, 10:11 PM
Hey everyone, I’m excited to share a new Bitcoin prefix address finder called VanitySearch. It’s pretty similar to Vanitygen, but there are a couple of key differences. For starters, VanitySearch doesn’t rely on the heavy OpenSSL for CPU tasks, and its core is written in Cuda to really utilize inline PTX assembly. On my Intel Core i7-4770, VanitySearch is about 4 times quicker than vanitygen64, going from 1.32 Mkey/s to 5.27 MK/s. And on my GeForce GTX 645, it’s around 1.5 times faster than oclvanitygen, jumping from 9.26 Mkey/s to 14.548 MK/s. If you want to check how VanitySearch stacks up against Vanitygen, use the -u option for searching uncompressed addresses. Just a heads up, VanitySearch might not automatically find the best gridsize for your GPU, so try out several -g options to see what works best. Using compressed addresses is roughly 20% faster. You can grab VanitySearch from GitHub at this link. Benchmarks for different hardware can be found here. There’s still plenty of room for improvement, so feel free to give it a try and let me know if you run into any issues. Thanks for reading! And sorry if my English isn’t great. Jean-Luc
5 Reply Quote Share
nick88Member
Posts: 17 · Reputation: 119
#2Feb 18, 2020, 06:53 PM
Do you have any plan to write this for Linux? Or provide a guide to compile it on Linux? I might try it on my Linux and will compare it with Vanitygen (my laptop is old, so it might worth to compare directly here).
2 Reply Quote Share
coldmaxiMember
Posts: 21 · Reputation: 238
#3Feb 20, 2020, 06:35 PM
Yes, For the CPU code it should not be a problem unless some intrinsics are missing with gcc. I have to check. Concerning CUDA, I have to install the Cuda SDK on a Linux machine and try to compile, that should not be a big deal. There is only few Windows specific functions (concerning high resolution timer) but I can easily make a linux code for it using gettimeofday(). I let you informed.
0 Reply Quote Share
coldmaxiMember
Posts: 21 · Reputation: 238
#4Feb 21, 2020, 12:21 PM
Hello  I've just published a new release. There is also a makefile for Linux but it supports only CPU release. CUDA release for Linux is coming. I'm very interested in knowing performance you get on your hardware (Linux/Windows/CPU/GPU). Thanks for testing and reporting issues.
1 Reply Quote Share
coldmaxiMember
Posts: 21 · Reputation: 238
#5Feb 21, 2020, 12:55 PM
Thanks for testing  The 2 "Check" fields are here especially for debugging/checking purposes. The 2 'checked' addresses are recomputed from the private key by a direct multiplication. To reach the desired address, during the search, generator points are added one by one. You're right by default, if you just add the -gpu option, all CPU cores are used and it slows down much the system and even the GPU. The CPU cannot handle GPU/CPU transfer efficiently. I wrote few words about this on the README but I will let one CPU core free if the gpu is selected.
5 Reply Quote Share
GrimGweiMember
Posts: 15 · Reputation: 164
#6Feb 21, 2020, 05:59 PM
Great to see someone continuing to develop an open source vanity application.  I'll have to check this out when I get an opportunity.
3 Reply Quote Share
coldmaxiMember
Posts: 21 · Reputation: 238
#7Feb 21, 2020, 10:21 PM
Hello, Thank you for your interest and for reporting issues I just published a new release (v1.2): -Updated probability calculation for very large prefix -Avoid that default configuration hangs the system when gpu is enabled -Performance increase (~10%)
0 Reply Quote Share
coldmaxiMember
Posts: 21 · Reputation: 238
#8Feb 21, 2020, 11:11 PM
Hello, I published a new release (1.3) with a ~15% global performance increase, (~20% on GPU). On my hardware, VanitySearch is now 2 times faster (GPU) than oclvanitygen. My goal was to reach a 8 characters (case sensitive) prefix in a reasonable time on my 6 years old hardware, it still need 2 weeks of computation for a 50% probability. I'm not sure I will reach my goal of 2 or 3 days without changing my hardware The next step will be to handle multiple GPU and to support CUDA for linux.
0 Reply Quote Share
Posts: 2 · Reputation: 109
#9Feb 22, 2020, 05:30 AM
Hello jean_luc I would like to send you an MP but it would be necessary if you would like to activate this option in your profile because otherwise the New can not.
3 Reply Quote Share
coldmaxiMember
Posts: 21 · Reputation: 238
#10Feb 22, 2020, 07:14 AM
Hello, No problem. Done
1 Reply Quote Share
sam777Member
Posts: 5 · Reputation: 130
#11Feb 22, 2020, 07:31 AM
Are you using affine or jacobian coordinates for the points?
0 Reply Quote Share
coldmaxiMember
Posts: 21 · Reputation: 238
#12Feb 22, 2020, 11:31 AM
Hello, Affine coordinates for search (faster): Each group perform p = startP + i*G, i in [1..group_size] where i*G is a pre-computed table containing G,2G,3G,.... in affine coordinates. The inversion of deltax (dx1-dx2) is done once per group (1 ModInv and 256*3 mult). group_size is 256 key long. Protective coordinates for EC multiplication (computation of starting keys). Normalization of the key is done after the multiplication for starting key. Edit: You also may have noticed that I have an innovative implementation of modular inversion (DRS62) which is almost 2 times faster than the Montgomery one. Some benchmark and comments are available in IntMop.cpp.
2 Reply Quote Share
coldmaxiMember
Posts: 21 · Reputation: 238
#13Feb 24, 2020, 03:00 AM
Hello, Some news: I just published (1.4) a new release with few fixes (especially for Linux) but the un-initialized memory bug may also affect Windows (I didn't manage to reproduced this bug on Windows but it can be random). I managed to get back an old PC from my company (~8 years old) with 2 Quadro 600 inside Unfortunately the Quadro 600 (fermi) has only compute capability 2.1 and I will have to set-up CUDA SDK 8.0 (the last one which supports fermi). I set up Ubuntu on this PC and I will try to develop the multi GPU release under Linux. Hope I will manage to get good drivers for the Quadro 600 and to make it work.
5 Reply Quote Share
sam777Member
Posts: 5 · Reputation: 130
#14Feb 25, 2020, 05:41 AM
Ok. two questions: 1) why only 256 for the group size? There is a memory problem? Less inversions are better 2) the field multiplication a*b = c mod p ;  why do you use Montgomery, are you sure it is worth it?
0 Reply Quote Share
coldmaxiMember
Posts: 21 · Reputation: 238
#15Feb 25, 2020, 06:17 AM
A group size of 512 does not bring significant improvement (less than 1%). The DRS62 ModInv is fast and almost negligible with a group size of 256. If you have a modular mult faster than the digit serial Montgomery mult on a 256bit field, I'm obviously fully open. A folding does not improve thing on 256 bit when working with 64bit digits. I'm not sure if Barrett could be faster, I must say I didn't try and for "medium size field", there can be traps.
4 Reply Quote Share
sam777Member
Posts: 5 · Reputation: 130
#16Feb 25, 2020, 08:20 AM
On my pc: VanitySearch -stop -u -t 1 1tryme --> 1,2 MKeys/s my ecc library  --> 2,0 MKeys/s  (17 M Public keys/s) EDIT: I use: a) group of 4096 points b) a * b = c mod p   a*b --> 8 * 64 bit, then first 4 limbs * (2**256 - p) + lower 4 limbs. c) exploit some properties of secp256k1 curve
2 Reply Quote Share
coldmaxiMember
Posts: 21 · Reputation: 238
#17Feb 27, 2020, 12:14 PM
Linux or windows ? Is it open source ? Can i try it ?
2 Reply Quote Share
sam777Member
Posts: 5 · Reputation: 130
#18Feb 29, 2020, 06:14 PM
Linux. You have a PM
2 Reply Quote Share
coldmaxiMember
Posts: 21 · Reputation: 238
#19Feb 29, 2020, 08:05 PM
I tried this. ~same performance as the multiplication by P (for secpk1) for mmult  can be reduced in a single 64bit mult. So I'm interested in c. OK, on linux, performace are still bad, i'm sorry. Some problem with intrinsic....
2 Reply Quote Share
coldmaxiMember
Posts: 21 · Reputation: 238
#20Feb 29, 2020, 09:51 PM
I have to way 1 hour to answer to your last MP It's time for me to go to sleep. See you
3 Reply Quote Share

Related topics