Article View: gnu.gcc.bug
Article #6284Re: Recent serial port lossage
From: Charles Hannum
Date: Sun, 07 Jan 1996 00:00
Date: Sun, 07 Jan 1996 00:00
33 lines
1347 bytes
1347 bytes
I've tracked this down to what I believe to be a bug in GCC 2.7.2. Basically, if you have code of the form: volatile int foo; ... foo |= 0x80000000; ... in many (all?) cases, `gcc -O3' now compiles it as: movl _foo,%e?? orl $0x80000000,%e?? movl %e??,_foo rather than the obvious: orl $0x80000000,_foo This probably has something to do with pipeline scheduling on the Pentium, but it's not clear to me that the new behaviour, regardless of its relative performance, is *correct* for a `volatile' variable. In particular, I don't see a way to make sig_atomic_t work correctly. In general, it makes `volatile' nearly useless. At any rate, I've worked around the problem in this case, but I wouldn't be surprised if it causes other random bugs. If you've been having problems, please update your kernel sources after tonight's update, and let me know if your problems persist.
Technical Details
Message-ID:
<199601072229.RAA28966@cs1.boston.deshaw.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 113d02,b3c82d44300e73ca X-Google-Attributes: gid113d02,public From: Charles-Hannum@deshaw.com (Charles Hannum) Subject: Re: Recent serial port lossage Date: 1996/01/07 Message-ID: <199601072229.RAA28966@cs1.boston.deshaw.com> X-Deja-AN: 134699060 distribution: gnu sender: daemon@cis.ohio-state.edu organization: GNUs Not Usenet newsgroups: gnu.gcc.bug