]> granicus.if.org Git - clang/log
clang
10 years agoRemove a temporary workaround that is no longer relevant.
Bob Wilson [Tue, 14 Jan 2014 01:56:31 +0000 (01:56 +0000)]
Remove a temporary workaround that is no longer relevant.

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

10 years agoRemoving some attribute magic related to the OpenCL keyword attributes. Instead of...
Aaron Ballman [Tue, 14 Jan 2014 01:29:54 +0000 (01:29 +0000)]
Removing some attribute magic related to the OpenCL keyword attributes. Instead of mapping them to their semantics as a custom part of the parser, they instead map declaratively through the rest of the attribute system.

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

10 years ago[ms-abi] Small Change to pack+alignment interaction.
Warren Hunt [Tue, 14 Jan 2014 00:54:36 +0000 (00:54 +0000)]
[ms-abi] Small Change to pack+alignment interaction.

This patch makes a small behavioral change to the interaction between
pack and alignment.  Specifically it makes __declspec(align()) on a
field change that field's alignment without respect to pack but the
alignment change to the record alignment as a whole still obeys pack.

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

10 years ago[ms-abi] Remove duplicated vbptr offset code
Reid Kleckner [Tue, 14 Jan 2014 00:50:39 +0000 (00:50 +0000)]
[ms-abi] Remove duplicated vbptr offset code

Record layout will tell us the offset of a shared vbptr inside a
non-virtual base.

No functionality change.

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

10 years agoConsumed analysis: add two new attributes which fine-tune the behavior of
DeLesley Hutchins [Tue, 14 Jan 2014 00:36:53 +0000 (00:36 +0000)]
Consumed analysis: add two new attributes which fine-tune the behavior of
consumable objects.  These are useful for implementing error codes that
must be checked.  Patch also includes some significant refactoring, which was
necesary to implement the new behavior.

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

10 years ago[ms-abi] Report VBPtrOffset correctly
Warren Hunt [Tue, 14 Jan 2014 00:31:30 +0000 (00:31 +0000)]
[ms-abi] Report VBPtrOffset correctly

Although VBPtrs were being placed correctly by the ms-abi layout engine,
their offsets were being improperly reported to the ASTRecordLayout
builder due to a bug.  This patch fixes that and fixes the test cases to
use the correct values.
y

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

10 years ago[ms-abi] Always generate complete constructors in the Microsoft C++ ABI
Reid Kleckner [Mon, 13 Jan 2014 22:57:31 +0000 (22:57 +0000)]
[ms-abi] Always generate complete constructors in the Microsoft C++ ABI

Fixes PR18435, where we generated a base ctor instead of a complete
ctor, and so failed to construct virtual bases when constructing the
complete object.

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

10 years ago[ms-abi] Reordering __declspec(align) pragma pack handling
Warren Hunt [Mon, 13 Jan 2014 22:25:55 +0000 (22:25 +0000)]
[ms-abi] Reordering __declspec(align) pragma pack handling

This patch moves the check for pragma pack until after the application
of __declspec align to before pragma pack.  This causes observable
changes in the use of tail padding for bases.  A test case is included.

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

10 years agoclang-cl: Ignore /fallback when not actually compiling (PR18456)
Hans Wennborg [Mon, 13 Jan 2014 22:24:42 +0000 (22:24 +0000)]
clang-cl: Ignore /fallback when not actually compiling (PR18456)

For example, don't fall back in /P (preprocess) mode.

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

10 years agoLLVM's CMake is now using a feature that wasn't preasant in CMake 2.8.7,
Chandler Carruth [Mon, 13 Jan 2014 22:23:58 +0000 (22:23 +0000)]
LLVM's CMake is now using a feature that wasn't preasant in CMake 2.8.7,
so bump the minimum version in the standalone Clang CMake project as
well.

As I mentioned on the LLVM commit version of this, if this causes any
trouble for folks, just let me know. I'm trying to avoid re-implementing
functionality in CMake, but I will if there are problems using the newer
versions.

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

10 years agoAdding myself as the code owner for the attribute subsystem.
Aaron Ballman [Mon, 13 Jan 2014 22:23:27 +0000 (22:23 +0000)]
Adding myself as the code owner for the attribute subsystem.

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

10 years agoTeach the standalone Clang CMake bits about the flag to force using an
Chandler Carruth [Mon, 13 Jan 2014 22:22:24 +0000 (22:22 +0000)]
Teach the standalone Clang CMake bits about the flag to force using an
old toolchain to build. The toolchain version is now checked in
HandleLLVMOptions.

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

10 years agoWhen determining the attribute's parsed kind, pay attention to the syntax used. This...
Aaron Ballman [Mon, 13 Jan 2014 21:42:39 +0000 (21:42 +0000)]
When determining the attribute's parsed kind, pay attention to the syntax used. This fixes bugs where an attribute has differing GNU and Declspec spellings, but they are treated as the same. Eg) __declspec(aligned) when it should be __attribute__((aligned)), and __attribute__((align)) when it should be __declspec(align).

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

