Hi, While optimizing an implementation of levenshtein distance, I found that (min ...) took up a significant part of the profile (16%), so I tried replacing it with a simple implementation in Scheme. That worked out surprisingly well (shaved off about 25% of the total runtime) and when I benchmarked it directly it turned out to be between 1.5 and 3 times faster than the min in numbers.c.
Would it be a good idea to move min and max from C to Scheme? And what would be needed? Attached is my implementation directly in arithmetic.bm drop it into benchmark-suite/benchmarks/arithmetic.bm and run ./benchmark-guile arithmetic.bm to see the results. Best wishes, Arne
arithmetic.bm
Description: Binary data
-- Unpolitisch sein heißt politisch sein, ohne es zu merken. draketo.de
signature.asc
Description: PGP signature
