public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug ada/50571] New: [4.6/4.7 Regression] Undesirable folding in "m" constrained asm operands
@ 2011-09-30  6:04 jakub at gcc dot gnu.org
  2011-09-30  6:26 ` [Bug inline-asm/50571] " jakub at gcc dot gnu.org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: jakub at gcc dot gnu.org @ 2011-09-30  6:04 UTC (permalink / raw)
  To: gcc-bugs

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

             Bug #: 50571
           Summary: [4.6/4.7 Regression] Undesirable folding in "m"
                    constrained asm operands
    Classification: Unclassified
           Product: gcc
           Version: 4.6.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: ada
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: jakub@gcc.gnu.org


static const int var[4] = { 1, 2, 3, 4 };

void
foo (void)
{
  __asm volatile ("" : : "m" (*(int *) var));
}

warns at -O2:
warning: use of memory input without lvalue in asm operand 0 is deprecated
[enabled by default]

although the source has there addressable memory.  The problem is that
gimple-fold transformed this into "m" (1), which is deprecated.


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2012-06-12  2:45 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-09-30  6:04 [Bug ada/50571] New: [4.6/4.7 Regression] Undesirable folding in "m" constrained asm operands jakub at gcc dot gnu.org
2011-09-30  6:26 ` [Bug inline-asm/50571] " jakub at gcc dot gnu.org
2011-09-30  6:55 ` jakub at gcc dot gnu.org
2011-09-30 15:23 ` jakub at gcc dot gnu.org
2011-09-30 18:38 ` jakub at gcc dot gnu.org
2011-09-30 20:12 ` jakub at gcc dot gnu.org
2012-06-12  2:45 ` amker at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).