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

Subversion Repositories openrisc

[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc1/] [gcc/] [testsuite/] [g++.dg/] [ext/] [visibility/] [arm3.C] - Blame information for rev 338

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 301 jeremybenn
// { dg-do compile { target arm*-*-*eabi* } }
2
// { dg-require-dll "" }
3
// { dg-options "-fvisibility=hidden" }
4
 
5
/* From ARM C++ ABI \S 3.2.5.5:
6
 
7
     A class should be exported unless explicitly tagged otherwise.
8
 
9
   This admonition applies even on DLL-based systems where hidden
10
   visibility is the default.  We want -fvisibility=hidden to behave
11
   identically to the situation where hidden visibility is the
12
   hard-wired default.  So, both A and B are exported classes.
13
 
14
   Furthermore:
15
 
16
     If CAG symbol Y names one of the impedimenta associated with an
17
     exported class X:
18
 
19
     ...
20
 
21
     * Otherwise, if X has no key function:
22
 
23
       - Y is exported from ... each DLL that refers to X and uses Y.
24
 
25
   So, the type-info and virtual-table symbols associated with A and B
26
   must be exported.  */
27
 
28
// { dg-final { scan-not-hidden "_ZTI1A" } }
29
// { dg-final { scan-not-hidden "_ZTS1A" } }
30
// { dg-final { scan-not-hidden "_ZTV1B" } }
31
// { dg-final { scan-not-hidden "_ZTI1B" } }
32
// { dg-final { scan-not-hidden "_ZTS1B" } }
33
 
34
struct A {};
35
struct B : virtual public A {};
36
B b;

powered by: WebSVN 2.1.0

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