MCPcopy Create free account
hub / github.com/catboost/catboost / FastExpWithInfInplace

Function FastExpWithInfInplace

catboost/libs/helpers/math_utils.cpp:14–27  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

12namespace NCB {
13
14 void FastExpWithInfInplace(double* x, size_t count) {
15 #if defined(_x86_64_) || defined(_i386_)
16 if (NX86::CachedHaveAVX() && NX86::CachedHaveAVX2()) {
17 FastExpInplaceAvx2(x, count);
18 } else if (NX86::CachedHaveSSE2()) {
19 FastExpInplaceSse2(x, count);
20 } else
21 #endif
22 {
23 for (size_t i = 0; i < count; ++i) {
24 x[i] = std::exp(x[i]);
25 }
26 }
27 }
28
29}

Callers 15

CalcDersMethod · 0.85
CalcDersMultiMethod · 0.85
CalcDersMethod · 0.85
ExpApproxIfFunction · 0.85
operator[]Method · 0.85
EvalErrorsWithLeavesFunction · 0.85
EvalSingleThreadMethod · 0.85
EvalSingleQueryMethod · 0.85
CalcSoftmaxFunction · 0.85
CalcExponentFunction · 0.85

Calls 4

FastExpInplaceAvx2Function · 0.85
CachedHaveSSE2Function · 0.85
FastExpInplaceSse2Function · 0.85
expFunction · 0.50

Tested by

no test coverage detected