Commit Graph

106091 Commits

Author SHA1 Message Date
David Majnemer
4eff4f7003 Merging r215818:
------------------------------------------------------------------------
r215818 | majnemer | 2014-08-16 02:23:42 -0700 (Sat, 16 Aug 2014) | 12 lines

InstCombine: Fix a potential bug in 0 - (X sdiv C)  -> (X sdiv -C)

While *most* (X sdiv 1) operations will get caught by InstSimplify, it
is still possible for a sdiv to appear in the worklist which hasn't been
simplified yet.

This means that it is possible for 0 - (X sdiv 1) to get transformed
into (X sdiv -1); dividing by -1 can make the transform produce undef
values instead of the proper result.

Sorry for the lack of testcase, it's a bit problematic because it relies
on the exact order of operations in the worklist.
------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223645 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-08 09:11:48 +00:00
David Majnemer
af44f02444 Merging r214385:
------------------------------------------------------------------------
r214385 | majnemer | 2014-07-30 21:49:29 -0700 (Wed, 30 Jul 2014) | 9 lines

InstCombine: Correctly propagate NSW/NUW for x-(-A) -> x+A

We can only propagate the nsw bits if both subtraction instructions are
marked with the appropriate bit.

N.B.  We only propagate the nsw bit in InstCombine because the nuw case
is already handled in InstSimplify.

This fixes PR20189.
------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223644 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-08 09:11:36 +00:00
David Majnemer
f38406688d Fix merge conflict & minor test output differences
git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223643 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-08 09:10:57 +00:00
David Majnemer
e7ec6be8c2 Merging r222500:
------------------------------------------------------------------------
r222500 | majnemer | 2014-11-20 18:37:38 -0800 (Thu, 20 Nov 2014) | 1 line

This Reassociate change unintentionally slipped in r222499
------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223640 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-08 08:54:39 +00:00
David Majnemer
7b92d4ef0c Merging r216891:
------------------------------------------------------------------------
r216891 | majnemer | 2014-09-01 14:20:14 -0700 (Mon, 01 Sep 2014) | 12 lines

SROA: Don't insert instructions before a PHI

SROA may decide that it needs to insert a bitcast and would set it's
insertion point before a PHI.  This will create an invalid module
right quick.

Instead, choose the first insertion point in the basic block that holds
our PHI.

This fixes PR20822.

Differential Revision: http://reviews.llvm.org/D5141
------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223639 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-08 08:53:47 +00:00
David Majnemer
1c417269c7 Merging r217115:
------------------------------------------------------------------------
r217115 | majnemer | 2014-09-03 17:23:13 -0700 (Wed, 03 Sep 2014) | 3 lines

IndVarSimplify: Address review comments for r217102

No functional change intended, just some cleanups and comments added.
------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223638 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-08 08:50:39 +00:00
David Majnemer
280476e7c6 Merging rr217102:
------------------------------------------------------------------------
r217102 | majnemer | 2014-09-03 16:03:18 -0700 (Wed, 03 Sep 2014) | 11 lines

IndVarSimplify: Don't let LFTR compare against a poison value

LinearFunctionTestReplace tries to use the *next* indvar to compare
against when possible.  However, it may be the case that the calculation
for the next indvar has NUW/NSW flags and that it may only be safely
used inside the loop.  Using it in a comparison to calculate the exit
condition could result in observing poison.

This fixes PR20680.

Differential Revision: http://reviews.llvm.org/D5174
------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223637 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-08 08:50:22 +00:00
David Majnemer
6143cdcc6c Merging rr221501:
------------------------------------------------------------------------
r221501 | majnemer | 2014-11-06 16:31:14 -0800 (Thu, 06 Nov 2014) | 7 lines

LoopVectorize: Don't assume pointees are sized

A pointer's pointee might not be sized: the pointee could be a function.

Report this as IK_NoInduction when calculating isInductionVariable.

This fixes PR21508.
------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223636 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-08 08:49:20 +00:00
David Majnemer
c9f58af99d Merging rr222376:
------------------------------------------------------------------------
r222376 | majnemer | 2014-11-19 11:36:18 -0800 (Wed, 19 Nov 2014) | 3 lines

AliasSet: Simplify mergeSetIn

No functional change intended.
------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223635 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-08 08:48:58 +00:00
David Majnemer
a32748ff23 Merging r222338:
------------------------------------------------------------------------
r222338 | majnemer | 2014-11-19 01:41:05 -0800 (Wed, 19 Nov 2014) | 16 lines

AliasSetTracker: UnknownInsts should contribute to the refcount

AliasSetTracker::addUnknown may create an AliasSet devoid of pointers
just to contain an instruction if no suitable AliasSet already exists.
It will then AliasSet::addUnknownInst and we will be done.

However, it's possible for addUnknown to choose an existing AliasSet to
addUnknownInst.
If this were to occur, we are in a bit of a pickle: removing pointers
from the AliasSet can cause the entire AliasSet to become destroyed,
taking our unknown instructions out with them.

Instead, keep track whether or not our AliasSet has any unknown
instructions.

This fixes PR21582.
------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223627 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-08 08:48:09 +00:00
Daniel Sanders
3713d959d3 Merging r215169:
------------------------------------------------------------------------
r215169 | ghoflehner | 2014-08-08 00:19:55 +0100 (Fri, 08 Aug 2014) | 2 lines

Fix for multi-line comment warning

------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223582 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-06 10:34:51 +00:00
Daniel Sanders
00c36568bd Merging r220360:
------------------------------------------------------------------------
r220360 | filcab | 2014-10-22 03:16:06 +0100 (Wed, 22 Oct 2014) | 5 lines

Silence gcc's -Wcomment

gcc's (4.7, I think) -Wcomment warning is not "as smart" as clang's and
warns even if the line right after the backslash-newline sequence only has
a line comment that starts at the beginning of the line.
------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223581 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-06 10:34:24 +00:00
Michael Zolotukhin
b1cab82d1b Merging r223171:
PR21302. Vectorize only bottom-tested loops.

rdar://problem/18886083


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223535 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-05 22:31:29 +00:00
Michael Zolotukhin
b7a6d1fc71 Merging r223170:
Apply loop-rotate to several vectorizer tests.

Such loops shouldn't be vectorized due to the loops form.
After applying loop-rotate (+simplifycfg) the tests again start to check
what they are intended to check.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223534 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-05 22:29:16 +00:00
Michael Zolotukhin
868577b70c Merging r221009:
Correctly update dom-tree after loop vectorizer.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223531 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-05 22:17:26 +00:00
Daniel Sanders
1c954715ed Add the big-endian O32 small structures bugfix to the Mips release notes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223459 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-05 11:06:13 +00:00
Daniel Sanders
27f06d254d Merging r223148:
------------------------------------------------------------------------
r223148 | dsanders | 2014-12-02 20:40:27 +0000 (Tue, 02 Dec 2014) | 17 lines

[mips] Fix passing of small structures for big-endian O32.

Summary:
Like N32/N64, they must be passed in the upper bits of the register.

The new code could be merged with the existing if-statements but I've
refrained from doing this since it will make porting the O32 implementation
to tablegen harder later.

Reviewers: vmedic

Reviewed By: vmedic

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6463

------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223457 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-05 10:20:37 +00:00
Tim Northover
9e3aac616b Merging r223055:
ARM: lower tail calls correctly when using GHC calling convention.

Patch by Ben Gamari.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223406 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-04 22:59:55 +00:00
Duncan P. N. Exon Smith
0817ac89c2 Merging r223163:
------------------------------------------------------------------------
r223163 | cmatthews | 2014-12-02 14:19:21 -0800 (Tue, 02 Dec 2014) | 5 lines

Give lit a --xunit-xml-output option for saving results in xunit format
  
  --xunit-xml-output saves test results to disk in JUnit's xml format. This will allow Jenkins to report the details of a lit run.
  
  Based on a patch by David Chisnall.
