History log of /llvm-project-15.0.7/clang/lib/CodeGen/CGExprAgg.cpp (Results 276 – 300 of 476)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# 8d752430 25-Aug-2010 John McCall <[email protected]>

Expression statements undergo lvalue-to-rvalue conversion in C,
but not in C++, so don't emit aggregate loads of volatile references
in null context in C++. Happens to have been caught by an asserti

Expression statements undergo lvalue-to-rvalue conversion in C,
but not in C++, so don't emit aggregate loads of volatile references
in null context in C++. Happens to have been caught by an assertion.
We do not get the scalar case right. Volatiles are really broken.

llvm-svn: 112019

show more ...


# 630c76ef 22-Aug-2010 Douglas Gregor <[email protected]>

When performing value-initialization for a class with a non-trivial,
implicitly-defined default constructor, zero-initialize the memory
before calling the default constructor. Previously, we would on

When performing value-initialization for a class with a non-trivial,
implicitly-defined default constructor, zero-initialize the memory
before calling the default constructor. Previously, we would only
zero-initialize in the case of a trivial default constructor.

Also, simplify the hideous logic that determines when we have a
trivial default constructor and, therefore, don't need to emit any
call at all.

llvm-svn: 111779

show more ...


# a1dee530 22-Aug-2010 John McCall <[email protected]>

Experiment with using first-class aggregates to represent member function
pointers. I find the resulting code to be substantially cleaner, and it
makes it very easy to use the same APIs for data mem

Experiment with using first-class aggregates to represent member function
pointers. I find the resulting code to be substantially cleaner, and it
makes it very easy to use the same APIs for data member pointers (which I have
conscientiously avoided here), and it avoids a plethora of potential
inefficiencies due to excessive memory copying, but we'll have to see if it
actually works.

llvm-svn: 111776

show more ...


# 1c456c89 22-Aug-2010 John McCall <[email protected]>

Abstract out member-pointer creation. I'm really unhappy about the current
duplication between the constant and non-constant paths in all of this.

Implement ARM ABI semantics for member pointer con

Abstract out member-pointer creation. I'm really unhappy about the current
duplication between the constant and non-constant paths in all of this.

Implement ARM ABI semantics for member pointer constants and conversion.

llvm-svn: 111772

show more ...


# 84fa510a 22-Aug-2010 John McCall <[email protected]>

Abstract more member-pointerness out.

llvm-svn: 111771


# a8bbb82c 22-Aug-2010 John McCall <[email protected]>

Abstract out member-pointer conversions.

Pretty much everything having to do with member pointers is ABI-specific.

llvm-svn: 111770


# e50dda95 21-Aug-2010 Daniel Dunbar <[email protected]>

IRgen/LValue: Add LValue::setNonGC instead of SetObjCNonGC, for consistency with isNonGC().

llvm-svn: 111718


# 2e442a00 21-Aug-2010 Daniel Dunbar <[email protected]>

IRgen: Switch more MakeAddr() users to MakeAddrLValue; this time for calls which were previously not computing the qualifier list. In most cases, I don't think it matters, but I believe this is conse

IRgen: Switch more MakeAddr() users to MakeAddrLValue; this time for calls which were previously not computing the qualifier list. In most cases, I don't think it matters, but I believe this is conservatively more correct / consistent.

llvm-svn: 111717

show more ...


# f6fb7e2b 21-Aug-2010 Daniel Dunbar <[email protected]>

IRgen: Switch a bunch of trivial MakeAddr calls to use MakeAddrLValue.

llvm-svn: 111716


# cf142165 07-Aug-2010 John McCall <[email protected]>

Store inheritance paths after CastExprs instead of inside them.
This takes some trickery since CastExpr has subclasses (and indeed,
is abstract).

Also, smoosh the CastKind into the bitfield from Exp

Store inheritance paths after CastExprs instead of inside them.
This takes some trickery since CastExpr has subclasses (and indeed,
is abstract).

Also, smoosh the CastKind into the bitfield from Expr.

Drops two words of storage from Expr in the common case of expressions
which don't need inheritance paths. Avoids a separate allocation and
another word of overhead in cases needing inheritance paths. Also has
the advantage of not leaking memory, since destructors for AST nodes are
never run.

llvm-svn: 110507

show more ...


# 51954276 13-Jul-2010 Douglas Gregor <[email protected]>

Introduce a new cast kind for an "lvalue bitcast", which handles
reinterpret_casts (possibly indirectly via C-style/functional casts)
on values, e.g.,

int i;
reinterpret_cast<short&>(i);

The I

Introduce a new cast kind for an "lvalue bitcast", which handles
reinterpret_casts (possibly indirectly via C-style/functional casts)
on values, e.g.,

