DyCL: Dynamic Neural Network Compilation Via Program Rewriting and Graph Optimization
Simin Chen, Shiyi Wei, Cong Liu, Wei Yang

TL;DR
DyCL is a novel compilation approach that transforms dynamic neural networks into multiple static sub-networks with a control flow model, enabling existing DL compilers to efficiently compile and execute DyNNs with improved performance.
Contribution
DyCL introduces program analysis and transformation techniques to compile dynamic neural networks by splitting them into static sub-networks and synthesizing a control flow host module.
Findings
Achieved 100% success in compiling all tested DyNNs.
Generated executables run between 1.12x and 20.21x faster than original DyNNs.
Significantly improves compilation success and runtime performance for DyNNs.
Abstract
DL compiler's primary function is to translate DNN programs written in high-level DL frameworks such as PyTorch and TensorFlow into portable executables. These executables can then be flexibly executed by the deployed host programs. However, existing DL compilers rely on a tracing mechanism, which involves feeding a runtime input to a neural network program and tracing the program execution paths to generate the computational graph necessary for compilation. Unfortunately, this mechanism falls short when dealing with modern dynamic neural networks (DyNNs) that possess varying computational graphs depending on the inputs. Consequently, conventional DL compilers struggle to accurately compile DyNNs into executable code. To address this limitation, we propose \tool, a general approach that enables any existing DL compiler to successfully compile DyNNs. \tool tackles the dynamic nature of…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsMachine Learning in Materials Science · Advanced Neural Network Applications · Software Engineering Research
