| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
| |
generated block literal for lambdas which are immediately converted to block pointer type. This simplifies the AST, avoids an unnecessary copy of the lambda and makes it much easier to avoid copying the result onto the heap.
Note that this transformation has a substantial semantic effect outside of ARC: it gives the converted lambda lifetime semantics similar to a block literal. With ARC, the effect is much less obvious because the lifetime of blocks is already managed.
llvm-svn: 151797
|
|
|
|
|
|
| |
here, and generally nicer to the optimizer.
llvm-svn: 151659
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- variant members with nontrivial destructors make the containing class's
destructor deleted
- check for a virtual destructor after checking for overridden methods in the
base class(es)
- check for an inaccessible operator delete for a class with a virtual
destructor.
Do not try to call an anonymous union field's destructor from the destructor of
the containing class.
llvm-svn: 151483
|
|
|
|
|
|
| |
implement the retain+autorelease outside of ARC, and there's a bug that causes the generated code to crash in ARC (which I think is unrelated to my code, although I'm not completely sure).
llvm-svn: 151428
|
|
|
|
| |
llvm-svn: 150931
|
|
|
|
| |
llvm-svn: 150930
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
optional argument passed through the variadic ellipsis)
potentially affects how we need to lower it. Propagate
this information down to the various getFunctionInfo(...)
overloads on CodeGenTypes. Furthermore, rename those
overloads to clarify their distinct purposes, and make
sure we're calling the right one in the right place.
This has a nice side-effect of making it easier to construct
a function type, since the 'variadic' bit is no longer
separable.
This shouldn't really change anything for our existing
platforms, with one minor exception --- we should now call
variadic ObjC methods with the ... in the "right place"
(see the test case), which I guess matters for anyone
running GNUStep on MIPS. Mostly it's just a substantial
clean-up.
llvm-svn: 150788
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
conversion to function pointer. Rather than having IRgen synthesize
the body of this function, we instead introduce a static member
function "__invoke" with the same signature as the lambda's
operator() in the AST. Sema then generates a body for the conversion
to function pointer which simply returns the address of __invoke. This
approach makes it easier to evaluate a call to the conversion function
as a constant, makes the linkage of the __invoke function follow the
normal rules for member functions, and may make life easier down the
road if we ever want to constexpr'ify some of lambdas.
Note that IR generation is responsible for filling in the body of
__invoke (Sema just adds a dummy body), because the body can't
generally be expressed in C++.
Eli, please review!
llvm-svn: 150783
|
|
|
|
|
|
| |
conversion-to-function-pointer operator.
llvm-svn: 150660
|
|
|
|
| |
llvm-svn: 150649
|
|
|
|
| |
llvm-svn: 150452
|
|
|
|
|
|
| |
EmitMemberInitializer. The new function will be used to initialize the fields of lambda expressions.
llvm-svn: 150451
|
|
|
|
|
|
| |
CodeGenModule.
llvm-svn: 149943
|
|
|
|
| |
llvm-svn: 149543
|
|
|
|
|
|
|
| |
around, in the process cleaning up the various gcc/msvc compiler
workarounds.
llvm-svn: 149036
|
|
|
|
|
|
| |
change.)
llvm-svn: 145753
|
|
|
|
|
|
| |
review comment.
llvm-svn: 145741
|
|
|
|
|
|
| |
I'll be introducing uses of the specified alignment soon.
llvm-svn: 145736
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Start handling debug line and scope information better:
Migrate most of the location setting within the larger API in CGDebugInfo and
update a lot of callers.
Remove the existing file/scope change machinery in UpdateLineDirectiveRegion
and replace it with DILexicalBlockFile usage.
Finishes off the rest of rdar://10246360
after fixing a few bugs that were exposed in gdb testsuite testing.
llvm-svn: 141893
|
|
|
|
| |
llvm-svn: 141796
|
|
|
|
| |
llvm-svn: 141773
|
|
|
|
|
|
|
|
|
|
|
| |
Migrate most of the location setting within the larger API in CGDebugInfo and
update a lot of callers.
Remove the existing file/scope change machinery in UpdateLineDirectiveRegion
and replace it with DILexicalBlockFile usage.
Finishes off the rest of rdar://10246360
llvm-svn: 141732
|
|
|
|
|
|
| |
exist anymore.
llvm-svn: 140739
|
|
|
|
| |
llvm-svn: 140506
|
|
|
|
| |
llvm-svn: 140504
|
|
|
|
| |
llvm-svn: 140502
|
|
|
|
|
|
|
|
| |
generation when we're dealing with an implicitly-defined copy or move
constructor. And, actually set the implicitly-defined bit for
implicitly-defined constructors and destructors. Should fix self-host.
llvm-svn: 140334
|
|
|
|
|
|
|
| |
they still need the logic to cope with array member
initialization. Fixes PR10720.
llvm-svn: 140302
|
|
|
|
|
|
|
|
|
| |
Prior to C++11, this
has no effect since any such destructors must be trivial, and in C++11 such destructors must not
be called.
llvm-svn: 139997
|
|
|
|
| |
llvm-svn: 139770
|
|
|
|
|
|
| |
we don't need to.
llvm-svn: 139769
|
|
|
|
|
|
|
|
|
| |
This makes the code duplication of implicit special member handling even worse,
but the cleanup will have to come later. For now, this works.
Follow-up with tests for explicit defaulting and enabling the __has_feature
flag to come.
llvm-svn: 138821
|
|
|
|
|
|
|
|
|
|
| |
emit call results into potentially aliased slots. This allows us
to properly mark indirect return slots as noalias, at the cost
of requiring an extra memcpy when assigning an aggregate call
result into a l-value. It also brings us into compliance with
the x86-64 ABI.
llvm-svn: 138599
|
|
|
|
|
|
|
| |
creators to tell us whether something needs GC barriers.
No functionality change.
llvm-svn: 138581
|
|
|
|
| |
llvm-svn: 137126
|
|
|
|
|
|
|
|
| |
LLVM.h imports
them into the clang namespace.
llvm-svn: 135852
|
|
|
|
| |
llvm-svn: 135370
|
|
|
|
| |
llvm-svn: 135036
|
|
|
|
|
|
| |
partial destruction.
llvm-svn: 135033
|
|
|
|
| |
llvm-svn: 135029
|
|
|
|
|
|
| |
of flags. No functionality change.
llvm-svn: 134997
|
|
|
|
|
|
| |
and kill a lot of redundant code.
llvm-svn: 134988
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Emit default-initialization of arrays that were partially initialized
with initializer lists with a loop, rather than emitting the default
initializer N times;
- support destroying VLAs of non-trivial type, although this is not
yet exposed to users; and
- support the partial destruction of arrays initialized with
initializer lists when an initializer throws an exception.
llvm-svn: 134784
|
|
|
|
|
|
| |
by removing the redundant type parameter.
llvm-svn: 133860
|
|
|
|
| |
llvm-svn: 133144
|
|
|
|
|
|
|
|
|
|
| |
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.
llvm-svn: 133103
|
|
|
|
| |
llvm-svn: 132878
|
|
|
|
|
|
|
| |
optimization. Make sure to require a vtable when trying to get the address
of a VTT, otherwise we would never end up emitting the VTT.
llvm-svn: 131400
|
|
|
|
| |
llvm-svn: 131385
|
|
|
|
| |
llvm-svn: 131372
|