Skip to content

Unhandled access‑violation in BandGenLinLapackSolver::solve (DGBSV) — should inputs be pre‑validated? #1611

Description

@fabioflemingleitao

When running a transient (seismic) analysis via OpenSeesPy with the BandGeneral solver, under certain dynamic loading the call to the LAPACK routine DGBSV in BandGenLinLapackSolver::solve() receives invalid arguments—such as mismatched band‑matrix dimensions or uninitialized pointers—and triggers a Windows “Access Violation” crash (0xC0000005). The Python kernel simply dies with no catchable error, making it impossible to handle the failure gracefully in Tcl/Python.

This issue started to appear in some of my analyses (NLTH in buildings). The code simply crashes.
I have a minimal working example (MWE) here: https://github.com/fabioflemingleitao/clean_model

Recently, I managed to debug the OpenSees C++ source using a Python input file via Visual Studio.
I identified that the problem occurs in the BandGenLinLapackSolver.cpp file, exactly at line 122 (DGBSV), as shown in the image.
At a certain point during the analysis, the input variables to the DGBSV function seem to have incompatible values, which causes the program to crash.
It might be worth implementing error handling for this situation, or adding a compatibility check of the variables before the function is executed.

Image

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions