[rtems commit] sp19: Eliminate warnings
Joel Sherrill
joel at rtems.org
Thu Sep 4 13:59:25 UTC 2014
Module: rtems
Branch: master
Commit: e1462e162a9a6e04c40a98f0bd07b01b63c6333f
Changeset: http://git.rtems.org/rtems/commit/?id=e1462e162a9a6e04c40a98f0bd07b01b63c6333f
Author: Joel Sherrill <joel.sherrill at oarcorp.com>
Date: Tue Sep 2 12:30:25 2014 -0500
sp19: Eliminate warnings
---
testsuites/sptests/sp19/fptask.c | 6 +----
testsuites/sptests/sp19/fptest.h | 49 +++++++++++--------------------------
2 files changed, 16 insertions(+), 39 deletions(-)
diff --git a/testsuites/sptests/sp19/fptask.c b/testsuites/sptests/sp19/fptask.c
index 979182f..3ff7340 100644
--- a/testsuites/sptests/sp19/fptask.c
+++ b/testsuites/sptests/sp19/fptask.c
@@ -41,11 +41,7 @@ rtems_task FP_task(
INTEGER_factors[ task_index ]
);
put_name( Task_name[ task_index ], FALSE );
- #if ( RTEMS_HAS_HARDWARE_FP == 1 )
- printf( " - float base = (%g)\n", FP_factors[ task_index ] );
- #else
- printf( " - float base = (NA)\n" );
- #endif
+ printf( " - float base = (%g)\n", FP_factors[ task_index ] );
previous_seconds = (uint32_t)-1;
diff --git a/testsuites/sptests/sp19/fptest.h b/testsuites/sptests/sp19/fptest.h
index 77c3265..285b5dd 100644
--- a/testsuites/sptests/sp19/fptest.h
+++ b/testsuites/sptests/sp19/fptest.h
@@ -1,20 +1,22 @@
-/* fptest.h
+/**
+ * @file
+ * @brief Floating Point Register Pressure and Check
*
- * This include file contains the CPU dependent implementation
- * of the following routines needed to test RTEMS floating
- * point support:
- * FP_load( &context )
- * FP_check( &context )
+ * This include file contains the implementation of the following
+ * routines needed to test RTEMS floating point support:
*
- * FP_load - loads the specified floating point context
- * FP_check - checks the specified floating point context
+ * FP_load( &context )
+ * FP_check( &context )
*
- * NOTE: These routines are VERY CPU dependent and are thus
- * located in in the CPU dependent include file
- * fptest.h. These routines form the core of the
- * floating point context switch test.
+ * FP_load - loads the specified floating point context
+ * FP_check - checks the specified floating point context
*
- * COPYRIGHT (c) 1989-1999.
+ * Whether the CPU model has hardware or software floating point,
+ * these methods should put load on the floating point register set.
+ */
+
+/*
+ * COPYRIGHT (c) 1989-2014.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -28,25 +30,6 @@
#include <stdio.h>
-#ifndef RTEMS_HAS_HARDWARE_FP
-#error "This CPU does not have RTEMS_HAS_HARDWARE_FP defined"
-#endif
-
-#if ( RTEMS_HAS_HARDWARE_FP == FALSE )
-
-/*
- * The following is useless except to avoid some warnings.
- */
-
-#define FP_DECLARE unsigned int fp01 = 0;
-#define FP_LOAD( _factor ) fp01 = 2;
-#define FP_CHECK( _factor ) \
- if ( fp01 != 2 ) \
- printf("%" PRIu32 ": single integer is wrong -- (%d != 2) \n", \
- task_index, fp01 ); \
-
-#else
-
#define FP_DECLARE \
double fp01 = 1.0; \
double fp02 = 2.0; \
@@ -165,5 +148,3 @@
} while (0)
#endif
-
-#endif
More information about the vc
mailing list