History log of /external/clang/lib/CodeGen/CGException.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
8990daf237a48fa2eed3d0546687fc097a004db6 22-Sep-2011 Bill Wendling <isanbard@gmail.com> Don't remove filters.

It's not valid to remove filters from landingpad instructions, even if we catch
the type. The metadata won't be set up correctly.

Testcase is projects/llvm-test/SingleSource/UnitTests/EH/filter-2.cpp.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140335 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
eecb6a1e8b95fcdb7d1a0d92b0a0311c041440cd 20-Sep-2011 Bill Wendling <isanbard@gmail.com> Don't assume that the clause is a GlobalVariable. It could be a constant.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140123 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
40ccaccd21a4377cd76d6adda2b192dcf9514ef6 20-Sep-2011 Bill Wendling <isanbard@gmail.com> The eh.selector intrinsic isn't used anymore. Replace the check here with a
check for the landingpad instruction instead. This check looks at each of the
clauses in the landingpad instruction. If it's a catch clause, it compares the
name directly with the global. If it's a filter clause, it has to look through
each value in the filer to see if any have the prefix.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140075 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
285cfd8953d4ca4da613a47a0d691f7234068f8c 19-Sep-2011 Bill Wendling <isanbard@gmail.com> Throw the switch to convert clang to the new exception handling model!

This model uses the 'landingpad' instruction, which is pinned to the top of the
landing pad. (A landing pad is defined as the destination of the unwind branch
of an invoke instruction.) All of the information needed to generate the correct
exception handling metadata during code generation is encoded into the
landingpad instruction.

