Uninvoked logging with interpolated string screws performance

Without having checked, I think what you’re seeing is that the string from the interpolation might be constructed regardless. Or that the effects of creating a string through interpolation disable some other optimization the compiler is ordinarily able to do.

You could try using a LazyString?

1 Like