10 years ago__forceinline is a keyword, and not a GNU-style attribute. This FIXME appears to...
Aaron Ballman [Mon, 13 Jan 2014 21:40:16 +0000 (21:40 +0000)]
__forceinline is a keyword, and not a GNU-style attribute. This FIXME appears to be out-dated, and the attribute syntax is becoming more important these days.

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

10 years agoUpdating the attribute declarations to have the correct syntaxes. This means giving...
Aaron Ballman [Mon, 13 Jan 2014 21:32:48 +0000 (21:32 +0000)]
Updating the attribute declarations to have the correct syntaxes. This means giving a __declspec spelling to: deprecated, naked, noinline, noreturn, and nothrow. uuid has no GNU spelling, so it was switched to __declspec. dllexport and dllimport both are now supported with GNU spellings.

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

10 years agoThere is no such thing as __attribute__((align)); that's a __declspec attribute....
Aaron Ballman [Mon, 13 Jan 2014 21:30:03 +0000 (21:30 +0000)]
There is no such thing as __attribute__((align)); that's a __declspec attribute. Fixing these test cases to use the proper spelling for their syntax.

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

10 years agoCodeGen: Clarify a comment about PGO in case statement ranges
Justin Bogner [Mon, 13 Jan 2014 21:24:25 +0000 (21:24 +0000)]
CodeGen: Clarify a comment about PGO in case statement ranges

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

10 years agoCodeGen: Rename adjustFallThroughCount -> adjustForControlFlow
Justin Bogner [Mon, 13 Jan 2014 21:24:22 +0000 (21:24 +0000)]
CodeGen: Rename adjustFallThroughCount -> adjustForControlFlow

adjustFallThroughCount isn't a good name, and the documentation was
even worse. This commit attempts to clarify what it's for and when to
use it.

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

10 years agoCodeGen: Introduce CodeGenPGO::setCurrentRegionUnreachable
Justin Bogner [Mon, 13 Jan 2014 21:24:18 +0000 (21:24 +0000)]
CodeGen: Introduce CodeGenPGO::setCurrentRegionUnreachable

There are a number of places where we do PGO.setCurrentRegionCount(0)
directly after an unconditional branch. Give this operation a name so
that it's clearer why we're doing this.

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

10 years agoCodeGen: Remove a superfluous setCurrentRegionCount
Justin Bogner [Mon, 13 Jan 2014 21:24:15 +0000 (21:24 +0000)]
CodeGen: Remove a superfluous setCurrentRegionCount

This call looks like it was an artifact of an earlier change, and
doesn't actually make sense. We begin a new region immediately anyway,
so it was mostly harmless.

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

10 years agoCodeGen: Remove some unnecessary braces
Justin Bogner [Mon, 13 Jan 2014 21:24:13 +0000 (21:24 +0000)]
CodeGen: Remove some unnecessary braces

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

10 years ago[ms-abi] Leading VFPtrs don't suppress the leading zero sized flag
Warren Hunt [Mon, 13 Jan 2014 19:55:52 +0000 (19:55 +0000)]
[ms-abi] Leading VFPtrs don't suppress the leading zero sized flag

The MS-ABI tracks a bit that asserts that the first sub-object is zero
sized.  This bit is used to add padding between objects if there's the
potential for zero sized objects to alias.  The bit is still true even
if the zero sized base is lead by a VFPtr.  This patch makes clang mimic
that behavior.

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

10 years agoUse the MS ABI for Win32 targets by default
Hans Wennborg [Mon, 13 Jan 2014 19:48:18 +0000 (19:48 +0000)]
Use the MS ABI for Win32 targets by default

In addition to being a sensible default, this is a huge improvement
in test coverage for the MS ABI: any bot that targets Win32 will
now run the test suite using the MS ABI by default.

Differential Revision: http://llvm-reviews.chandlerc.com/D2401

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

10 years agoUpdate tests in preparation for using the MS ABI for Win32 targets
Hans Wennborg [Mon, 13 Jan 2014 19:48:13 +0000 (19:48 +0000)]
Update tests in preparation for using the MS ABI for Win32 targets

In preparation for making the Win32 triple imply MS ABI mode,
make all tests pass in this mode, or make them use the Itanium
mode explicitly.

Differential Revision: http://llvm-reviews.chandlerc.com/D2401

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

10 years ago[ms-abi] Quick fix layout of an array of records
Reid Kleckner [Mon, 13 Jan 2014 19:25:00 +0000 (19:25 +0000)]
[ms-abi] Quick fix layout of an array of records

This fixes llvm::SmallVector, which fixes lots of TUs in the MS ABI self
host.

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

