An interface for a FPU compiled from VHDL
[ipdf/code.git] / src / tests / vfpufloat.cpp
diff --git a/src/tests/vfpufloat.cpp b/src/tests/vfpufloat.cpp
new file mode 100644 (file)
index 0000000..606ba5e
--- /dev/null
@@ -0,0 +1,14 @@
+#include "main.h"
+
+#include "vfpu.h"
+using namespace std;
+
+
+int main(int argc, char ** argv)
+{
+       VFPU::Start();
+       float result = VFPU::Exec(25,10, VFPU::SUB);
+       printf("%f\n", result);
+       VFPU::Halt();
+       return 0;
+}

UCC git Repository :: git.ucc.asn.au