------------------------------------------------------------------------


git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223250 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-03 18:17:15 +00:00
Daniel Sanders
59b40b0f4b Moved [ASZ]ExtUpper to the end of the CCValAssign::LocInfo enum.
This makes the 3.5.1 version of libLLVM-3.5.so compatible with the 3.5.0 version.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223242 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-03 17:21:26 +00:00
Daniel Sanders
80b3711ee8 Added release notes for the Mips target.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223231 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-03 13:43:39 +00:00
Daniel Sanders
fbdf576a96 Merged from r221604:
[mips] Fix sret arguments for N32/N64 which were accidentally broken in r221534.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223070 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 19:38:20 +00:00
Daniel Sanders
6f5449ce9f Merged from r221534:
[mips] Promote i32 arguments to i64 for the N32/N64 ABI and fix <64-bit structs...

Summary:
... and after all that refactoring, it's possible to distinguish softfloat
floating point values from integers so this patch no longer breaks softfloat to
do it.

Remove direct handling of i32's in the N32/N64 ABI by promoting them to
i64. This more closely reflects the ABI documentation and also fixes
problems with stack arguments on big-endian targets.

We now rely on signext/zeroext annotations (already generated by clang) and
the Assert[SZ]ext nodes to avoid the introduction of unnecessary sign/zero
extends.

It was not possible to convert three tests to use signext/zeroext. These tests
are bswap.ll, ctlz-v.ll, ctlz-v.ll. It's not possible to put signext on a
vector type so we just accept the sign extends here for now. These tests don't
pass the vectors the same way clang does (clang puts multiple elements in the
same argument, these map 1 element to 1 argument) so we don't need to worry too
much about it.

With this patch, all known N32/N64 bugs should be fixed and we now pass the
first 10,000 tests generated by ABITestGen.py.

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6117




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223069 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 19:33:33 +00:00
Daniel Sanders
b65ea91efe Merged from r221529:
[mips] Removed the remainder of MipsCC. NFC.

Summary:
One of the calls to AllocateStack (the one in LowerCall) doesn't look like
it should be there but it was there before and removing it breaks the
frame size calculation.

Reviewers: vmedic, theraven

Reviewed By: theraven

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6116




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223065 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 19:02:59 +00:00
Daniel Sanders
a68869d1f1 Merged from r221528:
[mips] Remove MipsCC::reservedArgArea() in favour of MipsABIInfo::GetCalleeAllocdArgSizeInBytes(). NFC.

Summary:

Reviewers: theraven, vmedic

Reviewed By: vmedic

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6115




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223063 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 18:57:45 +00:00
Daniel Sanders
20d7e9f3d7 Merged from r221527:
MipsCCState.h: Use LLVM_DELETED_FUNCTION for msc17.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223062 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 18:52:41 +00:00
Daniel Sanders
a06f6f2af5 Merged from r221525:
[mips] Move MipsCCState to a separate file and clang-formatted it.

Summary:

Reviewers: theraven, vmedic

Reviewed By: vmedic

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6114




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223061 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 18:48:22 +00:00
Daniel Sanders
857274fe04 Merged from r221522:
[mips] Fix unused variable warnings introduced in r221521



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223058 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 18:43:35 +00:00
Daniel Sanders
5652743307 Merged from r221521:
[mips] Remove remaining use of MipsCC::intArgRegs() in favour of MipsABIInfo::GetByValArgRegs() and MipsABIInfo::GetVarArgRegs()

Summary:

Reviewers: theraven, vmedic

Reviewed By: vmedic

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6113




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223053 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 17:14:37 +00:00
Daniel Sanders
e9f9537b80 Merged from r221519:
[mips] Remove MipsCC::getRegVT(). NFC

Summary: It's no longer used.

Reviewers: vmedic, theraven

Reviewed By: theraven

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6112



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223052 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 17:12:32 +00:00
Daniel Sanders
d2e0bdc3ff Merged from r221518:
[mips] Remove MipsCC::analyzeCallOperands in favour of CCState::AnalyzeCallOperands. NFC

