Lines Matching refs:nsec
230 _PyTime_ObjectToTimespec(PyObject *obj, time_t *sec, long *nsec, in _PyTime_ObjectToTimespec() argument
233 return _PyTime_ObjectToDenominator(obj, sec, nsec, SEC_TO_NS, round); in _PyTime_ObjectToTimespec()
270 long long nsec; in _PyTime_FromNanosecondsObject() local
280 nsec = PyLong_AsLongLong(obj); in _PyTime_FromNanosecondsObject()
281 if (nsec == -1 && PyErr_Occurred()) { in _PyTime_FromNanosecondsObject()
289 t = (_PyTime_t)nsec; in _PyTime_FromNanosecondsObject()
298 _PyTime_t t, nsec; in pytime_fromtimespec() local
315 nsec = ts->tv_nsec; in pytime_fromtimespec()
317 assert(nsec >= 0); in pytime_fromtimespec()
318 if (t > _PyTime_MAX - nsec) { in pytime_fromtimespec()
326 t += nsec; in pytime_fromtimespec()
638 _PyTime_t secs, nsec; in _PyTime_AsTimespec() local
641 nsec = t % SEC_TO_NS; in _PyTime_AsTimespec()
642 if (nsec < 0) { in _PyTime_AsTimespec()
643 nsec += SEC_TO_NS; in _PyTime_AsTimespec()
647 assert(0 <= nsec && nsec < SEC_TO_NS); in _PyTime_AsTimespec()
648 ts->tv_nsec = nsec; in _PyTime_AsTimespec()