OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [opt/] [const6.C] - Blame information for rev 693

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 693 jeremybenn
// PR target/39179
2
// Make sure that we don't optimize away the load from K::k.
3
// { dg-options "-O2" }
4
// { dg-final { scan-assembler _ZN1K1kE } }
5
 
6
struct K {
7
    static const unsigned k;
8
};
9
extern "C" void abort (void);
10
int main() {
11
    if ( K::k != 1 )
12
      abort ();
13
    return 1;
14
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.