10 years agoFollow-up to r199120: don't try referencing the dtor if the param decl isn't valid.
Hans Wennborg [Mon, 13 Jan 2014 19:24:31 +0000 (19:24 +0000)]
Follow-up to r199120: don't try referencing the dtor if the param decl isn't valid.

This was caught by running test/SemaCXX/destructor.cpp in MS ABI mode.

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

10 years agoUpdate for getLazyBitcodeModule API change.
Rafael Espindola [Mon, 13 Jan 2014 18:31:09 +0000 (18:31 +0000)]
Update for getLazyBitcodeModule API change.

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

10 years agoHook up NetBSD/aarch64.
Joerg Sonnenberger [Mon, 13 Jan 2014 18:25:15 +0000 (18:25 +0000)]
Hook up NetBSD/aarch64.

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

10 years ago[analyzer] Add a CFG node for the allocator call in a C++ 'new' expression.
Jordan Rose [Mon, 13 Jan 2014 17:59:19 +0000 (17:59 +0000)]
[analyzer] Add a CFG node for the allocator call in a C++ 'new' expression.

In an expression like "new (a, b) Foo(x, y)", two things happen:
- Memory is allocated by calling a function named 'operator new'.
- The memory is initialized using the constructor for 'Foo'.

Currently the analyzer only models the second event, though it has special
cases for both the default and placement forms of operator new. This patch
is the first step towards properly modeling both events: it changes the CFG
so that the above expression now generates the following elements.

1. a
2. b
3. (CFGNewAllocator)
4. x
5. y
6. Foo::Foo

The analyzer currently ignores the CFGNewAllocator element, but the next
step is to treat that as a call like any other.

The CFGNewAllocator element is not added to the CFG for analysis-based
warnings, since none of them take advantage of it yet.

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

10 years ago[ms-cxxabi] Elide dtor access checks for pass-by-val objects in callees
Hans Wennborg [Mon, 13 Jan 2014 17:23:24 +0000 (17:23 +0000)]
[ms-cxxabi] Elide dtor access checks for pass-by-val objects in callees

The ABI requires the destructor to be invoked in the callee, but the
standard does not require access checks here so we avoid doing direct
access checks on the destructor.

If we end up needing to define an implicit destructor, we don't skip
access checks for the base class, etc. Those checks are effectively part
of generating the destructor definition, and aren't affected by which TU
the check is performed in.

Differential Revision: http://llvm-reviews.chandlerc.com/D2409

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

10 years agoclang-format: Fix corner case with comment in ctor initializer.
Daniel Jasper [Mon, 13 Jan 2014 14:10:04 +0000 (14:10 +0000)]
clang-format: Fix corner case with comment in ctor initializer.

Formatting:
  Constructor() :
      // Comment forcing unwanted break.
      aaaa(aaaa) {}

Before:
  Constructor()
      :
        // Comment forcing unwanted break.
        aaaa(aaaa) {}

After:
  Constructor()
      : // Comment forcing unwanted break.
        aaaa(aaaa) {}

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

10 years agoclang-format: Don't indent relative to ./->.
Daniel Jasper [Mon, 13 Jan 2014 13:42:08 +0000 (13:42 +0000)]
clang-format: Don't indent relative to ./->.

Before:
  SomeThing          // break
      .SomeFunction( // break
           param);
After:
  SomeThing          // break
      .SomeFunction( // break
          param);

Seems to be more common in editors and codebases I have looked at.

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

10 years ago[PM] Update Clang to reflect LLVM r199095 which moves the core DomTree
Chandler Carruth [Mon, 13 Jan 2014 10:56:17 +0000 (10:56 +0000)]
[PM] Update Clang to reflect LLVM r199095 which moves the core DomTree
algorithms and datastructures into the fully generic support library,
separating them (almost) entirely from the LLVM IR. This makes the
reliance on domtrees here *much* cleaner.

It might be worthwhile for someone to use extern templates and other
tools to sink a lot more of this code into the .cpp files instead of the
.h files, but leaving that for someone other than me.

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

10 years ago[cleanup] Update the include of Dominators.h to reflect its move to the
Chandler Carruth [Mon, 13 Jan 2014 09:26:48 +0000 (09:26 +0000)]
[cleanup] Update the include of Dominators.h to reflect its move to the
IR library in LLVM r199082.

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

10 years ago[PM] Update Clang to reflect the new header for the bitcode writer pass
Chandler Carruth [Mon, 13 Jan 2014 07:47:38 +0000 (07:47 +0000)]
[PM] Update Clang to reflect the new header for the bitcode writer pass
added in LLVM r199078.

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

10 years ago[CMake] Move BUG_REPORT_URL from clang to llvm.
NAKAMURA Takumi [Mon, 13 Jan 2014 05:25:13 +0000 (05:25 +0000)]
[CMake] Move BUG_REPORT_URL from clang to llvm.

