Accelerating the Global Nested Air Quality Prediction Modeling System
(GNAQPMS) model on Intel Xeon Phi processors
Hui Wang1,2,4,*, Huansheng Chen2,*, Qizhong Wu1,4, Junming Lin3, Xueshun Chen2, Xinwei Xie3, Rongrong Wang1,4, Xiao Tang2, and Zifa Wang21College of Global Change and Earth System Science, Beijing Normal University, Beijing 100875, China 2LAPC, Institute of Atmospheric Physics, Chinese Academy of Sciences, Beijing 100875, China 3Intel Corporation 4Joint Centre for Global Changes Studies, Beijing Normal University, Beijing 100875, China *These authors contributed equally to this work.
Received: 15 Dec 2016 – Accepted for review: 21 Feb 2017 – Discussion started: 22 Feb 2017
Abstract. The GNAQPMS model is the global version of the Nested Air Quality Prediction Modelling System (NAQPMS), which is a multi-scale chemical transport model used for air quality forecast and atmospheric environmental research. In this study, we present our work of porting and optimizing the GNAQPMS model on the second generation Intel Xeon Phi processor codename “Knights Landing” (KNL). Compared with the first generation Xeon Phi coprocessor, KNL introduced many new hardware features such as a bootable processor, high performance in-package memory and ISA compatibility with Intel Xeon processor. In particular, we described the five optimizations we applied to the key modules of GNAQPMS – CBM-Z gas chemistry, advection, convection and wet deposition. These optimizations work well on both the KNL 7250 processor as well as the Intel Xeon processor E5-2697 V4. They include: 1) updating the pure MPI parallel mode to hybrid parallel mode with MPI and OpenMP in emission, advection, convection and chemistry modules; 2) fully employ the 512-bit wide vector processing units (VPU) on the KNL platform; 3) reducing unnecessary memory access to improve caches efficiency; 4) reducing thread local storage (TLS) in CBM-Z gas phase chemistry module to improve its OpenMP performance; 5) changing global communication from interface-files writing/reading to using Message Passing Interface (MPI) functions to improve the performance and the parallel scalability. These optimizations improved GNAQPMS performance great. The same optimizations also work well for the Intel Xeon Broadwell processor, specifically, E5-2697v4. Compared with the baseline version of GNAQPMS, the optimized version is 3.34x faster on KNL and 2.39x faster on CPU. Furthermore, the optimized version on KNL runs at 26 % lower average power compare to CPU. Combining the performance and energy improvement, the KNL platform is 47% more efficient compare to the CPU platform. The optimizations also enables much further parallel scalability on both the CPU cluster and KNL cluster – scale to 40 CPU nodes and 30 KNL nodes, with a parallel efficiency of 70.4 % and 42.2 %, respectively.
Wang, H., Chen, H., Wu, Q., Lin, J., Chen, X., Xie, X., Wang, R., Tang, X., and Wang, Z.: Accelerating the Global Nested Air Quality Prediction Modeling System
(GNAQPMS) model on Intel Xeon Phi processors, Geosci. Model Dev. Discuss., doi:10.5194/gmd-2016-307, in review, 2017.
Hui Wang et al.
Hui Wang et al.
Model code and software
Accelerating the Global Nested Air Quality Prediction Modeling System (GNAQPMS) model on Intel Xeon Phi processors
H. Wang, H. Chen, Q. Wu, J. Lin, X. Chen, X. Xie, R. Wang, X. Tang, and Z. Wang