sta: Fix segfault in Table::findValue for NaN axis values#9990
Open
DeepanshuDadhich wants to merge 1 commit intoThe-OpenROAD-Project:masterfrom
Open
sta: Fix segfault in Table::findValue for NaN axis values#9990DeepanshuDadhich wants to merge 1 commit intoThe-OpenROAD-Project:masterfrom
DeepanshuDadhich wants to merge 1 commit intoThe-OpenROAD-Project:masterfrom
Conversation
Update OpenSTA submodule to include fix for segfault during repair_timing (issue The-OpenROAD-Project#9768). Root cause: findValueIndex returns SIZE_MAX when given a NaN value because IEEE 754 NaN comparisons always return false, causing the bisection search to end with lower=-1. The fix adds an early guard for NaN/Inf values in findValueIndex, returning 0 as a safe fallback index. Fixes The-OpenROAD-Project#9768 Signed-off-by: Deepanshu Dadhich <deepanshudadhich7@gmail.com>
d73f1af to
434fd34
Compare
Member
|
conflict to resolve |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Transient segfault during
repair_timing(issue #9768).The crash occurs in
sta::Table::findValuewith an out-of-bounds vector access assertion failure.Root Cause
In
findValueIndex()(TableModel.cc), when the inputvalueis NaN (from numerical instabilities in the DMP Ceff delay calculator), all IEEE 754 float comparisons return false. This causes the bisection search to end withlower = -1, which wraps toSIZE_MAXassize_t, triggering an out-of-bounds vector access.Fix
Add an early guard in
findValueIndex()for NaN/Inf values, returning index 0 as a safe fallback.Testing
Fixes #9768