mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-08-03 18:50:39 +08:00
Fix computation of CwiseUnaryOp::CoeffReadCost when the cost of the nested expression is Dynamic
This commit is contained in:
parent
d0980c7706
commit
1eea595550
@ -47,7 +47,7 @@ struct traits<CwiseUnaryOp<UnaryOp, XprType> >
|
||||
Flags = _XprTypeNested::Flags & (
|
||||
HereditaryBits | LinearAccessBit | AlignedBit
|
||||
| (functor_traits<UnaryOp>::PacketAccess ? PacketAccessBit : 0)),
|
||||
CoeffReadCost = _XprTypeNested::CoeffReadCost + functor_traits<UnaryOp>::Cost
|
||||
CoeffReadCost = _XprTypeNested::CoeffReadCost==Dynamic ? Dynamic : (_XprTypeNested::CoeffReadCost + functor_traits<UnaryOp>::Cost)
|
||||
};
|
||||
};
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user