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 |
/* Verify that ldr is preferred on XScale for loading a 3 or 4 byte constant. */
|
/* Verify that ldr is preferred on XScale for loading a 3 or 4 byte constant. */
|
/* { dg-do compile } */
|
/* { dg-do compile } */
|
/* { dg-options "-mcpu=xscale -O" } */
|
/* { dg-options "-mcpu=xscale -O" } */
|
|
|
unsigned load4(void) __attribute__ ((naked));
|
unsigned load4(void) __attribute__ ((naked));
|
unsigned load4(void)
|
unsigned load4(void)
|
{
|
{
|
/* Best code would be:
|
/* Best code would be:
|
ldr r0, =65809
|
ldr r0, =65809
|
mov pc, lr */
|
mov pc, lr */
|
|
|
return 65809;
|
return 65809;
|
}
|
}
|
|
|
/* { dg-final { scan-assembler "ldr\[ ].*" } } */
|
/* { dg-final { scan-assembler "ldr\[ ].*" } } */
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.