It was too late to set BUG_REPORT_URL after configure_file(config.h).
BUG_REPORT_URL in config.h.cmake would be updated at 2nd run of cmake.
It caused many recompilations.

FYI, configure handles BUG_REPORT_URL in llvm side.

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

10 years agoRename target i386-linux-android to i686-linux-android
Alexey Bataev [Mon, 13 Jan 2014 03:49:38 +0000 (03:49 +0000)]
Rename target i386-linux-android to i686-linux-android

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

10 years agoAdd help text for -MMD, -MD, -MM, -M, -MF.
Nico Weber [Sun, 12 Jan 2014 23:12:35 +0000 (23:12 +0000)]
Add help text for -MMD, -MD, -MM, -M, -MF.

Also regroup these flags so that alike flags are next to each other, while
keeping the list still mostly alphabetical.

The help text isn't ideal, but I feel it's less maze-like than
http://gcc.gnu.org/onlinedocs/gcc-4.1.2/gcc/Preprocessor-Options.html (look
at the entry for '-MMD' and count how many other entries you need to look up
until you know what it does).

And it looks like -M / -MM are mostly an historical accident and most people
use -MD or -MMD for deps tracking these days, so make -M / -MM refer to
-MD / -MMD instead of the other way round.

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

10 years agoDynamicASTMatchers/VariantValueTest.cpp: It works with msvcrt since setmode(stderr...
NAKAMURA Takumi [Sun, 12 Jan 2014 17:49:26 +0000 (17:49 +0000)]
DynamicASTMatchers/VariantValueTest.cpp: It works with msvcrt since setmode(stderr, O_BINARY) were removed.

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

10 years agoDelete inaccurate doc comment - isVariadic is long gone
Alp Toker [Sun, 12 Jan 2014 15:18:15 +0000 (15:18 +0000)]
Delete inaccurate doc comment - isVariadic is long gone

The canonical documentation in the header is up-to-date.

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

10 years agoClarify warn_cxx98_compat_attribute diagnostic
Alp Toker [Sun, 12 Jan 2014 15:18:06 +0000 (15:18 +0000)]
Clarify warn_cxx98_compat_attribute diagnostic

Various attribute flavours are supported in C++98. Make it clear that this
compatibility warning relates specifically to C++11-style generalized
attributes.

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

10 years ago[PM] Update the creation of an IR printing pass to reflect the API
Chandler Carruth [Sun, 12 Jan 2014 11:31:22 +0000 (11:31 +0000)]
[PM] Update the creation of an IR printing pass to reflect the API
update in LLVM r199044.

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

10 years ago[PM] Update Clang to follow the header rename in LLVM r199041.
Chandler Carruth [Sun, 12 Jan 2014 11:11:50 +0000 (11:11 +0000)]
[PM] Update Clang to follow the header rename in LLVM r199041.

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

10 years agoSPARC passes non-trivial C++ objects indirectly like everybody else.
Jakob Stoklund Olesen [Sun, 12 Jan 2014 06:54:56 +0000 (06:54 +0000)]
SPARC passes non-trivial C++ objects indirectly like everybody else.

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

10 years agoMIPS and SPARC assemblers both take the -KPIC flag.
Jakob Stoklund Olesen [Sun, 12 Jan 2014 04:53:36 +0000 (04:53 +0000)]
MIPS and SPARC assemblers both take the -KPIC flag.

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

10 years agotest case hygiene.
Benjamin Kramer [Sat, 11 Jan 2014 21:22:35 +0000 (21:22 +0000)]
test case hygiene.

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

10 years agoMake helper function static.
Benjamin Kramer [Sat, 11 Jan 2014 18:42:35 +0000 (18:42 +0000)]
Make helper function static.

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

10 years agoSelect the UltraSPARC instruction set when invoking the assembler.
Jakob Stoklund Olesen [Sat, 11 Jan 2014 18:25:01 +0000 (18:25 +0000)]
Select the UltraSPARC instruction set when invoking the assembler.

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

10 years agoWhoops! Fix major think-o in the first example in the documentation that I edited...
Nick Lewycky [Sat, 11 Jan 2014 02:55:22 +0000 (02:55 +0000)]
Whoops! Fix major think-o in the first example in the documentation that I edited at 3am.

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

10 years agoAdd a new attribute 'enable_if' which can be used to control overload resolution...
Nick Lewycky [Sat, 11 Jan 2014 02:50:57 +0000 (02:50 +0000)]
Add a new attribute 'enable_if' which can be used to control overload resolution based on the values of the function arguments at the call site.

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

10 years agoUse the appropriate SourceLocation for the template backtrace when doing
Nick Lewycky [Sat, 11 Jan 2014 02:37:12 +0000 (02:37 +0000)]
Use the appropriate SourceLocation for the template backtrace when doing
template argument deduction.

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

10 years agoPR12208: Under -fno-elide-constructors, don't forget to actually copy an NRVO
Richard Smith [Sat, 11 Jan 2014 01:24:05 +0000 (01:24 +0000)]
PR12208: Under -fno-elide-constructors, don't forget to actually copy an NRVO
variable to the return slot. Patch by David Wiberg, with test case alterations
by me.

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

10 years ago[ms-abi] Change the way alignment is tracked
Warren Hunt [Sat, 11 Jan 2014 01:16:40 +0000 (01:16 +0000)]
[ms-abi] Change the way alignment is tracked

This patch more cleanly seperates the concepts of Preferred Alignment
and Required Alignment.  Most notable that changes to Required Alignment
do *not* impact preferred alignment until late in struct layout.  This
is observable when using pragma pack and non-virtual bases and the use
of tail padding when laying them out.

Test cases included.

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

10 years agoFix "regression" caused by updating our notion of POD to better match the C++11
Richard Smith [Sat, 11 Jan 2014 00:53:35 +0000 (00:53 +0000)]
Fix "regression" caused by updating our notion of POD to better match the C++11
rules: instead of requiring flexible array members to be POD, require them to
be trivially-destructible. This seems to be the only constraint that actually
matters here (and even then, it's questionable whether this matters).

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

10 years ago[ms-abi] Adjusting Rules for Padding Between Bases
Warren Hunt [Fri, 10 Jan 2014 23:32:32 +0000 (23:32 +0000)]
[ms-abi] Adjusting Rules for Padding Between Bases

The presence of a VBPtr suppresses the presence of zero sized
sub-objects in the non-virtual portion of the object in the context of
determining if two base objects need alias-avoidance padding placed
between them.

Test cases included.

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

10 years agoUse the simpler version of llvm::sys::fs::remove when possible.
Rafael Espindola [Fri, 10 Jan 2014 21:32:14 +0000 (21:32 +0000)]
Use the simpler version of llvm::sys::fs::remove when possible.

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

10 years agoDowngrade bogus ExtWarn on duplicate 'friend' specifier to a Warning, and add a
Richard Smith [Fri, 10 Jan 2014 21:27:55 +0000 (21:27 +0000)]
Downgrade bogus ExtWarn on duplicate 'friend' specifier to a Warning, and add a
Warning for a duplicate 'constexpr' specifier.

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

10 years ago[analyzer] Model getters of known-@synthesized Objective-C properties.
Jordan Rose [Fri, 10 Jan 2014 20:06:06 +0000 (20:06 +0000)]
[analyzer] Model getters of known-@synthesized Objective-C properties.

...by synthesizing their body to be "return self->_prop;", with an extra
nudge to RetainCountChecker to still treat the value as +0 if we have no
other information.

This doesn't handle weak properties, but that's mostly correct anyway,
since they can go to nil at any time. This also doesn't apply to properties
whose implementations we can't see, since they may not be backed by an
ivar at all. And finally, this doesn't handle properties of C++ class type,
because we can't invoke the copy constructor. (Sema has actually done this
work already, but the AST it synthesizes is one the analyzer doesn't quite
handle -- it has an rvalue DeclRefExpr.)

Modeling setters is likely to be more difficult (since it requires
handling strong/copy), but not impossible.

<rdar://problem/11956898>

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

10 years agoObjectiveC. Remove warning on mismatched methods
Fariborz Jahanian [Fri, 10 Jan 2014 19:27:21 +0000 (19:27 +0000)]
ObjectiveC. Remove warning on mismatched methods
which may belong to unrelated classes. It was
primarily intended for miuse of @selector expression.
But warning is too noisy and will be issued when
an actual @selector is used. // rdar://15740134

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

10 years agoImplement -m32 and -m64 with llvm::Triple functions.
Jakob Stoklund Olesen [Fri, 10 Jan 2014 15:25:23 +0000 (15:25 +0000)]
Implement -m32 and -m64 with llvm::Triple functions.

Don't repeat the 32 <-> 64 architecture mapping incompletely.

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

10 years agoRemove unexpected code completion handling from ConsumeToken()
Alp Toker [Fri, 10 Jan 2014 14:37:02 +0000 (14:37 +0000)]
Remove unexpected code completion handling from ConsumeToken()

With this change tok::code_completion is finally handled exclusively as a
special token kind like other tokens that need special treatment.

All callers have been updated to use the specific token consumption methods and
the parser has a clear idea the current token isn't special by the time
ConsumeToken() gets called, so this has been unreachable for some time.

ConsumeAnyToken() behaviour is unchanged and will continue to support
unexpected code completion as part of the special token path.

This survived an amount of fuzzing and validation, but please ping the list if
you hit a code path that previously relied on the old unexpected handler and
now asserts.

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

10 years agoEnable -fuse-init-array for all AArch64 ELF targets by default, not just linux.
Kristof Beyls [Fri, 10 Jan 2014 13:44:34 +0000 (13:44 +0000)]
Enable -fuse-init-array for all AArch64 ELF targets by default, not just linux.

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

10 years agoUse 'w' instead of 'c' to represent the win32 mangling.
Rafael Espindola [Fri, 10 Jan 2014 13:42:17 +0000 (13:42 +0000)]
Use 'w' instead of 'c' to represent the win32 mangling.

This change was requested to avoid confusion if we ever support non windows
coff systems.

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

10 years agoUpdate LangOpt descriptions
Alp Toker [Fri, 10 Jan 2014 11:19:45 +0000 (11:19 +0000)]
Update LangOpt descriptions

Based on recent discussions, attempt to provide a clearer distinction between
MicrosoftMode and MicrosoftExt. This still doesn't feel perfect but gives a
better idea which is which.

Also update the CPlusPlus11 description which got missed in r171367.

C++0x is dead, long live C++0x!

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

10 years agoTryConsume parser cleanups
Alp Toker [Fri, 10 Jan 2014 11:19:30 +0000 (11:19 +0000)]
TryConsume parser cleanups

Also move some comments into the block they were meant to describe.

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

10 years agoclang-format: Slightly adapt line break in edge case.
Daniel Jasper [Fri, 10 Jan 2014 08:40:17 +0000 (08:40 +0000)]
clang-format: Slightly adapt line break in edge case.

Before:
  SomeMap[std::pair(aaaaaaaaaaaabbbbbbbbbbbbbbb)]
      .insert(ccccccccccccccccccccccc);

After:
  SomeMap[std::pair(aaaaaaaaaaaabbbbbbbbbbbbbbb)].insert(
      ccccccccccccccccccccccc);

This seems to be about 3:1 more common in Google and Chromium style and I found
only a handful of instances inside the LLVM codebase.

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

10 years agoUse the right dynamic linker for SPARC Linux executables.
Jakob Stoklund Olesen [Fri, 10 Jan 2014 08:18:34 +0000 (08:18 +0000)]
Use the right dynamic linker for SPARC Linux executables.

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

10 years agoreapply r198858: Disable LeakSanitizer in TableGen binaries, see PR18325; this time...
Kostya Serebryany [Fri, 10 Jan 2014 08:05:42 +0000 (08:05 +0000)]
reapply r198858: Disable LeakSanitizer in TableGen binaries, see PR18325; this time LeakSanitizerIsTurnedOffForTheCurrentProcess is used instead of __lsan_is_turned_off

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

10 years agoclang-format: Understand ObjC boxed expressions.
Daniel Jasper [Fri, 10 Jan 2014 07:44:53 +0000 (07:44 +0000)]
clang-format: Understand ObjC boxed expressions.

Before:
  [dictionary setObject:@(1)forKey:@"number"];
After:
  [dictionary setObject:@(1) forKey:@"number"];

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

10 years agoLocate GCC installations on SPARC systems.
Jakob Stoklund Olesen [Fri, 10 Jan 2014 06:53:02 +0000 (06:53 +0000)]
Locate GCC installations on SPARC systems.

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

10 years agoMake the tautological out of range warning use Sema::DiagRuntimeBehavior so that
Richard Trieu [Fri, 10 Jan 2014 04:38:09 +0000 (04:38 +0000)]
Make the tautological out of range warning use Sema::DiagRuntimeBehavior so that
the warning will not trigger on code protected by compile time checks.

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

10 years agoGive the linker the right ELF type for SPARC targets.
Jakob Stoklund Olesen [Fri, 10 Jan 2014 03:51:33 +0000 (03:51 +0000)]
Give the linker the right ELF type for SPARC targets.

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

10 years agoPass -32/-64 to the assembler when building for sparc/sparc64.
Jakob Stoklund Olesen [Fri, 10 Jan 2014 03:51:29 +0000 (03:51 +0000)]
Pass -32/-64 to the assembler when building for sparc/sparc64.

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

10 years ago[ms-abi] Handle __declspec(align) on bitfields "properly"
Warren Hunt [Fri, 10 Jan 2014 01:28:05 +0000 (01:28 +0000)]
[ms-abi] Handle __declspec(align) on bitfields "properly"

__declspec(align), when applied to bitfields affects their perferred
alignment instead of their required alignment.  We don't know why.
Also, #pragma pack(n) turns packing *off* if n is greater than the
pointer size.  This is now observable because of the impact of
declspec(align) on bitfields.

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

10 years agoCGRecordLayoutBuilder.cpp: Clarify if-else. [-Wdangling-else]
NAKAMURA Takumi [Fri, 10 Jan 2014 00:54:50 +0000 (00:54 +0000)]
CGRecordLayoutBuilder.cpp: Clarify if-else. [-Wdangling-else]

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

10 years agoObjectiveC. 1) Warn when @dynamic (as well as synthesize)
Fariborz Jahanian [Fri, 10 Jan 2014 00:53:48 +0000 (00:53 +0000)]
ObjectiveC. 1) Warn when @dynamic (as well as synthesize)
property has the naming convention that implies 'ownership'.
2) improve on diagnostic and make it property specific.
3) fix the line number in the case of default property
synthesis. // rdar://15757510

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

10 years agoReapply r198845, reverted in r198849, with a fix to make it valid C++98, not
Richard Smith [Fri, 10 Jan 2014 00:40:45 +0000 (00:40 +0000)]
Reapply r198845, reverted in r198849, with a fix to make it valid C++98, not
just valid C++11 =)

Original commit message:

PR18427: Use an appropriately-aligned buffer in APValue, to avoid a crash on
SPARC, where uint64_t apparently requires higher alignment than void*.

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

10 years ago[ms-abi] Fixing CGRecordLayoutBuilder w.r.t. MS NonVirutalBase Layout
Warren Hunt [Thu, 9 Jan 2014 23:51:31 +0000 (23:51 +0000)]
[ms-abi] Fixing CGRecordLayoutBuilder w.r.t. MS NonVirutalBase Layout

The MS abi lays out *all* non-virtual bases with leading vfptrs before
laying out non-virutal bases without vfptrs.  This guarantees that the
primary base is laid out first.  r198818 fixed RecordLayoutBuilder to
produce compatiable layouts.  This patch fixes CGRecordLayoutBuilder to
be able to consume those layouts and produce meaningful output without
tripping any asserts about assumed incoming layout.

A test case is included that shows CGRecordLayoutBuilder in fact
produces output in the compatiable order.

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