The new 'resume' instruction takes the place of the llvm.eh.resume intrinsic
call. It's lowered in much the same way as the intrinsic is.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140049 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
ae270598d5c7a9a283d4b3ddce53b151c6e2b182 15-Sep-2011 Bill Wendling <isanbard@gmail.com> Refactor the load of the exception pointer and the exception selector from their
storage slot into helper functions.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139826 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
bcfd1f55bfbb3e5944cd5e03d07b343e280838c4 02-Sep-2011 Douglas Gregor <dgregor@apple.com> Extend the ASTContext constructor to delay the initialization of
builtin types (When requested). This is another step toward making
ASTUnit build the ASTContext as needed when loading an AST file,
rather than doing so after the fact. No actual functionality change (yet).


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138985 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
74cfb23d44de82f1932f0229b742805b0b3c3719 27-Aug-2011 Benjamin Kramer <benny.kra@googlemail.com> Remove unused variables noticed by GCC.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138707 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
1366862c3f5d390140b5978380d9ac7317d60fc6 26-Aug-2011 John McCall <rjmccall@apple.com> The allocated exception slot does not alias anything; should fix self-host.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138615 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
7c2349be2d11143a2e59a167fd43362a3bf4585e 25-Aug-2011 John McCall <rjmccall@apple.com> Use stronger typing for the flags on AggValueSlot and require
creators to tell us whether something needs GC barriers.
No functionality change.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138581 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
777d6e56ad9b1fed9866daf3ee6486d85c5b7d32 11-Aug-2011 John McCall <rjmccall@apple.com> Simplify EH control flow by observing that EH scopes form a simple
hierarchy of delegation, and that EH selector values are meaningful
function-wide (good thing, too, or inlining wouldn't work).
2,3d
1a
hierarchy of delegation and that EH selector values have the same
meaning everywhere in the function instead of being meaningful only
in the context of a specific selector.

This removes the need for routing edges through EH cleanups,
since a cleanup simply always branches to its enclosing scope.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@137293 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
da549e8995c447542d5631b8b67fcc3a9582797a 29-Jul-2011 Jay Foad <jay.foad@gmail.com> Remove some unnecessary single element array temporaries.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@136461 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
5f9e272e632e951b1efe824cd16acb4d96077930 23-Jul-2011 Chris Lattner <sabre@nondot.org> remove unneeded llvm:: namespace qualifiers on some core types now that LLVM.h imports
them into the clang namespace.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135852 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
2acc6e3feda5e4f7d9009bdcf8b1cd777fecfe2d 18-Jul-2011 Chris Lattner <sabre@nondot.org> de-constify llvm::Type, patch by David Blaikie!


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135370 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
4c7d9f1507d0f102bd4133bba63348636facd469 15-Jul-2011 Jay Foad <jay.foad@gmail.com> Convert CallInst and InvokeInst APIs to use ArrayRef.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135265 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
ad346f4f678ab1c3222425641d851dc63e9dfa1a 12-Jul-2011 John McCall <rjmccall@apple.com> Generalize Cleanup::Emit's "isForEH" parameter into a set
of flags. No functionality change.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@134997 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
c4a1a8450a3613ef256a71b9d8305b41f79eef50 12-Jul-2011 John McCall <rjmccall@apple.com> Do full-expression cleanups in a much more sensible way that still lets
people write useful cleanup classes.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@134942 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
61c1601e2a8534c09cb7032f791f918158abaa27 10-Jul-2011 John McCall <rjmccall@apple.com> Use cached types; no functionality change.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@134880 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
9cbe4f0ba01ec304e1e3d071c071f7bca33631c0 09-Jul-2011 Chris Lattner <sabre@nondot.org> clang side to match the LLVM IR type system rewrite patch.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@134831 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
256a76e0b0e0c9e65a3122917d553ef10bc84d29 06-Jul-2011 John McCall <rjmccall@apple.com> Call objc_terminate() instead of abort() when a cleanup throws an
exception in Objective-C; in Objective-C++ we still use std::terminate().
This is only available in very recent runtimes.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@134456 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
cf5abc7ba032bd35158e4d75b0bc92a482fc67e8 23-Jun-2011 Fariborz Jahanian <fjahanian@apple.com> Support for catching objc pointer objects in c++ catch-statement
in fragile abi mode and some other cleanups. // rdar://8940528



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133747 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
9d96bce991048fd2337cf058ec6a6a722207cbf2 22-Jun-2011 Fariborz Jahanian <fjahanian@apple.com> Alloa catching Objective-C id's being thrown with C++ throw
in Darwin's fragile abi mode. // rdar://8940528


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133639 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
d768e9d29abe1ac1ccc3ed63f2dce835d9bab342 22-Jun-2011 John McCall <rjmccall@apple.com> Emit @finally blocks completely lazily instead of forcing their
existence by always threading an edge from the catchall. Not doing
this was previously causing a crash in the very extreme case where
neither the normal cleanup nor the EH catchall was actually reachable:
we would delete the catchall entry block, which would cause us to
delete the entry block of the finally cleanup as well because the
cleanup logic would merge the blocks, which in turn triggered an assert
because later blocks in the finally would still be using values from the
entry. Laziness turns out to be the most elegant solution to the problem.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133601 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
f85e193739c953358c865005855253af4f68a497 16-Jun-2011 John McCall <rjmccall@apple.com> Automatic Reference Counting.

Language-design credit goes to a lot of people, but I particularly want
to single out Blaine Garst and Patrick Beard for their contributions.

Compiler implementation credit goes to Argyrios, Doug, Fariborz, and myself,
in no particular order.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133103 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
93c332a8ba2c193c435b293966d343dab15f555b 28-May-2011 John McCall <rjmccall@apple.com> Convert Clang over to resuming from landing pads with llvm.eh.resume.
It's quite likely that this will explode, but I need to know how. :)



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@132269 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
addd80d1c80d1e9f249988452103c93a564945f0 27-May-2011 Eli Friedman <eli.friedman@gmail.com> Back out r132209; it's breaking nightly tests.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@132219 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
0903421e36c174a82597f83bd296f3cd5b5f169b 27-May-2011 John McCall <rjmccall@apple.com> Implement a new, much improved version of the cleanup hack. We just need
to be careful to emit landing pads that are always prepared to handle a
cleanup path. This is correct mostly because of the fix to the LLVM
inliner, r132200.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@132209 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
eab80782f645489db299db24aa7a5886b37185b0 26-Apr-2011 Daniel Dunbar <daniel@zuster.org> IRgen/Darwin: Fix refacto introduced in Triple changes.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@130233 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
db57a4cdb0a6abf3239f3a794a900ce312c5887b 19-Apr-2011 Daniel Dunbar <daniel@zuster.org> ADT/Triple: Switch to using .isOSDarwin() predicate.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129823 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
2839d6b17715045d5eba6a47f750060a198d04b2 18-Apr-2011 Anders Carlsson <andersca@mac.com> Get rid of std::vector usage when getting function types in CGException.cpp

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129698 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
fc8f0e14ad142ed811e90fbd9a30e419e301c717 15-Apr-2011 Chris Lattner <sabre@nondot.org> fix a bunch of comment typos found by codespell. Patch by
Luis Felipe Strano Moraes!



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129559 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
80558d2db10a96eada4d8fb79949b3263b44652b 20-Mar-2011 David Chisnall <csdavec@swan.ac.uk> Fix Objective-C++ exceptions (GNU runtime).



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127980 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
a968e97947b1281c3bb3c4d47a952b3801d9bb02 15-Mar-2011 Sebastian Redl <sebastian.redl@getdesigned.at> Reintroduce r127617: "Code generation for noexcept." with fixes.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127685 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
112d5ee15a09f15e597037724e006004b3f2f78f 15-Mar-2011 Jakob Stoklund Olesen <stoklund@2pi.dk> Revert r127617: "Code generation for noexcept."

The tests fail in a -Asserts build.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127635 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
f86d5f2b888573f7d72d7eeae7237cf6c5080958 14-Mar-2011 Sebastian Redl <sebastian.redl@getdesigned.at> Code generation for noexcept.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127617 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
60618fa7f88d5162bb5b40988b6b38d4d75d6fc6 12-Mar-2011 Sebastian Redl <sebastian.redl@getdesigned.at> Propagate the new exception information to FunctionProtoType.
Change the interface to expose the new information and deal with the enormous fallout.
Introduce the new ExceptionSpecificationType value EST_DynamicNone to more easily deal with empty throw specifications.
Update the tests for noexcept and fix the various bugs uncovered, such as lack of tentative parsing support.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127537 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
15348aeb81285c75b2e92b5bf8d2db3445d147c2 28-Feb-2011 Anders Carlsson <andersca@mac.com> Add a -fcxx-exceptions flag to the frontend, which can be used to enable
C++ exceptions, even when exceptions have been turned off using -fno-exceptions.
Make the -fobjc-exceptions flag do the same thing, but for Objective-C exceptions.

C++ and Objective-C exceptions can also be disabled using -fno-cxx-excptions and
-fno-objc-exceptions.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126630 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
7a17851eee37f933eb57a5af7e1a0eb455443f6a 28-Feb-2011 Anders Carlsson <andersca@mac.com> Get rid of the areExceptionsEnabled() getter from LangOptions.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126598 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
34695856c0e67b3765b46304cc71b5d2cd5b71c7 22-Feb-2011 John McCall <rjmccall@apple.com> Reorganize the emission of local variables.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126189 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
c1cfdf8647a499b6b3024f4bd14a236cddb23988 20-Feb-2011 Anders Carlsson <andersca@mac.com> Add a LangOptions::areExceptionsEnabled and start using it.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126062 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
56ca35d396d8692c384c785f9aeebcf22563fe1e 17-Feb-2011 John McCall <rjmccall@apple.com> Change the representation of GNU ?: expressions to use a different expression
class and to bind the shared value using OpaqueValueExpr. This fixes an
unnoticed problem with deserialization of these expressions where the
deserialized form would lose the vital pointer-equality trait; or rather,
it fixes it because this patch also does the right thing for deserializing
OVEs.

Change OVEs to not be a "temporary object" in the sense that copy elision is
permitted.

This new representation is not totally unawkward to work with, but I think
that's really part and parcel with the semantics we're modelling here. In
particular, it's much easier to fix things like the copy elision bug and to
make the CFG look right.

I've tried to update the analyzer to deal with this in at least some
obvious cases, and I think we get a much better CFG out, but the printing
of OpaqueValueExprs probably needs some work.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125744 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
acff696118d98c3acd09a16b96c95807057b5c99 16-Feb-2011 John McCall <rjmccall@apple.com> Remove this FIXME; clear up an unused variable; style.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125662 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
e996ffd240f20a1048179d7727a6ee3227261921 16-Feb-2011 John McCall <rjmccall@apple.com> Save a copy expression for non-trivial copy constructions of catch variables.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125661 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
d16c2cf1cafa413709aa487cbbd5dc392f1ba1ff 08-Feb-2011 John McCall <rjmccall@apple.com> Reorganize CodeGen{Function,Module} to eliminate the unfortunate
Block{Function,Module} base class. Minor other refactorings.

Fixed a few address-space bugs while I was there.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125085 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
36f893c1efe367f929d92c8b125f964c22ba189e 28-Jan-2011 John McCall <rjmccall@apple.com> Move all the cleanups framework code into a single file.
Pure motion.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124484 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
3ad32c8d93eb65d1d4943d7df567fc9b4f55d137 28-Jan-2011 John McCall <rjmccall@apple.com> Convert the exception-freeing cleanup over to the conditional cleanups code,
fixing a crash which probably nobody was ever going to see. In doing so,
fix a horrendous number of problems with the conditional-cleanups code.
Also, make conditional cleanups re-use the cleanup's activation variable,
which avoids some unfortunate repetitiveness.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124481 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
4bbcbda302cba8b1b0d88c20d735d09b483bd005 26-Jan-2011 John McCall <rjmccall@apple.com> Fix some obvious bugs in the conditional-cleanup code and then make the
dtor cleanup use it.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124309 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
150b462afc7a713edd19bcbbbb22381fe060d4f5 26-Jan-2011 John McCall <rjmccall@apple.com> Better framework for conditional cleanups; untested as yet.
I'm separately committing this because it incidentally changes some
block orderings and minor IR issues, like using a phi instead of
an unnecessary alloca.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124277 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
82a113adf8063baa70251dfa269d039ca22e2537 24-Jan-2011 Anders Carlsson <andersca@mac.com> "Name" a bool parameter.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124094 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
cd5b22e12b6513163dd131589746c194090f14e6 12-Jan-2011 John McCall <rjmccall@apple.com> Fix a latent bug where, after emitting an expression statement, we would
delete the block we began emitting into if it had no predecessors. We never
want to do this, because there are several valid cases during statement
emission where an existing block has no known predecessors but will acquire
some later. The case in my test case doesn't inherently fall into this
category, because we could safely emit the case-range code before the statement
body, but there are examples with labels that can't be fallen into
that would also demonstrate this bug.

rdar://problem/8837067



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@123303 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
4765fa05b5652fcc4356371c2f481d0ea9a1b007 06-Dec-2010 John McCall <rjmccall@apple.com> Rename CXXExprWithTemporaries -> ExprWithCleanups; there's no theoretical
reason this is limited to C++, and it's certainly not limited to temporaries.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@120996 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
44680786286f4f651603c6811f8412a3ee7fe975 07-Nov-2010 John McCall <rjmccall@apple.com> ARM EH uses a different personality function in C.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@118366 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
14e1bc9201681a52e06b0544ee800b422f6f3efe 29-Oct-2010 John McCall <rjmccall@apple.com> Don't assert on attempts to throw 'bool'. I wonder if in the history of C++
anyone has ever intentionally done this outside of a compiler test case.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@117645 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
b6bbcc9995186799a60ce17d0c1acff31601653a 15-Oct-2010 John McCall <rjmccall@apple.com> Death to blocks, or at least the word "block" in one particular obnoxiously
ambiguous context.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116567 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
b25938303de0976b9f189363d43033e5788e3d36 16-Sep-2010 John McCall <rjmccall@apple.com> Opportunistically use the C++ personality function in ObjC++
translation units that don't catch ObjC types. rdar://problem/8434851



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@114070 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
558d2abc7f9fd6801cc7677200992313ae90b5d8 15-Sep-2010 John McCall <rjmccall@apple.com> one piece of code is responsible for the lifetime of every aggregate
slot. The easiest way to do that was to bundle up the information
we care about for aggregate slots into a new structure which demands
that its creators at least consider the question.

I could probably be convinced that the ObjC 'needs GC' bit should
be rolled into this structure.
Implement generalized copy elision. The main obstacle here is that
IR-generation must be much more careful about making sure that exactly



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@113962 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
91a16fa3265686b90054715eea504d9b4a13438b 21-Aug-2010 Daniel Dunbar <daniel@zuster.org> IRgen: Change Emit{Load,Store}OfScalar to take a required Alignment argument and
update callers as best I can.
- This is a work in progress, our alignment handling is very horrible / sketchy -- I am just aiming for monotonic improvement.
- Serious review appreciated.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111707 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
cd2d2b7814e0104ed41a8da159a06a8ca77b70d8 13-Aug-2010 John McCall <rjmccall@apple.com> Sketch out a framework for delaying the activation of a cleanup.
Not yet complete or used.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111044 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
a5f2de2e49e25ece82dd9fd63d8f390a7cda6417 11-Aug-2010 John McCall <rjmccall@apple.com> When re-raising an exception after a cleanup, we need to call _Unwind_Resume_or_Rethrow
instead of _Unwind_Resume. With SJLJ exceptions, this is spelled
"_Unwind_SjLj_Resume_or_Rethrow", not "_Unwind_SjLj_Resume", which has
significantly different semantics.

We should actually never be generating a call to _Unwind_SjLj_Resume directly;
even if we were generating true cleanups (which we aren't because of the
horrible hack), we should be calling __cxa_end_cleanup() on ARM. I
haven't implemented this because there's little point as long as the HH is
present.

I believe this fixes <rdar://problem/8281377>.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@110851 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
d96a8e771ca9f406f0fa1dd4639997335ae444a7 11-Aug-2010 John McCall <rjmccall@apple.com> Fix a bug in @finally emission in both the fragile and non-fragile EH schemes
where we weren't accounting for the possibility that a @finally block might
have internal cleanups and therefore might write to the cleanup destination slot.

Fixes <rdar://problem/8293901>.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@110760 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
5a180397870944548aaadeaebf58e415885b9489 24-Jul-2010 John McCall <rjmccall@apple.com> Support catching Objective C pointers in C++ under the non-fragile NeXT runtime.
Diagnose attempts to do this under the GNU or fragile NeXT runtimes.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@109298 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
ff8e11579fc904aa4032d90d2be6ce1ac5fc9fe1 23-Jul-2010 John McCall <rjmccall@apple.com> Revise cleanup IR generation to fix a major bug with cleanups (PR7686)
as well as some significant asymptotic inefficiencies with threading
multiple jumps through deep cleanups.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@109274 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
1f0fca54676cfa8616e7f3cd7a26788ab937e3cd 21-Jul-2010 John McCall <rjmccall@apple.com> Rename LazyCleanup -> Cleanup. No functionality change for these last three
commits.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@109000 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
7495f22934d577c71b4b5bae82142ad54ccb1d59 21-Jul-2010 John McCall <rjmccall@apple.com> Rip out EHCleanupScope.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108999 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
6962f8d156735172146ae812732f4c4ddc13e91b 21-Jul-2010 John McCall <rjmccall@apple.com> Kill the CleanupBlock API.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108998 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
77199713ab56f87ffad9a535ff2a0877704eed87 21-Jul-2010 John McCall <rjmccall@apple.com> Switch finally cleanups over to being lazy cleanups. We get basically nothing
from the laziness features here except better block ordering, but it removes yet
another CleanupBlock use.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108990 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
55b20fc514678ff8ae1627cd9aef047d1f780119 21-Jul-2010 John McCall <rjmccall@apple.com> Convert the end-catch call for finally blocks to a lazy cleanup. This kills off
the last of the shared-code cleanups.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108975 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
204b075fcc47c3f2aa7276dfba9b42eb25840b53 21-Jul-2010 John McCall <rjmccall@apple.com> Fix the IR generation for catching pointers by references.
Fixes <rdar://problem/8212123>.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108944 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
8262b6a44c98cf14e1d5f347a01e6bf44858198f 17-Jul-2010 John McCall <rjmccall@apple.com> The GNU-runtime ObjC personality function doesn't let us rethrow with URR for
multiple reasons. Rethrow with _objc_exception_throw instead. Fixes PR7656.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108595 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
3e29f96988b0438e42dba3790f61fb3df42d90cb 14-Jul-2010 John McCall <rjmccall@apple.com> Work around an obnoxious GCC warning by changing semantics in a hopefully-
harmless way.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108295 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
fcd5c0c62ef3d86ecd991753bb43c88c861470e7 14-Jul-2010 John McCall <rjmccall@apple.com> Switch the __cxa_rethrow cleanup to be lazy.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108288 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
8e3f86193995c47ee0d229e4336c3382410f09f5 14-Jul-2010 John McCall <rjmccall@apple.com> Allow for the possibility that __cxa_end_catch might throw for a catch-all block
or a catch of a record type by value or reference. Also convert this to a
lazy cleanup.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108287 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
09faeabf39a6fab2e2beb6bf03da970c17d2049a 13-Jul-2010 John McCall <rjmccall@apple.com> Switch the __cxa_free_exception cleanup to be lazy.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108276 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
da65ea86482bc116906edfb9ba1d7124f76cc867 13-Jul-2010 John McCall <rjmccall@apple.com> Teach IR generation how to lazily emit cleanups. This has a lot of advantages,
mostly in avoiding unnecessary work at compile time but also in producing more
sensible block orderings.

Move the destructor cleanups for local variables over to use lazy cleanups.
Eventually all cleanups will do this; for now we have some awkward code
duplication.

Tell IR generation just to never produce landing pads in -fno-exceptions.
This is a much more comprehensive solution to a problem which previously was
half-solved by checks in most cleanup-generation spots.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108270 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
59a7000a79118e4c140885ccbb2ac6a686a73092 07-Jul-2010 John McCall <rjmccall@apple.com> Teach function-try-blocks on constructors and destructors to implicitly
rethrow. Fixes rdar://problem/7696603



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@107757 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
f1549f66a8216a78112286e3978cea2c29d6334c 06-Jul-2010 John McCall <rjmccall@apple.com> Validated by nightly-test runs on x86 and x86-64 darwin, including after
self-host. Hopefully these results hold up on different platforms.

I tried to keep the GNU ObjC runtime happy, but it's hard for me to test.
Reimplement how clang generates IR for exceptions. Instead of creating new
invoke destinations which sequentially chain to the previous destination,
push a more semantic representation of *why* we need the cleanup/catch/filter
behavior, then collect that information into a single landing pad upon request.

Also reorganizes how normal cleanups (i.e. cleanups triggered by non-exceptional
control flow) are generated, since it's actually fairly closely tied in with
the former. Remove the need to track which cleanup scope a block is associated
with.

Document a lot of previously poorly-understood (by me, at least) behavior.

The new framework implements the Horrible Hack (tm), which requires every
landing pad to have a catch-all so that inlining will work. Clang no longer
requires the Horrible Hack just to make exceptions flow correctly within
a function, however. The HH is an unfortunate requirement of LLVM's EH IR.




git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@107631 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
1d110e05e0ff48c1c7a483d6b7fd094cdf28316a 01-Jul-2010 Douglas Gregor <dgregor@apple.com> Remove unnecessary ASTContext parameter from
CXXRecordDecl::getDestructor(); no functionality change.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@107394 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
77b89b87c3b9220fea1bc80f6d6598d2003cc8a8 27-Jun-2010 Chris Lattner <sabre@nondot.org> finally get around to doing a significant cleanup to irgen:
have CGF create and make accessible standard int32,int64 and
intptr types. This fixes a ton of 80 column violations
introduced by LLVMContextification and cleans up stuff a lot.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@106977 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
8019c45024be3026f854e3d22bfd89842be82266 28-May-2010 Daniel Dunbar <daniel@zuster.org> Fix personality function name when using SjLj exceptions.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@104999 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
dcf22ad88fdb6c4dd74f9065262cde8bac4f807b 17-May-2010 Chandler Carruth <chandlerc@gmail.com> Fix an ambiguous else warning from GCC by adding some much needed curlies.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@103972 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
79a9ad8e5eec3696989354be13a74a1106f64f72 17-May-2010 David Chisnall <csdavec@swan.ac.uk> Pick the correct personality function based on the language. This prevents link failures when C/ObjC code uses __attribute__((cleanup())) (previously this was inserting references to two libstc++ symbols; the personality function and the __terminate() function).

This is still probably wrong for Objective-C++ and adds a couple of lines in CGException that should probably be in the CGObjCRuntime subclass. The personality function is now only looked up in one place in CGException though, so this should be easier to fix in the future.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@103938 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
86a3a03667bdb0dcab7e6a2877dfd234b07a6d43 16-May-2010 Douglas Gregor <dgregor@apple.com> When initializing thread-safe statics, put the call to
__cxa_guard_abort along the exceptional edge into (in effect) a nested
"try" that rethrows after aborting. Fixes PR7144 and the remaining
Boost.ProgramOptions failures, along with the regressions that r103880
caused.

The crucial difference between this and r103880 is that we now follow
LLVM's little dance with the llvm.eh.exception and llvm.eh.selector
calls, then use _Unwind_Resume_or_Rethrow to rethrow.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@103892 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
1eb2e59338c4b9c0429fc39ca98662adc9e7a3f2 16-May-2010 Douglas Gregor <dgregor@apple.com> Revert r103880 (thread-safe static initialization w/ exceptions),
because it's causing strange linker errors. Unfixes PR7144.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@103890 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
bfcc823a5c53dabab8cfc842bfea70e2b69cdee0 15-May-2010 Douglas Gregor <dgregor@apple.com> When initializing thread-safe statics, put the call to
__cxa_guard_abort along the exceptional edge into (in effect) a nested
"try" that rethrows after aborting. Fixes PR7144 and the remaining
Boost.ProgramOptions failures.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@103880 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
9dffe6f51c676c1e423c382c62d1648746e36cd4 30-Apr-2010 John McCall <rjmccall@apple.com> Fix -fno-rtti -fexceptions by forcing the emission of (non-"builtin") RTTI
when used by the exceptions routines. Fixes PR 6974.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102684 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
891f80ec2fb2d1730b769467d602689e1080845b 30-Apr-2010 John McCall <rjmccall@apple.com> Teach EHCleanupBlock to deal appropriately with the possibility that there
might not have been an insertion block set at start. Fixes PR6975.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102677 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
ac418162692a951ca3796d6830496a85a2d12493 22-Apr-2010 John McCall <rjmccall@apple.com> Call PerformCopyInitialization to properly initialize the exception temporary
in a throw expression. Use EmitAnyExprToMem to emit the throw expression,
which magically elides the final copy-constructor call (which raises a new
strict-compliance bug, but baby steps). Give __cxa_throw a destructor pointer
if the exception type has a non-trivial destructor.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102039 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
3d3ec1c099ec8bfac3aa1fb0126fe515b7c7fa05 21-Apr-2010 John McCall <rjmccall@apple.com> Miscellaneous codegen cleanups. Mostly, don't create new basic blocks
just to save the current insertion state! This change significantly
simplifies the IR CFG in exceptions code.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@101996 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
7c647a1270cbe02f5e64cee9e3f3ddc176ed61e9 18-Mar-2010 Benjamin Kramer <benny.kra@googlemail.com> Replace some SmallVectors with arrays.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98833 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
9fc6a7774643a810c8501dae2323e863fefb623e 19-Feb-2010 John McCall <rjmccall@apple.com> More refactoring around constructor/destructor code generation.
Fix some bugs with function-try-blocks and simplify normal try-block
code generation.

This implementation excludes a deleting destructor's call to
operator delete() from the function-try-block, which I believe
is correct but which I can't find straightforward support for at
a moment's glance.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@96670 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
b2987d159a88ab0ee2e40c884eb4d77b42ab89b6 10-Feb-2010 Daniel Dunbar <daniel@zuster.org> Switch to using -fsjlj-exceptions instead of hard-coding it. Notably, this fixes
calls to the UnwindResumeOrRethrow function for C++/Obj-C exception handling,
for Darwin ARM.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@95787 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
1851a12605bc6f1ea70d11974a315340ebaab6eb 07-Feb-2010 Anders Carlsson <andersca@mac.com> Make sure to set vtable pointers in the destructors as well.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@95525 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
a994ee4b197554282ae6b222c3284ccaa3a6484c 07-Feb-2010 Anders Carlsson <andersca@mac.com> Make EmitStartEHSpec and EmitEndEHSpec return early when exceptions are disabled.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@95509 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
04a67a6aa3dfdc92d57f7f8d93ba397348c868a4 05-Feb-2010 John McCall <rjmccall@apple.com> Standardize the parsing of function type attributes in a way that
follows (as conservatively as possible) gcc's current behavior: attributes
written on return types that don't apply there are applied to the function
instead, etc. Only parse CC attributes as type attributes, not as decl attributes;
don't accepet noreturn as a decl attribute on ValueDecls, either (it still
needs to apply to other decls, like blocks). Consistently consume CC/noreturn
information throughout codegen; enforce this by removing their default values
in CodeGenTypes::getFunctionInfo().



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@95436 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
13b2f92184bb7a310b800dd7e22c320361a72c4d 01-Jan-2010 Mike Stump <mrs@apple.com> Fix last patch, catch of reference to non-pointer.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92386 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
b606c384684f317cd75cdb1a2b2b172a42ee7706 01-Jan-2010 Mike Stump <mrs@apple.com> Fix catching a reference to a pointer.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92385 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
f3c47c9525153aea2de0ec4bd615b9cf2d81c103 24-Dec-2009 Anders Carlsson <andersca@mac.com> Pass ReturnValueSlot to EmitCall. No functionality change yet.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92138 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
63df2ae96bd0477a7d516814750640b7ce348a71 24-Dec-2009 Mike Stump <mrs@apple.com> Cleanup some dead code.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92122 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
154fe9812faddcd94568a64aee5f3cb0d47003d9 23-Dec-2009 Douglas Gregor <dgregor@apple.com> There is no such thing as typeinfo for a cv-qualified type. Assert
that this is true when mangling, then fix up the various places in
Sema and/or CodeGen that need to remove qualifiers. Addresses a
linking issue when building LLVM with Clang.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92064 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
1d7088d1d9dc99e5478c0184a3e21cafef2a0b53 17-Dec-2009 Anders Carlsson <andersca@mac.com> Rename GetAddrOfRTTI to GetAddrOfRTTIDescriptor. Remove the overload that takes a CXXRecordDecl since we were just creating a QualType from it anyway.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91590 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
f2945c0a74ec15d4d171b34a98e7ef109b9b414b 17-Dec-2009 Mike Stump <mrs@apple.com> Ensure we run cleanups for CXXTemporaries on the exceptional edge. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91588 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
e8e4a1c0bf2e3dd26dd0721a102307bbb589e96a 16-Dec-2009 Anders Carlsson <andersca@mac.com> Use GetAddrOfRTTI everywhere and remove GenerateRTTI and GenerateRTTIRef. With this change, we can now compile and link TableGen.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91520 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
60cfcecaf48e4310339dcfbdb0e3f0e6d2853855 13-Dec-2009 Chandler Carruth <chandlerc@gmail.com> Silence some release build warnings.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91234 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
9f61aa9e280adea9fbf3365f0e4f6ed568c9885a 12-Dec-2009 Jeffrey Yasskin <jyasskin@google.com> Un-namespace-qualify llvm_unreachable. It's a macro, so the qualification gave
no extra safety anyway.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91207 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
8370c58b9295b32bee50443fe3ac43a47a2047e8 11-Dec-2009 Anders Carlsson <andersca@mac.com> When an exception needs to be freed by calling __cxa_exception_free, make sure to stash away the exception pointer somewhere.

