Files
lapack/CBLAS/testing/c_dblas1.c
T
Hans Johnson 78d32fd2a6 STYLE: Remove trailing whitespace in C files
This is mostly a long term maintenance improvement.

Many coding styles require elimination of trailing whitespace, and
many editors and source code management configurations automatically
gobble up whitespace. When these tools gobble up whitespace, it
complicates reviewing the meaningful code changes.

By removing whitespace on one patch, it makes future
code reviews much easier.

=SCRIPT====================================================================

if which tempfile &>/dev/null; then
  TEMPMAKER=tempfile
elif which mktemp &>/dev/null; then
  TEMPMAKER=mktemp
else
  echo "Cannot find tempfile program." 2>&1
  exit 1
fi

MYTEMP=$($TEMPMAKER)
trap 'rm -f $MYTEMP' SIGINT SIGTERM

stripit() {
  echo "stripping $1"
  sed 's/[ \t]*$//' "$1" > $MYTEMP
  cp $MYTEMP "$1"
}

if [ $# -gt 0 ]; then
  while [ "$1" != "" ]; do
    stripit $1
    shift
  done
else
  while read -t 2; do
    stripit $REPLY
  done
fi

rm $MYTEMP
=================================================
2016-07-09 10:53:07 -05:00

84 lines
1.8 KiB
C

/*
* c_dblas1.c
*
* The program is a C wrapper for dcblat1.
*
* Written by Keita Teranishi. 2/11/1998
*
*/
#include "cblas_test.h"
#include "cblas.h"
double F77_dasum(const int *N, double *X, const int *incX)
{
return cblas_dasum(*N, X, *incX);
}
void F77_daxpy(const int *N, const double *alpha, const double *X,
const int *incX, double *Y, const int *incY)
{
cblas_daxpy(*N, *alpha, X, *incX, Y, *incY);
return;
}
void F77_dcopy(const int *N, double *X, const int *incX,
double *Y, const int *incY)
{
cblas_dcopy(*N, X, *incX, Y, *incY);
return;
}
double F77_ddot(const int *N, const double *X, const int *incX,
const double *Y, const int *incY)
{
return cblas_ddot(*N, X, *incX, Y, *incY);
}
double F77_dnrm2(const int *N, const double *X, const int *incX)
{
return cblas_dnrm2(*N, X, *incX);
}
void F77_drotg( double *a, double *b, double *c, double *s)
{
cblas_drotg(a,b,c,s);
return;
}
void F77_drot( const int *N, double *X, const int *incX, double *Y,
const int *incY, const double *c, const double *s)
{
cblas_drot(*N,X,*incX,Y,*incY,*c,*s);
return;
}
void F77_dscal(const int *N, const double *alpha, double *X,
const int *incX)
{
cblas_dscal(*N, *alpha, X, *incX);
return;
}
void F77_dswap( const int *N, double *X, const int *incX,
double *Y, const int *incY)
{
cblas_dswap(*N,X,*incX,Y,*incY);
return;
}
double F77_dzasum(const int *N, void *X, const int *incX)
{
return cblas_dzasum(*N, X, *incX);
}
double F77_dznrm2(const int *N, const void *X, const int *incX)
{
return cblas_dznrm2(*N, X, *incX);
}
int F77_idamax(const int *N, const double *X, const int *incX)
{
if (*N < 1 || *incX < 1) return(0);
return (cblas_idamax(*N, X, *incX)+1);
}