Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for some stack overflow issues with FAST.Farm #2452

Merged
merged 2 commits into from
Oct 21, 2024

Commits on Oct 8, 2024

  1. Intel builds: add /heap-arrays:1000 compile flag

    We have been having issues with stack overflows in FAST.Farm when large
    wind grids were passed to AWAE.  This was eventually tracked down to
    line 1078 in AWAE.f90 which reads:
    `m%u_IfW_Low%PositionXYZ = p%Grid_low`
    The `p%Grid_low` is of unknown size at compile time, but can be
    extremely large (3x160000 or more).  This copy involves a temporary
    array and would normally be handled on the stack, but could result in
    an overflow for some models.  By setting the `/heap-arrays:1000` any
    operation resulting in a temporary array of unknown array size at
    compile time will use the heap for the temprary array, and as will any
    array known at compile time to be larger than 1000 kB.
    
    Testing shows that this fixes issue OpenFAST#2053, and will likely also solve OpenFAST#843 and OpenFAST#2241
    
    See
    https://www.intel.com/content/www/us/en/docs/fortran-compiler/developer-guide-reference/2024-2/heap-arrays.html
    for reference.
    andrew-platt committed Oct 8, 2024
    Configuration menu
    Copy the full SHA
    dde75b8 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    31d281e View commit details
    Browse the repository at this point in the history