10 years agoUpdating documentation for the __has_attribute changes landed in r198897.
Aaron Ballman [Thu, 9 Jan 2014 23:11:13 +0000 (23:11 +0000)]
Updating documentation for the __has_attribute changes landed in r198897.

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

10 years ago__has_attribute now understands target-specific attributes. So when you ask whether...
Aaron Ballman [Thu, 9 Jan 2014 22:57:44 +0000 (22:57 +0000)]
__has_attribute now understands target-specific attributes. So when you ask whether an ARM target has the "interrupt" attribute, it will return true for ARM and MSP430 targets, and false for others.

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

10 years agoRemoving the notion of TargetAttributesSema and replacing it with one where the parse...
Aaron Ballman [Thu, 9 Jan 2014 22:48:32 +0000 (22:48 +0000)]
Removing the notion of TargetAttributesSema and replacing it with one where the parsed attributes are responsible for knowing their target-specific nature, instead of letting Sema figure it out. This is necessary so that __has_attribute can eventually determine whether a parsed attribute applies to the given target or not.

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

10 years agoFix ast-dump-color.cpp test following r198883
Alp Toker [Thu, 9 Jan 2014 21:43:39 +0000 (21:43 +0000)]
Fix ast-dump-color.cpp test following r198883

The commit added a source location that used to be missing from the AST.

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

