Top "Nanotime" questions

Anything related to programming languages functions (or other similar facilities) allowing the retrieval of the current time with a resolution in the nanoseconds range.

Is System.nanoTime() completely useless?

As documented in the blog post Beware of System.nanoTime() in Java, on x86 systems, Java's System.nanoTime() returns the …

java nanotime
Conversion of nanoseconds to milliseconds and nanoseconds < 999999 in Java

I'm wondering what the most accurate way of converting a big nanoseconds value is to milliseconds and nanoseconds, with an …

java time milliseconds nanotime
How to convert epoch time with nanoseconds to human-readable?

I have a timestamp in epoch time with nanoseconds - e.g. 1360287003083988472 nanoseconds since 1970-01-01. The Python datetime objects …

python time epoch nanotime
Java 8 Instant.now() with nanosecond resolution?

Java 8's java.time.Instant stores in "nanosecond resolution", but using Instant.now() only provides millisecond resolution... Instant instant = Instant.…

java time nanotime
How to get a meaningful result from subtracting 2 nanoTime objects?

I created a filter that monitors the length of a request. long start = System.nanoTime(); ... long end = System.nanoTime(); How …

java performance nanotime
How to suspend a java thread for a small period of time, like 100 nanoseconds?

I know Thread.sleep() can make a java thread suspend for a while, like certain milliseconds and certain nanoseconds. But …

java sleep thread-sleep method-invocation nanotime
How to get time in PHP with nanosecond precision?

Is this even possible in PHP? If not, what is the highest precision available?

php datetime nanotime
What is the equivalent to System.nanoTime() in .NET?

The title is pretty much self-explanatory, I'm killing myself over this simplicity. Looked here, but it isn't much helpful.

c# java .net nanotime
java.sql.Timestamp way of storing NanoSeconds

java.sql.Timestamp constructor go like this: public Timestamp(long time) { super((time/1000)*1000); nanos = (int)((time%1000) * 1000000); if (nanos < 0) { nanos = 1000000000 + …

java jdbc timestamp nanotime
how correctly display nanotime to second conversion

I have a BFS algorithm to solve the 8-Puzzle, and one of the project requirements is to output the amount …

java nanotime