int i;
reinterpret_cast<short&>(i);

The IR generated for this is essentially the same as for

*reinterpret_cast<short*>(&i).

Fixes PR6437, PR7593, and PR7344.

llvm-svn: 108294

show more ...


# 747eb784 08-Jul-2010 Douglas Gregor <[email protected]>

Reinstate the fix for PR7556. A silly use of isTrivial() was
suppressing copies of objects with trivial copy constructors.

llvm-svn: 107857


# cb7696cf 08-Jul-2010 Chris Lattner <[email protected]>

fix the clang side of PR7437: EmitAggregateCopy
was not producing a memcpy with the right address
spaces because of two places in it doing casts of
the arguments to i8, one of which that didn't
prese

fix the clang side of PR7437: EmitAggregateCopy
was not producing a memcpy with the right address
spaces because of two places in it doing casts of
the arguments to i8, one of which that didn't
preserve the address space.

There is also an optimizer bug here.

llvm-svn: 107842

show more ...


# e182370e 07-Jul-2010 Douglas Gregor <[email protected]>

Revert r107828 and r107827, the fix for PR7556, which seems to be
breaking bootstrap on Linux.

llvm-svn: 107837


# 6df2b8c3 07-Jul-2010 Douglas Gregor <[email protected]>

Rename CXXZeroInitValueExpr to CXXScalarValueInitExpr, to reflect its
newly-narrowed scope. No functionality change.

llvm-svn: 107828


# bd30929e 06-Jul-2010 John McCall <[email protected]>

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 ha

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.

llvm-svn: 107631

show more ...


# 818efb64 27-Jun-2010 Chris Lattner <[email protected]>

misc tidying

llvm-svn: 106978


# 5e016ae9 27-Jun-2010 Chris Lattner <[email protected]>

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 LLVMCo

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.

llvm-svn: 106977

show more ...


# 04775f84 26-Jun-2010 Anders Carlsson <[email protected]>

Change EmitReferenceBindingToExpr to take a decl instead of a boolean.

llvm-svn: 106949


# 021510e9 15-Jun-2010 Fariborz Jahanian <[email protected]>

Patch adds support for copying of those
objective-c++ class objects which have GC'able objc object
pointers and need to use ObjC's objc_memmove_collectable
API (radar 8070772).

llvm-svn: 106061


# c8731be3 30-May-2010 Eli Friedman <[email protected]>

Fix for PR7040: Don't try to compute the LLVM type for a function where it
isn't possible to compute.

This patch is mostly refactoring; the key change is the addition of the code
starting with the c

Fix for PR7040: Don't try to compute the LLVM type for a function where it
isn't possible to compute.

This patch is mostly refactoring; the key change is the addition of the code
starting with the comment, "Check whether the function has a computable LLVM
signature." The solution here is essentially the same as the way the
vtable code handles such functions.

llvm-svn: 105151

show more ...


# cc04e9f6 22-May-2010 John McCall <[email protected]>

Re-teach IR gen to perform GC moves on rvalues resulting from various ObjC
expressions. Essentially, GC breaks a certain form of the return-value
optimization.

llvm-svn: 104454


# c0964b60 22-May-2010 Anders Carlsson <[email protected]>

Re-land the fix for PR7139.

llvm-svn: 104446


# aae38d66 22-May-2010 Douglas Gregor <[email protected]>

Improve our handling of reference binding for subobjects of
temporaries. There are actually several interrelated fixes here:

- When converting an object to a base class, it's only an lvalue
cast

Improve our handling of reference binding for subobjects of
temporaries. There are actually several interrelated fixes here:

- When converting an object to a base class, it's only an lvalue
cast when the original object was an lvalue and we aren't casting
pointer-to-derived to pointer-to-base. Previously, we were
misclassifying derived-to-base casts of class rvalues as lvalues,
causing various oddities (including problems with reference binding
not extending the lifetimes of some temporaries).

- Teach the code for emitting a reference binding how to look
through no-op casts and parentheses directly, since
Expr::IgnoreParenNoOpCasts is just plain wrong for this. Also, make
sure that we properly look through multiple levels of indirection
from the temporary object, but destroy the actual temporary object;
this fixes the reference-binding issue mentioned above.

- Teach Objective-C message sends to bind the result as a temporary
when needed. This is actually John's change, but it triggered the
reference-binding problem above, so it's included here. Now John
can actually test his return-slot improvements.

llvm-svn: 104434

show more ...


# 78a15113 22-May-2010 John McCall <[email protected]>

Push a return-value slot throughout ObjC message-send codegen. Will be
critical for ObjC++ correctness; hard to test independently of various
required Sema changes, though.

llvm-svn: 104422


1...<<11121314151617181920