1 /* { dg-do compile } */
2 /* { dg-options "-fstack-protector-all -Os" } */
3
4 void __attribute__ ((noipa))
5 f (void)
6 {
7 volatile int x;
8 asm volatile ("" :::
9 "r0", "r1", "r2", "r3", "r4", "r5", "r6", "r7",
10 "r8", "r9", "r10", "r11", "r12", "r14");
11 }
12
13 /* The register clobbers above should not generate any single LDRs or STRs;
14 all registers should be pushed and popped using register lists. The only
15 STRs should therefore be those associated with the stack protector tests
16 themselves.
17
18 Make sure the address of the canary is not spilled and reloaded,
19 since that would give the attacker an opportunity to change the
20 canary value. */
21 /* { dg-final { scan-assembler-times {\tstr\t} 1 } } */