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

Subversion Repositories openrisc_me

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /openrisc/trunk/gnu-src/gcc-4.5.1
    from Rev 311 to Rev 312
    Reverse comparison

Rev 311 → Rev 312

/gcc/testsuite/gcc.target/alpha/alpha.exp
0,0 → 1,41
# Copyright (C) 2005, 2007 Free Software Foundation, Inc.
 
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GCC; see the file COPYING3. If not see
# <http://www.gnu.org/licenses/>.
 
# GCC testsuite that uses the `dg.exp' driver.
 
# Exit immediately if this isn't an Alpha target.
if ![istarget alpha*-*-*] then {
return
}
 
# Load support procs.
load_lib gcc-dg.exp
 
# If a testcase doesn't have special options, use these.
global DEFAULT_CFLAGS
if ![info exists DEFAULT_CFLAGS] then {
set DEFAULT_CFLAGS " -ansi -pedantic-errors"
}
 
# Initialize `dg'.
dg-init
 
# Main loop.
dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/*.\[cS\]]] \
"" $DEFAULT_CFLAGS
 
# All done.
dg-finish
/gcc/testsuite/gcc.target/alpha/980217-1.c
0,0 → 1,39
/* Test float on alpha. */
 
/* { dg-do run } */
/* { dg-options "-mieee -O2" } */
 
extern void abort(void);
extern int printf(const char *, ...);
 
typedef int int32_t __attribute__ ((__mode__ ( __SI__ ))) ;
typedef union
{
float value;
int32_t word;
} ieee_float_shape_type;
 
int isinff(float x)
{
int32_t ix,t;
ieee_float_shape_type gf_u;
gf_u.value = x;
ix = gf_u.word;
printf ("%x\n", ix);
t = ix & 0x7fffffff;
t ^= 0x7f800000;
t |= -t;
return ~(t >> 31) & (1 - ((ix & 0x80000000) >> 30));
}
 
