D
djc
- kind of new to c# and very new to multithreading -
1) are all objects (value and reference type variables and objects/classes)
safe to *read* from multiple threads? I know if something is not marked as
thread safe you have to use one of the synchronization features to
coordinate *writes* to it but what about simple reads of some global
variables that are accessible to many threads?
2) can I queue up several threads to run a *static* method (each thread
running it with different parameters) without any special synchronization
code? or do I need to make the method not static so a seperate copy of it's
class is instantiated each time?
confused.
1) are all objects (value and reference type variables and objects/classes)
safe to *read* from multiple threads? I know if something is not marked as
thread safe you have to use one of the synchronization features to
coordinate *writes* to it but what about simple reads of some global
variables that are accessible to many threads?
2) can I queue up several threads to run a *static* method (each thread
running it with different parameters) without any special synchronization
code? or do I need to make the method not static so a seperate copy of it's
class is instantiated each time?
confused.