Difference between revisions of "Example fbench"
Line 2: | Line 2: | ||
This is a guide to the '''fbench''' C example project included in the EMAC OE SDK. | This is a guide to the '''fbench''' C example project included in the EMAC OE SDK. | ||
− | How fast is your machine? How accurate is your floating-point math library? | + | How fast is your machine? How accurate is your floating-point math library? The '''FBench''' project creates 2 executables for measuring just that: '''fbench''' and ''ffbench'''. |
− | ''' | + | '''fbench''' is a complete optical design raytracing algorithm. It is based on the Marinchip Interactive Lens Design System written by John Walker of Fourmilab. We chopped off the ui, however, so you won't be doing any optical design with it. We just use it because it's an extremely sensitive floating-point and CPU-intensive algorithm. It's wonderful for testing your CPU to it's limits and determining if your floating-point library harbors any bugs. Run it and regard it's output. A perusal of the source-comments will show you how your system stacks up against the competition. |
− | + | '''ffbench''' does the same job as '''fbench''' except it does it by looping through a fast Fourier transform of a square matrix of complex numbers, reversing that transform, and then checking the results. | |
== Opening, Building and Uploading the Project Files == | == Opening, Building and Uploading the Project Files == | ||
Line 28: | Line 28: | ||
==Usage and Behavior== | ==Usage and Behavior== | ||
− | + | ===Hardware Requirements=== | |
− | ''' | + | Given the appropriate compiler it should make and run for any hardware target with no problems. |
+ | |||
+ | ===Using fbench=== | ||
+ | |||
+ | The ''fbench'' project creates 2 programs : ''fbench'' and ''ffbench''. | ||
+ | |||
+ | ''fbench'' | ||
fbench <itercount><br /> | fbench <itercount><br /> |
Revision as of 11:41, 3 December 2013
This is a guide to the fbench C example project included in the EMAC OE SDK.
How fast is your machine? How accurate is your floating-point math library? The FBench' project creates 2 executables for measuring just that: fbench and ffbench.
fbench is a complete optical design raytracing algorithm. It is based on the Marinchip Interactive Lens Design System written by John Walker of Fourmilab. We chopped off the ui, however, so you won't be doing any optical design with it. We just use it because it's an extremely sensitive floating-point and CPU-intensive algorithm. It's wonderful for testing your CPU to it's limits and determining if your floating-point library harbors any bugs. Run it and regard it's output. A perusal of the source-comments will show you how your system stacks up against the competition.
ffbench does the same job as fbench except it does it by looping through a fast Fourier transform of a square matrix of complex numbers, reversing that transform, and then checking the results.
Contents
Opening, Building and Uploading the Project Files
1. Open the C/C++ editing perspective.
stub
2. Open the fbench project files.
stub
3. Build the fbench project.
stub
4. Upload the fbench binary to the target machine.
stub
Usage and Behavior
Hardware Requirements
Given the appropriate compiler it should make and run for any hardware target with no problems.
Using fbench
The fbench project creates 2 programs : fbench and ffbench.
fbench
fbench <itercount>
Where <itercount> is an optional specification for the number of iterations to be executed, 1000 being the default.
i.e. : ./fbench 123
It runs until it is finished and then outputs the results to the terminal. hey mike fbench appears to have a bug or something. It's supposed to finish and output some results but it just keeps running until you tell it to "stop the timer". It also gives me a funny message at one point "Measured run time in seconds should be divided by 0". Strange. maybe the board is just slow, I dunno. You want me to track down the problem in the code?
Usage for ffbench:
ffbench i.e. : ./ffbench
It runs until it is finished and then outputs to the terminal whether or not errors were detected in it's results.