GPU calculations disabled again
This commit is contained in:
1 parent
d30a915890
commit
38b3df9405
1 file changed
+10
-10
@@ -317,7 +317,7 @@ internal static partial class PrimeOrderCalculator
|
|||||||
bool gpuStackRemainders = false;
|
bool gpuStackRemainders = false;
|
||||||
GpuPow2ModStatus status = GpuPow2ModStatus.Unavailable;
|
GpuPow2ModStatus status = GpuPow2ModStatus.Unavailable;
|
||||||
|
|
||||||
// if (allowGpuBatch && IsGpuPow2Allowed)
|
if (allowGpuBatch && IsGpuPow2Allowed)
|
||||||
{
|
{
|
||||||
if (batchSize <= StackGpuBatchSize)
|
if (batchSize <= StackGpuBatchSize)
|
||||||
{
|
{
|
||||||
@@ -638,17 +638,17 @@ internal static partial class PrimeOrderCalculator
|
|||||||
|
|
||||||
private static bool Pow2EqualsOneCpu(ulong exponent, ulong prime, in MontgomeryDivisorData divisorData)
|
private static bool Pow2EqualsOneCpu(ulong exponent, ulong prime, in MontgomeryDivisorData divisorData)
|
||||||
{
|
{
|
||||||
// if (IsGpuPow2Allowed)
|
if (IsGpuPow2Allowed)
|
||||||
// {
|
{
|
||||||
ulong remainder = exponent.Pow2MontgomeryModWindowedGpu(divisorData, false);
|
// ulong remainder = exponent.Pow2MontgomeryModWindowedGpu(divisorData, false);
|
||||||
// GpuPow2ModStatus status = PrimeOrderGpuHeuristics.TryPow2Mod(exponent, prime, out ulong remainder, divisorData);
|
GpuPow2ModStatus status = PrimeOrderGpuHeuristics.TryPow2Mod(exponent, prime, out ulong remainder, divisorData);
|
||||||
// if (status == GpuPow2ModStatus.Success)
|
if (status == GpuPow2ModStatus.Success)
|
||||||
// {
|
{
|
||||||
return remainder == 1UL;
|
return remainder == 1UL;
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
|
|
||||||
// return exponent.Pow2MontgomeryModWindowedCpu(divisorData, keepMontgomery: false) == 1UL;
|
return exponent.Pow2MontgomeryModWindowedCpu(divisorData, keepMontgomery: false) == 1UL;
|
||||||
}
|
}
|
||||||
|
|
||||||
// [ThreadStatic]
|
// [ThreadStatic]
|
||||||
|
|||||||
Reference in new issue
Block a user