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/] [execute/] [simd-4.c] - Blame information for rev 154

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

Line No. Rev Author Line
1 149 jeremybenn
typedef int __attribute__((vector_size(8))) v2si;
2
long long s64;
3
 
4
static inline long long
5
__ev_convert_s64 (v2si a)
6
{
7
  return (long long) a;
8
}
9
 
10
int main()
11
{
12
  union { long long ll; int i[2]; } endianness_test;
13
  endianness_test.ll = 1;
14
  int little_endian = endianness_test.i[0];
15
  s64 = __ev_convert_s64 ((v2si){1,0xffffffff});
16
  if (s64 != (little_endian ? 0xffffffff00000001LL : 0x1ffffffffLL))
17
    abort ();
18
  return 0;
19
}

powered by: WebSVN 2.1.0

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