OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [gcc.c-torture/] [unsorted/] [xopt.c] - Rev 853

Go to most recent revision | Compare with Previous | Blame | View Log

proc1 (a)
     unsigned a;
{
  return (a >> 20) & 0x010fffff;
}
 
proc2 (a)
     unsigned a;
{
  return (a << 17) & 0xfffff001;
}
 
proc3 (a)
     unsigned a;
{
  return (a & 0xff00000a) >> 25;
}
 
proc4 (a)
     unsigned a;
{
  return (a & 0x100000ff) << 25;
}
 
proc5 (a)
     unsigned a;
{
  return (unsigned char) (a >> 24);
}
 
proc6 (a)
     unsigned a;
{
  return ((unsigned char) a) << 30;
}
 

Go to most recent revision | Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.