main ()
{
float x = 1.0 / 0.0;
int i = isinff (x);
 
if (i == 0)
abort ();
 
printf ("%d\n", i);
return 0;
}
gcc/testsuite/gcc.target/alpha/980217-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/base-1.c =================================================================== --- gcc/testsuite/gcc.target/alpha/base-1.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/base-1.c (revision 312) @@ -0,0 +1,73 @@ +/* Test that the base isa builtins compile. */ +/* { dg-do link } */ +/* { dg-options "-mcpu=ev4" } */ + +void test_BASE (long x, long y) +{ + volatile long sink; + long z; + + sink = __builtin_alpha_implver (); + sink = __builtin_alpha_rpcc (); + + sink = __builtin_alpha_amask (-1); + sink = __builtin_alpha_amask (x); + + sink = __builtin_alpha_cmpbge (x, y); + sink = __builtin_alpha_cmpbge (-1, x); + + sink = __builtin_alpha_extbl (x, y); + sink = __builtin_alpha_extwl (x, y); + sink = __builtin_alpha_extll (x, y); + sink = __builtin_alpha_extql (x, y); + sink = __builtin_alpha_extwh (x, y); + sink = __builtin_alpha_extlh (x, y); + sink = __builtin_alpha_extqh (x, y); + + sink = __builtin_alpha_insbl (x, y); + sink = __builtin_alpha_inswl (x, y); + sink = __builtin_alpha_insll (x, y); + sink = __builtin_alpha_insql (x, y); + sink = __builtin_alpha_inswh (x, y); + sink = __builtin_alpha_inslh (x, y); + sink = __builtin_alpha_insqh (x, y); + + sink = __builtin_alpha_mskbl (x, y); + sink = __builtin_alpha_mskwl (x, y); + sink = __builtin_alpha_mskll (x, y); + sink = __builtin_alpha_mskql (x, y); + sink = __builtin_alpha_mskwh (x, y); + sink = __builtin_alpha_msklh (x, y); + sink = __builtin_alpha_mskqh (x, y); + + sink = __builtin_alpha_umulh (x, y); +} + +void test_zap (long x, long y) +{ + volatile long sink; + long z; + sink = __builtin_alpha_zap (x, y); + sink = __builtin_alpha_zap (x, 0xaa); + z = 0xaa; + sink = __builtin_alpha_zap (x, z); + z = 0; + sink = __builtin_alpha_zap (z, x); + sink = __builtin_alpha_zap (x, z); +} + +void test_zapnot (long x, long y) +{ + volatile long sink; + long z; + + sink = __builtin_alpha_zapnot (x, y); + sink = __builtin_alpha_zapnot (x, 0xaa); + z = 0xaa; + sink = __builtin_alpha_zapnot (x, z); + z = 0; + sink = __builtin_alpha_zapnot (z, x); + sink = __builtin_alpha_zapnot (x, z); +} + +int main() { return 0; }
gcc/testsuite/gcc.target/alpha/base-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/base-2.c =================================================================== --- gcc/testsuite/gcc.target/alpha/base-2.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/base-2.c (revision 312) @@ -0,0 +1,5 @@ +/* Test that alpha-base-1.c compiles with optimization. */ +/* { dg-do link } */ +/* { dg-options "-mcpu=ev4 -O2" } */ + +#include "base-1.c"
gcc/testsuite/gcc.target/alpha/base-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/pr42113.c =================================================================== --- gcc/testsuite/gcc.target/alpha/pr42113.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/pr42113.c (revision 312) @@ -0,0 +1,12 @@ +/* { dg-do compile } */ +/* { dg-options "-O2" } */ + +int foo (int a, int b) +{ + int bar = a * sizeof (int); + + if (b) + bar += sizeof (int); + + return bar; +}
gcc/testsuite/gcc.target/alpha/pr42113.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/asm-1.c =================================================================== --- gcc/testsuite/gcc.target/alpha/asm-1.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/asm-1.c (revision 312) @@ -0,0 +1,82 @@ +/* Asm operands that are given as hard registers must keep the same + hard register all the way through compilation. Example derived + from glibc source. */ +/* { dg-do compile } */ +/* { dg-options "-O2 -frename-registers -fcprop-registers" } */ +/* { dg-final { scan-assembler "callsys1 .0 .19 .0 .16 .17" } } */ +/* { dg-final { scan-assembler "callsys2 .0 .19 .0 .16 .17" } } */ + +struct stat { + int dummy; +}; + +struct kernel_stat { + int dummy; +}; + +extern int xstat_conv (int vers, struct kernel_stat *kbuf, void *ubuf); +extern int *__errno_location (void) __attribute__ ((__const__)); + +int +__fxstat (int vers, int fd, struct stat *buf) +{ + struct kernel_stat kbuf; + int result; + + if (vers == 0) + return + ({ + long _sc_ret, _sc_err; + { + register long _sc_0 __asm__("$0"); + register long _sc_16 __asm__("$16"); + register long _sc_17 __asm__("$17"); + register long _sc_19 __asm__("$19"); + _sc_0 = 91; + _sc_16 = (long) (fd); + _sc_17 = (long) (((struct kernel_stat *) buf)); + __asm__("callsys1 %0 %1 %2 %3 %4" + : "=r"(_sc_0), "=r"(_sc_19) + : "0"(_sc_0), "r"(_sc_16), "r"(_sc_17) + : "$1", "$2", "$3", "$4", "$5", "$6", "$7", "$8", + "$22", "$23", "$24", "$25", "$27", "$28", "memory"); + _sc_ret = _sc_0, _sc_err = _sc_19; + } + if (_sc_err) + { + (*__errno_location ()) = (_sc_ret); + _sc_ret = -1L; + } + _sc_ret; + }); + + result = + ({ + long _sc_ret, _sc_err; + { + register long _sc_0 __asm__("$0"); + register long _sc_16 __asm__("$16"); + register long _sc_17 __asm__("$17"); + register long _sc_19 __asm__("$19"); + _sc_0 = 91; + _sc_16 = (long) (fd); + _sc_17 = (long) ((&kbuf)); + __asm__("callsys2 %0 %1 %2 %3 %4" + : "=r"(_sc_0), "=r"(_sc_19) + : "0"(_sc_0), "r"(_sc_16), "r"(_sc_17) + : "$1", "$2", "$3", "$4", "$5", "$6", "$7", "$8", + "$22", "$23", "$24", "$25", "$27", "$28", "memory"); + _sc_ret = _sc_0, _sc_err = _sc_19; + } + if (_sc_err) + { + (*__errno_location ()) = (_sc_ret); + _sc_ret = -1L; + } + _sc_ret; + }); + if (result == 0) + result = xstat_conv (vers, &kbuf, buf); + + return result; +}
gcc/testsuite/gcc.target/alpha/asm-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/pr22093.c =================================================================== --- gcc/testsuite/gcc.target/alpha/pr22093.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/pr22093.c (revision 312) @@ -0,0 +1,14 @@ +/* { dg-do compile } */ +/* { dg-options "-O2" } */ + +struct shared_ptr_struct +{ + unsigned long phase : 48; + unsigned thread : 16; + void *addr; +} x; + +void foo (void) +{ + x.thread = 2; +}
gcc/testsuite/gcc.target/alpha/pr22093.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/cix-1.c =================================================================== --- gcc/testsuite/gcc.target/alpha/cix-1.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/cix-1.c (revision 312) @@ -0,0 +1,14 @@ +/* Test that the CIX isa builtins compile. */ +/* { dg-do link } */ +/* { dg-options "-mcpu=ev67" } */ + +void test_CIX (long x) +{ + volatile long sink; + + sink = __builtin_alpha_cttz (x); + sink = __builtin_alpha_ctlz (x); + sink = __builtin_alpha_ctpop (x); +} + +int main() { return 0; }
gcc/testsuite/gcc.target/alpha/cix-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/cix-2.c =================================================================== --- gcc/testsuite/gcc.target/alpha/cix-2.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/cix-2.c (revision 312) @@ -0,0 +1,5 @@ +/* Test that alpha-cix-1.c compiles with optimization. */ +/* { dg-do link } */ +/* { dg-options "-mcpu=ev67 -O2" } */ + +#include "cix-1.c"
gcc/testsuite/gcc.target/alpha/cix-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/max-1.c =================================================================== --- gcc/testsuite/gcc.target/alpha/max-1.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/max-1.c (revision 312) @@ -0,0 +1,27 @@ +/* Test that the MAX isa builtins compile. */ +/* { dg-do link } */ +/* { dg-options "-mcpu=pca56" } */ + +void test_MAX (long x, long y) +{ + volatile long sink; + + sink = __builtin_alpha_pklb (x); + sink = __builtin_alpha_pkwb (x); + sink = __builtin_alpha_unpkbl (x); + sink = __builtin_alpha_unpkbw (x); + + sink = __builtin_alpha_minub8 (0, x); + sink = __builtin_alpha_minub8 (1, x); + sink = __builtin_alpha_minub8 (x, y); + sink = __builtin_alpha_minsb8 (x, y); + sink = __builtin_alpha_minuw4 (x, y); + sink = __builtin_alpha_minsw4 (x, y); + sink = __builtin_alpha_maxub8 (x, y); + sink = __builtin_alpha_maxsb8 (x, y); + sink = __builtin_alpha_maxuw4 (x, y); + sink = __builtin_alpha_maxsw4 (x, y); + sink = __builtin_alpha_perr (x, y); +} + +int main() { return 0; }
gcc/testsuite/gcc.target/alpha/max-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/max-2.c =================================================================== --- gcc/testsuite/gcc.target/alpha/max-2.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/max-2.c (revision 312) @@ -0,0 +1,5 @@ +/* Test that alpha-max-1.c compiles with optimization. */ +/* { dg-do link } */ +/* { dg-options "-mcpu=pca56 -O2" } */ + +#include "max-1.c"
gcc/testsuite/gcc.target/alpha/max-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/pr42448-1.c =================================================================== --- gcc/testsuite/gcc.target/alpha/pr42448-1.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/pr42448-1.c (revision 312) @@ -0,0 +1,27 @@ +/* { dg-do run } */ +/* { dg-options "-mcpu=21064 -O0" } */ + +extern void abort (void); + +struct S2180 +{ + char t; + _Complex char u[2]; +}; + +struct S2180 s2180; + +int +main (void) +{ + volatile struct S2180 x; + + s2180.u[1] = 3 + 4i; + + x.u[1] = s2180.u[1]; + + if (x.u[1] != s2180.u[1]) + abort (); + + return 0; +}
gcc/testsuite/gcc.target/alpha/pr42448-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/pr42269-1.c =================================================================== --- gcc/testsuite/gcc.target/alpha/pr42269-1.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/pr42269-1.c (revision 312) @@ -0,0 +1,13 @@ +/* { dg-do compile } */ +/* { dg-options "-O2" } */ +/* { dg-final { scan-assembler-not "addl" } } */ + +unsigned +parity (unsigned x) +{ + x ^= x >> 16; + x ^= x >> 8; + x ^= x >> 4; + x &= 0xf; + return (0x6996 >> x) & 1; +}
gcc/testsuite/gcc.target/alpha/pr42269-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/pr42448-2.c =================================================================== --- gcc/testsuite/gcc.target/alpha/pr42448-2.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/pr42448-2.c (revision 312) @@ -0,0 +1,27 @@ +/* { dg-do run } */ +/* { dg-options "-mcpu=21064 -O0" } */ + +extern void abort (void); + +struct S2180 +{ + char t; + _Complex char u[4]; +}; + +struct S2180 s2180; + +int +main (void) +{ + volatile struct S2180 x; + + s2180.u[3] = 3 + 4i; + + x.u[3] = s2180.u[3]; + + if (x.u[3] != s2180.u[3]) + abort (); + + return 0; +}
gcc/testsuite/gcc.target/alpha/pr42448-2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/pr24178.c =================================================================== --- gcc/testsuite/gcc.target/alpha/pr24178.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/pr24178.c (revision 312) @@ -0,0 +1,13 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -mcpu=ev4" } */ + +struct S { + long l; + unsigned char c; +}; +unsigned long f(unsigned char *p10) { + struct S *p = (struct S *) (p10 + 10); + return p->c; +} + +/* { dg-final { scan-assembler "ldl.*,18\\(" } } */
gcc/testsuite/gcc.target/alpha/pr24178.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/pr39740.c =================================================================== --- gcc/testsuite/gcc.target/alpha/pr39740.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/pr39740.c (revision 312) @@ -0,0 +1,162 @@ +/* { dg-do compile } */ +/* { dg-options "-O3 -std=c99 -mexplicit-relocs" } */ + +typedef int R_len_t; +typedef unsigned int SEXPTYPE; +struct sxpinfo_struct +{ + SEXPTYPE type:5; +}; + +struct vecsxp_struct +{ + R_len_t length; + R_len_t truelength; +}; + +struct listsxp_struct +{ + struct SEXPREC *carval; + struct SEXPREC *cdrval; + struct SEXPREC *tagval; +}; + +typedef struct SEXPREC +{ + struct sxpinfo_struct sxpinfo; + union + { + struct listsxp_struct listsxp; + } u; +} SEXPREC, *SEXP; + +typedef struct VECTOR_SEXPREC +{ + struct vecsxp_struct vecsxp; +} VECTOR_SEXPREC, *VECSEXP; + +typedef union +{ + VECTOR_SEXPREC s; + double align; +} SEXPREC_ALIGN; + +extern SEXP R_NilValue; +extern SEXP R_MissingArg; + +int Rf_envlength (SEXP rho); +SEXP Rf_protect (SEXP); +const char *Rf_translateChar (SEXP); + +inline R_len_t +Rf_length (SEXP s) +{ + int i; + switch (((s)->sxpinfo.type)) + { + case 0: + return 0; + case 24: + return (((VECSEXP) (s))->vecsxp.length); + case 6: + case 17: + i = 0; + while (s != ((void *) 0) && s != R_NilValue) + { + i++; + s = ((s)->u.listsxp.cdrval); + } + return i; + case 4: + return Rf_envlength (s); + default: + return 1; + } +} + +inline SEXP +Rf_lang3 (SEXP s, SEXP t, SEXP u) +{ + return s; +} + +typedef SEXP (*CCODE) (SEXP, SEXP, SEXP, SEXP); + +static SEXP PlusSymbol; +static SEXP MinusSymbol; +static SEXP DivideSymbol; + +int isZero (SEXP s); +SEXP PP (SEXP s); +SEXP AddParens (SEXP expr); +SEXP Rf_install (); + +static int +isUminus (SEXP s) +{ + if (((s)->sxpinfo.type) == 6 && ((s)->u.listsxp.carval) == MinusSymbol) + { + switch (Rf_length (s)) + { + case 2: + return 1; + case 3: + if (((((((s)->u.listsxp.cdrval))->u.listsxp.cdrval))->u.listsxp. + carval) == R_MissingArg) + return 1; + else + return 0; + } + } + else + return 0; +} + +static SEXP +simplify (SEXP fun, SEXP arg1, SEXP arg2) +{ + SEXP ans; + if (fun == PlusSymbol) + { + if (isZero (arg1)) + ans = arg2; + else if (isUminus (arg1)) + ans = + simplify (MinusSymbol, arg2, + ((((arg1)->u.listsxp.cdrval))->u.listsxp.carval)); + else if (isUminus (arg2)) + ans = + simplify (MinusSymbol, arg1, + ((((arg2)->u.listsxp.cdrval))->u.listsxp.carval)); + } + else if (fun == DivideSymbol) + { + ans = Rf_lang3 (DivideSymbol, arg1, arg2); + } + + return ans; +} + + +static SEXP +D (SEXP expr, SEXP var) +{ + return simplify (PlusSymbol, + PP (D + (((((expr)->u.listsxp.cdrval))->u.listsxp.carval), + var)), + PP (D + (((((((expr)->u.listsxp.cdrval))->u.listsxp.cdrval))-> + u.listsxp.carval), var))); +} + +SEXP +do_D (SEXP call, SEXP op, SEXP args, SEXP env) +{ + SEXP expr, var; + var = Rf_install (); + expr = ((args)->u.listsxp.carval); + Rf_protect (expr = D (expr, var)); + expr = AddParens (expr); + return expr; +}
gcc/testsuite/gcc.target/alpha/pr39740.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/pr42774.c =================================================================== --- gcc/testsuite/gcc.target/alpha/pr42774.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/pr42774.c (revision 312) @@ -0,0 +1,10 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -mcpu=ev4" } */ + +unsigned int ntfs_getinfo(void *p) +{ + char bootsect[8]; + + __builtin_memcpy(bootsect, p, sizeof bootsect); + return *(unsigned short *)(bootsect + 3); +}
gcc/testsuite/gcc.target/alpha/pr42774.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/pr19518.c =================================================================== --- gcc/testsuite/gcc.target/alpha/pr19518.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/pr19518.c (revision 312) @@ -0,0 +1,60 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -mcpu=ev67" } */ + +typedef short INT16; +typedef unsigned int CARD32; +typedef unsigned short CARD16; +typedef unsigned char CARD8; +typedef struct _Picture *PicturePtr; +typedef int FbStride; +typedef unsigned long __m64; +extern __m64 load8888 (__m64); +static __inline __m64 _mm_adds_pu8(__m64 __m1, __m64 __m2) +{ + return __m1 + __builtin_alpha_minsb8(__m2, ~__m1); +} +static __inline __m64 _mm_packs_pu16(__m64 __m1, __m64 __m2) +{ + __m1 = __builtin_alpha_minuw4(__m1, 0x00ff00ff00ff00ff); + __m2 = __builtin_alpha_minuw4(__m2, 0x00ff00ff00ff00ff); + return __m1 | (__m2 << 32); +} +typedef unsigned long long ullong; +static __inline__ __m64 pix_multiply(__m64 a) +{ + if (a) + return a; +} +static __inline__ __m64 over(__m64 src, __m64 srca, __m64 dest) +{ + return _mm_adds_pu8(src, pix_multiply(dest)); +} + +void fbCompositeSolid_nx8888mmx(CARD8 op, PicturePtr pSrc, PicturePtr pMask, + INT16 yDst, CARD16 width, CARD16 height) +{ + CARD32 src; + CARD32 *dstLine, *dst; + CARD16 w; + FbStride dstStride; + __m64 vsrc, vsrca; + vsrc = load8888(src); + while (height--) { + dst = dstLine; + dstLine += dstStride; + while (w && (unsigned long) dst & 7) { + *dst = _mm_packs_pu16(_mm_adds_pu8(vsrc, load8888(*dst)), + _mm_setzero_si64()); + dst++; + } + while (w >= 2) { + __m64 dest0, dest1; + *(__m64 *) dst = _mm_packs_pu16(dest0, dest1); + w -= 2; + } + while (w) { + *dst = _mm_packs_pu16(_mm_adds_pu8(vsrc, pix_multiply(0)), 0); + w--; + } + } +}
gcc/testsuite/gcc.target/alpha/pr19518.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/20011018-1.c =================================================================== --- gcc/testsuite/gcc.target/alpha/20011018-1.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/20011018-1.c (revision 312) @@ -0,0 +1,15 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -mieee" } */ + +double foo (void); +void bar (float, float); + +void test (void) +{ + float f, g; + + f = foo(); + g = foo(); + asm (""); + bar (f, g); +}
gcc/testsuite/gcc.target/alpha/20011018-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property Index: gcc/testsuite/gcc.target/alpha/20000715-1.c =================================================================== --- gcc/testsuite/gcc.target/alpha/20000715-1.c (nonexistent) +++ gcc/testsuite/gcc.target/alpha/20000715-1.c (revision 312) @@ -0,0 +1,9 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -mieee" } */ + +float foo(unsigned char n) +{ + float r = 10 * n; + asm volatile("" : : : "memory"); + return r; +}
gcc/testsuite/gcc.target/alpha/20000715-1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:keywords ## -0,0 +1 ## +Id \ No newline at end of property

powered by: WebSVN 2.1.0

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