10 years agoUse getPointerSizeInBits.
Rafael Espindola [Thu, 9 Jan 2014 21:32:51 +0000 (21:32 +0000)]
Use getPointerSizeInBits.

I introduced this bug in 198815. Thanks for Mark Lacey for noticing.
Unfortunately, I have no idea how to test this code.

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

10 years agoPreserve -fretain-comments-from-system-headers in modules
Ben Langmuir [Thu, 9 Jan 2014 20:53:49 +0000 (20:53 +0000)]
Preserve -fretain-comments-from-system-headers in modules

Preserves the setting of -fretain-comments-from-system-headers when
building/saving/loading module files. This allows code completion to pick up
documentation comments from system modules.

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

10 years agoHave attribute 'objc_precise_lifetime' suppress -Wunused.
Ted Kremenek [Thu, 9 Jan 2014 20:19:45 +0000 (20:19 +0000)]
Have attribute 'objc_precise_lifetime' suppress -Wunused.

Fixes <rdar://problem/15596883>

In ARC, __attribute__((objc_precise_lifetime)) guarantees that the
object stored in it will survive to the end of the variable's formal
lifetime.  It is therefore useful even if it completely unused.

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

10 years agoAttempting to appease the build bots on systems with ansi escape sequences.
Aaron Ballman [Thu, 9 Jan 2014 20:12:12 +0000 (20:12 +0000)]
Attempting to appease the build bots on systems with ansi escape sequences.

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

10 years agoRevert "Disable LeakSanitizer in TableGen binaries, see PR18325"
Alp Toker [Thu, 9 Jan 2014 19:43:17 +0000 (19:43 +0000)]
Revert "Disable LeakSanitizer in TableGen binaries, see PR18325"

To declare or define reserved identifers is undefined behaviour in standard
C++. This needs to be addressed in compiler-rt before it can be used in LLVM.

See the list discussion for details.

This reverts commit r198858.

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

