Commit a02c490
authored
Fix cache thrashing for large images (#106)
cfImageCrop constructs a new image with the default tile cache
size. This create disastrously bad performance on large images.
For example, calling imagetoraster on an ARCHE sized page (36x48 inches,
21600 pixels wide) takes over 300s before this patch, all of which is in
libc_read and libc_write. The cache size is 10 tiles, but the required
cache size is actually about 900-1000 tiles. With the patch, the temp
image correctly inherits a bigger cache (that was sized using the image
width), and that same invocation costs 40s.1 parent badb59e commit a02c490
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
653 | 653 | | |
654 | 654 | | |
655 | 655 | | |
656 | | - | |
| 656 | + | |
657 | 657 | | |
658 | 658 | | |
659 | 659 | | |
| |||
0 commit comments