OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.dg/] [tree-ssa/] [pr36881.c] - Rev 399

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

/* PR tree-optimization/36881 */
/* { dg-do compile { target fpic } } */
/* { dg-options "-O2 -fpic -fdump-tree-switchconv-all" } */
 
const char *foo (int i)
{
  const char *p;
  switch (i)
    {
    case 0:
    case 6: p = ""; break;
    case 1:
    case 7: p = "abc"; break;
    case 2:
    case 8: p = "def"; break;
    default: p = "ghi"; break;
    }
  return p;
}
 
/* { dg-final { scan-assembler-not "CSWTCH" } } */
/* { dg-final { scan-tree-dump "need runtime relocations" "switchconv" } } */
/* { dg-final { cleanup-tree-dump "switchconv" } } */
 

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.