![]() |
|
|||
File indexing completed on 2025-04-13 22:49:41
0001 #ifndef DataFormats_Math_logic_h 0002 #define DataFormats_Math_logic_h 0003 0004 namespace reco { 0005 // this function can be called with any boolean expressions as the parameters 0006 // this forces the evaluation of both expressions (faster if the expressions are simple) 0007 // and applying && to two bools avoids branching (jump instruction) 0008 // whereas applying && to the two original expressions may cause branching 0009 // this is an alternative to using the bitwise and operator (&), which never short-circuits 0010 inline bool branchless_and(bool a, bool b) { return a && b; } 0011 } // namespace reco 0012 0013 #endif
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.2.1 LXR engine. The LXR team |
![]() ![]() |