summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/EHScopeStack.h
Commit message (Collapse)AuthorAgeFilesLines
* Replace llvm::integer_sequence and friends with the C++14 standard versionBenjamin Kramer2019-08-151-2/+2
| | | | | | The implementation in libc++ takes O(1) compile time, ours was O(n). llvm-svn: 368990
* Update the file headers across all of the LLVM projects in the monorepoChandler Carruth2019-01-191-4/+3
| | | | | | | | | | | | | | | | | to reflect the new license. We understand that people may be surprised that we're moving the header entirely to discuss the new license. We checked this carefully with the Foundation's lawyer and we believe this is the correct approach. Essentially, all code in the project is now made available by the LLVM project under our new license, so you will see that the license headers include that license only. Some of our contributors have contributed code under our old license, and accordingly, we have retained a copy of our old license notice in the top-level files in each project and repository. llvm-svn: 351636
* Spelling mistakes in comments. NFCI. (PR27635)Simon Pilgrim2017-03-301-1/+1
| | | | llvm-svn: 299083
* Retire llvm::alignOf in favor of C++11 alignof.Benjamin Kramer2016-10-201-3/+3
| | | | | | No functionality change intended. llvm-svn: 284730
* [Temporary, Lifetime] Add lifetime marks for temporariesTim Shen2016-07-011-1/+4
| | | | | | | | | With all MaterializeTemporaryExprs coming with a ExprWithCleanups, it's easy to add correct lifetime.end marks into the right RunCleanupsScope. Differential Revision: http://reviews.llvm.org/D20499 llvm-svn: 274385
* [CodeGen] Emit lifetime.end intrinsic after objects are destructed inAkira Hatanaka2016-04-011-3/+1
| | | | | | | | | | | | | | | | landing pads. Previously, lifetime.end intrinsics were inserted only on normal control flows. This prevented StackColoring from merging stack slots for objects that were destroyed on the exception handling control flow since it couldn't tell their lifetime ranges were disjoint. This patch fixes code-gen to emit the intrinsic on both control flows. rdar://problem/22181976 Differential Revision: http://reviews.llvm.org/D18196 llvm-svn: 265197
* Update clang to use the updated LLVM EH instructionsDavid Majnemer2015-12-121-4/+0
| | | | | | | | | | Depends on D15139. Reviewers: rnk Differential Revision: http://reviews.llvm.org/D15140 llvm-svn: 255423
* [CodeGen] Remove dead code. NFC.Benjamin Kramer2015-10-151-4/+0
| | | | llvm-svn: 250418
* [SEH] Use cleanupendpad so that WinEHPrepare gets the coloring rightReid Kleckner2015-09-101-2/+2
| | | | | | | Cleanupendpad is a lot like catchendpad, so we can reuse the same EHScopeStack type. llvm-svn: 247349
* Devirtualize EHScopeStack::Cleanup's dtor because it's never destroyed ↵David Blaikie2015-08-181-5/+5
| | | | | | polymorphically llvm-svn: 245378
* Fix for MSVCDavid Blaikie2015-08-181-1/+1
| | | | llvm-svn: 245368
* Wdeprecated: Support movability of EHScopeStack::Cleanup objects as they are ↵David Blaikie2015-08-181-0/+5
| | | | | | move constructed in ConditionalCleanup::restore llvm-svn: 245367
* [MS ABI] Hook clang up to the new EH instructionsDavid Majnemer2015-07-311-0/+4
| | | | | | | | | | The new EH instructions make it possible for LLVM to generate .xdata tables that the MSVC personality routines will be happy about. Because this is experimental, hide it behind a -cc1 flag (-fnew-ms-eh). Differential Revision: http://reviews.llvm.org/D11405 llvm-svn: 243767
* Hopefully fix android i386 build after r242554.James Y Knight2015-07-171-1/+2
| | | | | | | | | That platform has alignof(uint64_t) == 4, but, since LLVM_ALIGNAS(...) cannot take anything but literal integers due to MSVC limitations, the literal '8' used there didn't match. Switch ScopeStackAlignment to just use 8, as well. llvm-svn: 242578
* Fix alignment issues in Clang.James Y Knight2015-07-171-0/+9
| | | | | | | | | | | | | | | | | Some const-correctness changes snuck in here too, since they were in the area of code I was modifying. This seems to make Clang actually work without Bus Error on 32bit-sparc. Follow-up patches will factor out a trailing-object helper class, to make classes using the idiom of appending objects to other objects easier to understand, and to ensure (with static_assert) that required alignment guarantees continue to hold. Differential Revision: http://reviews.llvm.org/D10272 llvm-svn: 242554
* Revert "Revert r234581, it might have caused a few miscompiles in Chromium."David Majnemer2015-04-221-0/+4
| | | | | | | | This reverts commit r234700. It turns out that the lifetime markers were not the cause of Chromium failing but a bug which was uncovered by optimizations exposed by the markers. llvm-svn: 235553
* Revert r234581, it might have caused a few miscompiles in Chromium.Nico Weber2015-04-111-4/+0
| | | | | | | If the revert helps, I'll get a repro this Monday. Else I'll put the change back in. llvm-svn: 234700
* Remove threshold for inserting lifetime markers for named temporariesArnaud A. de Grandmaison2015-04-101-0/+4
| | | | | | | | | | | | | | | | | | | Now that TailRecursionElimination has been fixed with r222354, the threshold on size for lifetime marker insertion can be removed. This only affects named temporary though, as the patch for unnamed temporaries is still in progress. My previous commit (r222993) was not handling debuginfo correctly, but this could only be seen with some asan tests. Basically, lifetime markers are just instrumentation for the compiler's usage and should not affect debug information; however, the cleanup infrastructure was assuming it contained only destructors, i.e. actual code to be executed, and was setting the breakpoint for the end of the function to the closing '}', and not the return statement, in order to show some destructors have been called when leaving the function. This is wrong when the cleanups are only lifetime markers, and this is now fixed. llvm-svn: 234581
* Disambiguate call for GCC.Benjamin Kramer2015-03-121-1/+1
| | | | llvm-svn: 232122
* CodeGen: Base the conditional cleanup machinery on variadic templatesBenjamin Kramer2015-03-121-70/+23
| | | | | | | | | | | This is complicated by the fact that we can't simply use side-effecting calls in an argument list without losing all guarantees about the order they're emitted. To keep things deterministic we use tuples and brace initialization, which thankfully guarantees evaluation order. No functionality change intended. llvm-svn: 232121
* Add comments for two CleanupKinds.Nico Weber2015-02-251-0/+6
| | | | llvm-svn: 230459
* Remove comment addressed by d0k in r229327.Nico Weber2015-02-231-2/+0
| | | | llvm-svn: 230199
* Unbreak the build.Benjamin Kramer2015-02-151-1/+1
| | | | llvm-svn: 229329
* Make pushCleanup a variadic template. NFC.Benjamin Kramer2015-02-151-46/+5
| | | | llvm-svn: 229327
* Silence a warning from MSVC "14" by making an enum unsignedReid Kleckner2014-10-311-1/+1
| | | | | | | | | | It says there is a narrowing conversion when we assign it to an unsigned 3 bit bitfield. Also, use unsigned instead of size_t for the Size field of the struct in question. Otherwise they won't run together in MSVC or clang-cl. llvm-svn: 221019
* Header guard canonicalization, clang part.Benjamin Kramer2014-08-131-2/+2
| | | | | | Modifications made by clang-tidy with minor tweaks. llvm-svn: 215557
* [C++11] Use 'nullptr'. CodeGen edition.Craig Topper2014-05-211-2/+2
| | | | llvm-svn: 209272
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-121-4/+4
| | | | | | class. llvm-svn: 203643
* [C++11] Replace LLVM-style type traits with C++11 standard ones.Benjamin Kramer2014-03-071-3/+3
| | | | | | No functionality change. llvm-svn: 203241
* Sort all the #include lines with LLVM's utils/sort_includes.py whichChandler Carruth2014-01-071-1/+1
| | | | | | | encodes the canonical rules for LLVM's style. I noticed this had drifted quite a bit when cleaning up LLVM, so wanted to clean up Clang as well. llvm-svn: 198686
* [CodeGen] Move EHScopeStack into its own headerReid Kleckner2013-06-191-0/+489
CGCleanup.h isn't meant to be included by all of CodeGen according to John. llvm-svn: 184321
OpenPOWER on IntegriCloud