FreeBSD/sys/compat/cloudabi/cloudabi_futex.c
/* Converts a relative timestamp to an sbintime. */
Converts a relative timestamp to an sbintime.
Converts a relative timestamp to an sbintime .
static sbintime_t
futex_queue_convert_timestamp_relative(cloudabi_timestamp_t ts)
{
	cloudabi_timestamp_t s, ns;
	s = ts / 1000000000;
	ns = ts % 1000000000;
	if (s > INT32_MAX)
		return (INT64_MAX);
	return ((s << 32) + (ns << 32) / 1000000000);
}
static sbintime_t futex_queue_convert_timestamp_relative ( cloudabi_timestamp_t ts ) { cloudabi_timestamp_t s , ns ; s = ts / 1000000000 ; ns = ts % 1000000000 ; if ( s > INT32_MAX ) return ( INT64_MAX ) ; return ( ( s << 32 ) + ( ns << 32 ) / 1000000000 ) ; }
Converts a relative timestamp to an sbintime.
Converts a relative timestamp to an sbintime .