libclang: introduce cxstring::createNull()


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174173 91177308-0d34-0410-b5e6-96231b3b80d8
libclang: itroduce cxstring::createEmpty()


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174174 91177308-0d34-0410-b5e6-96231b3b80d8
Revise unit testing for -fno-altivec, -mno-altivec.

As suggested, reverted the end-to-end test and added variations to an
existing Driver test.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174176 91177308-0d34-0410-b5e6-96231b3b80d8
Fix PR14881 by implementing conversion rules between int and complex int.

Prior to the patch, Clang does not properly promote types when a complex
integer operand is combined with an integer via a binary operator, or when
one is assigned to the other in either order.  This patch detects when
promotion is needed (and permissible) and generates the necessary code.

The test assmes no target has the same size operands for "char" and
"long long," and that no target performs arithmetic on char operands without
extending them to a larger format first.  If there are any targets for
which this is not the case, they should be XFAILed.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174181 91177308-0d34-0410-b5e6-96231b3b80d8
Fixed segmentation fault when a CFGBlock has NULL successor.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174182 91177308-0d34-0410-b5e6-96231b3b80d8
Fix a string not seen without asserts

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174183 91177308-0d34-0410-b5e6-96231b3b80d8
Add check for @foo

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174185 91177308-0d34-0410-b5e6-96231b3b80d8
Introduce SourceManager::PredefinesFileID, to allow each checking of whether
a source location came from the predefines buffer.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174190 91177308-0d34-0410-b5e6-96231b3b80d8
For ModuleLoader::makeModuleVisible() also pass the source location where the
module import occurred.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174191 91177308-0d34-0410-b5e6-96231b3b80d8
[modules] Introduce ModuleFile::DirectImportLoc which is the source location
where the module was explicitly or implicitly imported in the local translation unit.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174192 91177308-0d34-0410-b5e6-96231b3b80d8
libclang: add comments for CXStringFlag


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174194 91177308-0d34-0410-b5e6-96231b3b80d8
libclang: document the purpose of createNull()


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174195 91177308-0d34-0410-b5e6-96231b3b80d8
Fix comments: these are not trailing comments


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174197 91177308-0d34-0410-b5e6-96231b3b80d8
Fix indent


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174201 91177308-0d34-0410-b5e6-96231b3b80d8
Micro change: moved '{' for better readability (+don't confuse -Wimplicit-fallthrough)

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174202 91177308-0d34-0410-b5e6-96231b3b80d8
[driver] Don't try to generate diagnostic information for dsymutil crashes.
Part of rdar://13134273


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174203 91177308-0d34-0410-b5e6-96231b3b80d8
Add -mqpx and -mno-qpx feature flags to toggle use of the PPC QPX vector instruction set

I've renamed the altivec test to ppc-features (because now there is more than one feature to test).

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174204 91177308-0d34-0410-b5e6-96231b3b80d8
Fix exception handling line table problems introduced by r173593

r173593 made us a little too eager to associate all code at the end of a
function with the user-written 'return' line. This caused problems with
breakpoints as they'd be set in exception handling code preceeding the
actual non-exception return handling code, leading to the breakpoint never
being hit in non-exceptional execution.

This change restores the pre-r173593 exception handling line information where
the cleanup code is associated with the '}' not the return line.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174206 91177308-0d34-0410-b5e6-96231b3b80d8
[analyzer] Reuse a LazyCompoundVal if its type matches the new region.

This allows us to keep from chaining LazyCompoundVals in cases like this:
  CGRect r = CGRectMake(0, 0, 640, 480);
  CGRect r2 = r;
  CGRect r3 = r2;

Previously we only made this optimization if the struct did not begin with
an aggregate member, to make sure that we weren't picking up an LCV for
the first field of the struct. But since LazyCompoundVals are typed, we can
make that inference directly by comparing types.

This is a pure optimization; the test changes are to guard against possible
future regressions.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174211 91177308-0d34-0410-b5e6-96231b3b80d8
Re-apply "[analyzer] Model trivial copy/move ctors with an aggregate bind."

With the optimization in the previous commit, this should be safe again.

Originally applied in r173951, then reverted in r174069.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174212 91177308-0d34-0410-b5e6-96231b3b80d8