Skip to content

Commit 4e4d4aa

Browse files
committed
[TOPI] Use integer arithmetic for topi.image.resize
Prior to this commit, floating point expressions were used to map between different-sized pixel arrays. These floating point expressions are less aggressively optimized by `RewriteSimplifier`, which can prevent some optimizations This was first noticed during investigation into issue #13508. Benchmarks of `topi.image.resize` showed 1000x and 50x performance improvements using the LLVM and CUDA backends, respectively, by using integer expressions instead of floating point. This performance improvement is partly driven by enabling `tir.transform.VectorizeLoops` to recognize vectorizable indices, where the round-trip through floating point previously prevented that optimization.
1 parent 6782a35 commit 4e4d4aa

File tree

5 files changed

+738
-420
lines changed

5 files changed

+738
-420
lines changed

0 commit comments

Comments
 (0)