This sucks:
https://github.com/bitemyapp/blacktip/blob/master/src/Database/Blacktip.hs#L45
Worse, it sucks in multiple ways.
First:
(round . (*1000))
round is slow-as. The (*1000) ideally wouldn't even be necessary.
Second:
PSX.getPOSIXTime originates in a syscall and goes through like 3 redundant transformations before I get anything out of it. This is slow and unnecessary! Ideally we'd want a millisecond-resolution with the same 64-bit representation in as little work as is possible.
Worth noting that getPOSIXTime doesn't guarantee monotonicity. I don't know how likely of a problem that is.
This sucks:
https://github.com/bitemyapp/blacktip/blob/master/src/Database/Blacktip.hs#L45
Worse, it sucks in multiple ways.
First:
(round . (*1000))roundis slow-as. The(*1000)ideally wouldn't even be necessary.Second:
PSX.getPOSIXTimeoriginates in a syscall and goes through like 3 redundant transformations before I get anything out of it. This is slow and unnecessary! Ideally we'd want a millisecond-resolution with the same 64-bit representation in as little work as is possible.Worth noting that getPOSIXTime doesn't guarantee monotonicity. I don't know how likely of a problem that is.