URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Details |
Compare with Previous |
View Log
Line No. |
Rev |
Author |
Line |
1 |
704 |
jeremybenn |
/* Test if constant CFStrings get placed in the correct section and that the
|
2 |
|
|
layout of the object is correct for both m32 and m64. */
|
3 |
|
|
/* Contributed by Ziemowit Laski <zlaski@apple.com> */
|
4 |
|
|
|
5 |
|
|
/* So far, CFString is darwin-only. */
|
6 |
|
|
/* { dg-do compile { target *-*-darwin* } } */
|
7 |
|
|
/* { dg-skip-if "NeXT only" { *-*-* } { "-fgnu-runtime" } { "" } } */
|
8 |
|
|
/* { dg-options "-mconstant-cfstrings" } */
|
9 |
|
|
|
10 |
|
|
typedef const struct __CFString * CFStringRef;
|
11 |
|
|
static CFStringRef appKey = (CFStringRef) @"com.apple.soundpref";
|
12 |
|
|
|
13 |
|
|
void *foo (void)
|
14 |
|
|
{
|
15 |
|
|
void *a = (void *)appKey;
|
16 |
|
|
return a;
|
17 |
|
|
}
|
18 |
|
|
|
19 |
|
|
/* { dg-final { scan-assembler ".section __DATA, __cfstring" } } */
|
20 |
|
|
/* { dg-final { scan-assembler ".long\t___CFConstantStringClassReference\n\t.long\t1992\n\t.long\t.*\n\t.long\t19\n" { target { *-*-darwin* && { ! lp64 } } } } } */
|
21 |
|
|
/* { dg-final { scan-assembler ".quad\t___CFConstantStringClassReference\n\t.long\t1992\n\t.space 4\n\t.quad\t.*\n\t.quad\t19\n" { target { *-*-darwin* && { lp64 } } } } } */
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.