Skip to content Where Legends Are Made
Cooperative Institute for Research to Operations in Hydrology

CIROH Training and Developers Conference 2025 Abstracts

Authors: Huidae Cho – New Mexico State University

Title: Longest Flow Paths, Shortest Compute Times

Presentation Type: Poster 

Abstract: Computing the Longest Flow Paths (LFPs) across continental-scale flow direction matrices presents significant challenges in parallel computing performance and memory efficiency. Recent advances in efficient LFP computation include a sequential divide-and-conquer algorithm based on Hack’s law and an OpenMP-based parallel algorithm employing a top-down strategy. However, the sequential algorithm requires an additional input matrix and does not scale well when computing a large number of LFPs. The OpenMP parallel algorithm offers stable compute times because of its top-down traversal strategy but incurs high memory usage and is limited to computing only a single LFP per outlet. This poster introduces a new Memory-Efficient Longest Flow Path (MELFP) algorithm that utilizes a hybrid parallel strategy—Loop then Task. The Loop-then-task strategy combines loop-level and task-level OpenMP constructs to improve workload distribution and minimize memory footprint. MELFP tailors parallelism to the nature of the tail-recursive algorithm used in LFP computation, reducing synchronization overhead and exploiting data locality. It demonstrates substantial improvements in both performance and scalability on a large flow direction matrix covering the continental U.S., enabling faster hydrologic analysis while conserving computational resources. This work provides a foundation for efficient, large-scale hydrologic modeling in high-performance computing environments.