Source-Aware Image Transformation Planning for Serverless WebAssembly
Image transformation pipelines may reconstruct and materialize source information that is unnecessary for producing their requested outputs. This paper presents Tinyimg, a source-aware image processing architecture implemented in freestanding WebAssembly for serverless execution. Tinyimg represents transformations through a bounded intermediate representation, combining symbolic rewriting, source-region and resolution propagation, codec-specific partial reconstruction, and fused raster execution. A planner ablation demonstrates a 3.18x speedup over eager execution for a representative transformation sequence. Measurements across seven source formats establish that reduced materialization does not necessarily reduce computational work: eighth-resolution JPEG decoding requires 20.3% of full-resolution execution time, while the corresponding PNG decoding configuration requires 154.7%. Additional experiments characterize progressive JPEG scan elimination, spatial reconstruction dependencies in WebP, and source-content-dependent inverse-transform optimizations. Differential verification and numerical measurements distinguish exact transformation preservation from intentionally different numerical semantics. The released implementation occupies approximately 806 KiB and its integration within Drupflare demonstrates the feasibility of application-local image processing on Cloudflare Workers. These results establish that propagating transformation requirements into source reconstruction and raster execution can eliminate computation across processing stages, subject to the dependencies imposed by the encoded representation.
Authors
- Gregory Mitchell (ORCID: https://orcid.org/0009-0002-3956-4818)
Publication Details
- Journal
- Zenodo (CERN European Organization for Nuclear Research)
- Published
- 2026-12-01
- DOI
- https://doi.org/10.5281/zenodo.24732030
- Primary Topic
- Mobile and Web Applications
- Type
- preprint