ausblenden:
Schlagwörter:
-
Zusammenfassung:
We present an autotuning approach for compile-time optimization of numerical discretization methods insimulations of partial differential equations. Our approach is based on data-driven regression of performancemodels for numerical methods. We use these models at compile time to automatically determine the parameters(e.g., resolution, time step size, etc.) of numerical simulations of continuum spatio-temporal models in order tooptimize the tradeoff between simulation accuracy and runtime. The resulting autotuner is developed for thecompiler of a Domain-Specific Language (DSL) for numerical simulations. The abstractions in the DSL enablethe compiler to automatically determine the performance models and know which discretization parametersto tune. We demonstrate that this high-level approach can explore a large space of possible simulations, withsimulation runtimes spanning multiple orders of magnitude. We evaluate our approach in two test cases:the linear diffusion equation and the nonlinear Gray-Scott reaction–diffusion equation. The results show thatour model-based autotuner consistently finds configurations that outperform those found by state-of-the-artgeneral-purpose autotuners. Specifically, our autotuner yields simulations that are on average 4.2x faster thanthose found by the best generic exploration algorithms, while using 16x less tuning time. Compared to manualtuning by a group of researchers with varying levels of expertise, the autotuner was slower than the best usersby not more than a factor of 2, whereas it was able to significantly outperform half of them.