#include    <mpl.h> 
#include    "mpl_blas.h" 
#define PRECISION float
/***************************************************************************
*                                                                          *
*   DATA PARALLEL BLAS based on MPL                                        *
*                                                                          *
*   Internal routine, this routine is not supposed to be                   *
*                     called by user programs.                             *
*                                                                          *
*   Version 1.0   1/4-92 ,                                                 *
*   For MasPar MP-1 computers                                              *
*                                                                          *
*   para//ab, University of Bergen, NORWAY                                 *
*                                                                          *
*   The calling sequence may be changed in a future version.               *
*   Please report any BUGs, ideas for improvement or other                 *
*   comments to                                                            *
*                    adm@parallab.uib.no                                   *
*                                                                          *
*   Future versions may then reflect your suggestions.                     *
*   The most current version of this software is available                 *
*   from netlib@nac.no , send the message `send index from maspar'         *
*                                                                          *
*   REVISIONS:                                                             *
*                                                                          *
***************************************************************************/
#ifdef __STDMPL__
visible void
mpl_sswap(
    register int    n,
    register plural PRECISION  *x, 
    register plural PRECISION  *y
    )
#else
visible void
mpl_sswap(n, x, y)
    register int    n;
    register plural PRECISION  *x, *y;
#endif
{
    register int i;
    register plural PRECISION  t;

    for (i=0; i<NFB(n); i++)
       {
         t = *y;
         *(y++) = *x;
         *(x++) = t;
        }
     if(ENDVEC(n))
	{
	  t = *y;
	 *y = *x;
	 *x = t;
        }
}
