From c17393ffc627a90a35f49db675b2a3438222c037 Mon Sep 17 00:00:00 2001 From: Andrea Valassi Date: Thu, 15 Aug 2024 17:53:40 +0200 Subject: [PATCH] [cmsdy] in dsample.f of pp_dy3j.mad P0_gux_taptamggux (also copied to gg_tt.mad), simplify the code for xbin_min and xbin_max (part1 of #969) There is indeed a small but clear improvement CUDACPP_RUNTIME_DISABLEFPE=1 ./build.cuda_d_inl0_hrd0/madevent_cuda < /tmp/avalassi/input_dy3j_x1_cudacpp [COUNTERS] PROGRAM TOTAL : 4.5494s [COUNTERS] Fortran Other ( 0 ) : 0.1688s [COUNTERS] Fortran Initialise(I/O) ( 1 ) : 0.0669s [COUNTERS] Fortran Random2Momenta ( 3 ) : 3.2830s for 1170103 events => throughput is 2.81E-06 events/s [COUNTERS] Fortran PDFs ( 4 ) : 0.1061s for 49152 events => throughput is 2.16E-06 events/s [COUNTERS] Fortran UpdateScaleCouplings ( 5 ) : 0.1361s for 16384 events => throughput is 8.31E-06 events/s [COUNTERS] Fortran Reweight ( 6 ) : 0.0519s for 16384 events => throughput is 3.17E-06 events/s [COUNTERS] Fortran Unweight(LHE-I/O) ( 7 ) : 0.0649s for 16384 events => throughput is 3.96E-06 events/s [COUNTERS] Fortran SamplePutPoint ( 8 ) : 0.1366s for 1170103 events => throughput is 1.17E-07 events/s [COUNTERS] CudaCpp Initialise ( 11 ) : 0.4745s [COUNTERS] CudaCpp Finalise ( 12 ) : 0.0257s [COUNTERS] CudaCpp MEs ( 19 ) : 0.0349s for 16384 events => throughput is 2.13E-06 events/s [COUNTERS] OVERALL NON-MEs ( 21 ) : 4.5145s [COUNTERS] OVERALL MEs ( 22 ) : 0.0349s for 16384 events => throughput is 2.13E-06 events/s --- epochX/cudacpp/gg_tt.mad/Source/dsample.f | 3 +-- epochX/cudacpp/pp_dy3j.mad/Source/dsample.f | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/epochX/cudacpp/gg_tt.mad/Source/dsample.f b/epochX/cudacpp/gg_tt.mad/Source/dsample.f index a5e066edc0..c594d5e9d1 100644 --- a/epochX/cudacpp/gg_tt.mad/Source/dsample.f +++ b/epochX/cudacpp/gg_tt.mad/Source/dsample.f @@ -1307,8 +1307,7 @@ subroutine sample_get_x(wgt, x, j, ipole, xmin, xmax) c write(*,'(a,4e15.4)') 'Bad limits',xbin_min,xbin_max, c & xmin,xmax c xbin_max=xbin_min+1d-10 - xbin_max = xbin(xmax,minvar(j,ipole)) - xbin_min = min(xbin(xmin,minvar(j,ipole)), xbin_max) + xbin_min = min(xbin_min, xbin_max) endif c c Line which allows us to keep choosing same x diff --git a/epochX/cudacpp/pp_dy3j.mad/Source/dsample.f b/epochX/cudacpp/pp_dy3j.mad/Source/dsample.f index a5e066edc0..c594d5e9d1 100644 --- a/epochX/cudacpp/pp_dy3j.mad/Source/dsample.f +++ b/epochX/cudacpp/pp_dy3j.mad/Source/dsample.f @@ -1307,8 +1307,7 @@ subroutine sample_get_x(wgt, x, j, ipole, xmin, xmax) c write(*,'(a,4e15.4)') 'Bad limits',xbin_min,xbin_max, c & xmin,xmax c xbin_max=xbin_min+1d-10 - xbin_max = xbin(xmax,minvar(j,ipole)) - xbin_min = min(xbin(xmin,minvar(j,ipole)), xbin_max) + xbin_min = min(xbin_min, xbin_max) endif c c Line which allows us to keep choosing same x