mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-22 22:44:34 +00:00
Optimize Int48 reconstruction.
This commit is contained in:
parent
76afef9117
commit
6f4a10be04
@ -125,10 +125,11 @@ public:
|
|||||||
|
|
||||||
tracy_force_inline int64_t Val() const
|
tracy_force_inline int64_t Val() const
|
||||||
{
|
{
|
||||||
int64_t val = 0;
|
int16_t hi;
|
||||||
memcpy( ((char*)&val)+2, m_val, 6 );
|
memcpy( &hi, m_val+4, 2 );
|
||||||
val >>= 16;
|
uint32_t lo;
|
||||||
return val;
|
memcpy( &lo, m_val, 4 );
|
||||||
|
return ( int64_t( hi ) << 32 ) | lo;
|
||||||
}
|
}
|
||||||
|
|
||||||
tracy_force_inline bool IsNonNegative() const
|
tracy_force_inline bool IsNonNegative() const
|
||||||
|
Loading…
Reference in New Issue
Block a user