Mantevo/miniFE

How to change the definition of Scalar, universally, from a `double` to a third-party implementation of floating point math?

Closed this issue · 1 comments

I'm trying to merge the posit implementation found here into the ref/src implementation of the miniFE application. I'm kind of new to editing makefiles and was hoping for some tips.

miniFE uses a traits mechanism to support introducing new new scalar types. You would need to add posit versions of the traits. This file contains traits for existing types:

https://github.com/Mantevo/miniFE/blob/master/ref/utils/TypeTraits.hpp

You should be able to add definitions here and then define MINIFE_SCALAR to by posit when executing make:

make -DMINIFE_SCALAR=posit

I hope this helps.