Skip to content

1.67× fast_blur speedup + gaussian blur improvements #2809

@art049

Description

@art049

Hello,

I've been profiling the blur operations and have a PR ready with three targeted optimizations: art049#2

Wall-time results (cargo bench)

Benchmark Before After Speedup
fast blur σ=3.0 40.1 ms 24.0 ms 1.67×
fast blur σ=7.0 40.1 ms 24.1 ms 1.66×
fast blur σ=50.0 40.8 ms 24.6 ms 1.65×
gaussian blur σ=3.0 21.6 ms 18.5 ms +17%
gaussian blur σ=7.0 36.3 ms 33.1 ms +10%
gaussian blur σ=50.0 361.4 ms 348.7 ms +4%

I also have a separate PR setting up CodSpeed: art049#1. That's what I used to find these hot spots and iterate.
Full disclaimer: I created CodSpeed, and we'd be happy to provide it for free to image-rs, but I prefer to be upfront about it.
Setting it up would require installing the GitHub App on the org (one-click, org admin needed), and you'd get PR comments like this: art049#2 (comment)

Both PRs are independent, happy to open the perf PR against upstream on its own. Let me know how you'd like to proceed!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions