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

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.2.2/] [gcc/] [testsuite/] [g++.old-deja/] [g++.other/] [builtins2.C] - Diff between revs 149 and 154

Only display areas with differences | Details | Blame | View Log

Rev 149 Rev 154
// { dg-do run  }
// { dg-do run  }
// { dg-options "-O2" }
// { dg-options "-O2" }
// Test whether this builtin minimally works in G++.
// Test whether this builtin minimally works in G++.
// Origin: Kaveh Ghazi Jan 16, 2001
// Origin: Kaveh Ghazi Jan 16, 2001
// Copyright (C) 2001 Free Software Foundation.
// Copyright (C) 2001 Free Software Foundation.
//
//
namespace std
namespace std
{
{
  extern "C" void abort (void);
  extern "C" void abort (void);
}
}
int main ()
int main ()
{
{
  using namespace std;
  using namespace std;
  char f[16];
  char f[16];
  if (::__builtin_strcpy (f, "hello world") != f
  if (::__builtin_strcpy (f, "hello world") != f
      || __builtin_memcmp (f, "hello world", sizeof ("hello world")))
      || __builtin_memcmp (f, "hello world", sizeof ("hello world")))
    abort ();
    abort ();
  return 0;
  return 0;
}
}
 
 

powered by: WebSVN 2.1.0

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