| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
| |
Now that llvm cannot represent alias cycles, we have to diagnose erros just
before trying to close the cycle. This degrades the errors a bit. The real
solution is what it was before: if we want to provide good errors for these
cases, we have to be able to find a clang level decl given a mangled name
and produce the error from Sema.
llvm-svn: 209008
|
|
|
|
| |
llvm-svn: 208984
|
|
|
|
|
|
|
|
|
|
|
|
| |
In the Microsoft C++ ABI, instance methods always return records
indirectly via the second hidden parameter. This was implemented in
X86_32ABIInfo, but not WinX86_64ABIInfo.
Rather than exposing a handful of boolean methods in the CGCXXABI
interface, we can expose a single method that applies C++ ABI return
value classification rules.
llvm-svn: 208733
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
MSVC always passes 'sret' after 'this', unlike GCC. This required
changing a number of places in Clang that assumed the sret parameter was
always first in LLVM IR.
This fixes win64 MSVC ABI compatibility for methods returning structs.
Reviewers: rsmith, majnemer
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D3618
llvm-svn: 208458
|
|
|
|
|
|
| |
registers'). Bots are now pacified.
llvm-svn: 208425
|
|
|
|
|
|
| |
registers'). This is a followon commit from r208413 which broke the LLVM bots.
llvm-svn: 208422
|
|
|
|
|
|
|
| |
This is the clang counterpart to 208413, which ensures that Homogeneous
Floating-point Aggregates are passed in consecutive registers on ARM.
llvm-svn: 208417
|
|
|
|
| |
llvm-svn: 208324
|
|
|
|
|
|
|
| |
Just because the first "if" didn't fire, doesn't mean we can not have
an HFA in the "else" clause.
llvm-svn: 208216
|
|
|
|
|
|
|
|
|
|
|
|
| |
ABIArgInfo::getExpandWithPadding
In cases where a struct must, according to the AAPCS, not be split between
general purpose and floating point registers, we use
ABIArgInfo::getExpandWithPadding to add the padding arguments. However,
ExpandWithPadding does not work if the struct contains bitfields, so we
instead must use ABIArgInfo::getDirect.
llvm-svn: 208185
|
|
|
|
| |
llvm-svn: 208072
|
|
|
|
|
|
|
| |
This includes the addition of the virtual function:
TargetCodeGenInfo::EmitTargetMD()
llvm-svn: 207832
|
|
|
|
| |
llvm-svn: 207820
|
|
|
|
|
|
|
|
| |
dependent-type-member-pointer.cpp is failing on a win64 bot because
-fms-extensions is not enabled. Use ConvertType rather than relying on
the inheritance attributes. It's less code, but probably slower.
llvm-svn: 207819
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The Win64 ABI docs on MSDN say that arguments bigger than 8 bytes are
passed by reference. Prior to this change, we were only applying this
logic to RecordType arguments. This affects both the Itanium and
Microsoft C++ ABIs.
Reviewers: majnemer
Differential Revision: http://reviews.llvm.org/D3587
llvm-svn: 207817
|
|
|
|
|
|
|
|
| |
test for arm64_be.
This ensures that r203917 (cpirker "AArch64_be varargs processing for ARM ABI") is ported to ARM64.
llvm-svn: 206961
|
|
|
|
|
|
|
|
|
|
|
| |
Unlike the standard AAPCS64 ABI, variadic arguments are always passed on the
stack with the Darwin ABI, and this was not being considered when deciding
whether to expand HFA/HVA arguments in a call. An HFA argument with a "float"
base type was being expanded into separate "float" arguments, each of which
was then extended to a double, resulting in a serious mismatch from what is
expected by the va_arg implementation. <rdar://problem/15777067>
llvm-svn: 206729
|
|
|
|
| |
llvm-svn: 206728
|
|
|
|
|
|
|
| |
This is one of those DarwinPCS differences. It'd been caught in
arguments, but not return values.
llvm-svn: 206594
|
|
|
|
|
|
| |
Another AAPCS bug, part of PR19432.
llvm-svn: 206580
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
| |
llvm-svn: 206304
|
|
|
|
|
|
|
|
|
|
| |
Sema does have a CUDALaunchBoundsAttr, but CodeGen was doing nothing with it.
This change translates CUDALaunchBoundsAttr to maxntidx and minctasm
metadata, which NVPTX then translates to the correct PTX directives.
Patch by Manjunath Kudlur.
llvm-svn: 206302
|
|
|
|
|
|
|
|
|
|
| |
This implements clause C.8 of the AAPCS in the front-end, so that Clang
accurately knows when the registers run out and it has to insert padding before
the stack objects begin.
PR19432.
llvm-svn: 206296
|
|
|
|
|
|
|
| |
This ensures that the overall struct size will be a multiple of 4, as
required by the ABI.
llvm-svn: 205981
|
|
|
|
|
|
|
|
|
|
|
| |
This adds Clang support for the ARM64 backend. There are definitely
still some rough edges, so please bring up any issues you see with
this patch.
As with the LLVM commit though, we think it'll be more useful for
merging with AArch64 from within the tree.
llvm-svn: 205100
|
|
|
|
|
|
| |
Reviewed at http://llvm-reviews.chandlerc.com/D3096
llvm-svn: 205008
|
|
|
|
|
|
|
|
|
| |
This follows the LLVM change to canonicalise the Windows target triple
spellings. Rather than treating each Windows environment as a single entity,
the environments are now modelled properly as an environment. This is a
mechanical change to convert the triple use to reflect that change.
llvm-svn: 204978
|
|
|
|
|
|
| |
arguments(). Updating all of the usages of the iterators with range-based for loops.
llvm-svn: 204068
|
|
|
|
| |
llvm-svn: 203917
|
|
|
|
|
|
| |
iterator_range bases(). Updating all of the usages of the iterators with range-based for loops.
llvm-svn: 203803
|
|
|
|
|
|
|
|
|
|
| |
When a struct has bitfields overlapping with other members
(as required by the AAPCS), clang uses a packed struct to
represent this. If such a struct is large enough for clang to
pass it as a byval pointer (>64 bytes), we need to set the
alignment of the argument to match the original type.
llvm-svn: 203660
|
|
|
|
|
|
| |
class.
llvm-svn: 203643
|
|
|
|
|
|
| |
iterator_range fields(). Updating all of the usages of the iterators with range-based for loops.
llvm-svn: 203355
|
|
|
|
| |
llvm-svn: 202711
|
|
|
|
| |
llvm-svn: 202151
|
|
|
|
|
|
|
|
| |
Previously the X86 backend would look for the sret attribute and handle
this for us. inalloca takes that all away, so we have to do the return
ourselves now.
llvm-svn: 202097
|
|
|
|
| |
llvm-svn: 202059
|
|
|
|
|
|
|
|
|
|
| |
According to the AAPCS, we can split structs between GPRs and the stack,
except for when an argument has already been allocated on the stack. This
can occur when a large number of floating-point arguments fill up the VFP
registers, and are alllocated on the stack before the general-purpose argument
registers are full.
llvm-svn: 201137
|
|
|
|
|
|
|
|
|
| |
An HFA is defined as a struct containing floating point values of the
same machine type. In the 32-bit ABI, double and long double have the
same machine type, so a struct with a mixture of these types must be an
HFA (assuming it meets the other criteria).
llvm-svn: 200971
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When a non-trivial parameter is present, clang now gathers up all the
parameters that lack inreg and puts them into a packed struct. MSVC
always aligns each parameter to 4 bytes and no more, so this is a pretty
simple struct to lay out.
On win64, non-trivial records are passed indirectly. Prior to this
change, clang was incorrectly using byval on win64.
I'm able to self-host a working clang with this change and additional
LLVM patches.
Reviewers: rsmith
Differential Revision: http://llvm-reviews.chandlerc.com/D2636
llvm-svn: 200597
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes PR15768, where the sret parameter and the 'this' parameter
are in the wrong order.
Instance methods compiled by MSVC never return records in registers,
they always return indirectly through an sret pointer. That sret
pointer always comes after the 'this' parameter, for both __cdecl and
__thiscall methods.
Unfortunately, the same is true for other calling conventions, so we'll
have to change the overall approach here relatively soon.
Reviewers: rsmith
Differential Revision: http://llvm-reviews.chandlerc.com/D2664
llvm-svn: 200587
|
|
|
|
|
|
|
|
|
| |
Arguments and return values must always be marshalled as for the base
AAPCS when the callee is a variadic function.
Patch by Oliver Stannard!
llvm-svn: 200307
|
|
|
|
|
|
|
|
|
| |
Currently it tracks the number of free registers, but soon it will track
stack offsets for inalloca lowering.
No functional change.
llvm-svn: 199532
|
|
|
|
| |
llvm-svn: 199037
|
|
|
|
|
|
| |
same attribute. Also removes a hasAttr that's not required. No functional changes intended.
llvm-svn: 197675
|
|
|
|
|
|
| |
change intended -- this only replaces Boolean uses of getAttr.
llvm-svn: 197648
|
|
|
|
| |
llvm-svn: 197406
|
|
|
|
|
|
| |
so use the same exception size as GNUEABI does.
llvm-svn: 197404
|
|
|
|
|
|
| |
Triple::getEnvironment.
llvm-svn: 197181
|