Stan Math Library
4.9.0
Automatic Differentiation
Loading...
Searching...
No Matches
chainable_alloc.hpp
Go to the documentation of this file.
1
#ifndef STAN_MATH_REV_CORE_CHAINABLE_ALLOC_HPP
2
#define STAN_MATH_REV_CORE_CHAINABLE_ALLOC_HPP
3
4
#include <
stan/math/rev/core/chainablestack.hpp
>
5
6
namespace
stan
{
7
namespace
math {
8
16
class
chainable_alloc
{
17
public
:
18
chainable_alloc
() {
19
ChainableStack::instance_
->
var_alloc_stack_
.push_back(
this
);
20
}
21
virtual
~chainable_alloc
() {}
22
};
23
24
}
// namespace math
25
}
// namespace stan
26
#endif
chainablestack.hpp
stan::math::chainable_alloc::chainable_alloc
chainable_alloc()
Definition
chainable_alloc.hpp:18
stan::math::chainable_alloc::~chainable_alloc
virtual ~chainable_alloc()
Definition
chainable_alloc.hpp:21
stan::math::chainable_alloc
A chainable_alloc is an object which is constructed and destructed normally but the memory lifespan i...
Definition
chainable_alloc.hpp:16
stan
The lgamma implementation in stan-math is based on either the reentrant safe lgamma_r implementation ...
Definition
fvar.hpp:9
stan::math::AutodiffStackSingleton::AutodiffStackStorage::var_alloc_stack_
std::vector< ChainableAllocT * > var_alloc_stack_
Definition
autodiffstackstorage.hpp:106
stan::math::AutodiffStackSingleton::instance_
static thread_local AutodiffStackStorage * instance_
Definition
autodiffstackstorage.hpp:118
stan
math
rev
core
chainable_alloc.hpp
[
Stan Home Page
]
© 2011–2019, Stan Development Team.