This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: SimpleDateFormat thread problems?


>>>>> "Vladimir" == Vladimir Leven <vladimirl@wrx-ca.com> writes:

Vladimir> (which is updated by another thread, but presumably
Vladimir> this.time = System.currentTimeMillis is atomic?)

Assignment of a `long' is not guaranteed to be atomic.  This comes
from the JLS or perhaps the JVM spec, I forget.

Vladimir> Related question: Is there a way to dump the stack trace for a given
Vladimir> thread? I can only seem to look at the stack trace for the currently
Vladimir> running thread.

In gdb, just switch to the thread you're interested in with the
"thread" command, then "bt".

Outside of gdb, no, I don't think there is a way.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]