10 years agoRemoving a bit of custom parsing functionality used by the thread safety analysis...
Aaron Ballman [Thu, 9 Jan 2014 19:39:35 +0000 (19:39 +0000)]
Removing a bit of custom parsing functionality used by the thread safety analysis APIs. Now using tablegen to determine whether an attribute's arguments should be parsed in an unevaluated context instead of relying on a separate, hard-coded list of attributes.

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

10 years agoclang-format: Add @s when breaking NSString literals.
Daniel Jasper [Thu, 9 Jan 2014 14:18:12 +0000 (14:18 +0000)]
clang-format: Add @s when breaking NSString literals.

While it is allowed to not have an @ on subsequent lines, it seems
general practice to add them. If undesired, the code author can easily
remove them again and clang-format won't re-add them.

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

10 years agoclang-format: Understand #pragma mark
Daniel Jasper [Thu, 9 Jan 2014 13:56:49 +0000 (13:56 +0000)]
clang-format: Understand #pragma mark

Before:
  #pragma mark Any non - hyphenated or hyphenated string(including parentheses).
After:
  #pragma mark Any non-hyphenated or hyphenated string (including parentheses).

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

10 years agoclang-format: Some tweaks to braces list formatting:
Daniel Jasper [Thu, 9 Jan 2014 13:42:56 +0000 (13:42 +0000)]
clang-format: Some tweaks to braces list formatting:

- Format a braced list with one element per line if it has nested
  braced lists.
- Use a column layout only when the list has 6+ elements (instead of the
  current 4+ elements).

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

10 years agoThe OpenCL specification states that images are allocated
Pekka Jaaskelainen [Thu, 9 Jan 2014 13:37:30 +0000 (13:37 +0000)]
The OpenCL specification states that images are allocated
from the global address space (6.5.1 of the OpenCL 1.2 specification).
This makes clang construct the image arguments in the global address
space and generate the argument metadata with the correct address space
descriptor.

Patch by Pedro Ferreira!

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

10 years agocheck-clang: Add dependencies to PrintFunctionNames and SampleAnalyzerPlugin, for...
NAKAMURA Takumi [Thu, 9 Jan 2014 13:26:02 +0000 (13:26 +0000)]
check-clang: Add dependencies to PrintFunctionNames and SampleAnalyzerPlugin, for r198747 and r198820.

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

10 years agoDisable LeakSanitizer in TableGen binaries, see PR18325
Kostya Serebryany [Thu, 9 Jan 2014 09:26:26 +0000 (09:26 +0000)]
Disable LeakSanitizer in TableGen binaries, see PR18325

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

10 years agoFix leak in lib/CodeGen/CGException.cpp, PR18318
Kostya Serebryany [Thu, 9 Jan 2014 09:22:32 +0000 (09:22 +0000)]
Fix leak in lib/CodeGen/CGException.cpp, PR18318

Summary: This fixes the leak described in http://llvm.org/bugs/show_bug.cgi?id=18318

Reviewers: chandlerc, dblaikie

Reviewed By: chandlerc

CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D2474

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

10 years agoIn areVectorOperandsLaxBitCastable() allow bitcast between a vector and scalar.
Argyrios Kyrtzidis [Thu, 9 Jan 2014 07:58:22 +0000 (07:58 +0000)]
In areVectorOperandsLaxBitCastable() allow bitcast between a vector and scalar.

rdar://15779837.

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

10 years agoRevert "PR18427: Use an appropriately-aligned buffer in APValue, to avoid a crash on"
Argyrios Kyrtzidis [Thu, 9 Jan 2014 05:01:04 +0000 (05:01 +0000)]
Revert "PR18427: Use an appropriately-aligned buffer in APValue, to avoid a crash on"

It broke building.
This reverts commit r198845.

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

10 years agoPR18427: Use an appropriately-aligned buffer in APValue, to avoid a crash on
Richard Smith [Thu, 9 Jan 2014 03:29:54 +0000 (03:29 +0000)]
PR18427: Use an appropriately-aligned buffer in APValue, to avoid a crash on
SPARC, where uint64_t apparently requires higher alignment than void*.

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

10 years agoUpdate Clang's CFGBlock interface to conform to the strange part of
Chandler Carruth [Thu, 9 Jan 2014 02:56:16 +0000 (02:56 +0000)]
Update Clang's CFGBlock interface to conform to the strange part of
LLVM's Value interface which is used in LLVM's DominatorTree analysis
and which changed in LLVM r198836.

The DominatorTree analysis is actually a generic graph analysis and
should be moved to LLVM's support library to clarify that Clang and
others are using it with arbitrary graphs. Further, it seems likely that
it should be using something other than printAsOperand, but this is
a simpler build fix. I'll clean this up later.

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

10 years agoFix the clang -Werror build after r198818
David Blaikie [Thu, 9 Jan 2014 02:34:06 +0000 (02:34 +0000)]
Fix the clang -Werror build after r198818

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