URL
https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk
Only display areas with differences |
Details |
Blame |
View Log
Rev 313 |
Rev 384 |
/* { dg-do compile } */
|
/* { dg-do compile } */
|
/* { dg-options "-O0" } */
|
/* { dg-options "-O0" } */
|
/* Check that function arguments aren't assigned and copied to stack slots
|
/* Check that function arguments aren't assigned and copied to stack slots
|
in naked functions. This ususally happens at -O0 (presumably for
|
in naked functions. This ususally happens at -O0 (presumably for
|
better debugging), but is highly undesirable if we haven't created
|
better debugging), but is highly undesirable if we haven't created
|
a stack frame. */
|
a stack frame. */
|
void __attribute__((naked))
|
void __attribute__((naked))
|
foo(int n)
|
foo(int n)
|
{
|
{
|
__asm__ volatile ("frob r0\n");
|
__asm__ volatile ("frob r0\n");
|
}
|
}
|
/* { dg-final { scan-assembler "\tfrob r0" } } */
|
/* { dg-final { scan-assembler "\tfrob r0" } } */
|
/* { dg-final { scan-assembler-not "\tstr" } } */
|
/* { dg-final { scan-assembler-not "\tstr" } } */
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.