Summary:
In addition to the usual f128 workaround, it was also necessary to provide
a means of accessing ArgListEntry::IsFixed.

Reviewers: theraven, vmedic

Reviewed By: vmedic

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6111




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223048 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 17:05:38 +00:00
Daniel Sanders
8283cd9f05 Merged from r221517:
[mips] Move SpecialCallingConv to MipsCCState and use it from tablegen-erated code. NFC

Summary:
In the long run, it should probably become a calling convention in its own
right but for now just move it out of
MipsISelLowering::analyzeCallOperands() so that we can drop this function
in favour of CCState::AnalyzeCallOperands().

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6085




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223047 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 17:02:26 +00:00
Daniel Sanders
b9d802e7d9 Merged from r221516:
[mips] Removed IsVarArg from MipsISelLowering::analyzeCallOperands(). NFC.

Summary:
CCState objects already carry this information in their isVarArg() method.

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6084



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223045 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 16:35:35 +00:00
Daniel Sanders
15093b561d Merged from r221463:
[mips] Removed IsSoftFloat from MipsISelLowering::analyzeCallOperands(). NFC

Summary:
It isn't used anymore.

Reviewers: vmedic

Reviewed By: vmedic

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6083




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223044 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 16:33:17 +00:00
Daniel Sanders
05a4461c15 Merged from r221461:
[mips] Removed MipsISelLowering::analyzeFormalArguments() in favour of CCState::AnalyzeFormalArguments()

Summary:
As with returns, we must be able to identify f128 arguments despite them
being lowered away. We do this with a pre-analyze step that builds a
vector and then we use this vector from the tablegen-erated code.

Reviewers: vmedic

Reviewed By: vmedic

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D6081



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223042 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 16:32:03 +00:00
Daniel Sanders
db438499ee Merged from r221146:
[mips] Remove unused prototype and variable. NFC.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223041 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 16:30:07 +00:00
Daniel Sanders
f805dbc7ec Merged from r221081 and r221102:
-------------------------------------------------------------------------------
Revert r221056 and others, "[mips] Move F128 argument handling into MipsCCState as we did for returns. NFC."

  r221056 "[mips] Move F128 argument handling into MipsCCState as we did for returns. NFC."
  r221058 "[mips] Fix unused variable warning introduced in r221056"
  r221059 "[mips] Move all ByVal handling into CCState and tablegen-erated code. NFC."
  r221061 "Renamed CCState members that appear to misspell 'Processed' as 'Proceed'. NFC."

It caused an undefined behavior in LLVM :: CodeGen/Mips/return-vector.ll.

-------------------------------------------------------------------------------
Re-commit r221056 and others with fix, "[mips] Move F128 argument handling into MipsCCState as we did for returns. NFC."

sret arguments can never originate from an f128 argument so we detect
sret arguments and push false into OriginalArgWasF128.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223040 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 16:26:48 +00:00
Daniel Sanders
08dc4d2346 Merged from r221061:
Renamed CCState members that appear to misspell
 'Processed' as 'Proceed'. NFC.

Reviewers: rnk

Reviewed By: rnk

Subscribers: rnk, llvm-commits

Differential Revision: http://reviews.llvm.org/D5978




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223039 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 16:05:07 +00:00
Daniel Sanders
da0e11cf7d Merged from r221059:
[mips] Move all ByVal handling into CCState and tablegen-erated code. NFC.

Summary:
CCState already contains a byval implementation that is very similar to the
Mips custom code. This patch merges the custom code into the existing
common code and tablegen-erated code.

Reviewers: vmedic

Reviewed By: vmedic

Subscribers: rnk, llvm-commits

Differential Revision: http://reviews.llvm.org/D5977




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223037 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 15:50:46 +00:00
Daniel Sanders
c5b18cff0a Merged from r221058:
[mips] Fix unused variable warning introduced in r221056



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223036 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 15:37:28 +00:00
Daniel Sanders
b87b49da10 Merged from r221057:
[mips] Remove ByValArgInfo::Address in favour of CCValAssign::getMemLocOffset(). NFC.

