aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.apple/asm-function-11.c
blob: e75f3c132f8b9e9a06ffaedd2ac6c986febb1d84 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/* APPLE LOCAL file CW asm blocks */
/* { dg-do assemble { target powerpc*-*-* } } */
/* { dg-options "-fasm-blocks" } */

struct tDummyStruct
{
	unsigned long fDummy;
	unsigned long fSample;
};

asm void foo()
{
	lwz		r1,-8+tDummyStruct.fSample(r2)
	stw		r1,-8+tDummyStruct.fSample(r2)
	lwz		r1,-8-(tDummyStruct.fSample-tDummyStruct.fDummy)(r2)
	stw		r1,-8-(tDummyStruct.fSample-tDummyStruct.fDummy)(r2)
}

int main (int argc, char * const argv[]) 
{
	foo();
}