Go to file
Jordan Rose 8e6b6c0c2f [analyzer] Translate "a != b" to "(b - a) != 0" in the constraint manager.
Canonicalizing these two forms allows us to better model containers like
std::vector, which use "m_start != m_finish" to implement empty() but
"m_finish - m_start" to implement size(). The analyzer should have a
consistent interpretation of these two symbolic expressions, even though
it's not properly reasoning about either one yet.

The other unfortunate thing is that while the size() expression will only
ever be written "m_finish - m_start", the comparison may be written
"m_finish == m_start" or "m_start == m_finish". Right now the analyzer does
not attempt to canonicalize those two expressions, since it doesn't know
which length expression to pick. Doing this correctly will probably require
implementing unary minus as a new SymExpr kind (<rdar://problem/12351075>).

For now, the analyzer inverts the order of arguments in the comparison to
build the subtraction, on the assumption that "begin() != end()" is
written more often than "end() != begin()". This is purely speculation.

<rdar://problem/13239003>

llvm-svn: 177801
2013-03-23 01:21:16 +00:00
clang [analyzer] Translate "a != b" to "(b - a) != 0" in the constraint manager. 2013-03-23 01:21:16 +00:00
clang-tools-extra Fix Makefile. 2013-03-20 10:02:35 +00:00
compiler-rt Build and install .syms files alongside sanitizer runtimes. These are used to 2013-03-23 00:31:07 +00:00
debuginfo-tests Remove IR scenario tests. 2013-03-15 20:52:10 +00:00
libclc Update the copyright coredits -- Happy new year 2013! 2013-01-01 10:00:19 +00:00
libcxx Test cleanup with respect to use of deprecated tmpnam function. Also Windows port for these tests to use _tempnam. The bulk of this patch was donated anonymously. I've tested it on OS X and accept responsibility for it. If I've broken anyone's platform by switching from tmpnam to mktemp for the generation of temporary file names, just let me know. Should be easy to fix in test/support/platform_support.h 2013-03-22 20:05:40 +00:00
libcxxabi Bruce Mitchener: Typo fixes. 2013-02-15 15:48:49 +00:00
lld [ELF][Hexagon][test] check .got.plt order 2013-03-20 23:39:43 +00:00
lldb <rdar://problem/13315663> 2013-03-23 01:12:38 +00:00
llvm Fix comparison of mixed signedness 2013-03-23 00:07:29 +00:00
polly Cloog: Add virtual destructor to silence gcc warning 2013-03-23 01:10:53 +00:00