[llvm-bugs] [Bug 25078] New: [Analyzer] Assertion "System is over constrained" after truncating 64 bits integers to 32 bits.
via llvm-bugs
llvm-bugs at lists.llvm.org
Tue Oct 6 10:12:04 PDT 2015
https://llvm.org/bugs/show_bug.cgi?id=25078
Bug ID: 25078
Summary: [Analyzer] Assertion "System is over constrained"
after truncating 64 bits integers to 32 bits.
Product: clang
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: Static Analyzer
Assignee: kremenek at apple.com
Reporter: pierregousseau14 at gmail.com
CC: llvm-bugs at lists.llvm.org
Classification: Unclassified
Created attachment 15014
--> https://llvm.org/bugs/attachment.cgi?id=15014&action=edit
test case
clang version: trunk @248379
Given the following test case:
void f1(long foo)
{
unsigned index = -1;
if (index < foo) index = foo;
if (index + 1 == 0) // -> "system over constrained" assertion
clang_analyzer_warnIfReached(); // -> never reached but should be
else
clang_analyzer_warnIfReached();
}
A "System is over constrained" assertion is triggered with debug builds:
$ clang -cc1 -triple x86_64-pc-linux -analyze
-analyzer-checker=core,debug.ExprInspection test.cpp
clang:
../tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/ConstraintManager.h:86:
clang::ento::ConstraintManager::ProgramStatePair
clang::ento::ConstraintManager::assumeDual(clang::ento::ProgramStateRef,
clang::ento::DefinedSVal): Assertion `assume(State, Cond, false) && "System is
over constrained."' failed.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20151006/cb6a67af/attachment-0001.html>
More information about the llvm-bugs
mailing list