Date: 14 Jan 2000 14:15:55 -0500 From: evs@telerama.com To: keramida@ceid.upatras.gr, Giorgos Keramidas <charon@hades.hell.gr> Cc: Mikhail Evstiounin <evstiounin@adelphia.net>, freebsd-questions@FreeBSD.ORG Subject: Re: Volatile variables Message-ID: <20000114191555.19421.qmail@speedbuggy.telerama.com> In-Reply-To: <20000114194012.B31079@hades.hell.gr> References: <010701bf5e3b$a6dac5e0$a9353018@evstiouninadelphia.net.pit.adelphia.net> <20000114194012.B31079@hades.hell.gr>
next in thread | previous in thread | raw e-mail | index | archive | help
Quoting Giorgos Keramidas <charon@hades.hell.gr>: > definition of sig_atomic_t is `int', as in: > > typedef int sig_atomic_t; it's exactly what I expected. Thanx. > > I did try to change `volatile int k' to `volatile sig_atomic_t k' and > the generated code did not have any difference from before. The same > sequence of `movl $0,k ; movl $1,k' statements was produced. > > Since in FreeBSD, the sizeof(int) returns 4, and the system runs on a > machine with 32-bits, the size of a word is apparently the largest > value that can be atomically set from the underlying hardware. Not sure, starting from 8087, and looking at PIII - you can operate with 64 bits integer. It's very easy to implement 64 bit integer arithmetics using either FPU only, or FPU/double word combination and adc/subc commands. Implicit conclusion - you do have underlying hardware to set 64 bit value. > > Ciao. > > -- > Giorgos Keramidas, < keramida @ ceid . upatras . gr > > "What we have to learn to do, we learn by doing." [Aristotle] > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message > Sincerely yours Mikhail Evstiounin To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20000114191555.19421.qmail>