chiark / gitweb /
Add PORTING note and autoconf warning pointing to it
authorRoss Younger <onyx-commits@impropriety.org.uk>
Fri, 1 Feb 2013 20:56:09 +0000 (09:56 +1300)
committerRoss Younger <onyx-commits@impropriety.org.uk>
Fri, 1 Feb 2013 20:56:09 +0000 (09:56 +1300)
PORTING [new file with mode: 0644]
configure.ac

diff --git a/PORTING b/PORTING
new file mode 100644 (file)
index 0000000..6a7fdb5
--- /dev/null
+++ b/PORTING
@@ -0,0 +1,15 @@
+I have not run this code on anything other than linux on x86_64 (amd64).
+
+On any other architecture the smallest minimum pixel sizes for the maths
+types encoded in FractalMaths.h are likely wrong; you'll have to experiment.
+
+What worked for me was computing the size of _epsilon_ at 3.0 (being the
+edge of the field for most fractals).
+
+A little C or C++ code (horribly architecture-specific, so I can't usefully
+provide actual code) works this out:
+1. Store 3.0 in the floating-point type of choice
+2. Take its pointer, cast to an array of uint8_t
+3. Increment the least significant byte of the mantissa by 1
+4. Deduct 3 from the modified floater; there's your answer.
+
index dccb25f..637dfc0 100644 (file)
@@ -38,7 +38,7 @@ case $host_cpu in
   *)
        default_float=yes
        default_double=yes
-       # Argh, the epsilon values are likely wrong :-/
+       AC_WARN([Floating point limits are untested on this architecture; see PORTING])
        ;;
 esac