diff options
author | xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e> | 2006-02-09 14:55:48 +0000 |
---|---|---|
committer | xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e> | 2006-02-09 14:55:48 +0000 |
commit | 2ae43be7b9d4118335c9d2cef6e098f9b9f807fe (patch) | |
tree | bbb5e49ccbf7e3614966571acc317f8d318fecad /test/harness/mainfib.c | |
download | compcert-2ae43be7b9d4118335c9d2cef6e098f9b9f807fe.tar.gz compcert-2ae43be7b9d4118335c9d2cef6e098f9b9f807fe.zip |
Initial import of compcert
git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@1 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e
Diffstat (limited to 'test/harness/mainfib.c')
-rw-r--r-- | test/harness/mainfib.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/harness/mainfib.c b/test/harness/mainfib.c new file mode 100644 index 00000000..a736d70b --- /dev/null +++ b/test/harness/mainfib.c @@ -0,0 +1,13 @@ +#include <stdlib.h> +#include <stdio.h> + +extern int fib(int); + +int main(int argc, char ** argv) +{ + int n, r; + if (argc >= 2) n = atoi(argv[1]); else n = 30; + r = fib(n); + printf("fib(%d) = %d\n", n, r); + return 0; +} |