template<class T >
bool Valgrind::CheckDefined |
( |
const T &value |
OPM_UNUSED | ) |
|
|
inline |
Make valgrind complain if any of the memory occupied by an object is undefined.
Please note that this does not check whether the destinations of an object's pointers or references are defined. Also, for performance reasons the compiler might insert "padding bytes" between within the objects which leads to false positives.
Example:
- Template Parameters
-
T | The type of the object which ought to be checked |
- Parameters
-
value | the object which valgrind should check |
- Returns
- true iff there are no undefined bytes in the memory occupied by the object.
Referenced by Opm::LinearMaterial< TraitsT, ParamsT >::capillaryPressures(), Opm::PengRobinsonParams< Scalar >::checkDefined(), Opm::FluidStateExplicitTemperatureModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, false > >::checkDefined(), Opm::FluidStateExplicitViscosityModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, false > >::checkDefined(), Opm::FluidStateExplicitPressureModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, false > >::checkDefined(), Opm::FluidStateExplicitSaturationModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, false > >::checkDefined(), Opm::FluidStateExplicitEnthalpyModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, true > >::checkDefined(), Opm::FluidStateExplicitFugacityModule< Scalar, FluidSystem::numPhases, FluidSystem::numComponents, CompositionalFluidState< Scalar, FluidSystem, false > >::checkDefined(), Opm::FluidStateExplicitDensityModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, false > >::checkDefined(), Opm::FluidStateEquilibriumTemperatureModule< Scalar, FluidSystem::numPhases, CompositionalFluidState< Scalar, FluidSystem, false > >::checkDefined(), Opm::FluidStateExplicitCompositionModule< Scalar, FluidSystem, CompositionalFluidState< Scalar, FluidSystem, false > >::checkDefined(), Opm::ThreePhaseParkerVanGenuchtenParams< TraitsT >::checkDefined(), Opm::SaturationOverlayFluidState< FluidState >::checkDefined(), Opm::PressureOverlayFluidState< FluidState >::checkDefined(), Opm::TemperatureOverlayFluidState< FluidState >::checkDefined(), Opm::PengRobinsonParamsMixture< Scalar, FluidSystem, gasPhaseIdx, true >::checkDefined(), Opm::PengRobinson< Scalar >::computeMolarVolume(), Opm::LocalAd::Evaluation< ScalarT, VarSetTag, numVars >::createConstant(), Opm::FluidSystems::BrineCO2< Scalar, CO2Tables >::density(), Opm::LiveOilPvt< Scalar >::density(), Opm::FluidSystems::H2ON2LiquidPhase< Scalar, useComplexRelations >::enthalpy(), Opm::FluidSystems::BrineCO2< Scalar, CO2Tables >::enthalpy(), Opm::FluidSystems::H2OAir< Scalar, H2Otype, useComplexRelations >::enthalpy(), Opm::FluidSystems::H2ON2< Scalar, useComplexRelations >::enthalpy(), Opm::UniformXTabulated2DFunction< Scalar >::eval(), Opm::LiveOilPvt< Scalar >::formationVolumeFactor(), Opm::FluidSystems::H2OAirMesitylene< Scalar >::fugacityCoefficient(), Opm::BinaryCoeff::Brine_CO2< Scalar, CO2Tables, verbose >::fugacityCoefficientCO2(), Opm::H2O< Scalar >::gasPressure(), Opm::Somerton< FluidSystem, ScalarT, ParamsT >::heatConductivity(), Opm::NcpFlash< Scalar, FluidSystem >::linearize_(), Opm::LinearMaterial< TraitsT, ParamsT >::pcgn(), Opm::LinearMaterial< TraitsT, ParamsT >::pcnw(), Opm::LinearMaterial< TraitsT, ParamsT >::relativePermeabilities(), Opm::FluidSystems::BlackOil< Scalar >::saturatedOilFormationVolumeFactor(), Opm::FluidStateExplicitCompositionModule< Scalar, FluidSystem, CompositionalFluidState< Scalar, FluidSystem, false > >::setMoleFraction(), Opm::NcpFlash< Scalar, FluidSystem >::setQuantity_(), Opm::NcpFlash< Scalar, FluidSystem >::setQuantityRaw_(), Opm::CompositionFromFugacities< Scalar, FluidSystem, Evaluation >::solve(), Opm::NcpFlash< Scalar, FluidSystem >::solve(), Opm::CompositionFromFugacities< Scalar, FluidSystem, Evaluation >::solveIdealMix_(), Opm::PengRobinsonParamsMixture< Scalar, FluidSystem, gasPhaseIdx, true >::updateMix(), Opm::Spe5ParameterCache< Scalar, FluidSystem >::updateMix_(), Opm::PengRobinsonParamsMixture< Scalar, FluidSystem, gasPhaseIdx, true >::updatePure(), and Opm::FluidSystems::BrineCO2< Scalar, CO2Tables >::viscosity().
template<class T >
bool Valgrind::CheckDefined |
( |
const T *value |
OPM_UNUSED, |
|
|
int size |
OPM_UNUSED |
|
) |
| |
|
inline |
Make valgrind complain if any of the the memory occupied by a C-style array objects is undefined.
Please note that this does not check whether the destinations of an object's pointers or references are defined. Also, for performance reasons the compiler might insert "padding bytes" between within the objects which leads to false positives.
Example:
- Template Parameters
-
T | The type of the object which ought to be checked |
- Parameters
-
value | Pointer to the first object of the array. |
size | The size of the array in number of objects |
- Returns
- true iff there are no undefined bytes in the memory occupied by the array.
bool Valgrind::IsRunning |
( |
| ) |
|
|
inline |
Returns whether the program is running under Valgrind or not.
template<class T >
void Valgrind::SetDefined |
( |
const T &value |
OPM_UNUSED | ) |
|
|
inline |
template<class T >
void Valgrind::SetDefined |
( |
const T *value |
OPM_UNUSED, |
|
|
int n |
OPM_UNUSED |
|
) |
| |
|
inline |
Make the memory on which a C-style array of objects resides defined.
Example:
- Template Parameters
-
T | The type of the object which valgrind should consider as defined |
- Parameters
-
value | Pointer to the first object of the array. |
n | The size of the array in number of objects |
template<class T >
void Valgrind::SetNoAccess |
( |
const T &value |
OPM_UNUSED | ) |
|
|
inline |
Make valgrind complain if an object's memory is accessed.
Example:
- Template Parameters
-
T | The type of the object which valgrind should complain if accessed |
- Parameters
-
value | The object which's memory valgrind should complain if accessed |
template<class T >
void Valgrind::SetNoAccess |
( |
const T *value |
OPM_UNUSED, |
|
|
int size |
OPM_UNUSED |
|
) |
| |
|
inline |
Make valgrind complain if the memory of a C-style array of objects is accessed.
Example:
int i[3] = {0, 1, 2};
int j = i[1];
- Parameters
-
value | Pointer to the first object of the array. |
size | The size of the array in number of objects |
template<class T >
void Valgrind::SetUndefined |
( |
const T &value |
OPM_UNUSED | ) |
|
|
inline |
Make the memory on which an object resides undefined in valgrind runs.
Example:
- Template Parameters
-
T | The type of the object which ought to be set to undefined |
- Parameters
-
value | The object which's memory valgrind should be told is undefined |
Referenced by Opm::BrooksCoreyParams< TraitsT >::BrooksCoreyParams(), Opm::PengRobinson< Scalar >::computeMolarVolume(), Opm::FluidSystems::H2OAir< Scalar, H2Otype, useComplexRelations >::density(), Opm::FluidStateNullEnthalpyModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, false > >::enthalpy(), Opm::FluidStateEquilibriumTemperatureModule< Scalar, FluidSystem::numPhases, CompositionalFluidState< Scalar, FluidSystem, false > >::FluidStateEquilibriumTemperatureModule(), Opm::FluidStateExplicitCompositionModule< Scalar, FluidSystem, CompositionalFluidState< Scalar, FluidSystem, false > >::FluidStateExplicitCompositionModule(), Opm::FluidStateExplicitDensityModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, false > >::FluidStateExplicitDensityModule(), Opm::FluidStateExplicitEnthalpyModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, true > >::FluidStateExplicitEnthalpyModule(), Opm::FluidStateExplicitFugacityModule< Scalar, FluidSystem::numPhases, FluidSystem::numComponents, CompositionalFluidState< Scalar, FluidSystem, false > >::FluidStateExplicitFugacityModule(), Opm::FluidStateExplicitPressureModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, false > >::FluidStateExplicitPressureModule(), Opm::FluidStateExplicitSaturationModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, false > >::FluidStateExplicitSaturationModule(), Opm::FluidStateExplicitTemperatureModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, false > >::FluidStateExplicitTemperatureModule(), Opm::FluidStateExplicitViscosityModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, false > >::FluidStateExplicitViscosityModule(), Opm::FluidStateNullEnthalpyModule< Scalar, FluidSystem::numPhases, NonEquilibriumFluidState< Scalar, FluidSystem, false > >::internalEnergy(), Opm::NcpFlash< Scalar, FluidSystem >::linearize_(), Opm::FluidStateExplicitCompositionModule< Scalar, FluidSystem, CompositionalFluidState< Scalar, FluidSystem, false > >::setMoleFraction(), Opm::NcpFlash< Scalar, FluidSystem >::solve(), and Opm::Spe5ParameterCache< Scalar, FluidSystem >::Spe5ParameterCache().
template<class T >
void Valgrind::SetUndefined |
( |
const T *value |
OPM_UNUSED, |
|
|
int size |
OPM_UNUSED |
|
) |
| |
|
inline |
Make the memory on which an array of object resides undefined in valgrind runs.
Example:
- Template Parameters
-
T | The type of the object which ought to be set to undefined |
- Parameters
-
value | Pointer to the first object of the array. |
size | The size of the array in number of objects |
|