Home
last modified time | relevance | path

Searched refs:nanoseconds (Results 1 – 25 of 214) sorted by relevance

123456789

/external/protobuf/csharp/src/Google.Protobuf/WellKnownTypes/
DDurationPartial.cs65 internal static bool IsNormalized(long seconds, int nanoseconds) in IsNormalized() argument
69 nanoseconds < MinNanoseconds || nanoseconds > MaxNanoseconds) in IsNormalized()
75 return Math.Sign(seconds) * Math.Sign(nanoseconds) != -1; in IsNormalized()
164 internal static Duration Normalize(long seconds, int nanoseconds) in Normalize() argument
167 int extraSeconds = nanoseconds / NanosecondsPerSecond; in Normalize()
169 nanoseconds -= extraSeconds * NanosecondsPerSecond; in Normalize()
172 if (seconds < 0 && nanoseconds > 0) in Normalize()
175 nanoseconds -= NanosecondsPerSecond; in Normalize()
177 else if (seconds > 0 && nanoseconds < 0) in Normalize()
180 nanoseconds += NanosecondsPerSecond; in Normalize()
[all …]
DTimestampPartial.cs48 private static bool IsNormalized(long seconds, int nanoseconds) => in IsNormalized() argument
49 nanoseconds >= 0 && in IsNormalized()
50 nanoseconds <= MaxNanos && in IsNormalized()
154 … int nanoseconds = (int) (dateTime.Ticks % TimeSpan.TicksPerSecond) * Duration.NanosecondsPerTick; in FromDateTime()
155 …turn new Timestamp { Seconds = secondsSinceBclEpoch - BclSecondsAtUnixEpoch, Nanos = nanoseconds }; in FromDateTime()
173 internal static Timestamp Normalize(long seconds, int nanoseconds) in Normalize() argument
175 int extraSeconds = nanoseconds / Duration.NanosecondsPerSecond; in Normalize()
177 nanoseconds -= extraSeconds * Duration.NanosecondsPerSecond; in Normalize()
179 if (nanoseconds < 0) in Normalize()
181 nanoseconds += Duration.NanosecondsPerSecond; in Normalize()
[all …]
/external/libcxx/test/std/utilities/time/time.duration/time.duration.nonmember/
Dop_mod_duration.pass.cpp27 std::chrono::nanoseconds ns1(15); in main()
28 std::chrono::nanoseconds ns2(6); in main()
29 std::chrono::nanoseconds r = ns1 % ns2; in main()
34 std::chrono::nanoseconds ns2(28); in main()
35 std::chrono::nanoseconds r = us1 % ns2; in main()
46 constexpr std::chrono::nanoseconds ns1(15); in main()
47 constexpr std::chrono::nanoseconds ns2(6); in main()
48 constexpr std::chrono::nanoseconds r = ns1 % ns2; in main()
53 constexpr std::chrono::nanoseconds ns2(28); in main()
54 constexpr std::chrono::nanoseconds r = us1 % ns2; in main()
Dop_divide_duration.pass.cpp28 std::chrono::nanoseconds ns1(15); in main()
29 std::chrono::nanoseconds ns2(5); in main()
34 std::chrono::nanoseconds ns2(5); in main()
49 constexpr std::chrono::nanoseconds ns1(15); in main()
50 constexpr std::chrono::nanoseconds ns2(5); in main()
55 constexpr std::chrono::nanoseconds ns2(5); in main()
Dop_times_rep.pass.cpp32 std::chrono::nanoseconds ns(3); in main()
40 constexpr std::chrono::nanoseconds ns(3); in main()
41 constexpr std::chrono::nanoseconds ns2 = ns * 5; in main()
43 constexpr std::chrono::nanoseconds ns3 = 6 * ns; in main()
Dop_mod_rep.pass.cpp27 std::chrono::nanoseconds ns(15); in main()
33 constexpr std::chrono::nanoseconds ns(15); in main()
34 constexpr std::chrono::nanoseconds ns2 = ns % 6; in main()
Dop_divide_rep.pass.cpp27 std::chrono::nanoseconds ns(15); in main()
33 constexpr std::chrono::nanoseconds ns(15); in main()
34 constexpr std::chrono::nanoseconds ns2 = ns / 5; in main()
/external/protobuf/php/src/Google/Protobuf/Internal/
DGPBUtil.php418 $nanoseconds = 0;
437 $nanoseconds = substr($timestamp, $periodIndex + 1, $nanosecondsLength);
438 $nanoseconds = intval($nanoseconds);
455 $value->setNanos($nanoseconds);
467 $nanoseconds = static::getNanosecondsForTimestamp($value->getNanos());
468 if (!empty($nanoseconds)) {
469 $nanoseconds = ".".$nanoseconds;
472 return $date->format("Y-m-d\TH:i:s".$nanoseconds."\Z");
577 public static function getNanosecondsForTimestamp($nanoseconds) argument
579 if ($nanoseconds == 0) {
[all …]
/external/grpc-grpc/src/cpp/util/
Dtime_cc.cc25 using std::chrono::nanoseconds;
41 nanoseconds nsecs = duration_cast<nanoseconds>(deadline - secs); in Timepoint2Timespec()
57 nanoseconds nsecs = duration_cast<nanoseconds>(deadline - secs); in TimepointHR2Timespec()
71 duration_cast<system_clock::time_point::duration>(nanoseconds(t.tv_nsec)); in Timespec2Timepoint()
/external/tensorflow/tensorflow/core/grappler/costs/
Dcost_estimator.h102 struct NanoSeconds : std::chrono::nanoseconds {
103 NanoSeconds() : std::chrono::nanoseconds(0) {} in NanoSeconds()
104 NanoSeconds(double d) : std::chrono::nanoseconds(static_cast<int64>(d)) {} in NanoSeconds()
105 NanoSeconds(const std::chrono::nanoseconds& d) in NanoSeconds()
106 : std::chrono::nanoseconds(d) {} in NanoSeconds()
107 NanoSeconds& operator=(const std::chrono::nanoseconds& d) {
108 std::chrono::nanoseconds::operator=(d);
118 return NanoSeconds(std::chrono::nanoseconds::max()); in infinity()
/external/ImageMagick/MagickCore/
Drandom.c359 nanoseconds, in GenerateEntropicChaos() local
407 nanoseconds=0; in GenerateEntropicChaos()
416 nanoseconds=(size_t) (1000UL*timer.tv_usec); in GenerateEntropicChaos()
428 nanoseconds=timer.tv_nsec; in GenerateEntropicChaos()
435 SetStringInfoLength(chaos,sizeof(nanoseconds)); in GenerateEntropicChaos()
436 SetStringInfoDatum(chaos,(unsigned char *) &nanoseconds); in GenerateEntropicChaos()
438 nanoseconds=0; in GenerateEntropicChaos()
440 nanoseconds=clock(); in GenerateEntropicChaos()
448 nanoseconds=timer.tms_utime+timer.tms_stime; in GenerateEntropicChaos()
451 SetStringInfoLength(chaos,sizeof(nanoseconds)); in GenerateEntropicChaos()
[all …]
/external/perfetto/protos/perfetto/metrics/android/
Dhwui_metric.proto30 // in nanoseconds.
36 // Number of GPU commands flushes and max/min/avg time per flush in nanoseconds.
43 // nanoseconds.
50 // in nanoseconds.
57 // max/min/avg time in nanoseconds.
64 // times to prepare a shader in nanoseconds.
69 // to prepare a shader in nanoseconds.
74 // a shader in nanoseconds.
/external/libcxx/src/
Dcondition_variable.cpp51 chrono::time_point<chrono::system_clock, chrono::nanoseconds> tp) _NOEXCEPT in __do_timed_wait()
57 nanoseconds d = tp.time_since_epoch(); in __do_timed_wait()
58 if (d > nanoseconds(0x59682F000000E941)) in __do_timed_wait()
59 d = nanoseconds(0x59682F000000E941); in __do_timed_wait()
Dchrono.cpp58 nanoseconds::period>>; in now()
122 return time_point(seconds(tp.tv_sec) + nanoseconds(tp.tv_nsec)); in now()
209 return time_point(seconds(tp.tv_sec) + nanoseconds(tp.tv_nsec)); in now()
/external/protobuf/csharp/compatibility_tests/v3.0.0/src/Google.Protobuf.Test/WellKnownTypes/
DTimestampTest.cs69 public void ToDateTime_OutOfRange(long seconds, int nanoseconds) in ToDateTime_OutOfRange() argument
71 var value = new Timestamp { Seconds = seconds, Nanos = nanoseconds }; in ToDateTime_OutOfRange()
81 public void ToDateTime_ValidBoundaries(long seconds, int nanoseconds) in ToDateTime_ValidBoundaries() argument
83 var value = new Timestamp { Seconds = seconds, Nanos = nanoseconds }; in ToDateTime_ValidBoundaries()
DDurationTest.cs106 public void ToTimeSpan_Invalid(long seconds, int nanoseconds) in ToTimeSpan_Invalid() argument
108 var duration = new Duration { Seconds = seconds, Nanos = nanoseconds }; in ToTimeSpan_Invalid()
117 public void ToTimeSpan_Valid(long seconds, int nanoseconds) in ToTimeSpan_Valid() argument
120 var duration = new Duration { Seconds = seconds, Nanos = nanoseconds }; in ToTimeSpan_Valid()
/external/ltp/testcases/open_posix_testsuite/conformance/interfaces/nanosleep/
Dcoverage.txt20 STARTSEC, STARTNSEC = the start time, seconds and nanoseconds, respectively
21 FINISHSEC, FINISHNSEC = the finish time, seconds and nanoseconds, respectively
22 slepts, sleptns = amount of seconds and nanoseconds slept, respectively
/external/tensorflow/tensorflow/compiler/xla/
Dutil.cc202 string HumanReadableNumOps(double flops, double nanoseconds, in HumanReadableNumOps() argument
204 if (nanoseconds == 0) { in HumanReadableNumOps()
207 double nano_flops = flops / nanoseconds; in HumanReadableNumOps()
221 string HumanReadableNumFlops(double flops, double nanoseconds) { in HumanReadableNumFlops() argument
222 return HumanReadableNumOps(flops, nanoseconds, "FL"); in HumanReadableNumFlops()
225 string HumanReadableNumTranscendentalOps(double trops, double nanoseconds) { in HumanReadableNumTranscendentalOps() argument
226 return HumanReadableNumOps(trops, nanoseconds, "TR"); in HumanReadableNumTranscendentalOps()
/external/protobuf/csharp/src/Google.Protobuf.Test/WellKnownTypes/
DDurationTest.cs106 public void ToTimeSpan_Invalid(long seconds, int nanoseconds) in ToTimeSpan_Invalid() argument
108 var duration = new Duration { Seconds = seconds, Nanos = nanoseconds }; in ToTimeSpan_Invalid()
117 public void ToTimeSpan_Valid(long seconds, int nanoseconds) in ToTimeSpan_Valid() argument
120 var duration = new Duration { Seconds = seconds, Nanos = nanoseconds }; in ToTimeSpan_Valid()
/external/libcxx/test/std/utilities/time/time.duration/time.duration.literals/
Dliterals.pass.cpp29 static_assert ( std::is_same<decltype( 3ns ), std::chrono::nanoseconds>::value, "" ); in main()
56 std::chrono::nanoseconds ns = 645ns; in main()
57 assert ( ns == std::chrono::nanoseconds(645)); in main()
/external/libcxx/test/std/thread/thread.threads/thread.thread.this/
Dsleep_until.pass.cpp30 std::chrono::nanoseconds ns = (t1 - t0) - ms; in main()
31 std::chrono::nanoseconds err = 5 * ms / 100; in main()
/external/tensorflow/tensorflow/core/platform/windows/
Denv_time.cc23 using std::chrono::nanoseconds;
67 return duration_cast<nanoseconds>(system_clock::now().time_since_epoch()) in NowNanos()
/external/protobuf/java/util/src/main/java/com/google/protobuf/util/
DTimeUtil.java221 public static Timestamp createTimestampFromNanos(long nanoseconds) { in createTimestampFromNanos() argument
222 return Timestamps.fromNanos(nanoseconds); in createTimestampFromNanos()
231 public static Duration createDurationFromNanos(long nanoseconds) { in createDurationFromNanos() argument
232 return Durations.fromNanos(nanoseconds); in createDurationFromNanos()
/external/swiftshader/third_party/llvm-7.0/llvm/unittests/Support/
DChrono.cpp45 system_clock::from_time_t(mktime(&TM)) + nanoseconds(123456789); in TEST()
72 TimePoint<nanoseconds> Nano = toTimePoint(TimeT); in TEST()
88 EXPECT_EQ("1 ns", formatv("{0}", nanoseconds(1)).str()); in TEST()
/external/guava/android/guava-testlib/src/com/google/common/testing/
DFakeTicker.java53 public FakeTicker advance(long nanoseconds) { in advance() argument
54 nanos.addAndGet(nanoseconds); in advance()

123456789