#Device Alias
#Name Name
-GeForce_GTX_980 ALIAS_maxwell
-GeForce_GTX_750_Ti ALIAS_maxwell
+GeForce_GTX_560_Ti ALIAS_nv_budget
+GeForce_GTX_750_Ti ALIAS_nv_budget
+
+GeForce_GTX_570 ALIAS_nv_old
+GeForce_GTX_Titan ALIAS_nv_old
+
Iris ALIAS_OSX_GPU
Intel(R)_Core(TM)_i7-4578U_CPU_@_3.00GHz ALIAS_OSX_CPU
#Device Attack Hash Vector Kernel Kernel
#Name Mode Type Width Accel Loops
-AMD_FX(tm)-8120_Eight-Core_Processor 0 0 4 64 32
-AMD_FX(tm)-8120_Eight-Core_Processor 1 0 4 64 64
-AMD_FX(tm)-8120_Eight-Core_Processor 3 0 4 64 128
-
-ALIAS_maxwell 0 0 2 1024 32
-ALIAS_maxwell 1 0 1 1024 160
-ALIAS_maxwell 3 0 4 1024 384
-
-GeForce_GTX_560_Ti 0 0 2 1024 24
-GeForce_GTX_560_Ti 1 0 1 1024 48
-GeForce_GTX_560_Ti 3 0 4 1024 160
-
-Hawaii 0 0 1 1024 96
-Hawaii 1 0 1 1024 128
-Hawaii 3 0 4 1024 256
-Hawaii 0 900 1 1024 128
-Hawaii 1 900 1 1024 160
-Hawaii 3 900 4 1024 512
+* * * N 1024 1
+* * 1500 1 1 1
+* * 3000 1 1 1
#
-# Following is some default we set for all not matching requests
+# slow hashes need low accel
#
+* * 400 1 1 1024
+* * 500 1 1 1024
+* * 501 1 1 1024
+* * 1600 1 1 1024
+* * 1800 1 1 1024
+* * 2100 1 1 1024
+* * 2500 1 1 1024
+* * 3200 1 1 1024
+* * 5200 1 1 1024
+* * 5800 1 1 1024
+* * 6211 1 1 1024
+* * 6221 1 1 1024
+* * 6231 1 1 1024
+* * 6241 1 1 1024
+* * 6212 1 1 1024
+* * 6222 1 1 1024
+* * 6232 1 1 1024
+* * 6242 1 1 1024
+* * 6213 1 1 1024
+* * 6223 1 1 1024
+* * 6233 1 1 1024
+* * 6243 1 1 1024
+* * 6400 1 1 1024
+* * 6500 1 1 1024
+* * 6600 1 1 1024
+* * 6700 1 1 1024
+* * 7100 1 1 1024
+* * 7200 1 1 1024
+* * 7900 1 1 1024
+* * 8200 1 1 1024
+* * 8900 1 1 1024
+* * 9200 1 1 1024
+* * 9300 1 1 1024
+* * 9400 1 1 1024
+* * 9500 1 1 1024
+* * 9600 1 1 1024
+* * 10000 1 1 1024
+* * 10700 1 1 1024
+* * 11300 1 1 1024
+* * 11600 1 1 1024
+* * 12100 1 1 1024
+* * 12200 1 1 1024
+* * 12300 1 1 1024
+* * 12500 1 1 1024
+
#Device Attack Hash Vector Kernel Kernel
#Name Mode Type Width Accel Loops
-* 0 * N 1024 8
-* 0 * N 1024 16
-* 0 * N 1024 64
-* 1 * N 1024 12
-* 1 * N 1024 24
-* 1 * N 1024 96
-* 3 * N 1024 16
-* 3 * N 1024 32
-* 3 * N 1024 128
+ALIAS_nv_budget 0 0 2 1024 1
+ALIAS_nv_budget 1 0 2 1024 1
+ALIAS_nv_budget 3 0 2 1024 1
+ALIAS_nv_budget 0 11 2 1024 1
+ALIAS_nv_budget 1 11 2 1024 1
+ALIAS_nv_budget 3 11 2 1024 1
+ALIAS_nv_budget 0 12 2 1024 1
+ALIAS_nv_budget 1 12 2 1024 1
+ALIAS_nv_budget 3 12 2 1024 1
+ALIAS_nv_budget 0 21 2 1024 1
+ALIAS_nv_budget 1 21 2 1024 1
+ALIAS_nv_budget 3 21 2 1024 1
+ALIAS_nv_budget 0 22 2 1024 1
+ALIAS_nv_budget 1 22 2 1024 1
+ALIAS_nv_budget 3 22 2 1024 1
+ALIAS_nv_budget 0 23 2 1024 1
+ALIAS_nv_budget 1 23 2 1024 1
+ALIAS_nv_budget 3 23 2 1024 1
+ALIAS_nv_budget 0 200 2 1024 1
+ALIAS_nv_budget 1 200 2 1024 1
+ALIAS_nv_budget 3 200 2 1024 1
+ALIAS_nv_budget 0 900 2 1024 1
+ALIAS_nv_budget 1 900 2 1024 1
+ALIAS_nv_budget 3 900 2 1024 1
+ALIAS_nv_budget 0 1000 2 1024 1
+ALIAS_nv_budget 1 1000 2 1024 1
+ALIAS_nv_budget 3 1000 2 1024 1
+ALIAS_nv_budget 0 1100 2 1024 1
+ALIAS_nv_budget 1 1100 2 1024 1
+ALIAS_nv_budget 3 1100 2 1024 1
+ALIAS_nv_budget 0 2400 2 1024 1
+ALIAS_nv_budget 1 2400 2 1024 1
+ALIAS_nv_budget 3 2400 2 1024 1
+ALIAS_nv_budget 0 2410 2 1024 1
+ALIAS_nv_budget 1 2410 2 1024 1
+ALIAS_nv_budget 3 2410 2 1024 1
+ALIAS_nv_budget 0 2600 2 1024 1
+ALIAS_nv_budget 1 2600 2 1024 1
+ALIAS_nv_budget 3 2600 2 1024 1
+ALIAS_nv_budget 0 2611 2 1024 1
+ALIAS_nv_budget 1 2611 2 1024 1
+ALIAS_nv_budget 3 2611 2 1024 1
+ALIAS_nv_budget 0 2612 2 1024 1
+ALIAS_nv_budget 1 2612 2 1024 1
+ALIAS_nv_budget 3 2612 2 1024 1
+ALIAS_nv_budget 0 2711 2 1024 1
+ALIAS_nv_budget 1 2711 2 1024 1
+ALIAS_nv_budget 3 2711 2 1024 1
+ALIAS_nv_budget 0 2811 2 1024 1
+ALIAS_nv_budget 1 2811 2 1024 1
+ALIAS_nv_budget 3 2811 2 1024 1
+ALIAS_nv_budget 0 3711 2 1024 1
+ALIAS_nv_budget 1 3711 2 1024 1
+ALIAS_nv_budget 3 3711 2 1024 1
+ALIAS_nv_budget 0 5100 2 1024 1
+ALIAS_nv_budget 1 5100 2 1024 1
+ALIAS_nv_budget 3 5100 2 1024 1
+ALIAS_nv_budget 0 5500 2 1024 1
+ALIAS_nv_budget 1 5500 2 1024 1
+ALIAS_nv_budget 3 5500 2 1024 1
+ALIAS_nv_budget 0 6000 2 1024 1
+ALIAS_nv_budget 1 6000 2 1024 1
+ALIAS_nv_budget 3 6000 2 1024 1
+ALIAS_nv_budget 0 9900 2 1024 1
+ALIAS_nv_budget 1 9900 2 1024 1
+ALIAS_nv_budget 3 9900 2 1024 1
+ALIAS_nv_budget 0 10100 2 1024 1
+ALIAS_nv_budget 1 10100 2 1024 1
+ALIAS_nv_budget 3 10100 2 1024 1
+ALIAS_nv_budget 0 11000 2 1024 1
+ALIAS_nv_budget 1 11000 2 1024 1
+ALIAS_nv_budget 3 11000 2 1024 1
+ALIAS_nv_budget 0 11400 2 1024 1
+ALIAS_nv_budget 1 11400 2 1024 1
+ALIAS_nv_budget 3 11400 2 1024 1
-##############
-## OBSOLETE ##
-##############
+#Device Attack Hash Vector Kernel Kernel
+#Name Mode Type Width Accel Loops
-#
-# Following is the old values which is used as long we haven't fully build up this database with new values
-#
+ALIAS_nv_old 0 0 2 1024 1
+ALIAS_nv_old 1 0 2 1024 1
+ALIAS_nv_old 3 0 2 1024 1
+ALIAS_nv_old 0 11 2 1024 1
+ALIAS_nv_old 1 11 2 1024 1
+ALIAS_nv_old 3 11 2 1024 1
+ALIAS_nv_old 0 12 2 1024 1
+ALIAS_nv_old 1 12 2 1024 1
+ALIAS_nv_old 3 12 2 1024 1
+ALIAS_nv_old 0 21 2 1024 1
+ALIAS_nv_old 1 21 2 1024 1
+ALIAS_nv_old 3 21 2 1024 1
+ALIAS_nv_old 0 22 2 1024 1
+ALIAS_nv_old 1 22 2 1024 1
+ALIAS_nv_old 3 22 2 1024 1
+ALIAS_nv_old 0 23 2 1024 1
+ALIAS_nv_old 1 23 2 1024 1
+ALIAS_nv_old 3 23 2 1024 1
+ALIAS_nv_old 0 100 2 1024 1
+ALIAS_nv_old 1 100 2 1024 1
+ALIAS_nv_old 3 100 2 1024 1
+ALIAS_nv_old 0 101 2 1024 1
+ALIAS_nv_old 1 101 2 1024 1
+ALIAS_nv_old 3 101 2 1024 1
+ALIAS_nv_old 0 111 2 1024 1
+ALIAS_nv_old 1 111 2 1024 1
+ALIAS_nv_old 3 111 2 1024 1
+ALIAS_nv_old 0 112 2 1024 1
+ALIAS_nv_old 1 112 2 1024 1
+ALIAS_nv_old 3 112 2 1024 1
+ALIAS_nv_old 0 131 2 1024 1
+ALIAS_nv_old 1 131 2 1024 1
+ALIAS_nv_old 3 131 2 1024 1
+ALIAS_nv_old 0 132 2 1024 1
+ALIAS_nv_old 1 132 2 1024 1
+ALIAS_nv_old 3 132 2 1024 1
+ALIAS_nv_old 0 133 2 1024 1
+ALIAS_nv_old 1 133 2 1024 1
+ALIAS_nv_old 3 133 2 1024 1
+ALIAS_nv_old 0 200 2 1024 1
+ALIAS_nv_old 1 200 2 1024 1
+ALIAS_nv_old 3 200 2 1024 1
+ALIAS_nv_old 0 300 2 1024 1
+ALIAS_nv_old 1 300 2 1024 1
+ALIAS_nv_old 3 300 2 1024 1
+ALIAS_nv_old 0 900 2 1024 1
+ALIAS_nv_old 1 900 2 1024 1
+ALIAS_nv_old 3 900 2 1024 1
+ALIAS_nv_old 0 1000 2 1024 1
+ALIAS_nv_old 1 1000 2 1024 1
+ALIAS_nv_old 3 1000 2 1024 1
+ALIAS_nv_old 0 2400 2 1024 1
+ALIAS_nv_old 1 2400 2 1024 1
+ALIAS_nv_old 3 2400 2 1024 1
+ALIAS_nv_old 0 2410 2 1024 1
+ALIAS_nv_old 1 2410 2 1024 1
+ALIAS_nv_old 3 2410 2 1024 1
+ALIAS_nv_old 0 2600 2 1024 1
+ALIAS_nv_old 1 2600 2 1024 1
+ALIAS_nv_old 3 2600 2 1024 1
+ALIAS_nv_old 0 2611 2 1024 1
+ALIAS_nv_old 1 2611 2 1024 1
+ALIAS_nv_old 3 2611 2 1024 1
+ALIAS_nv_old 0 2612 2 1024 1
+ALIAS_nv_old 1 2612 2 1024 1
+ALIAS_nv_old 3 2612 2 1024 1
+ALIAS_nv_old 0 2711 2 1024 1
+ALIAS_nv_old 1 2711 2 1024 1
+ALIAS_nv_old 3 2711 2 1024 1
+ALIAS_nv_old 0 2811 2 1024 1
+ALIAS_nv_old 1 2811 2 1024 1
+ALIAS_nv_old 3 2811 2 1024 1
+ALIAS_nv_old 0 3711 2 1024 1
+ALIAS_nv_old 1 3711 2 1024 1
+ALIAS_nv_old 3 3711 2 1024 1
+ALIAS_nv_old 0 5500 2 1024 1
+ALIAS_nv_old 1 5500 2 1024 1
+ALIAS_nv_old 3 5500 2 1024 1
+ALIAS_nv_old 0 5600 2 1024 1
+ALIAS_nv_old 1 5600 2 1024 1
+ALIAS_nv_old 3 5600 2 1024 1
+ALIAS_nv_old 0 6800 2 1024 1
+ALIAS_nv_old 1 6800 2 1024 1
+ALIAS_nv_old 3 6800 2 1024 1
+ALIAS_nv_old 0 7800 2 1024 1
+ALIAS_nv_old 1 7800 2 1024 1
+ALIAS_nv_old 3 7800 2 1024 1
+ALIAS_nv_old 0 8600 2 1024 1
+ALIAS_nv_old 1 8600 2 1024 1
+ALIAS_nv_old 3 8600 2 1024 1
+ALIAS_nv_old 0 9100 2 1024 1
+ALIAS_nv_old 1 9100 2 1024 1
+ALIAS_nv_old 3 9100 2 1024 1
+ALIAS_nv_old 0 9700 2 1024 1
+ALIAS_nv_old 1 9700 2 1024 1
+ALIAS_nv_old 3 9700 2 1024 1
+ALIAS_nv_old 0 9710 2 1024 1
+ALIAS_nv_old 1 9710 2 1024 1
+ALIAS_nv_old 3 9710 2 1024 1
+ALIAS_nv_old 0 9800 2 1024 1
+ALIAS_nv_old 1 9800 2 1024 1
+ALIAS_nv_old 3 9800 2 1024 1
+ALIAS_nv_old 0 9810 2 1024 1
+ALIAS_nv_old 1 9810 2 1024 1
+ALIAS_nv_old 3 9810 2 1024 1
+ALIAS_nv_old 0 9900 2 1024 1
+ALIAS_nv_old 1 9900 2 1024 1
+ALIAS_nv_old 3 9900 2 1024 1
+ALIAS_nv_old 0 10100 2 1024 1
+ALIAS_nv_old 1 10100 2 1024 1
+ALIAS_nv_old 3 10100 2 1024 1
+ALIAS_nv_old 0 10300 2 1024 1
+ALIAS_nv_old 1 10300 2 1024 1
+ALIAS_nv_old 3 10300 2 1024 1
+ALIAS_nv_old 0 10400 2 1024 1
+ALIAS_nv_old 1 10400 2 1024 1
+ALIAS_nv_old 3 10400 2 1024 1
+ALIAS_nv_old 0 10410 2 1024 1
+ALIAS_nv_old 1 10410 2 1024 1
+ALIAS_nv_old 3 10410 2 1024 1
+ALIAS_nv_old 0 10500 2 1024 1
+ALIAS_nv_old 1 10500 2 1024 1
+ALIAS_nv_old 3 10500 2 1024 1
+ALIAS_nv_old 0 11000 2 1024 1
+ALIAS_nv_old 1 11000 2 1024 1
+ALIAS_nv_old 3 11000 2 1024 1
+ALIAS_nv_old 0 11100 2 1024 1
+ALIAS_nv_old 1 11100 2 1024 1
+ALIAS_nv_old 3 11100 2 1024 1
+ALIAS_nv_old 0 11400 2 1024 1
+ALIAS_nv_old 1 11400 2 1024 1
+ALIAS_nv_old 3 11400 2 1024 1
+ALIAS_nv_old 0 12000 2 1024 1
+ALIAS_nv_old 1 12000 2 1024 1
+ALIAS_nv_old 3 12000 2 1024 1
+ALIAS_nv_old 0 12400 2 1024 1
+ALIAS_nv_old 1 12400 2 1024 1
+ALIAS_nv_old 3 12400 2 1024 1
+ALIAS_nv_old 0 12700 2 1024 1
+ALIAS_nv_old 1 12700 2 1024 1
+ALIAS_nv_old 3 12700 2 1024 1
-* 0 0 N 128 256
-* 1 0 N 256 256
-* 3 0 N 512 256
-* 0 10 N 128 256
-* 1 10 N 256 256
-* 3 10 N 512 256
-* 0 11 N 128 256
-* 1 11 N 256 256
-* 3 11 N 512 256
-* 0 12 N 128 256
-* 1 12 N 256 256
-* 3 12 N 512 256
-* 0 20 N 64 256
-* 1 20 N 128 256
-* 3 20 N 256 256
-* 0 21 N 64 256
-* 1 21 N 128 256
-* 3 21 N 256 256
-* 0 22 N 64 256
-* 1 22 N 128 256
-* 3 22 N 256 256
-* 0 23 N 64 256
-* 1 23 N 128 256
-* 3 23 N 256 256
-* 0 30 N 128 256
-* 1 30 N 256 256
-* 3 30 N 512 256
-* 0 40 N 64 256
-* 1 40 N 128 256
-* 3 40 N 256 256
-* 0 50 N 64 64
-* 1 50 N 128 64
-* 3 50 N 256 64
-* 0 60 N 64 64
-* 1 60 N 128 64
-* 3 60 N 256 64
-* 0 100 N 64 128
-* 1 100 N 128 128
-* 3 100 N 256 128
-* 0 101 N 64 128
-* 1 101 N 128 128
-* 3 101 N 256 128
-* 0 110 N 64 128
-* 1 110 N 128 128
-* 3 110 N 256 128
-* 0 111 N 64 128
-* 1 111 N 128 128
-* 3 111 N 256 128
-* 0 112 N 64 128
-* 1 112 N 128 128
-* 3 112 N 256 128
-* 0 120 N 64 128
-* 1 120 N 128 128
-* 3 120 N 256 128
-* 0 121 N 64 128
-* 1 121 N 128 128
-* 3 121 N 256 128
-* 0 122 N 64 128
-* 1 122 N 128 128
-* 3 122 N 256 128
-* 0 124 N 64 128
-* 1 124 N 128 128
-* 3 124 N 256 128
-* 0 130 N 64 128
-* 1 130 N 128 128
-* 3 130 N 256 128
-* 0 131 N 64 128
-* 1 131 N 128 128
-* 3 131 N 256 128
-* 0 132 N 64 128
-* 1 132 N 128 128
-* 3 132 N 256 128
-* 0 133 N 64 128
-* 1 133 N 128 128
-* 3 133 N 256 128
-* 0 140 N 64 128
-* 1 140 N 128 128
-* 3 140 N 256 128
-* 0 141 N 64 128
-* 1 141 N 128 128
-* 3 141 N 256 128
-* 0 150 N 64 64
-* 1 150 N 128 64
-* 3 150 N 256 64
-* 0 160 N 64 64
-* 1 160 N 128 64
-* 3 160 N 256 64
-* 0 190 N 64 128
-* 1 190 N 128 128
-* 3 190 N 256 128
-* 0 200 N 64 128
-* 1 200 N 128 128
-* 3 200 N 256 128
-* 0 300 N 64 64
-* 1 300 N 128 64
-* 3 300 N 256 64
-* 0 400 N 8 256
-* 1 400 N 16 256
-* 3 400 N 32 256
-* 0 500 N 8 256
-* 1 500 N 16 256
-* 3 500 N 32 256
-* 0 501 N 8 256
-* 1 501 N 16 256
-* 3 501 N 32 256
-* 0 900 N 128 256
-* 1 900 N 256 256
-* 3 900 N 512 256
-* 0 910 N 128 256
-* 1 910 N 256 256
-* 3 910 N 512 256
-* 0 1000 N 128 256
-* 1 1000 N 256 256
-* 3 1000 N 512 256
-* 0 1100 N 64 128
-* 1 1100 N 128 128
-* 3 1100 N 256 128
-* 0 1400 N 64 64
-* 1 1400 N 128 64
-* 3 1400 N 256 64
-* 0 1410 N 64 64
-* 1 1410 N 128 64
-* 3 1410 N 256 64
-* 0 1420 N 64 64
-* 1 1420 N 128 64
-* 3 1420 N 256 64
-* 0 1421 N 64 64
-* 1 1421 N 128 64
-* 3 1421 N 256 64
-* 0 1430 N 64 64
-* 1 1430 N 128 64
-* 3 1430 N 256 64
-* 0 1440 N 64 64
-* 1 1440 N 128 64
-* 3 1440 N 256 64
-* 0 1441 N 64 64
-* 1 1441 N 128 64
-* 3 1441 N 256 64
-* 0 1450 N 32 32
-* 1 1450 N 64 32
-* 3 1450 N 128 32
-* 0 1460 N 32 32
-* 1 1460 N 64 32
-* 3 1460 N 128 32
-* 0 1500 N 16 256
-* 1 1500 N 32 256
-* 3 1500 N 64 256
-* 0 1600 N 8 256
-* 1 1600 N 16 256
-* 3 1600 N 32 256
-* 0 1700 N 64 32
-* 1 1700 N 128 32
-* 3 1700 N 256 32
-* 0 1710 N 64 32
-* 1 1710 N 128 32
-* 3 1710 N 256 32
-* 0 1711 N 64 32
-* 1 1711 N 128 32
-* 3 1711 N 256 32
-* 0 1720 N 64 32
-* 1 1720 N 128 32
-* 3 1720 N 256 32
-* 0 1722 N 64 32
-* 1 1722 N 128 32
-* 3 1722 N 256 32
-* 0 1730 N 64 32
-* 1 1730 N 128 32
-* 3 1730 N 256 32
-* 0 1731 N 64 32
-* 1 1731 N 128 32
-* 3 1731 N 256 32
-* 0 1740 N 64 32
-* 1 1740 N 128 32
-* 3 1740 N 256 32
-* 0 1750 N 32 16
-* 1 1750 N 64 16
-* 3 1750 N 128 16
-* 0 1760 N 32 16
-* 1 1760 N 64 16
-* 3 1760 N 128 16
-* 0 1800 N 2 16
-* 1 1800 N 4 16
-* 3 1800 N 8 16
-* 0 2100 N 8 256
-* 1 2100 N 16 256
-* 3 2100 N 32 256
-* 0 2400 N 64 256
-* 1 2400 N 128 256
-* 3 2400 N 256 256
-* 0 2410 N 64 256
-* 1 2410 N 128 256
-* 3 2410 N 256 256
-* 0 2500 N 8 256
-* 1 2500 N 16 256
-* 3 2500 N 32 256
-* 0 2600 N 64 128
-* 1 2600 N 128 128
-* 3 2600 N 256 128
-* 0 2611 N 64 128
-* 1 2611 N 128 128
-* 3 2611 N 256 128
-* 0 2612 N 64 128
-* 1 2612 N 128 128
-* 3 2612 N 256 128
-* 0 2711 N 64 64
-* 1 2711 N 128 64
-* 3 2711 N 256 64
-* 0 2811 N 64 64
-* 1 2811 N 128 64
-* 3 2811 N 256 64
-* 0 3000 N 128 256
-* 1 3000 N 256 256
-* 3 3000 N 512 256
-* 0 3100 N 16 16
-* 1 3100 N 32 16
-* 3 3100 N 64 16
-* 0 3200 N 2 16
-* 1 3200 N 4 16
-* 3 3200 N 8 16
-* 0 3710 N 64 128
-* 1 3710 N 128 128
-* 3 3710 N 256 128
-* 0 3711 N 64 128
-* 1 3711 N 128 128
-* 3 3711 N 256 128
-* 0 3800 N 128 256
-* 1 3800 N 256 256
-* 3 3800 N 512 256
-* 0 4300 N 64 128
-* 1 4300 N 128 128
-* 3 4300 N 256 128
-* 0 4400 N 64 128
-* 1 4400 N 128 128
-* 3 4400 N 256 128
-* 0 4500 N 64 128
-* 1 4500 N 128 128
-* 3 4500 N 256 128
-* 0 4700 N 64 128
-* 1 4700 N 128 128
-* 3 4700 N 256 128
-* 0 4800 N 128 256
-* 1 4800 N 256 256
-* 3 4800 N 512 256
-* 0 4900 N 64 128
-* 1 4900 N 128 128
-* 3 4900 N 256 128
-* 0 5000 N 64 64
-* 1 5000 N 128 64
-* 3 5000 N 256 64
-* 0 5100 N 64 256
-* 1 5100 N 128 256
-* 3 5100 N 256 256
-* 0 5200 N 8 256
-* 1 5200 N 16 256
-* 3 5200 N 32 256
-* 0 5300 N 32 32
-* 1 5300 N 64 32
-* 3 5300 N 128 32
-* 0 5400 N 32 32
-* 1 5400 N 64 32
-* 3 5400 N 128 32
-* 0 5500 N 64 128
-* 1 5500 N 128 128
-* 3 5500 N 256 128
-* 0 5600 N 64 64
-* 1 5600 N 128 64
-* 3 5600 N 256 64
-* 0 5700 N 64 64
-* 1 5700 N 128 64
-* 3 5700 N 256 64
-* 0 5800 N 8 256
-* 1 5800 N 16 256
-* 3 5800 N 32 256
-* 0 6000 N 64 64
-* 1 6000 N 128 64
-* 3 6000 N 256 64
-* 0 6100 N 8 64
-* 1 6100 N 16 64
-* 3 6100 N 32 64
-* 0 6211 N 16 200
-* 1 6211 N 32 200
-* 3 6211 N 64 200
-* 0 6212 N 8 200
-* 1 6212 N 16 200
-* 3 6212 N 32 200
-* 0 6213 N 8 200
-* 1 6213 N 16 200
-* 3 6213 N 32 200
-* 0 6221 N 4 200
-* 1 6221 N 8 200
-* 3 6221 N 16 200
-* 0 6222 N 4 200
-* 1 6222 N 8 200
-* 3 6222 N 16 200
-* 0 6223 N 4 200
-* 1 6223 N 8 200
-* 3 6223 N 16 200
-* 0 6231 N 4 200
-* 1 6231 N 8 200
-* 3 6231 N 16 200
-* 0 6232 N 4 200
-* 1 6232 N 8 200
-* 3 6232 N 16 200
-* 0 6233 N 4 200
-* 1 6233 N 8 200
-* 3 6233 N 16 200
-* 0 6241 N 32 200
-* 1 6241 N 64 200
-* 3 6241 N 128 200
-* 0 6242 N 16 200
-* 1 6242 N 32 200
-* 3 6242 N 64 200
-* 0 6243 N 16 200
-* 1 6243 N 32 200
-* 3 6243 N 64 200
-* 0 6300 N 8 256
-* 1 6300 N 16 256
-* 3 6300 N 32 256
-* 0 6400 N 8 256
-* 1 6400 N 16 256
-* 3 6400 N 32 256
-* 0 6500 N 8 256
-* 1 6500 N 16 256
-* 3 6500 N 32 256
-* 0 6600 N 8 200
-* 1 6600 N 16 200
-* 3 6600 N 32 200
-* 0 6700 N 8 256
-* 1 6700 N 16 256
-* 3 6700 N 32 256
-* 0 6800 N 8 200
-* 1 6800 N 16 200
-* 3 6800 N 32 200
-* 0 6900 N 16 64
-* 1 6900 N 32 64
-* 3 6900 N 64 64
-* 0 7100 N 2 256
-* 1 7100 N 4 256
-* 3 7100 N 8 256
-* 0 7200 N 2 200
-* 1 7200 N 4 200
-* 3 7200 N 8 200
-* 0 7300 N 64 64
-* 1 7300 N 128 64
-* 3 7300 N 256 64
-* 0 7400 N 2 200
-* 1 7400 N 4 200
-* 3 7400 N 8 200
-* 0 7500 N 8 16
-* 1 7500 N 16 16
-* 3 7500 N 32 16
-* 0 7600 N 64 128
-* 1 7600 N 128 128
-* 3 7600 N 256 128
-* 0 7700 N 16 128
-* 1 7700 N 32 128
-* 3 7700 N 64 128
-* 0 7800 N 8 64
-* 1 7800 N 16 64
-* 3 7800 N 32 64
-* 0 7900 N 2 256
-* 1 7900 N 4 256
-* 3 7900 N 8 256
-* 0 8000 N 8 64
-* 1 8000 N 16 64
-* 3 8000 N 32 64
-* 0 8100 N 64 128
-* 1 8100 N 128 128
-* 3 8100 N 256 128
-* 0 8200 N 2 200
-* 1 8200 N 4 200
-* 3 8200 N 8 200
-* 0 8300 N 64 64
-* 1 8300 N 128 64
-* 3 8300 N 256 64
-* 0 8400 N 64 64
-* 1 8400 N 128 64
-* 3 8400 N 256 64
-* 0 8500 N 64 16
-* 1 8500 N 128 16
-* 3 8500 N 256 16
-* 0 8600 N 8 16
-* 1 8600 N 16 16
-* 3 8600 N 32 16
-* 0 8700 N 8 16
-* 1 8700 N 16 16
-* 3 8700 N 32 16
-* 0 8800 N 8 256
-* 1 8800 N 16 256
-* 3 8800 N 32 256
-* 0 8900 N 16 1
-* 1 8900 N 32 1
-* 3 8900 N 64 1
-* 0 9000 N 2 16
-* 1 9000 N 4 16
-* 3 9000 N 8 16
-* 0 9100 N 8 256
-* 1 9100 N 16 256
-* 3 9100 N 32 256
-* 0 9200 N 2 200
-* 1 9200 N 4 200
-* 3 9200 N 8 200
-* 0 9300 N 2 1
-* 1 9300 N 4 1
-* 3 9300 N 8 1
-* 0 9400 N 8 200
-* 1 9400 N 16 200
-* 3 9400 N 32 200
-* 0 9500 N 8 200
-* 1 9500 N 16 200
-* 3 9500 N 32 200
-* 0 9600 N 2 200
-* 1 9600 N 4 200
-* 3 9600 N 8 200
-* 0 9700 N 8 200
-* 1 9700 N 16 200
-* 3 9700 N 32 200
-* 0 9710 N 8 200
-* 1 9710 N 16 200
-* 3 9710 N 32 200
-* 0 9720 N 8 200
-* 1 9720 N 16 200
-* 3 9720 N 32 200
-* 0 9800 N 8 200
-* 1 9800 N 16 200
-* 3 9800 N 32 200
-* 0 9810 N 8 200
-* 1 9810 N 16 200
-* 3 9810 N 32 200
-* 0 9820 N 8 200
-* 1 9820 N 16 200
-* 3 9820 N 32 200
-* 0 9900 N 64 256
-* 1 9900 N 128 256
-* 3 9900 N 256 256
-* 0 10000 N 2 200
-* 1 10000 N 4 200
-* 3 10000 N 8 200
-* 0 10100 N 128 512
-* 1 10100 N 256 512
-* 3 10100 N 512 512
-* 0 10200 N 64 64
-* 1 10200 N 128 64
-* 3 10200 N 256 64
-* 0 10300 N 8 128
-* 1 10300 N 16 128
-* 3 10300 N 32 128
-* 0 10400 N 8 256
-* 1 10400 N 16 256
-* 3 10400 N 32 256
-* 0 10410 N 8 256
-* 1 10410 N 16 256
-* 3 10410 N 32 256
-* 0 10420 N 8 256
-* 1 10420 N 16 256
-* 3 10420 N 32 256
-* 0 10500 N 64 64
-* 1 10500 N 128 64
-* 3 10500 N 256 64
-* 0 10600 N 64 64
-* 1 10600 N 128 64
-* 3 10600 N 256 64
-* 0 10700 N 1 64
-* 1 10700 N 2 64
-* 3 10700 N 4 64
-* 0 10800 N 64 32
-* 1 10800 N 128 32
-* 3 10800 N 256 32
-* 0 10900 N 2 200
-* 1 10900 N 4 200
-* 3 10900 N 8 200
-* 0 11000 N 64 256
-* 1 11000 N 128 256
-* 3 11000 N 256 256
-* 0 11100 N 64 128
-* 1 11100 N 128 128
-* 3 11100 N 256 128
-* 0 11200 N 64 128
-* 1 11200 N 128 128
-* 3 11200 N 256 128
-* 0 11300 N 2 256
-* 1 11300 N 4 256
-* 3 11300 N 8 256
-* 0 11400 N 8 128
-* 1 11400 N 16 128
-* 3 11400 N 32 128
-* 0 11500 N 128 256
-* 1 11500 N 256 256
-* 3 11500 N 512 256
-* 0 11600 N 2 512
-* 1 11600 N 4 512
-* 3 11600 N 8 512
-* 0 11700 N 4 64
-* 1 11700 N 8 64
-* 3 11700 N 16 64
-* 0 11800 N 4 64
-* 1 11800 N 8 64
-* 3 11800 N 16 64
-* 0 11900 N 2 200
-* 1 11900 N 4 200
-* 3 11900 N 8 200
-* 0 12000 N 2 200
-* 1 12000 N 4 200
-* 3 12000 N 8 200
-* 0 12100 N 2 200
-* 1 12100 N 4 200
-* 3 12100 N 8 200
-* 0 12200 N 2 256
-* 1 12200 N 4 256
-* 3 12200 N 8 256
-* 0 12300 N 2 256
-* 1 12300 N 4 256
-* 3 12300 N 8 256
-* 0 12400 N 64 256
-* 1 12400 N 128 256
-* 3 12400 N 256 256
-* 0 12500 N 8 256
-* 1 12500 N 16 256
-* 3 12500 N 32 256
-* 0 12600 N 32 32
-* 1 12600 N 64 32
-* 3 12600 N 128 32
-* 0 12700 N 64 10
-* 1 12700 N 128 10
-* 3 12700 N 256 10
-* 0 12800 N 64 100
-* 1 12800 N 128 100
-* 3 12800 N 256 100
-* 0 12900 N 8 64
-* 1 12900 N 16 64
-* 3 12900 N 32 64
-* 0 13000 N 8 64
-* 1 13000 N 16 64
-* 3 13000 N 32 64
+###############
+## OSX CHAOS ##
+###############
+
+Iris ALIAS_OSX_GPU
+Intel(R)_Core(TM)_i7-4578U_CPU_@_3.00GHz ALIAS_OSX_CPU
ALIAS_OSX_CPU 0 0 N 128 256
ALIAS_OSX_CPU 1 0 N 256 256
const uint VERSION_BIN = 210;
const uint RESTORE_MIN = 210;
+double TARGET_MS_PROFILE[3] = { 8, 24, 72 };
+
#define INCR_RULES 10000
#define INCR_SALTS 100000
#define INCR_MASKS 1000
#define MARKOV_DISABLE 0
#define MARKOV_CLASSIC 0
#define BENCHMARK 0
-#define BENCHMARK_MODE 1
#define RESTORE 0
#define RESTORE_TIMER 60
#define RESTORE_DISABLE 0
" -h, --help Print help",
" --quiet Suppress output",
"",
- "* Benchmark:",
- "",
- " -b, --benchmark Run benchmark",
- " --benchmark-mode=NUM Benchmark-mode, see references below",
- "",
"* Misc:",
"",
" --hex-charset Assume charset is given in hex",
"",
"* Resources:",
"",
+ " -b, --benchmark Run benchmark",
" -c, --segment-size=NUM Size in MB to cache from the wordfile",
" --bitmap-min=NUM Minimum number of bits allowed for bitmaps",
" --bitmap-max=NUM Maximum number of bits allowed for bitmaps",
" --opencl-device-types=STR OpenCL device-types to use, separate with comma, see references below",
" --opencl-vector-width=NUM OpenCL vector-width (either 1, 2, 4 or 8), overrides value from device query",
" -w, --workload-profile=NUM Enable a specific workload profile, see references below",
- " -n, --kernel-accel=NUM Workload tuning: 1, 8, 40, 80, 160",
- " -u, --kernel-loops=NUM Workload fine-tuning: 8 - 1024",
+ " -n, --kernel-accel=NUM Workload tuning, increase the outer-loop step size",
+ " -u, --kernel-loops=NUM Workload tuning, increase the inner-loop step size",
" --gpu-temp-disable Disable temperature and fanspeed readings and triggers",
#ifdef HAVE_HWMON
" --gpu-temp-abort=NUM Abort session if GPU temperature reaches NUM degrees celsius",
"",
"* Workload Profile:",
"",
- " 1 = Reduced performance profile (low latency desktop)",
- " 2 = Default performance profile",
- " 3 = Tuned performance profile (high latency desktop)",
- "",
- "* Benchmark Settings:",
- "",
- " 0 = Manual Tuning",
- " 1 = Performance Tuning, default",
+ " 1 = Interactive performance profile, kernel execution runtime to 8ms, lower latency desktop, lower speed",
+ " 2 = Default performance profile, kernel execution runtime to 24ms, economic setting",
+ " 3 = Headless performance profile, kernel execution runtime to 72ms, higher latency desktop, higher speed",
"",
"* OpenCL device-types:",
"",
* oclHashcat specific functions
*/
+static double get_avg_exec_time (hc_device_param_t *device_param, const int last_num_entries)
+{
+ int exec_pos = (int) device_param->exec_pos - 1 - last_num_entries;
+
+ if (exec_pos < 0) exec_pos += EXEC_CACHE;
+
+ double exec_ms_total = 0;
+
+ int exec_ms_cnt = 0;
+
+ for (int i = 0; i < last_num_entries; i++)
+ {
+ double exec_ms = device_param->exec_ms[(exec_pos + i) % EXEC_CACHE];
+
+ if (exec_ms)
+ {
+ exec_ms_total += exec_ms;
+
+ exec_ms_cnt++;
+ }
+ }
+
+ return exec_ms_total / exec_ms_cnt;
+}
+
void status_display_automat ()
{
FILE *out = stdout;
if (device_param->skipped) continue;
- double exec_ms_total = 0;
-
- int exec_ms_cnt = 0;
-
- for (int i = 0; i < EXEC_CACHE; i++)
- {
- double exec_ms = device_param->exec_ms[i];
-
- if (exec_ms)
- {
- exec_ms_total += exec_ms;
-
- exec_ms_cnt++;
- }
- }
-
- exec_ms_total /= exec_ms_cnt;
+ double exec_ms_total = get_avg_exec_time (device_param, EXEC_CACHE);
fprintf (out, "%f\t", exec_ms_total);
}
if (device_param->skipped) continue;
- double exec_ms_total = 0;
-
- int exec_ms_cnt = 0;
-
- for (int i = 0; i < EXEC_CACHE; i++)
- {
- double exec_ms = device_param->exec_ms[i];
-
- if (exec_ms)
- {
- exec_ms_total += exec_ms;
-
- exec_ms_cnt++;
- }
- }
-
- exec_ms_total /= exec_ms_cnt;
+ double exec_ms_total = get_avg_exec_time (device_param, EXEC_CACHE);
exec_all_ms[device_id] = exec_ms_total;
}
if (device_param->skipped) continue;
- double exec_ms_total = 0;
-
- int exec_ms_cnt = 0;
-
- for (int i = 0; i < EXEC_CACHE; i++)
- {
- double exec_ms = device_param->exec_ms[i];
-
- if (exec_ms)
- {
- exec_ms_total += exec_ms;
-
- exec_ms_cnt++;
- }
- }
-
- exec_ms_total /= exec_ms_cnt;
+ double exec_ms_total = get_avg_exec_time (device_param, EXEC_CACHE);
exec_all_ms[device_id] = exec_ms_total;
}
snprintf (source_file, 255, "%s/OpenCL/m%05d.cl", shared_dir, (int) kern_type);
}
-static void generate_cached_kernel_filename (const uint attack_exec, const uint attack_kern, const uint kern_type, char *profile_dir, char *device_name_chksum, char *cached_file)
+static void generate_cached_kernel_filename (const uint attack_exec, const uint attack_kern, const uint kern_type, char *profile_dir, const char *device_name_chksum, char *cached_file)
{
if (attack_exec == ATTACK_EXEC_INSIDE_KERNEL)
{
}
}
-static void generate_cached_kernel_mp_filename (const uint opti_type, const uint opts_type, char *profile_dir, char *device_name_chksum, char *cached_file)
+static void generate_cached_kernel_mp_filename (const uint opti_type, const uint opts_type, char *profile_dir, const char *device_name_chksum, char *cached_file)
{
if ((opti_type & OPTI_TYPE_BRUTE_FORCE) && (opts_type & OPTS_TYPE_PT_GENERATE_BE))
{
snprintf (source_file, 255, "%s/OpenCL/amp_a%d.cl", shared_dir, attack_kern);
}
-static void generate_cached_kernel_amp_filename (const uint attack_kern, char *profile_dir, char *device_name_chksum, char *cached_file)
+static void generate_cached_kernel_amp_filename (const uint attack_kern, char *profile_dir, const char *device_name_chksum, char *cached_file)
{
snprintf (cached_file, 255, "%s/kernels/amp_a%d.%s.kernel", profile_dir, attack_kern, device_name_chksum);
}
unlink (old_hashfile);
}
-static float find_kernel_blocks_div (const u64 total_left, const uint kernel_blocks_all)
+static float find_kernel_power_div (const u64 total_left, const uint kernel_power_all)
{
- // function called only in case kernel_blocks_all > words_left)
+ // function called only in case kernel_power_all > words_left
- float kernel_blocks_div = (float) (total_left) / kernel_blocks_all;
+ float kernel_power_div = (float) (total_left) / kernel_power_all;
- kernel_blocks_div += kernel_blocks_div / 100;
+ kernel_power_div += kernel_power_div / 100;
- u32 kernel_blocks_new = (u32) (kernel_blocks_all * kernel_blocks_div);
+ u32 kernel_power_new = (u32) (kernel_power_all * kernel_power_div);
- while (kernel_blocks_new < total_left)
+ while (kernel_power_new < total_left)
{
- kernel_blocks_div += kernel_blocks_div / 100;
+ kernel_power_div += kernel_power_div / 100;
- kernel_blocks_new = (u32) (kernel_blocks_all * kernel_blocks_div);
+ kernel_power_new = (u32) (kernel_power_all * kernel_power_div);
}
if (data.quiet == 0)
fflush (stdout);
}
- if ((kernel_blocks_all * kernel_blocks_div) < 8) return 1;
+ if ((kernel_power_all * kernel_power_div) < 8) return 1;
- return kernel_blocks_div;
+ return kernel_power_div;
}
static void run_kernel (const uint kern_run, hc_device_param_t *device_param, const uint num, const uint event_update)
}
device_param->exec_pos = exec_pos;
+
+ // autotune, first get the current avarage time exec_ms_total, this is our base for all
+
+ const double exec_ms_total = get_avg_exec_time (device_param, 4);
+
+ // now adjust kernel_loops
+
+ #define MIN_LOOPS device_param->kernel_loops_min
+ #define MAX_LOOPS device_param->kernel_loops_max
+
+ const double target_ms = TARGET_MS_PROFILE[data.workload_profile - 1];
+
+ if (exec_ms_total > target_ms)
+ {
+ u32 adj = 1;
+
+ if (device_param->kernel_loops >= (MIN_LOOPS + adj))
+ {
+ device_param->kernel_loops -= adj;
+ }
+ }
+
+ if (exec_ms_total < target_ms)
+ {
+ u32 adj = 1;
+
+ if (device_param->kernel_loops <= (MAX_LOOPS - adj))
+ {
+ device_param->kernel_loops += adj;
+ }
+ }
+
+ //printf ("%d %d %f\n", device_param->kernel_accel, device_param->kernel_loops, exec_ms_total);
}
hc_clReleaseEvent (data.ocl, event);
static void run_cracker (hc_device_param_t *device_param, const uint pw_cnt, const uint pws_cnt)
{
- const uint kernel_loops = device_param->kernel_loops;
-
- //only useful in debug
- //if (data.quiet == 0)
- // log_info ("Workload.Dev#%u : loops %u, accel %u", device_param->device_id + 1, device_param->kernel_loops, device_param->kernel_accel);
-
// init speed timer
uint speed_pos = device_param->speed_pos;
uint innerloop_step = 0;
uint innerloop_cnt = 0;
- if (data.attack_exec == ATTACK_EXEC_INSIDE_KERNEL) innerloop_step = kernel_loops;
+ if (data.attack_exec == ATTACK_EXEC_INSIDE_KERNEL) innerloop_step = device_param->kernel_loops;
else innerloop_step = 1;
if (data.attack_kern == ATTACK_KERN_STRAIGHT) innerloop_cnt = data.kernel_rules_cnt;
if (data.devices_status == STATUS_QUIT) break;
if (data.devices_status == STATUS_BYPASS) break;
+ // autotune start
+
+ if (data.attack_exec == ATTACK_EXEC_INSIDE_KERNEL) innerloop_step = device_param->kernel_loops;
+
+ // autotune stop
+
uint innerloop_left = innerloop_cnt - innerloop_pos;
if (innerloop_left > innerloop_step) innerloop_left = innerloop_step;
device_param->kernel_params_buf32[27] = innerloop_left;
- if (innerloop_left == 0) continue;
+ // i think we can get rid of this
+ if (innerloop_left == 0)
+ {
+ puts ("bug, how should this happen????\n");
+
+ continue;
+ }
// initialize amplifiers
uint iter = salt_buf->salt_iter;
- for (uint loop_pos = 0; loop_pos < iter; loop_pos += kernel_loops)
+ uint loop_step = device_param->kernel_loops;
+
+ for (uint loop_pos = 0; loop_pos < iter; loop_pos += loop_step)
{
+ // autotune start
+
+ if (data.attack_exec == ATTACK_EXEC_OUTSIDE_KERNEL) loop_step = device_param->kernel_loops;
+
+ // autotune stop
+
uint loop_left = iter - loop_pos;
- loop_left = MIN (loop_left, kernel_loops);
+ loop_left = MIN (loop_left, loop_step);
device_param->kernel_params_buf32[25] = loop_pos;
device_param->kernel_params_buf32[26] = loop_left;
run_kernel (KERN_RUN_2, device_param, pws_cnt, true);
- if (data.devices_status == STATUS_STOP_AT_CHECKPOINT) check_checkpoint ();
-
if (data.devices_status == STATUS_CRACKED) break;
if (data.devices_status == STATUS_ABORTED) break;
if (data.devices_status == STATUS_QUIT) break;
const u64 words_left = words_base - words_cur;
- if (data.kernel_blocks_all > words_left)
+ if (data.kernel_power_all > words_left)
{
- if (data.kernel_blocks_div == 0)
+ if (data.kernel_power_div == 0)
{
- data.kernel_blocks_div = find_kernel_blocks_div (words_left, data.kernel_blocks_all);
+ data.kernel_power_div = find_kernel_power_div (words_left, data.kernel_power_all);
}
}
- if (data.kernel_blocks_div)
+ if (data.kernel_power_div)
{
- if (device_param->kernel_blocks == device_param->kernel_blocks_user)
+ if (device_param->kernel_power == device_param->kernel_power_user)
{
- const u32 kernel_blocks_new = (float) device_param->kernel_blocks * data.kernel_blocks_div;
- const u32 kernel_power_new = kernel_blocks_new;
+ const u32 kernel_power_new = (float) device_param->kernel_power * data.kernel_power_div;
- if (kernel_blocks_new < device_param->kernel_blocks)
+ if (kernel_power_new < device_param->kernel_power)
{
- device_param->kernel_blocks = kernel_blocks_new;
- device_param->kernel_power = kernel_power_new;
+ device_param->kernel_power = kernel_power_new;
}
}
}
- const uint kernel_blocks = device_param->kernel_blocks;
+ const uint kernel_power = device_param->kernel_power;
- uint work = MIN (words_left, kernel_blocks);
+ uint work = MIN (words_left, kernel_power);
work = MIN (work, max);
const uint attack_kern = data.attack_kern;
- const uint kernel_blocks = device_param->kernel_blocks;
+ const uint kernel_power = device_param->kernel_power;
while ((data.devices_status != STATUS_EXHAUSTED) && (data.devices_status != STATUS_CRACKED) && (data.devices_status != STATUS_ABORTED) && (data.devices_status != STATUS_QUIT))
{
uint words_cur = 0;
- while (words_cur < kernel_blocks)
+ while (words_cur < kernel_power)
{
char buf[BUFSIZ] = { 0 };
if (data.devices_status == STATUS_BYPASS) break;
device_param->words_done = words_fin;
+
+ // first adjust kernel_accel
+
+/*
+ if (data.kernel_power_div) continue;
+
+ double exec_ms_total = get_avg_exec_time (device_param);
+
+ #define WL1_MS_ACCEL 8
+ #define WL2_MS_ACCEL 24
+ #define WL3_MS_ACCEL 72
+
+ if ((data.workload_profile == 3) || (data.benchmark == 1))
+ {
+ #define MIN_ACCEL 0
+ #define MAX_ACCEL device_param->kernel_accel_max
+
+ if (exec_ms_total < WL3_MS_ACCEL)
+ {
+ u32 adj = device_param->kernel_accel * (WL3_MS_ACCEL / exec_ms_total);
+
+ if (device_param->kernel_accel <= (MAX_ACCEL - adj))
+ {
+ device_param->kernel_accel += adj;
+
+ uint kernel_power = device_param->device_processors * device_param->kernel_threads * device_param->kernel_accel;
+
+ device_param->kernel_power = kernel_power;
+ }
+
+ clean_from_pos (device_param, 1);
+ }
+ }
+*/
}
}
else
exit (-1);
}
- const uint kernel_loops = device_param->kernel_loops;
-
salt_t *salt_buf = &data.salts_buf[salt_pos];
device_param->kernel_params_buf32[24] = salt_pos;
{
run_kernel (KERN_RUN_1, device_param, 1, false);
+ uint loop_step = device_param->kernel_loops;
+
const uint iter = salt_buf->salt_iter;
- for (uint loop_pos = 0; loop_pos < iter; loop_pos += kernel_loops)
+ for (uint loop_pos = 0; loop_pos < iter; loop_pos += loop_step)
{
+ // autotune start
+
+ if (data.attack_exec == ATTACK_EXEC_OUTSIDE_KERNEL) loop_step = device_param->kernel_loops;
+
+ // autotune stop
+
uint loop_left = iter - loop_pos;
- loop_left = MIN (loop_left, kernel_loops);
+ loop_left = MIN (loop_left, loop_step);
device_param->kernel_params_buf32[25] = loop_pos;
device_param->kernel_params_buf32[26] = loop_left;
uint version = VERSION;
uint quiet = QUIET;
uint benchmark = BENCHMARK;
- uint benchmark_mode = BENCHMARK_MODE;
uint show = SHOW;
uint left = LEFT;
uint username = USERNAME;
#define IDX_FORCE 0xff08
#define IDX_RUNTIME 0xff09
#define IDX_BENCHMARK 'b'
- #define IDX_BENCHMARK_MODE 0xff32
#define IDX_HASH_MODE 'm'
#define IDX_ATTACK_MODE 'a'
#define IDX_RP_FILE 'r'
{"outfile-check-dir", required_argument, 0, IDX_OUTFILE_CHECK_DIR},
{"force", no_argument, 0, IDX_FORCE},
{"benchmark", no_argument, 0, IDX_BENCHMARK},
- {"benchmark-mode", required_argument, 0, IDX_BENCHMARK_MODE},
{"restore", no_argument, 0, IDX_RESTORE},
{"restore-disable", no_argument, 0, IDX_RESTORE_DISABLE},
{"status", no_argument, 0, IDX_STATUS},
#endif
}
- uint hash_mode_chgd = 0;
- uint runtime_chgd = 0;
- uint kernel_loops_chgd = 0;
- uint kernel_accel_chgd = 0;
- uint attack_mode_chgd = 0;
- uint outfile_format_chgd = 0;
- uint rp_gen_seed_chgd = 0;
- uint remove_timer_chgd = 0;
- uint increment_min_chgd = 0;
- uint increment_max_chgd = 0;
+ uint hash_mode_chgd = 0;
+ uint runtime_chgd = 0;
+ uint kernel_loops_chgd = 0;
+ uint kernel_accel_chgd = 0;
+ uint attack_mode_chgd = 0;
+ uint outfile_format_chgd = 0;
+ uint rp_gen_seed_chgd = 0;
+ uint remove_timer_chgd = 0;
+ uint increment_min_chgd = 0;
+ uint increment_max_chgd = 0;
+ uint workload_profile_chgd = 0;
+
#if defined(HAVE_HWMON) && defined(HAVE_ADL)
- uint gpu_temp_retain_chgd = 0;
- uint gpu_temp_abort_chgd = 0;
+ uint gpu_temp_retain_chgd = 0;
+ uint gpu_temp_abort_chgd = 0;
#endif
optind = 1;
case IDX_LIMIT: limit = atoll (optarg); break;
case IDX_KEYSPACE: keyspace = 1; break;
case IDX_BENCHMARK: benchmark = 1; break;
- case IDX_BENCHMARK_MODE: benchmark_mode = atoi (optarg); break;
case IDX_RESTORE: break;
case IDX_RESTORE_DISABLE: restore_disable = 1; break;
case IDX_STATUS: status = 1; break;
opencl_device_types = optarg; break;
case IDX_OPENCL_VECTOR_WIDTH:
opencl_vector_width = atoi (optarg); break;
- case IDX_WORKLOAD_PROFILE: workload_profile = atoi (optarg); break;
+ case IDX_WORKLOAD_PROFILE: workload_profile = atoi (optarg);
+ workload_profile_chgd = 1; break;
case IDX_KERNEL_ACCEL: kernel_accel = atoi (optarg);
kernel_accel_chgd = 1; break;
case IDX_KERNEL_LOOPS: kernel_loops = atoi (optarg);
if (kernel_accel_chgd == 1)
{
- if (workload_profile != WORKLOAD_PROFILE)
- {
- log_error ("ERROR: kernel-accel parameter can only be set when workload-profile %i is used", WORKLOAD_PROFILE);
-
- return (-1);
- }
-
if (kernel_accel < 1)
{
log_error ("ERROR: Invalid kernel-accel specified");
if (kernel_loops_chgd == 1)
{
- if (workload_profile != WORKLOAD_PROFILE)
- {
- log_error ("ERROR: kernel-loops parameter can only be set when workload-profile %i is used", WORKLOAD_PROFILE);
-
- return (-1);
- }
-
if (kernel_loops < 1)
{
log_error ("ERROR: Invalid kernel-loops specified");
}
}
- if (benchmark == 1)
- {
- if (workload_profile != WORKLOAD_PROFILE)
- {
- log_error ("ERROR: Using the workload-profile in benchmark mode is not allowed");
-
- return (-1);
- }
- }
-
if ((workload_profile < 1) || (workload_profile > 3))
{
log_error ("ERROR: workload-profile %i not available", workload_profile);
return (-1);
}
}
-
- if (benchmark_mode == 0)
- {
- // nothing to do
- }
- else if (benchmark_mode == 1)
- {
- if (kernel_accel_chgd == 1 || kernel_loops_chgd == 1)
- {
- log_error ("ERROR: Benchmark-mode 1 does not allow kernel-accel or kernel-loops changed");
-
- return (-1);
- }
- }
- else
- {
- log_error ("ERROR: Benchmark-mode must be 0 or 1");
-
- return (-1);
- }
}
if (skip != 0 && limit != 0)
data.logfile_disable = logfile_disable;
data.truecrypt_keyfiles = truecrypt_keyfiles;
data.scrypt_tmto = scrypt_tmto;
+ data.workload_profile = workload_profile;
/**
* cpu affinity
logfile_top_uint (attack_mode);
logfile_top_uint (attack_kern);
logfile_top_uint (benchmark);
- logfile_top_uint (benchmark_mode);
logfile_top_uint (bitmap_min);
logfile_top_uint (bitmap_max);
logfile_top_uint (debug_mode);
* disable useless stuff for benchmark
*/
- restore_timer = 0;
- status_timer = 0;
- restore_disable = 1;
- potfile_disable = 1;
- weak_hash_threshold = 0;
-
- data.restore_timer = restore_timer;
- data.status_timer = status_timer;
- data.restore_disable = restore_disable;
+ status_timer = 0;
+ restore_timer = 0;
+ restore_disable = 1;
+ potfile_disable = 1;
+ weak_hash_threshold = 0;
- if (benchmark_mode == 1)
- {
- markov_disable = 1;
-
- workload_profile = 3;
- }
+ data.status_timer = status_timer;
+ data.restore_timer = restore_timer;
+ data.restore_disable = restore_disable;
/**
* force attack mode to be bruteforce
attack_mode = ATTACK_MODE_BF;
attack_kern = ATTACK_KERN_BF;
- if (runtime_chgd == 0)
+ if (workload_profile_chgd == 0)
{
- runtime = 8;
+ workload_profile = 3;
+
+ data.workload_profile = workload_profile;
+ }
- if (benchmark_mode == 1) runtime = 17;
+ if (runtime_chgd == 0)
+ {
+ runtime = 17;
data.runtime = runtime;
}
case 5400: esalt_size = sizeof (ikepsk_t); break;
case 5500: esalt_size = sizeof (netntlm_t); break;
case 5600: esalt_size = sizeof (netntlm_t); break;
- case 6211:
- case 6212:
- case 6213:
- case 6221:
- case 6222:
- case 6223:
- case 6231:
- case 6232:
- case 6233:
- case 6241:
- case 6242:
+ case 6211: esalt_size = sizeof (tc_t); break;
+ case 6212: esalt_size = sizeof (tc_t); break;
+ case 6213: esalt_size = sizeof (tc_t); break;
+ case 6221: esalt_size = sizeof (tc_t); break;
+ case 6222: esalt_size = sizeof (tc_t); break;
+ case 6223: esalt_size = sizeof (tc_t); break;
+ case 6231: esalt_size = sizeof (tc_t); break;
+ case 6232: esalt_size = sizeof (tc_t); break;
+ case 6233: esalt_size = sizeof (tc_t); break;
+ case 6241: esalt_size = sizeof (tc_t); break;
+ case 6242: esalt_size = sizeof (tc_t); break;
case 6243: esalt_size = sizeof (tc_t); break;
case 6600: esalt_size = sizeof (agilekey_t); break;
case 7100: esalt_size = sizeof (pbkdf2_sha512_t); break;
break;
case 5400: data.hashfile = mystrdup ("hashcat.ikesha1");
break;
- case 6211:
- case 6212:
- case 6213:
- case 6221:
- case 6222:
- case 6223:
- case 6231:
- case 6232:
- case 6233:
- case 6241:
- case 6242:
+ case 6211: data.hashfile = mystrdup ("hashcat.tc");
+ break;
+ case 6212: data.hashfile = mystrdup ("hashcat.tc");
+ break;
+ case 6213: data.hashfile = mystrdup ("hashcat.tc");
+ break;
+ case 6221: data.hashfile = mystrdup ("hashcat.tc");
+ break;
+ case 6222: data.hashfile = mystrdup ("hashcat.tc");
+ break;
+ case 6223: data.hashfile = mystrdup ("hashcat.tc");
+ break;
+ case 6231: data.hashfile = mystrdup ("hashcat.tc");
+ break;
+ case 6232: data.hashfile = mystrdup ("hashcat.tc");
+ break;
+ case 6233: data.hashfile = mystrdup ("hashcat.tc");
+ break;
+ case 6241: data.hashfile = mystrdup ("hashcat.tc");
+ break;
+ case 6242: data.hashfile = mystrdup ("hashcat.tc");
+ break;
case 6243: data.hashfile = mystrdup ("hashcat.tc");
break;
case 6600: data.hashfile = mystrdup ("hashcat.agilekey");
break;
case 5800: hashes_buf[0].salt->salt_iter = ROUNDS_ANDROIDPIN - 1;
break;
- case 6211:
- case 6212:
+ case 6211: hashes_buf[0].salt->salt_iter = ROUNDS_TRUECRYPT_2K;
+ break;
+ case 6212: hashes_buf[0].salt->salt_iter = ROUNDS_TRUECRYPT_2K;
+ break;
case 6213: hashes_buf[0].salt->salt_iter = ROUNDS_TRUECRYPT_2K;
break;
- case 6221:
- case 6222:
+ case 6221: hashes_buf[0].salt->salt_iter = ROUNDS_TRUECRYPT_1K;
+ break;
+ case 6222: hashes_buf[0].salt->salt_iter = ROUNDS_TRUECRYPT_1K;
+ break;
case 6223: hashes_buf[0].salt->salt_iter = ROUNDS_TRUECRYPT_1K;
break;
- case 6231:
- case 6232:
+ case 6231: hashes_buf[0].salt->salt_iter = ROUNDS_TRUECRYPT_1K;
+ break;
+ case 6232: hashes_buf[0].salt->salt_iter = ROUNDS_TRUECRYPT_1K;
+ break;
case 6233: hashes_buf[0].salt->salt_iter = ROUNDS_TRUECRYPT_1K;
break;
- case 6241:
- case 6242:
+ case 6241: hashes_buf[0].salt->salt_iter = ROUNDS_TRUECRYPT_1K;
+ break;
+ case 6242: hashes_buf[0].salt->salt_iter = ROUNDS_TRUECRYPT_1K;
+ break;
case 6243: hashes_buf[0].salt->salt_iter = ROUNDS_TRUECRYPT_1K;
break;
case 6300: hashes_buf[0].salt->salt_iter = ROUNDS_MD5CRYPT;
}
/**
- * kernel accel and loops auto adjustment
+ * kernel accel and loops tuning db adjustment
*/
uint _kernel_accel = kernel_accel;
if (kernel_loops_chgd == 0)
{
_kernel_loops = tuningdb_entry->kernel_loops;
- }
- if (workload_profile == 1)
- {
- _kernel_loops = (_kernel_loops > 8) ? _kernel_loops / 8 : 1;
- }
- else if (workload_profile == 2)
- {
- _kernel_loops = (_kernel_loops > 4) ? _kernel_loops / 4 : 1;
- }
-
- /**
- * there's a few algorithm that force a fixed kernel_loop count
- */
-
- if ((opts_type & OPTS_TYPE_PT_BITSLICE) && (attack_mode == ATTACK_MODE_BF))
- {
- _kernel_loops = 1024;
- }
-
- if (hash_mode == 12500)
- {
- _kernel_loops = ROUNDS_RAR3 / 16;
+ if (workload_profile == 1)
+ {
+ _kernel_loops = (_kernel_loops > 8) ? _kernel_loops / 8 : 1;
+ }
+ else if (workload_profile == 2)
+ {
+ _kernel_loops = (_kernel_loops > 4) ? _kernel_loops / 4 : 1;
+ }
}
device_param->kernel_accel = _kernel_accel;
if (benchmark == 1) log_info ("Hashmode: %d", data.hash_mode);
#endif
- uint kernel_blocks_all = 0;
+ uint kernel_power_all = 0;
for (uint device_id = 0; device_id < data.devices_cnt; device_id++)
{
* device properties
*/
- char *device_name_chksum = device_param->device_name_chksum;
-
- uint device_processors = device_param->device_processors;
-
- uint device_processor_cores = device_param->device_processor_cores;
-
- uint kernel_accel = device_param->kernel_accel;
+ const char *device_name_chksum = device_param->device_name_chksum;
+ const u32 device_processors = device_param->device_processors;
+ const u32 device_processor_cores = device_param->device_processor_cores;
/**
* create context for each device
device_param->command_queue = hc_clCreateCommandQueue (data.ocl, device_param->context, device_param->device, CL_QUEUE_PROFILING_ENABLE);
/**
- * create input buffers on device
+ * create input buffers on device : calculate size of fixed memory buffers
*/
- uint kernel_threads = KERNEL_THREADS;
-
- // bcrypt
- if (hash_mode == 3200) kernel_threads = 8;
- if (hash_mode == 9000) kernel_threads = 8;
-
- uint kernel_power = 1;
- uint kernel_blocks = 1;
-
- uint size_pws = 4;
- uint size_tmps = 4;
- uint size_hooks = 4;
-
- // find out if we would request too much memory on memory blocks which are based on kernel_accel
-
- while (kernel_accel)
- {
- kernel_power = device_processors * kernel_threads * kernel_accel;
- kernel_blocks = kernel_power;
-
- // size_pws
-
- size_pws = kernel_blocks * sizeof (pw_t);
-
- // size_tmps
-
- switch (hash_mode)
- {
- case 400: size_tmps = kernel_blocks * sizeof (phpass_tmp_t); break;
- case 500: size_tmps = kernel_blocks * sizeof (md5crypt_tmp_t); break;
- case 501: size_tmps = kernel_blocks * sizeof (md5crypt_tmp_t); break;
- case 1600: size_tmps = kernel_blocks * sizeof (md5crypt_tmp_t); break;
- case 1800: size_tmps = kernel_blocks * sizeof (sha512crypt_tmp_t); break;
- case 2100: size_tmps = kernel_blocks * sizeof (dcc2_tmp_t); break;
- case 2500: size_tmps = kernel_blocks * sizeof (wpa_tmp_t); break;
- case 3200: size_tmps = kernel_blocks * sizeof (bcrypt_tmp_t); break;
- case 5200: size_tmps = kernel_blocks * sizeof (pwsafe3_tmp_t); break;
- case 5800: size_tmps = kernel_blocks * sizeof (androidpin_tmp_t); break;
- case 6211:
- case 6212:
- case 6213: size_tmps = kernel_blocks * sizeof (tc_tmp_t); break;
- case 6221:
- case 6222:
- case 6223: size_tmps = kernel_blocks * sizeof (tc64_tmp_t); break;
- case 6231:
- case 6232:
- case 6233: size_tmps = kernel_blocks * sizeof (tc_tmp_t); break;
- case 6241:
- case 6242:
- case 6243: size_tmps = kernel_blocks * sizeof (tc_tmp_t); break;
- case 6300: size_tmps = kernel_blocks * sizeof (md5crypt_tmp_t); break;
- case 6400: size_tmps = kernel_blocks * sizeof (sha256aix_tmp_t); break;
- case 6500: size_tmps = kernel_blocks * sizeof (sha512aix_tmp_t); break;
- case 6600: size_tmps = kernel_blocks * sizeof (agilekey_tmp_t); break;
- case 6700: size_tmps = kernel_blocks * sizeof (sha1aix_tmp_t); break;
- case 6800: size_tmps = kernel_blocks * sizeof (lastpass_tmp_t); break;
- case 7100: size_tmps = kernel_blocks * sizeof (pbkdf2_sha512_tmp_t); break;
- case 7200: size_tmps = kernel_blocks * sizeof (pbkdf2_sha512_tmp_t); break;
- case 7400: size_tmps = kernel_blocks * sizeof (sha256crypt_tmp_t); break;
- case 7900: size_tmps = kernel_blocks * sizeof (drupal7_tmp_t); break;
- case 8200: size_tmps = kernel_blocks * sizeof (pbkdf2_sha512_tmp_t); break;
- case 8800: size_tmps = kernel_blocks * sizeof (androidfde_tmp_t); break;
- case 8900: size_tmps = kernel_blocks * sizeof (scrypt_tmp_t); break;
- case 9000: size_tmps = kernel_blocks * sizeof (pwsafe2_tmp_t); break;
- case 9100: size_tmps = kernel_blocks * sizeof (lotus8_tmp_t); break;
- case 9200: size_tmps = kernel_blocks * sizeof (pbkdf2_sha256_tmp_t); break;
- case 9300: size_tmps = kernel_blocks * sizeof (scrypt_tmp_t); break;
- case 9400: size_tmps = kernel_blocks * sizeof (office2007_tmp_t); break;
- case 9500: size_tmps = kernel_blocks * sizeof (office2010_tmp_t); break;
- case 9600: size_tmps = kernel_blocks * sizeof (office2013_tmp_t); break;
- case 10000: size_tmps = kernel_blocks * sizeof (pbkdf2_sha256_tmp_t); break;
- case 10200: size_tmps = kernel_blocks * sizeof (cram_md5_t); break;
- case 10300: size_tmps = kernel_blocks * sizeof (saph_sha1_tmp_t); break;
- case 10500: size_tmps = kernel_blocks * sizeof (pdf14_tmp_t); break;
- case 10700: size_tmps = kernel_blocks * sizeof (pdf17l8_tmp_t); break;
- case 10900: size_tmps = kernel_blocks * sizeof (pbkdf2_sha256_tmp_t); break;
- case 11300: size_tmps = kernel_blocks * sizeof (bitcoin_wallet_tmp_t); break;
- case 11600: size_tmps = kernel_blocks * sizeof (seven_zip_tmp_t); break;
- case 11900: size_tmps = kernel_blocks * sizeof (pbkdf2_md5_tmp_t); break;
- case 12000: size_tmps = kernel_blocks * sizeof (pbkdf2_sha1_tmp_t); break;
- case 12100: size_tmps = kernel_blocks * sizeof (pbkdf2_sha512_tmp_t); break;
- case 12200: size_tmps = kernel_blocks * sizeof (ecryptfs_tmp_t); break;
- case 12300: size_tmps = kernel_blocks * sizeof (oraclet_tmp_t); break;
- case 12400: size_tmps = kernel_blocks * sizeof (bsdicrypt_tmp_t); break;
- case 12500: size_tmps = kernel_blocks * sizeof (rar3_tmp_t); break;
- case 12700: size_tmps = kernel_blocks * sizeof (mywallet_tmp_t); break;
- case 12800: size_tmps = kernel_blocks * sizeof (pbkdf2_sha256_tmp_t); break;
- case 12900: size_tmps = kernel_blocks * sizeof (pbkdf2_sha256_tmp_t); break;
- case 13000: size_tmps = kernel_blocks * sizeof (pbkdf2_sha256_tmp_t); break;
- };
-
- // size_hooks
-
- if ((opts_type & OPTS_TYPE_HOOK12) || (opts_type & OPTS_TYPE_HOOK23))
- {
- // none yet
- }
-
- // now check if all device-memory sizes which depend on the kernel_accel amplifier are within its boundaries
- // if not, decrease amplifier and try again
-
- if (size_pws > device_param->device_maxmem_alloc)
- {
- kernel_accel--;
-
- continue;
- }
-
- if (size_tmps > device_param->device_maxmem_alloc)
- {
- kernel_accel--;
-
- continue;
- }
-
- if (size_hooks > device_param->device_maxmem_alloc)
- {
- kernel_accel--;
-
- continue;
- }
-
- if ((size_pws + size_tmps + size_hooks) > device_param->device_global_mem)
- {
- kernel_accel--;
-
- continue;
- }
-
- break;
- }
-
- if (kernel_accel == 0)
- {
- log_error ("ERROR: Device #%u does not provide enough allocatable device-memory to handle hash-type %u", device_id + 1, data.hash_mode);
-
- return -1;
- }
-
- device_param->kernel_threads = kernel_threads;
- device_param->kernel_power_user = kernel_power;
- device_param->kernel_blocks_user = kernel_blocks;
-
- kernel_blocks_all += kernel_blocks;
-
- device_param->size_pws = size_pws;
- device_param->size_tmps = size_tmps;
- device_param->size_hooks = size_hooks;
-
- // we can optimize some stuff here...
-
uint size_root_css = SP_PW_MAX * sizeof (cs_t);
uint size_markov_css = SP_PW_MAX * CHARSIZ * sizeof (cs_t);
uint size_results = KERNEL_THREADS * sizeof (uint);
- device_param->size_results = size_results;
+ device_param->size_results = size_results;
uint size_rules = kernel_rules_cnt * sizeof (kernel_rule_t);
uint size_rules_c = KERNEL_RULES * sizeof (kernel_rule_t);
uint size_bfs = KERNEL_BFS * sizeof (bf_t);
uint size_tm = 32 * sizeof (bs_word_t);
- // scrypt stuff
+ // scryptV stuff
u64 size_scryptV = 1;
if (quiet == 0) log_info ("SCRYPT tmto optimizer value set to: %u, mem: %u\n", data.salts_buf[0].scrypt_tmto, size_scryptV);
}
+ /**
+ * create input buffers on device : calculate size of dynamic size memory buffers
+ */
+
+ uint kernel_threads = KERNEL_THREADS;
+
+ // some algorithms need a fixed kernel-threads count (mostly because of shared memory usage)
+
+ if (hash_mode == 3200) kernel_threads = 8;
+ if (hash_mode == 9000) kernel_threads = 8;
+
+ /**
+ * some algorithms need a fixed kernel-loops count
+ */
+
+ u32 kernel_loops_min = 1;
+ u32 kernel_loops_max = 1024;
+
+ if ((opts_type & OPTS_TYPE_PT_BITSLICE) && (attack_mode == ATTACK_MODE_BF))
+ {
+ const u32 kernel_loops_fixed = 1024;
+
+ device_param->kernel_loops = kernel_loops_fixed;
+
+ kernel_loops_min = kernel_loops_fixed;
+ kernel_loops_max = kernel_loops_fixed;
+ }
+
+ if (hash_mode == 8900)
+ {
+ const u32 kernel_loops_fixed = 1;
+
+ device_param->kernel_loops = kernel_loops_fixed;
+
+ kernel_loops_min = kernel_loops_fixed;
+ kernel_loops_max = kernel_loops_fixed;
+ }
+
+ if (hash_mode == 9300)
+ {
+ const u32 kernel_loops_fixed = 1;
+
+ device_param->kernel_loops = kernel_loops_fixed;
+
+ kernel_loops_min = kernel_loops_fixed;
+ kernel_loops_max = kernel_loops_fixed;
+ }
+
+ if (hash_mode == 12500)
+ {
+ const u32 kernel_loops_fixed = ROUNDS_RAR3 / 16;
+
+ device_param->kernel_loops = kernel_loops_fixed;
+
+ kernel_loops_min = kernel_loops_fixed;
+ kernel_loops_max = kernel_loops_fixed;
+ }
+
+ device_param->kernel_loops_min = kernel_loops_min;
+ device_param->kernel_loops_max = kernel_loops_max;
+
+ // find out if we would request too much memory on memory blocks which are based on kernel_accel
+
+ uint size_pws = 4;
+ uint size_tmps = 4;
+ uint size_hooks = 4;
+
+ uint kernel_accel_min = 1;
+ uint kernel_accel_max = device_param->kernel_accel;
+
+ while (kernel_accel_max)
+ {
+ uint kernel_power_max = device_processors * kernel_threads * kernel_accel_max;
+
+ // size_pws
+
+ size_pws = kernel_power_max * sizeof (pw_t);
+
+ // size_tmps
+
+ switch (hash_mode)
+ {
+ case 400: size_tmps = kernel_power_max * sizeof (phpass_tmp_t); break;
+ case 500: size_tmps = kernel_power_max * sizeof (md5crypt_tmp_t); break;
+ case 501: size_tmps = kernel_power_max * sizeof (md5crypt_tmp_t); break;
+ case 1600: size_tmps = kernel_power_max * sizeof (md5crypt_tmp_t); break;
+ case 1800: size_tmps = kernel_power_max * sizeof (sha512crypt_tmp_t); break;
+ case 2100: size_tmps = kernel_power_max * sizeof (dcc2_tmp_t); break;
+ case 2500: size_tmps = kernel_power_max * sizeof (wpa_tmp_t); break;
+ case 3200: size_tmps = kernel_power_max * sizeof (bcrypt_tmp_t); break;
+ case 5200: size_tmps = kernel_power_max * sizeof (pwsafe3_tmp_t); break;
+ case 5800: size_tmps = kernel_power_max * sizeof (androidpin_tmp_t); break;
+ case 6211: size_tmps = kernel_power_max * sizeof (tc_tmp_t); break;
+ case 6212: size_tmps = kernel_power_max * sizeof (tc_tmp_t); break;
+ case 6213: size_tmps = kernel_power_max * sizeof (tc_tmp_t); break;
+ case 6221: size_tmps = kernel_power_max * sizeof (tc64_tmp_t); break;
+ case 6222: size_tmps = kernel_power_max * sizeof (tc64_tmp_t); break;
+ case 6223: size_tmps = kernel_power_max * sizeof (tc64_tmp_t); break;
+ case 6231: size_tmps = kernel_power_max * sizeof (tc_tmp_t); break;
+ case 6232: size_tmps = kernel_power_max * sizeof (tc_tmp_t); break;
+ case 6233: size_tmps = kernel_power_max * sizeof (tc_tmp_t); break;
+ case 6241: size_tmps = kernel_power_max * sizeof (tc_tmp_t); break;
+ case 6242: size_tmps = kernel_power_max * sizeof (tc_tmp_t); break;
+ case 6243: size_tmps = kernel_power_max * sizeof (tc_tmp_t); break;
+ case 6300: size_tmps = kernel_power_max * sizeof (md5crypt_tmp_t); break;
+ case 6400: size_tmps = kernel_power_max * sizeof (sha256aix_tmp_t); break;
+ case 6500: size_tmps = kernel_power_max * sizeof (sha512aix_tmp_t); break;
+ case 6600: size_tmps = kernel_power_max * sizeof (agilekey_tmp_t); break;
+ case 6700: size_tmps = kernel_power_max * sizeof (sha1aix_tmp_t); break;
+ case 6800: size_tmps = kernel_power_max * sizeof (lastpass_tmp_t); break;
+ case 7100: size_tmps = kernel_power_max * sizeof (pbkdf2_sha512_tmp_t); break;
+ case 7200: size_tmps = kernel_power_max * sizeof (pbkdf2_sha512_tmp_t); break;
+ case 7400: size_tmps = kernel_power_max * sizeof (sha256crypt_tmp_t); break;
+ case 7900: size_tmps = kernel_power_max * sizeof (drupal7_tmp_t); break;
+ case 8200: size_tmps = kernel_power_max * sizeof (pbkdf2_sha512_tmp_t); break;
+ case 8800: size_tmps = kernel_power_max * sizeof (androidfde_tmp_t); break;
+ case 8900: size_tmps = kernel_power_max * sizeof (scrypt_tmp_t); break;
+ case 9000: size_tmps = kernel_power_max * sizeof (pwsafe2_tmp_t); break;
+ case 9100: size_tmps = kernel_power_max * sizeof (lotus8_tmp_t); break;
+ case 9200: size_tmps = kernel_power_max * sizeof (pbkdf2_sha256_tmp_t); break;
+ case 9300: size_tmps = kernel_power_max * sizeof (scrypt_tmp_t); break;
+ case 9400: size_tmps = kernel_power_max * sizeof (office2007_tmp_t); break;
+ case 9500: size_tmps = kernel_power_max * sizeof (office2010_tmp_t); break;
+ case 9600: size_tmps = kernel_power_max * sizeof (office2013_tmp_t); break;
+ case 10000: size_tmps = kernel_power_max * sizeof (pbkdf2_sha256_tmp_t); break;
+ case 10200: size_tmps = kernel_power_max * sizeof (cram_md5_t); break;
+ case 10300: size_tmps = kernel_power_max * sizeof (saph_sha1_tmp_t); break;
+ case 10500: size_tmps = kernel_power_max * sizeof (pdf14_tmp_t); break;
+ case 10700: size_tmps = kernel_power_max * sizeof (pdf17l8_tmp_t); break;
+ case 10900: size_tmps = kernel_power_max * sizeof (pbkdf2_sha256_tmp_t); break;
+ case 11300: size_tmps = kernel_power_max * sizeof (bitcoin_wallet_tmp_t); break;
+ case 11600: size_tmps = kernel_power_max * sizeof (seven_zip_tmp_t); break;
+ case 11900: size_tmps = kernel_power_max * sizeof (pbkdf2_md5_tmp_t); break;
+ case 12000: size_tmps = kernel_power_max * sizeof (pbkdf2_sha1_tmp_t); break;
+ case 12100: size_tmps = kernel_power_max * sizeof (pbkdf2_sha512_tmp_t); break;
+ case 12200: size_tmps = kernel_power_max * sizeof (ecryptfs_tmp_t); break;
+ case 12300: size_tmps = kernel_power_max * sizeof (oraclet_tmp_t); break;
+ case 12400: size_tmps = kernel_power_max * sizeof (bsdicrypt_tmp_t); break;
+ case 12500: size_tmps = kernel_power_max * sizeof (rar3_tmp_t); break;
+ case 12700: size_tmps = kernel_power_max * sizeof (mywallet_tmp_t); break;
+ case 12800: size_tmps = kernel_power_max * sizeof (pbkdf2_sha256_tmp_t); break;
+ case 12900: size_tmps = kernel_power_max * sizeof (pbkdf2_sha256_tmp_t); break;
+ case 13000: size_tmps = kernel_power_max * sizeof (pbkdf2_sha256_tmp_t); break;
+ };
+
+ // size_hooks
+
+ if ((opts_type & OPTS_TYPE_HOOK12) || (opts_type & OPTS_TYPE_HOOK23))
+ {
+ // none yet
+ }
+
+ // now check if all device-memory sizes which depend on the kernel_accel_max amplifier are within its boundaries
+ // if not, decrease amplifier and try again
+
+ int skip = 0;
+
+ if (size_pws > device_param->device_maxmem_alloc) skip = 1;
+ if (size_tmps > device_param->device_maxmem_alloc) skip = 1;
+ if (size_hooks > device_param->device_maxmem_alloc) skip = 1;
+
+ if (( bitmap_size
+ + bitmap_size
+ + bitmap_size
+ + bitmap_size
+ + bitmap_size
+ + bitmap_size
+ + bitmap_size
+ + bitmap_size
+ + size_bfs
+ + size_combs
+ + size_digests
+ + size_esalts
+ + size_hooks
+ + size_markov_css
+ + size_plains
+ + size_pws
+ + size_results
+ + size_root_css
+ + size_rules
+ + size_rules_c
+ + size_salts
+ + size_scryptV
+ + size_shown
+ + size_tm
+ + size_tmps) > device_param->device_global_mem) skip = 1;
+
+ if (skip == 1)
+ {
+ kernel_accel_max--;
+
+ continue;
+ }
+
+ break;
+ }
+
+ if (kernel_accel_max == 0)
+ {
+ log_error ("Device #%u: Device does not provide enough allocatable device-memory to handle hash-type %u", device_id + 1, data.hash_mode);
+
+ return -1;
+ }
+
+ device_param->kernel_accel_min = kernel_accel_min;
+ device_param->kernel_accel_max = kernel_accel_max;
+
+ if (kernel_accel_max < kernel_accel)
+ {
+ if (quiet == 0) log_info ("Device #%u: Reduced maximum kernel-accel to %u", device_id + 1, kernel_accel_max);
+
+ device_param->kernel_accel = kernel_accel_max;
+ }
+
+ const u32 kernel_accel = device_param->kernel_accel;
+
+ device_param->size_pws = size_pws;
+ device_param->size_tmps = size_tmps;
+ device_param->size_hooks = size_hooks;
+
+ // do not confuse kernel_accel_max with kernel_accel here
+
+ const u32 kernel_power = device_processors * kernel_threads * kernel_accel;
+
+ device_param->kernel_threads = kernel_threads;
+ device_param->kernel_power_user = kernel_power;
+
+ kernel_power_all += kernel_power;
+
/**
* default building options
*/
#endif // HAVE_HWMON && HAVE_ADL
}
- data.kernel_blocks_all = kernel_blocks_all;
+ data.kernel_power_all = kernel_power_all;
if (data.quiet == 0) log_info ("");
memset (device_param->exec_ms, 0, EXEC_CACHE * sizeof (double));
- device_param->kernel_power = device_param->kernel_power_user;
- device_param->kernel_blocks = device_param->kernel_blocks_user;
+ device_param->kernel_power = device_param->kernel_power_user;
device_param->outerloop_pos = 0;
device_param->outerloop_left = 0;
device_param->words_done = 0;
}
- data.kernel_blocks_div = 0;
+ data.kernel_power_div = 0;
// figure out some workload
if ((wordlist_mode == WL_MODE_FILE) || (wordlist_mode == WL_MODE_MASK))
{
- if (data.words_base < kernel_blocks_all)
+ if (data.words_base < kernel_power_all)
{
if (quiet == 0)
{