c# - Is Stopwatch.ElapsedTicks threadsafe? -



c# - Is Stopwatch.ElapsedTicks threadsafe? -

if have shared system.diagnostics.stopwatch instance, can multiple threads phone call shared.elapsedticks in safe manner , accurate results?

is there difference in terms of thread-safety/accuracy between using shared instance of stopwatch in way, , using static gettimestamp() method?

i'm measuring intervals of around 180ms, , finding using shared instance giving me larger spread of results, including important number shorter expect.

the machine has multiple cpus (2 * intel x5550 it's worth)

from msdn: "any instance members not guaranteed thread safe."

c# stopwatch

Comments

Popular posts from this blog

c# - Move local mssql database to webhosted MYSQL -

java - How to pass parameters between Request-Scoped Controllers? -

string - what is the difference between "some" == "some\0" and strcmp("some","some\0") in c++? -