summaryrefslogtreecommitdiffstats
path: root/clang/lib
Commit message (Collapse)AuthorAgeFilesLines
* Updating to use more range-based for loops, nullptr and auto. No functional ↵Aaron Ballman2014-04-181-20/+14
| | | | | | changes. llvm-svn: 206590
* ARM64: make sure HFAs on the stack get properly aligned.Tim Northover2014-04-181-7/+8
| | | | | | Another AAPCS bug, part of PR19432. llvm-svn: 206580
* BackendUtil: Pass through -mdisable-tail-callsDuncan P. N. Exon Smith2014-04-181-0/+1
| | | | | | | | | | | | | | | The frontend option -fno-optimize-sibling-calls resolves to -cc1's -mdisable-tail-calls, which is passed to the TargetMachine in the backend. PassManagerBuilder was adding the -tailcallelim pass anyway. Use a new DisableTailCalls option in PassManagerBuilder to disable tail calls harder. Requires the matching commit in LLVM that adds DisableTailCalls. <rdar://problem/16050591> llvm-svn: 206543
* MS ABI: Don't append to vbtables that we shouldn't extendReid Kleckner2014-04-171-9/+9
| | | | | | | This was probably a benign bug, since nobody would look at the vbtable slots that we were filling in. llvm-svn: 206508
* Follow-up to r206457 -- fix static adjustments for some subtle virtual ↵Timur Iskhodzhanov2014-04-171-27/+15
| | | | | | | | inheritance cases Reviewed at http://reviews.llvm.org/D3410 llvm-svn: 206504
* Making some public members into private members. This also introduces a bit ↵Aaron Ballman2014-04-171-16/+10
| | | | | | more const-correctness, and now uses some range-based for loops. No functional changes intended. llvm-svn: 206503
* Add missing serialization code for one of the CXXRecordDecl definition flags.Richard Smith2014-04-172-0/+2
| | | | llvm-svn: 206493
* Nitpicky refactoring -- use of nullptr and auto, made a bit more ↵Aaron Ballman2014-04-171-12/+12
| | | | | | const-correct. No functional changes intended. llvm-svn: 206491
* Revised per Dmitri's comments. My first exposure to range-based for loops, ↵John Thompson2014-04-171-1/+1
| | | | | | thanks! llvm-svn: 206483
* Bug 18567: Fix constantexpr pointer casts with address spaces.Matt Arsenault2014-04-171-1/+3
| | | | | | | Getting a pointer into a struct at a non-zero offset would try to use the default address space. llvm-svn: 206478
* Revised per Dmitri's comments. My first exposure to range-based for loops, ↵John Thompson2014-04-171-10/+8
| | | | | | thanks! llvm-svn: 206474
* Fix alignment of trailing block comments.Alexander Kornienko2014-04-174-70/+112
| | | | | | | | | | | | | | | | | | | | | | Summary: This patch ensures that the lines of the block comments retain relative column offsets. In order to do this WhitespaceManager::Changes representing continuation of block comments keep a pointer on the change representing the whitespace change before the block comment, and a relative column offset to this change, so that the correct column can be reconstructed at the end of alignment process. Fixes http://llvm.org/PR19325 Reviewers: djasper Reviewed By: djasper CC: cfe-commits, klimek Differential Revision: http://reviews.llvm.org/D3408 llvm-svn: 206472
* Since the object is new'ed in the enterCFG function, now deleting in the ↵Aaron Ballman2014-04-171-0/+1
| | | | | | exitCFG function instead of the destructor to ensure proper pairing. This allows reuse of the builder without creating a memory leak. llvm-svn: 206471
* [ARM64] Teach Targets.cpp about Cortex-A53 and Cortex-A57, and enable more ↵James Molloy2014-04-171-0/+1
| | | | | | tests. llvm-svn: 206463
* [ARM64] Plumb in big-endian - add arm64_be to the many switches where it was ↵James Molloy2014-04-173-3/+17
| | | | | | missing. llvm-svn: 206462
* [ARM64] Default to the 'generic' CPU, unless -arch is present for backwards ↵James Molloy2014-04-171-2/+6
| | | | | | compatibility. llvm-svn: 206461
* clang-format: Respect BinPackParameters in Cpp11BracedListStyle.Daniel Jasper2014-04-172-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | With BinPackParameters=false and Cpp11BracedListStyle=true (i.e. mostly for Chromium): Before: const Aaaaaa aaaaa = {aaaaa, bbbbb, ccccc, ddddd, eeeee, ffffff, ggggg, hhhhhh, iiiiii, jjjjjj, kkkkkk}; After: const Aaaaaa aaaaa = {aaaaa, bbbbb, ccccc, ddddd, eeeee, ffffff, ggggg, hhhhhh, iiiiii, jjjjjj, kkkkkk}; This fixes llvm.org/PR19359. I am not sure we'll want this in all cases in the long run, but I'll guess we'll get feedback on that. llvm-svn: 206458
* Fix PR19408 - Missing static this adjustment in a vtordisp thunkTimur Iskhodzhanov2014-04-171-10/+28
| | | | | | | | Also fix a few other vtordisp-related bugs. Reviewed at http://reviews.llvm.org/D3400 llvm-svn: 206457
* ARM64: remove holes from *all* HFAs on the stack.Tim Northover2014-04-171-13/+15
| | | | | | | | | | My first attempt to make sure HFAs were contiguous was in the block dealing with padding registers, which meant it only triggered on the first stack-based HFA. This should extend it to the rest as well. Another part of PR19432. llvm-svn: 206456
* SemaTemplate.cpp: Rework r206451. Removing an argument was really bad idea.NAKAMURA Takumi2014-04-171-4/+5
| | | | llvm-svn: 206452
* SemaTemplate.cpp: Appease msvc to get rid of default argument in lambda ↵NAKAMURA Takumi2014-04-171-2/+2
| | | | | | | | definition. clang\lib\Sema\SemaTemplate.cpp(1826) : error C2064: term does not evaluate to a function taking 1 arguments llvm-svn: 206451
* PR19340: If we see a declaration of a member of an unspecialized class templateRichard Smith2014-04-171-39/+46
| | | | | | | that looks like it might be an explicit specialization, don't recover as an explicit specialization (bypassing the check that would reject that). llvm-svn: 206444
* Refactor all the checking for missing 'template<>'s when a declaration has aRichard Smith2014-04-174-94/+90
| | | | | | template-id after its scope specifier into a single place. llvm-svn: 206442
* Don't emit an ExtWarn on declarations of variable template specializations;Richard Smith2014-04-171-6/+6
| | | | | | | we'll already have issued the relevant diagnostic when we saw the declaration of the primary template. llvm-svn: 206441
* Adding type info for f16c floating-point type. This is consistent with theYunzhong Gao2014-04-171-1/+2
| | | | | | | | Itanium ABI in 2.9.2 Place of Emission. Differential Revision: http://reviews.llvm.org/D2750 llvm-svn: 206439
* Implement [over.match.oper]p3 properly, by filtering the non-candidates outRichard Smith2014-04-178-120/+97
| | | | | | | when building the candidate set, rather than trying to contort name lookup into handling this. llvm-svn: 206436
* PR19452: Implement more of [over.match.oper]p3's restrictions on which ↵Richard Smith2014-04-172-17/+22
| | | | | | non-member overloaded operators can be found when no operand is of class type. We used to fail to implement this rule if there was an operand of dependent type. llvm-svn: 206435
* Further simplify r206430.Adrian Prantl2014-04-171-13/+4
| | | | | | rdar://problem/16636569. llvm-svn: 206434
* Rename lib/Headers/module.map to module.modulemapBen Langmuir2014-04-173-5/+5
| | | | | | Don't install a file using the legacy spelling. llvm-svn: 206431
* Debug info: When collecting the parameters of C++ partial templateAdrian Prantl2014-04-171-4/+10
| | | | | | | | | | | | specializations collect all arguments and not just the ones from the class template partial specialization from which this class template specialization was instantiated. The debug info does not represent the partial specialization otherwise and so specialized parameters would go missing. rdar://problem/16636569. llvm-svn: 206430
* Added dump method for global module index.John Thompson2014-04-161-0/+15
| | | | llvm-svn: 206418
* Handle -m32 for NetBSD/sparc64 correctly. Extend test case to also checkJoerg Sonnenberger2014-04-161-0/+3
| | | | | | ARM, MIPS and i386 ABIs. llvm-svn: 206416
* Revert "Move -fms-extensions predefined macros into InitPreprocessor"Reid Kleckner2014-04-162-12/+13
| | | | | | | | | | This reverts commit r206413. This was proposed before, but it's not clear if this is really a good idea: http://reviews.llvm.org/D3034 llvm-svn: 206415
* Move -fms-extensions predefined macros into InitPreprocessorReid Kleckner2014-04-162-13/+12
| | | | | | | If someone on Linux asks for -fms-extensions, there's no reason not to define the feature test macros that MSVC defines. llvm-svn: 206413
* Fix indentation, NFC.Argyrios Kyrtzidis2014-04-161-4/+4
| | | | llvm-svn: 206411
* [objc] -[NSObject init] is documented to not do anything, don't warn if ↵Argyrios Kyrtzidis2014-04-161-2/+14
| | | | | | | | subclasses do not call [super init] on their initializers. Part of rdar://16568441 llvm-svn: 206410
* [objc] Consider new initializers inside @implementation when determining if ↵Argyrios Kyrtzidis2014-04-161-0/+6
| | | | | | | | | | the class introduces new initializers. Part of rdar://16568441 llvm-svn: 206409
* Objective-C rewriter. Use _WIN64 instead of __LLP64__Fariborz Jahanian2014-04-161-1/+1
| | | | | | | to conditinalize on 64bit length in a generated meta-data. // rdar://16489050 llvm-svn: 206402
* Add support for optimization reports.Diego Novillo2014-04-165-1/+70
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch adds a new flag -Rpass=. The flag indicates the name of the optimization pass that should emit remarks stating when it made a transformation to the code. This implements the design I proposed in: https://docs.google.com/document/d/1FYUatSjZZO-zmFBxjOiuOzAy9mhHA8hqdvklZv68WuQ/edit?usp=sharing Other changes: - Add DiagnosticIDs::isRemark(). Use it in printDiagnosticOptions to print "-R" instead of "-W" in the diagnostic message. - In BackendConsumer::OptimizationRemarkHandler, get a SourceLocation object out of the file name, line and column number. Use that location in the call to Diags.Report(). - When -Rpass is used without debug info a note is emitted alerting the user that they need to use -gline-tables-only -gcolumn-info to get this information. CC: llvm-commits Differential Revision: http://llvm-reviews.chandlerc.com/D3226 llvm-svn: 206401
* InstrProf: Calculate a better function hashDuncan P. N. Exon Smith2014-04-161-7/+131
| | | | | | | | | | | | | | | | | | The function hash should change when control flow changes. This patch hashes the type of each AST node that affects counters, rather than just counting how many there are. These types are combined into a small enumerator that currently has 16 values. The new hash algorithm packs the enums for consecutively visited types into a `uint64_t`. In order to save space for new types, the types are assumed to be 6-bit values (instead of 4-bit). In order to minimize overhead for functions with little control flow, the `uint64_t` is used directly as a hash if it never fills up; if it does, it's passed through an MD5 context. <rdar://problem/16435801> llvm-svn: 206397
* [ARM64] Plumb in the -mfpu= flag.James Molloy2014-04-161-0/+2
| | | | llvm-svn: 206395
* [ARM64] Allow the disabling of NEON and crypto instructions. Update tests to ↵James Molloy2014-04-161-18/+27
| | | | | | pass -target-feature +neon. llvm-svn: 206394
* [ARM64] Fix up predefines, including adding big endian support to Targets.cppJames Molloy2014-04-161-21/+78
| | | | llvm-svn: 206390
* clang-format: Add special case to reduce indentaiton in streams.Daniel Jasper2014-04-163-8/+20
| | | | | | | | | | | | | | | | This is similar to how we treat assignments and seems to be generally desirable. Before: llvm::errs() << aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( aaaaaaaaaaaaaaaaaaaaaaaaaaaa, aaaaaaaaaaaaaaaaaaaaaaaaaaaa); After: llvm::errs() << aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( aaaaaaaaaaaaaaaaaaaaaaaaaaaa, aaaaaaaaaaaaaaaaaaaaaaaaaaaa); llvm-svn: 206384
* Sema: Factor out argument range checks for builtin functionsRichard Sandiford2014-04-161-109/+19
| | | | | | No behavioural change intended. llvm-svn: 206364
* -Wunreachable-code: refine recognition of unreachable "sigil" to cope with ↵Ted Kremenek2014-04-162-1/+25
| | | | | | | | implicit casts in C++. Fixes <rdar://problem/16631033>. llvm-svn: 206360
* Lex: Fix __has_feature(cxx_exceptions) for objective C++Justin Bogner2014-04-161-1/+1
| | | | | | | | | | | | | | | At one point, -fexceptions was a synonym for -fcxx-exceptions. While the driver options still enables cxx-exceptions by default, the cc1 flag is purely about exception tables and this doesn't account for objective C exceptions. Because of this, checking for the cxx_exceptions feature in objective C++ often gives the wrong answer. The cxx_exceptions feature should be based on the -fcxx-exceptions cc1 flag, not -fexceptions. Furthermore, at some point the tests were changed to use cc1 even though they were testing the driver behaviour. We're better off testing both the driver and cc1 here. llvm-svn: 206352
* Fixed problem with exclude header. The exclude header argument needs to be ↵John Thompson2014-04-161-22/+0
| | | | | | relative to the module.map file. llvm-svn: 206342
* Make -Wabsolute-value C++-aware.Richard Trieu2014-04-151-43/+104
| | | | | | | | Warn on std::abs() with unsigned argument. Suggest std::abs as replacement for the C absolute value functions. Suggest C++ headers if the specific std::abs overload is not found. llvm-svn: 206340
* Format.cpp: Don't use initializer list.NAKAMURA Takumi2014-04-151-2/+2
| | | | llvm-svn: 206339
OpenPOWER on IntegriCloud