0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-11-25 16:22:35 +01:00

ircd::ctx: Eliminate branch in prof::mark() stack.

This commit is contained in:
Jason Volk 2020-08-02 06:42:04 -07:00
parent ea039f29b5
commit 1a433f7274

View file

@ -1629,8 +1629,15 @@ noexcept
_total.event[uint8_t(e)]++;
// Increment the ticker for the context's instance
if(likely(current))
current->profile.event[uint8_t(e)]++;
static uint64_t dummy;
uint64_t &ticker
{
current?
current->profile.event[uint8_t(e)]:
dummy
};
++ticker;
}
void