Skip to content

Commit

Permalink
New README
Browse files Browse the repository at this point in the history
  • Loading branch information
mcg1969 committed Mar 22, 2014
1 parent bc0ef1d commit 1dde8d5
Showing 1 changed file with 28 additions and 6 deletions.
34 changes: 28 additions & 6 deletions README
Original file line number Diff line number Diff line change
@@ -1,8 +1,30 @@
# dotwrp.f90
# dotwrp.c

This is a wrapper for four Level 1 BLAS functions
CDOTC CDOTU ZDOTC ZDOTU and SDOT in Accelerate.framework
of Mac OS X.
This is a wrapper for all of the BLAS functions in Apple's vecLib Framework
that have compatibility issues between F2C and GNU Fortran.

# Reference
http://developer.apple.com/hardwaredrivers/ve/errata.html#fortran_conventions
The functions fixed are:
cdotc
cdotu
zdotc
zdotu
sdot
snrm2
sasum
scnrm2
scasum
All other BLAS routines work correctly with or without the -ff2c flag.

Instead of using this package, you could instead compile your FORTRAN with
-ff2c. However, if your code exports any functions returning single-precision
or (single- or double-precision) complex results, then any code that calls
those functions will be forced to follow F2C conventions as well.

To use, just add dotwrp.c to your existing project, or link to it statically.

This is an expansion of the "dotwrp" project by tenomoto:
https://github.com/tenomoto/dotwrp
We've chosen to convert the f90 code to c so we can take advantage of the
__attribute__((visibility ("hidden"))) settings. This ensures that the symbols
generated by this code are not visible outside of your project---which is
important if you're mixing multiple FORTRAN-based projects together.

0 comments on commit 1dde8d5

Please sign in to comment.