[all-commits] [llvm/llvm-project] d96569: [analyzer] Fix crash on using `bitcast(<type>, <ar...
Pavel Skripkin via All-commits
all-commits at lists.llvm.org
Fri Aug 2 08:05:18 PDT 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: d96569ecc2807a13dab6495d8cc4e82775b00af1
https://github.com/llvm/llvm-project/commit/d96569ecc2807a13dab6495d8cc4e82775b00af1
Author: Pavel Skripkin <paskripkin at gmail.com>
Date: 2024-08-02 (Fri, 02 Aug 2024)
Changed paths:
M clang/lib/StaticAnalyzer/Core/Store.cpp
M clang/test/Analysis/exercise-ps.c
Log Message:
-----------
[analyzer] Fix crash on using `bitcast(<type>, <array>)` as array subscript (#101647)
Current CSA logic does not expect `LazyCompoundValKind` as array index.
This may happen if array is used as subscript to another, in case of
bitcast to integer type.
Catch such cases and return `UnknownVal`, since CSA cannot model
array -> int casts.
Closes #94496
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list