Re: [ARTIQ] Proposition for a units system

2014-10-13 Thread Sébastien Bourdeauducq
On 10/14/2014 05:47 AM, Robert Jordens wrote: The obvious performance optimization here is to have the constant folding transform work across statements. The llvm optimizer passes should be able to do that, right? As far as I can tell right now, not so much. In particular it does not work

Re: [ARTIQ] Proposition for a units system

2014-08-15 Thread Sébastien Bourdeauducq
On 08/14/2014 09:16 AM, Robert Jordens wrote: Also that excerpt misses the point of the underlying question, which is when to best convert floating point physical quantities to integer device units. What about having soft floating point (and rational with e.g. 64-bit numerator and denominator)

Re: [ARTIQ] Proposition for a units system

2014-08-15 Thread Robert Jordens
On 08/15/2014 08:32 AM, Sébastien Bourdeauducq wrote: On 08/14/2014 09:16 AM, Robert Jordens wrote: Also that excerpt misses the point of the underlying question, which is when to best convert floating point physical quantities to integer device units. What about having soft floating point

Re: [ARTIQ] Proposition for a units system

2014-08-12 Thread Robert Jordens
Hello, On 08/12/2014 01:20 AM, Sébastien Bourdeauducq wrote: I'd like to propose a new system to deal with units, quantization by the devices, and rounding errors. The basic idea is to expose the native integer units of the devices directly to the user. For example, the statement: delay(1)