[Bug target/56028] New: Splitting a 64-bit volatile store

amonakov at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri Jan 18 11:07:00 GMT 2013


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56028

             Bug #: 56028
           Summary: Splitting a 64-bit volatile store
    Classification: Unclassified
           Product: gcc
           Version: 4.7.2
               URL: http://gcc.gnu.org/ml/gcc-patches/2013-01/msg00870.htm
                    l
            Status: UNCONFIRMED
          Keywords: wrong-code
          Severity: normal
          Priority: P3
         Component: target
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: amonakov@gcc.gnu.org
                CC: eugeni.stepanov@gmail.com, khlebnikov@openvz.org,
                    mkl@pengutronix.de, paulmck@linux.vnet.ibm.com,
                    ubizjak@gmail.com, valery.bickov+gcc@gmail.com
            Target: i?86-*-* x86_64-*-*


Created attachment 29201
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=29201
test case

+++ This bug was initially created as a clone of Bug #55981 +++

As suggested in the parent bug, this is a separate report dealing specifically
with splitting of a 64-bit volatile (not necessarily atomic) store of an
immediate value into 32-bit accesses.  Comment 10 of the original report says:

> > > Btw, the same happens if atomic is replaced with "volatile unsigned long y" -
> > > which does not violate the standard, but may be considered undesirable by some.
> > > I don't have a strong opinion about this.
> > 
> > This really does need to be fixed in the "volatile unsigned long y" case, or
> > device drivers storing constants to device registers will break.  So please fix
> > this for volatiles as well as atomics.
> 
> Please open a new PR for this.

It looks to me that volatiles should not be allowed as offsetable operands, but
let's discuss this in a separate PR.



More information about the Gcc-bugs mailing list