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

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [g++.dg/] [tree-ssa/] [pr31307.C] - Rev 310

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

/* { dg-do compile } */
/* { dg-options "-O -fdump-tree-optimized" } */

union MY_M128
{
  double i;
};

struct RegFile
{
  MY_M128 dst[4];
};

__inline__ __attribute__((always_inline)) static void
MEM_OPT_LOAD(MY_M128* reg, double* mem)
{
  reg[0].i = *mem;
}

void _ia32_movntdq (double *, double);

__inline__ __attribute__((always_inline)) static void
MEM_OPT_STORE(MY_M128* reg, double* mem)
{
  _ia32_movntdq ((double*)mem, (double)reg[0].i);
}

double _mm_adds_epu8 (double __A, double __B);

int test(unsigned char *d)
{ 
  RegFile r;
  MEM_OPT_LOAD((r.dst) , ((double*) d)); 
  r.dst[0].i = _mm_adds_epu8(r.dst[0].i, r.dst[0].i);
  MEM_OPT_STORE((r.dst), (double*) d);
  return 0;
}

/* { dg-final { scan-tree-dump-not "r.dst" "optimized" } } */
/* { dg-final { cleanup-tree-dump "optimized" } } */

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.