The Portland Group™

Porting WRF to Microsoft Windows Compute Cluster Server

he Weather Research and Forecast (WRF) project is Building WRF With PVF an ongoing collaboration by several institutions to The compilation and execution of WRF requires significant develop a next-generation regional forecast model system resources including multiple gigabytes of system and data assimilation system for operational numeri- memory. For this port, compilation and execution were per- Tcal weather prediction and atmospheric research (www.wrf- formed using Windows remote desktop to the head node of model.org). WRF consists of about 360,000 lines of 90 an AMD Opteron processor-based cluster of HP DL 145 G2 and source code. It is parallelized using the Message Passing servers running Windows CCS 2003. The ability to build, test Interface (MPI) programming model. Using PGI® , and tune applications locally on a laptop or workstation and WRF has been ported to a wide variety of platforms including then build and deploy them using the same visual development clusters and, more recently, 64-bit AMD and Intel x64 environment on a cluster is a key attraction of PGI Visual For- processor-based clusters running Microsoft Windows Compute tran in a Windows environment. Windows Compute Cluster Cluster Server 2003. Server 2003 is pre-configured by Microsoft to enable builds Porting WRF to Windows CCS of MSMPI applications using the PGI compilers and tools, including PGI Visual Fortran. In an earlier project, a port of WRF to Windows Compute Cluster Server 2003 was undertaken following discussions be- tween the National Center for Atmospheric Research (NCAR), Microsoft, AMD, and The Portland Group (PGI). This port was performed within the command environment provided by the Microsoft Subsystem for UNIX-based Applications (SUA). In this instance, using the command-level environment simplified the port by allowing reuse of the existing WRF configuration and build infrastructure as supported on UNIX/Linux. The project culminated in a prototype version of WRF running in parallel using Microsoft MPI on an AMD Opteron-based clus- ter running Microsoft Windows CCS 2003. Porting WRF With PGI Visual Fortran As a test of the capabilities of PGI Visual Fortran™ (PVF™), The Portland Group migrated the WRF source code and build infrastructure into a PVF solution. This enables building and Conclusions executing WRF from within 2005, In this port the goal was to provide a PVF project infrastruc- the premier integrated development environment for Micro- ture that could be used easily as an add-on to the existing WRF soft Windows. PVF includes the latest version of PGI’s native source code and build infrastructure. This could enable WRF OpenMP/auto-parallel optimizing Fortran . Key fea- developers and users to work effectively either within PVF, tures include: a customized Fortran-aware text editor for Visual or using the existing command-level environment. At PGI, Studio 2005, Fortran intrinsics tips and keyword completion, a our experience is that some developers quickly adopt and use custom build engine for Fortran applications, a custom Fortran Visual Studio 2005 as a primary development environment, debug engine; support for debugging of single-thread, multi- while others continue to prefer working in a familiar and thread and OpenMP parallel applications, Microsoft Visual flexible cross-platform command-level environment. Finally, C++ 2005 interoperability, support for debugging of mixed this project demonstrates a practical means for developers and Fortran and Visual C++ 2005 applications, and an interactive users to evaluate, expand or migrate to Windows Compute parallel performance analyzer. Cluster Server.