From 7f86a6724a9b8ae50c9a4e6b22ab896e5347daf6 Mon Sep 17 00:00:00 2001 From: Tobias Meyer Andersen Date: Tue, 7 Jan 2025 08:49:36 +0100 Subject: [PATCH] remove unnecessary template argument --- tests/gpuistl/test_gpuPvt.cu | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/tests/gpuistl/test_gpuPvt.cu b/tests/gpuistl/test_gpuPvt.cu index 189b708e2..b1403190d 100644 --- a/tests/gpuistl/test_gpuPvt.cu +++ b/tests/gpuistl/test_gpuPvt.cu @@ -92,17 +92,17 @@ __global__ void gpuEvaluateUniformTabulated2DFunction(GpuTab gpuTab, Evaluation* // Kernel using a CO2 object on the GPU __global__ void gpuCO2GasViscosity(GpuViewCO2Tables gpuViewCo2Tables, Evaluation* temp, Evaluation* pressure, double* result) { - *result = GpuCO2::gasViscosity(gpuViewCo2Tables, *temp, *pressure, true).value(); + *result = GpuCO2::gasViscosity(gpuViewCo2Tables, *temp, *pressure, true).value(); } // Kernel using a SimpleHuDuanH20 object on a GPU __global__ void huDuanLiquidDensity(Evaluation* temp, Evaluation* pressure, double* result) { - *result = HuDuan::liquidDensity(*temp, *pressure, true).value(); + *result = HuDuan::liquidDensity(*temp, *pressure, true).value(); } // Kernel using a BrineDynamic object on a GPU __global__ void brineDynamicLiquidEnthalpy(Evaluation* temp, Evaluation* pressure, Evaluation* salinity, double* result) { - *result = BrineDyn::liquidEnthalpy(*temp, *pressure, *salinity).value(); + *result = BrineDyn::liquidEnthalpy(*temp, *pressure, *salinity).value(); } // Kernel using a Brine_CO2 object on a GPU @@ -112,12 +112,12 @@ __global__ void brineCO2GasDiffCoeff(GpuViewCO2Tables co2tables, Evaluation* tem // Kernel using a Co2GasPvt object on a GPU __global__ void co2GasPvtInternalEnergy(GpuViewCo2Pvt gpuViewCo2Pvt, Evaluation* temp, Evaluation* pressure, double* result) { - *result = gpuViewCo2Pvt.internalEnergy(1, *temp, *pressure, Evaluation(0.4), Evaluation(0.0)).value(); + *result = gpuViewCo2Pvt.internalEnergy(1, *temp, *pressure, Evaluation(0.4), Evaluation(0.0)).value(); } // Kernel using a BrineCo2Pvt object on a GPU __global__ void brineCo2PvtInternalEnergy(GpuViewBrineCo2Pvt gpuViewBrineCo2Pvt, Evaluation* temp, Evaluation* pressure, Evaluation* rs, Evaluation* saltConcentration, double* result) { - *result = gpuViewBrineCo2Pvt.internalEnergy(1, *temp, *pressure, *rs, *saltConcentration).value(); + *result = gpuViewBrineCo2Pvt.internalEnergy(1, *temp, *pressure, *rs, *saltConcentration).value(); } // Helper function to launch a kernel and retrieve the result on the CPU to reduce code duplicatoin @@ -202,7 +202,7 @@ BOOST_FIXTURE_TEST_CASE(TestEvaluateUniformTabulated2DFunctionOnGpu, Fixture) { BOOST_FIXTURE_TEST_CASE(TestUseCO2OnGpu, Fixture) { // use the CO2 tables to aquire the viscosity at 290[K] and 2e5[Pa] - double viscosityReference = Opm::CO2>>::gasViscosity(co2Tables, temp, pressure, true).value(); + double viscosityReference = Opm::CO2>>::gasViscosity(co2Tables, temp, pressure, true).value(); GpuBufCo2Tables gpuBufCo2Table = Opm::gpuistl::move_to_gpu, GpuB>(co2Tables); GpuViewCO2Tables gpuViewCo2Table = Opm::gpuistl::make_view(gpuBufCo2Table); @@ -217,7 +217,7 @@ BOOST_FIXTURE_TEST_CASE(TestUseCO2OnGpu, Fixture) { BOOST_FIXTURE_TEST_CASE(TestUseH2OOnGpu, Fixture) { // use the CO2 tables to aquire the densityReference at 290[K] and 2e5[Pa] - double densityReference = HuDuan::liquidDensity(temp, pressure, true).value(); + double densityReference = HuDuan::liquidDensity(temp, pressure, true).value(); gpuComputedResultOnCpu = launchKernelAndRetrieveResult(huDuanLiquidDensity, gpuTemp, gpuPressure); @@ -230,7 +230,7 @@ BOOST_FIXTURE_TEST_CASE(TestUseBrineDynamicOnGpu, Fixture) { Evaluation salinity(0.1); // [g/Kg] // use the CO2 tables to aquire the enthalpyReference at 290[K] and 2e5[Pa] - double enthalpyReference = BrineDyn::liquidEnthalpy(temp, pressure, salinity).value(); + double enthalpyReference = BrineDyn::liquidEnthalpy(temp, pressure, salinity).value(); // Allocate GPU memory for the Evaluation inputs Evaluation* gpuSalinity = nullptr; @@ -247,10 +247,10 @@ BOOST_FIXTURE_TEST_CASE(TestUseBrineDynamicOnGpu, Fixture) { BOOST_FIXTURE_TEST_CASE(TestBrine_CO2OnGPU, Fixture) { // use the CO2 tables to aquire the gasDiffCoeffReference at 290[K] and 2e5[Pa] - double gasDiffCoeffReference = CpuBrine_CO2::gasDiffCoeff(co2Tables, temp, pressure, true).value(); + double gasDiffCoeffReference = CpuBrine_CO2::gasDiffCoeff(co2Tables, temp, pressure, true).value(); // use the CO2 tables to aquire the viscosity at 290[K] and 2e5[Pa] - double viscosity = Opm::CO2>>::gasViscosity(co2Tables, temp, pressure, true).value(); + double viscosity = Opm::CO2>>::gasViscosity(co2Tables, temp, pressure, true).value(); GpuBufCo2Tables gpuBufCo2Table = Opm::gpuistl::move_to_gpu, GpuB>(co2Tables); GpuViewCO2Tables gpuViewCo2Table = Opm::gpuistl::make_view(gpuBufCo2Table); @@ -266,7 +266,7 @@ BOOST_FIXTURE_TEST_CASE(TestCo2GasPvt, Fixture) { std::vector salinities = {0.2, 0.3, 0.4}; CpuCo2Pvt cpuCo2Pvt(salinities); - double internalEnergyReference = cpuCo2Pvt.internalEnergy(1, temp, pressure, Evaluation(0.4), Evaluation(0.0)).value(); + double internalEnergyReference = cpuCo2Pvt.internalEnergy(1, temp, pressure, Evaluation(0.4), Evaluation(0.0)).value(); const GpuBufCo2Pvt gpuBufCo2Pvt = Opm::gpuistl::move_to_gpu(cpuCo2Pvt); const auto brineReferenceDensityCPUCopy = gpuBufCo2Pvt.getBrineReferenceDensity().asStdVector(); @@ -285,7 +285,7 @@ BOOST_FIXTURE_TEST_CASE(TestBrineCo2Pvt, Fixture) { std::vector salinities = {0.2, 0.3, 0.4}; CpuBrineCo2Pvt cpuBrineCo2Pvt(salinities); - double internalEnergyReference = cpuBrineCo2Pvt.internalEnergy(1, temp, pressure, rs, saltConcentration).value(); + double internalEnergyReference = cpuBrineCo2Pvt.internalEnergy(1, temp, pressure, rs, saltConcentration).value(); const GpuBufBrineCo2Pvt gpuBufBrineCo2Pvt = Opm::gpuistl::move_to_gpu(cpuBrineCo2Pvt); const GpuViewBrineCo2Pvt gpuViewBrineCo2Pvt = Opm::gpuistl::make_view(gpuBufBrineCo2Pvt);