summaryrefslogtreecommitdiff
path: root/fourier.c
diff options
context:
space:
mode:
authorMatt Turner <mattst88@gmail.com>2008-11-11 23:00:38 +0000
committerMatt Turner <mattst88@gmail.com>2008-11-11 23:00:38 +0000
commit5a7f0d2e7b4265153ccc70051bdae8b851617ede (patch)
treeb29e974f32a1ddba669359100bb6748c72cbfd1e /fourier.c
parentbef5cb4c61e44ee8784f233eb2ec230c776dbda6 (diff)
Remove stupid datatypes. Begin code cleanup
git-svn-id: svn://mattst88.com/svn/cleanbench/trunk@5 0d43b9a7-5ab2-4d7b-af9d-f64450cef757
Diffstat (limited to 'fourier.c')
-rw-r--r--fourier.c26
1 files changed, 13 insertions, 13 deletions
diff --git a/fourier.c b/fourier.c
index 1c95cb7..b6f40c8 100644
--- a/fourier.c
+++ b/fourier.c
@@ -22,8 +22,8 @@
void DoFourier(void)
{
FourierStruct *locfourierstruct; /* Local fourier struct */
-fardouble *abase; /* Base of A[] coefficients array */
-fardouble *bbase; /* Base of B[] coefficients array */
+double *abase; /* Base of A[] coefficients array */
+double *bbase; /* Base of B[] coefficients array */
unsigned long accumtime; /* Accumulated time in ticks */
double iterations; /* # of iterations */
char *errorcontext; /* Error context string pointer */
@@ -48,14 +48,14 @@ if(locfourierstruct->adjust==0)
while(1)
{
- abase=(fardouble *)AllocateMemory(locfourierstruct->arraysize*sizeof(double),
+ abase=(double *)AllocateMemory(locfourierstruct->arraysize*sizeof(double),
&systemerror);
if(systemerror)
{ ReportError(errorcontext,systemerror);
ErrorExit();
}
- bbase=(fardouble *)AllocateMemory(locfourierstruct->arraysize*sizeof(double),
+ bbase=(double *)AllocateMemory(locfourierstruct->arraysize*sizeof(double),
&systemerror);
if(systemerror)
{ ReportError(errorcontext,systemerror);
@@ -74,8 +74,8 @@ if(locfourierstruct->adjust==0)
/*
** Make bigger arrays and try again.
*/
- FreeMemory((farvoid *)abase,&systemerror);
- FreeMemory((farvoid *)bbase,&systemerror);
+ FreeMemory((void *)abase,&systemerror);
+ FreeMemory((void *)bbase,&systemerror);
locfourierstruct->arraysize+=50L;
}
}
@@ -84,14 +84,14 @@ else
** Don't need self-adjustment. Just allocate the
** arrays, and go.
*/
- abase=(fardouble *)AllocateMemory(locfourierstruct->arraysize*sizeof(double),
+ abase=(double *)AllocateMemory(locfourierstruct->arraysize*sizeof(double),
&systemerror);
if(systemerror)
{ ReportError(errorcontext,systemerror);
ErrorExit();
}
- bbase=(fardouble *)AllocateMemory(locfourierstruct->arraysize*sizeof(double),
+ bbase=(double *)AllocateMemory(locfourierstruct->arraysize*sizeof(double),
&systemerror);
if(systemerror)
{ ReportError(errorcontext,systemerror);
@@ -116,8 +116,8 @@ do {
** Clean up, calculate results, and go home.
** Also set adjustment flag to indicate no adjust code needed.
*/
-FreeMemory((farvoid *)abase,&systemerror);
-FreeMemory((farvoid *)bbase,&systemerror);
+FreeMemory((void *)abase,&systemerror);
+FreeMemory((void *)bbase,&systemerror);
locfourierstruct->fflops=iterations/(double)TicksToFracSecs(accumtime);
@@ -137,9 +137,9 @@ return;
** NOTE: The # of integration steps is fixed at
** 200.
*/
-static ulong DoFPUTransIteration(fardouble *abase, /* A coeffs. */
- fardouble *bbase, /* B coeffs. */
- ulong arraysize) /* # of coeffs */
+static unsigned long DoFPUTransIteration(double *abase, /* A coeffs. */
+ double *bbase, /* B coeffs. */
+ unsigned long arraysize) /* # of coeffs */
{
double omega; /* Fundamental frequency */
unsigned long i; /* Index */