Summary: ByValArgInfo is practically the same as CCState::ByValInfo now.

Reviewers: vmedic

Reviewed By: vmedic

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D5976




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223035 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 15:28:54 +00:00
Daniel Sanders
83eda6b665 Merged from r221056:
[mips] Move F128 argument handling into MipsCCState as we did for returns. NFC.

Summary:
There are a couple more changes to make before analyzeFormalArguments can
be merged into the standard AnalyzeFormalArguments. I've had to temporarily
poke a couple holes in MipsCCState's encapsulation to save having to make
all the required changes for this merge all at once*. These will be removed
shortly.

* We must merge our ByVal argument handling with the implementation in CCState.
  This will be done over the next three patches, then the fourth will merge
  analyzeFormalArguments with AnalyzeFormalArguments.

Reviewers: vmedic

Reviewed By: vmedic

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D5969




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223034 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 15:24:14 +00:00
Daniel Sanders
3c7ce872b2 Merged from r221054:
[mips] Remove MipsCC::CCInfo. NFC.

Summary:
It's now passed in as an argument to functions that need it. Eventually
this argument will be replaced by the 'this' pointer for a MipsCCState
object.

Reviewers: vmedic

Reviewed By: vmedic

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D5967




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223033 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 15:15:59 +00:00
Daniel Sanders
c915198c5c Merged from r221053:
[mips] Removed MipsCC::fixedArgFn(). NFC

Summary:
There is one remaining trace of it in MipsCC::analyzeCallOperands() where
Mips16 might override the calling convention. This will moved into
tablegen-erated code later.

Reviewers: vmedic

Reviewed By: vmedic

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D5966




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223032 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 15:14:34 +00:00
Daniel Sanders
6f2b3f23f5 [tablegen] Add CustomCallingConv and use it to tablegen-erate the outermost parts of the Mips O32 implementation
Summary:
CustomCallingConv is simply a CallingConv that tablegen should not generate the
implementation for. It allows regular CallingConv's to delegate to these custom
functions. This is (currently) necessary for Mips and we cannot use CCCustom
without having to adapt to the different API that CCCustom uses.

This brings us a bit closer to being able to remove
MipsCC::analyzeCallOperands and MipsCC::analyzeFormalArguments in favour of
the common implementation.

No functional change to the targets.

Reviewers: vmedic

Reviewed By: vmedic

Subscribers: vmedic, llvm-commits

Differential Revision: http://reviews.llvm.org/D5965



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223031 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 15:13:16 +00:00
Daniel Sanders
1842c73e12 Added file that should have been in r223022.
I forgot to 'svn add' it.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223030 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 15:10:11 +00:00
Daniel Sanders
f0383f0d31 Add file that should have been in r223027
git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223028 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 14:43:25 +00:00
Daniel Sanders
823f180c25 Merged from r220568:
[mips] Replace MipsABIEnum with a MipsABIInfo class.

Summary:
No functional change yet, it's just an object replacement for an enum.
It will allow us to gather ABI information in a single place so that we can
start testing for properties of the ABI's instead of the ABI itself.

For example we will eventually be able to use:
  ABI.MinStackAlignmentInBytes()
instead of:
  (isABI_N32() || isABI_N64()) ? 16 : 8
which is clearer and more maintainable.

Reviewers: matheusalmeida

Reviewed By: matheusalmeida

Differential Revision: http://reviews.llvm.org/D3341



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223027 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 14:30:22 +00:00
Daniel Sanders
426365daa6 Merged from r220564:
[mips] Fix >80-column line



git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223026 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 14:28:19 +00:00
Daniel Sanders
e2c44a48fc Merged from r220561:
[mips] Remove redundant code in RetCC_MipsN. NFC.

Summary:
i32 is always promoted to i64 so it no longer makes sense to assign i32 to
registers.

Reviewers: vmedic

Reviewed By: vmedic

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D5964




git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_35@223025 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-01 14:26:43 +00:00