HerbiePlugin icon indicating copy to clipboard operation
HerbiePlugin copied to clipboard

Need a way to filter out optimized expressions

Open ekmett opened this issue 10 years ago • 2 comments

When I optimize code using the suggestions from herbie, I get caught in a catch-22. the optimized expression often contains the original expression as one of its several branches.

Some way to filter these out would be ideal.

The simplest option would be to allow the use of an {-# ANN #-} pragma on a function to tell herbie to ignore it.

Even better would be a way to tell herbie the filtered range of arguments that can reach a sub-expression, so that it can know to avoid supplying better approximations for inputs that are outside of the domain.

ekmett avatar Sep 22 '15 20:09 ekmett

Does 1c5f8aeb99ccfbe0d15e4e9033d87e15c6383bad do something similar to what you had in mind?

Even better would be a way to tell herbie the filtered range of arguments that can reach a sub-expression, so that it can know to avoid supplying better approximations for inputs that are outside of the domain.

I agree, but the Herbie progam doesn't currently support this AFAIK.

mikeizbicki avatar Sep 22 '15 21:09 mikeizbicki

Perfect!

ekmett avatar Sep 22 '15 21:09 ekmett