This fixes an "Instruction does not dominate all uses!" verification error when compiling TableGen.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91084 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
0924a8a06f6b5ccf0c34d26ce25d680c045ea915 11-Dec-2009 Mike Stump <mrs@apple.com> Fix spacing.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91078 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
5030a98e20e7501366cf50a7e8b92dc016b98bfb 10-Dec-2009 Mike Stump <mrs@apple.com> Setup cleanup on eh edge out of the construction of the cleanup object
during throw to deallocate the exception object. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91035 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
8755ec336108839b9621c3b18f0e175f8a3b671c 10-Dec-2009 Mike Stump <mrs@apple.com> Fixup spacing.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91001 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
182f383db1782af752ecaf607fdff72a8542088b 10-Dec-2009 Mike Stump <mrs@apple.com> Ensure we only generate one terminate handler.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90998 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
23e17c81d508a124c980ae8d198a7b70292298b5 10-Dec-2009 Mike Stump <mrs@apple.com> Remove obsolete FIXME and some dead fallback code.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90997 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
76958099828bac6ebd45abef9f76934b3e99e397 10-Dec-2009 Mike Stump <mrs@apple.com> Add terminate handler for copy constructors for thrown objects. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90994 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
9b39c51ae3c547568ac42325f94b4197618f6b18 09-Dec-2009 Mike Stump <mrs@apple.com> Break out code for reuse. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90991 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
d88ea5687968640ada2bc5a10211cbeb68a671ec 09-Dec-2009 Mike Stump <mrs@apple.com> Add cleanups for exceptional edges. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90940 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
4e0179f03074f7a280da2c9691dc344500c79c90 08-Dec-2009 Mike Stump <mrs@apple.com> Add fixme.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90884 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
e64d434a3450c803beebc09920e111374397a4d2 08-Dec-2009 Mike Stump <mrs@apple.com> Remove some old code. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90882 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
b2debeb96da2b1d47ecffddbc35ade97b64af1c2 08-Dec-2009 Mike Stump <mrs@apple.com> Fixup catch parameters with class reference type. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90821 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
cce3d4f9812182ed4e551b7cf0fc86576be8d9c5 08-Dec-2009 Mike Stump <mrs@apple.com> Add codegen support for exception specifications. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90817 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
c2ab48698094f3e6f3acebc38a19b8cb04069b41 07-Dec-2009 Mike Stump <mrs@apple.com> Work around emitters that can't deal with dead code contexts yet.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90796 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
6a1e0eb557d47e85185e09bdf8721f53f4bf9c9c 05-Dec-2009 Mike Stump <mrs@apple.com> Add support for function try blocks.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90622 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
b2c9c0b1c5e25cfbee1403cde12b98f180e6b315 04-Dec-2009 Mike Stump <mrs@apple.com> Fixup nested try blocks.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90576 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
a086783570f76062a345e761811296dc8df571c8 04-Dec-2009 Mike Stump <mrs@apple.com> Fix warning and be sure to set up the rethrow pointer if we fall off
the end of all the catches.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90574 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
fffefeb8ecafa1e1a191a276361fd5acaa0f8c5e 04-Dec-2009 Mike Stump <mrs@apple.com> Try/catch statements seem to be working well enough to turn on.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90538 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
ce0339032a08012cdda99c3e8660b9fc4dfd9baf 04-Dec-2009 Mike Stump <mrs@apple.com> Disable for now, doesn't play nice with the temporary code.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90537 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
0a3816e566db7cd6084310a2f5a3167d0ec30b31 04-Dec-2009 Mike Stump <mrs@apple.com> Fixup reference binding for catch parameters.
Fixup throws and rethrows to use invoke as appropriate.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90513 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
3faae56c3bf75e12e09f3d0f1b7643bffa0479d2 03-Dec-2009 Mike Stump <mrs@apple.com> These are done.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90494 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
d9cb7e97327e148cfc54db5b991d0925686934fb 03-Dec-2009 Mike Stump <mrs@apple.com> Improve catch parameter bindings for scalar non-pointers. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90492 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
f668bd0e059774e44fd3571d998a5ca74cceb97f 03-Dec-2009 Mike Stump <mrs@apple.com> Reflow.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90407 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
6b85fa41214d9d3e8ef635f964fdc1c74f4702d6 03-Dec-2009 Mike Stump <mrs@apple.com> Remove untrue statement.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90377 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
be7c144fcbcc27eec3efaab5f744e3591995dde1 03-Dec-2009 Mike Stump <mrs@apple.com> Cleanups on exceptional edges don't work at all, yet. This doesn't
catch very many of them and if we caught all of them, the errors would
be annoying. I'm working on this next. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90358 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
f7f74675d4e63c4529a4b890c0dd62cf6dc4c476 03-Dec-2009 Mike Stump <mrs@apple.com> Add a cleanup scope for each catch clause.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90357 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
639787c8e989d4c5381da01cff156abf888817c2 02-Dec-2009 Mike Stump <mrs@apple.com> Pull the terminate handler up so that we can use it for the catch
parameter setup code and set up the catch parameter setup code to
protect that code with terminate.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90340 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
de05057932cebc3f43911f87d75869cb7b705a19 02-Dec-2009 Mike Stump <mrs@apple.com> Change rtti/Rtti to RTTI, as it is an acronym.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90334 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
c88b6735ea8d2c0c5126239c0761e0e139117349 02-Dec-2009 Mike Stump <mrs@apple.com> Avoid warning for getTerminateFn defined but not used.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90330 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
666571afadd9dc472da9696377a05b50c9b3f2ab 02-Dec-2009 Mike Stump <mrs@apple.com> terminate doesn't throw.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90308 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
99533834ba8f3658559f334e68a518ebb6388cea 02-Dec-2009 Mike Stump <mrs@apple.com> More exception handling improvements... WIP.

Highlights include:

Add a helper to generate __cxa_free_exception and _ZSt9terminatev.
Add a region to handle EH object deallocation for ctor failures for throw.
Add a terminate handler for __cxa_end_catch.
A framework for adding cleanup actions for the exceptional edges only.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90305 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
0f590be3808365e851352543faa6acbece50b686 01-Dec-2009 Mike Stump <mrs@apple.com> Much work on try/catch statement. WIP.

Highlights include:

Fix __cxa_begin_catch so it now returns a value.
Added getUnwindResumeOrRethrowFn helper to build up calls to
_Unwind_Resume_or_Rethrow.
Broke out object copying code into CopyObject from EmitCXXThrowExpr.
Built up another version of CopyObject that can copy from memory for
use in the catch parameter code.
RTTI generation for type matching for catch.
Code to check for the type match for catch.
Code to generate the catch parameter, WIP, need make sure references
and pointers and copy ctors work.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90205 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
2bf701ee4babb5c4a9ea99ca4675c5ef040bd402 21-Nov-2009 Mike Stump <mrs@apple.com> Checkpoint current work. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89513 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
d1abf673bf133bd779a94978286c92cef86d7d36 20-Nov-2009 Mike Stump <mrs@apple.com> Implement throw d, where d is a class type that requires copy
construction. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89442 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
e36c9abd383267775a5079166e5e02119866c129 20-Nov-2009 Mike Stump <mrs@apple.com> Handle throw d, where d is a class type but only has a trivial copy
constructor. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89438 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
b4eea691866a3fa75722da9eba735c44f140398a 20-Nov-2009 Mike Stump <mrs@apple.com> Add suport for throw;. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89424 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
23886d0dd3294b7b84a171fc9231bdded7f52cd1 20-Nov-2009 Mike Stump <mrs@apple.com> Fix rtti generation for throws. WIP.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89420 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
d3379292f90e1381d3236c68891bb725b02464b6 30-Oct-2009 Anders Carlsson <andersca@mac.com> Get throws limping along, still a bunch of FIXMEs. Too bad we don't support catching anything yet :)

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@85574 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp
756b5c4f9d52642d87d1948bee58f97a4f795b24 30-Oct-2009 Anders Carlsson <andersca@mac.com> Add CGException.cpp, to be used for exception related code generation.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@85560 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CGException.cpp