Commit 5a774ca17 for imagemagick.org

commit 5a774ca17c5e25c16e54798876e85c03f8c5c033
Author: Cristy <urban-warrior@imagemagick.org>
Date:   Sat Jul 18 21:12:27 2026 -0400

    increase threads for PHASE metric

diff --git a/MagickCore/compare.c b/MagickCore/compare.c
index b6481bd4c..a2bfcf4cf 100644
--- a/MagickCore/compare.c
+++ b/MagickCore/compare.c
@@ -1763,7 +1763,7 @@ static MagickBooleanType GetPHASESimilarity(const Image *image,
   reconstruct_view=AcquireVirtualCacheView(reconstruct_image,exception);
 #if defined(MAGICKCORE_OPENMP_SUPPORT)
   #pragma omp parallel for schedule(static) shared(area,similarity,status) \
-    magick_number_threads(image,image,rows,1)
+    magick_number_threads(image,image,rows,0.25)
 #endif
   for (y=0; y < (ssize_t) rows; y++)
   {
diff --git a/MagickCore/thread-private.h b/MagickCore/thread-private.h
index 067c2270b..9ae8edbcb 100644
--- a/MagickCore/thread-private.h
+++ b/MagickCore/thread-private.h
@@ -48,7 +48,7 @@ extern "C" {
 #endif

 static inline int GetMagickNumberThreads(const Image *source,
-  const Image *destination,const size_t chunk,const int factor)
+  const Image *destination,const size_t chunk,const double factor)
 {
   const CacheType
     destination_type = (CacheType) GetImagePixelCacheType(destination),
@@ -57,7 +57,7 @@ static inline int GetMagickNumberThreads(const Image *source,
   size_t
     max_threads = (size_t) GetMagickResourceLimit(ThreadResource),
     number_threads = 1UL,
-    rows_per_thread = 64UL*factor; /* target workload per thread */
+    rows_per_thread = CastDoubleToSizeT(64.0*factor);  /* workload */

   /*
     Determine number of threads based on rows per thread heuristic.