Matt Arsenault [Mon, 23 Jun 2014 18:28:28 +0000 (18:28 +0000)]
R600/SI: Fix div_scale intrinsic.
The operand that must match one of the others does matter,
and implement selecting for it.
llvm-svn: 211523
Matt Arsenault [Mon, 23 Jun 2014 18:28:23 +0000 (18:28 +0000)]
R600: Fix formatting of intrinsic definitions.
It makes more sense for the GCCBuiltin name to come immediately
after the ID name.
llvm-svn: 211522
Duncan P. N. Exon Smith [Mon, 23 Jun 2014 18:08:58 +0000 (18:08 +0000)]
Cleanup r211507
llvm-svn: 211521
Christian Pirker [Mon, 23 Jun 2014 18:05:53 +0000 (18:05 +0000)]
ARMEB: Vector extend operations
Reviewed at http://reviews.llvm.org/D4043
llvm-svn: 211520
Matt Arsenault [Mon, 23 Jun 2014 18:00:55 +0000 (18:00 +0000)]
R600: Remove AMDILISelLowering
llvm-svn: 211519
Matt Arsenault [Mon, 23 Jun 2014 18:00:52 +0000 (18:00 +0000)]
R600: Select is not expensive.
llvm-svn: 211518
Matt Arsenault [Mon, 23 Jun 2014 18:00:49 +0000 (18:00 +0000)]
R600: Move add/sub with overflow out of AMDILISelLowering
Add more tests for these.
llvm-svn: 211517
Matt Arsenault [Mon, 23 Jun 2014 18:00:44 +0000 (18:00 +0000)]
R600: Move more out of AMDILISelLowering
llvm-svn: 211516
Matt Arsenault [Mon, 23 Jun 2014 18:00:41 +0000 (18:00 +0000)]
R600: Don't set fp_round_inreg action.
There's no point in setting this since it seems to only
by created in 1 place for ppcf128
llvm-svn: 211515
Matt Arsenault [Mon, 23 Jun 2014 18:00:38 +0000 (18:00 +0000)]
R600/SI: Handle i64 sub.
We can handle it the same way as add
llvm-svn: 211514
Matt Arsenault [Mon, 23 Jun 2014 18:00:34 +0000 (18:00 +0000)]
R600/SI: Move selection of i64 add to separate function.
Also don't use a SmallVector for fixed size array.
llvm-svn: 211513
Matt Arsenault [Mon, 23 Jun 2014 18:00:31 +0000 (18:00 +0000)]
R600: Rename AMDIL file
llvm-svn: 211512
Matt Arsenault [Mon, 23 Jun 2014 18:00:26 +0000 (18:00 +0000)]
Fix missing words in sentence
llvm-svn: 211511
Matt Arsenault [Mon, 23 Jun 2014 18:00:24 +0000 (18:00 +0000)]
Use helper function
llvm-svn: 211510
Matt Arsenault [Mon, 23 Jun 2014 18:00:20 +0000 (18:00 +0000)]
Alphabetize forward declarations
llvm-svn: 211509
Rafael Espindola [Mon, 23 Jun 2014 17:58:39 +0000 (17:58 +0000)]
Delete utils/FileUpdate.
It is unused and it looks like it was never used.
llvm-svn: 211508
Duncan P. N. Exon Smith [Mon, 23 Jun 2014 17:47:40 +0000 (17:47 +0000)]
Support: Extract ScaledNumbers::compare()
llvm-svn: 211507
Saleem Abdulrasool [Mon, 23 Jun 2014 17:36:36 +0000 (17:36 +0000)]
Driver: correct behaviour of -fmsc-version=MAJOR
Ensure that we properly handle the case where just the major version component
is provided by the user.
Thanks to Alp Toker for pointing out that this was not handled correctly!
llvm-svn: 211506
David Majnemer [Mon, 23 Jun 2014 17:30:27 +0000 (17:30 +0000)]
MS ABI: Add an additional test for typeid
This tests typeid with polymorphic arguments which have an extendable
virtual function table.
llvm-svn: 211505
Ben Langmuir [Mon, 23 Jun 2014 16:36:40 +0000 (16:36 +0000)]
Stop sharing the FileManager in ASTUnit::Parse
We were using old stat values for any files that had previously been
looked up, leading to badness. There might be a more elegant solution in
invalidating the cache for those file (since we already know which ones
they are), but it seems too likely there are existing references to
them hiding somewhere.
llvm-svn: 211504
Todd Fiala [Mon, 23 Jun 2014 15:59:04 +0000 (15:59 +0000)]
lldb: deal with non-portable PTRACE-related constants
See http://reviews.llvm.org/D4091 for details.
Change by Paul Osmialowski.
llvm-svn: 211503
Rafael Espindola [Mon, 23 Jun 2014 15:34:32 +0000 (15:34 +0000)]
Allow using .cfi_startproc without a leading symbol.
This is possible now that we don't produce .eh symbols. This fixes pr19430.
llvm-svn: 211502
Rafael Espindola [Mon, 23 Jun 2014 15:17:34 +0000 (15:17 +0000)]
clang-format initializer to reduce noise in another patch.
llvm-svn: 211501
Rafael Espindola [Mon, 23 Jun 2014 15:13:23 +0000 (15:13 +0000)]
Stop producing func.eh symbols on Darwin.
According Nick Kledzik (http://llvm.org/bugs/show_bug.cgi?id=19430#c2):
"... mach-o no longer needs names in the __eh_frame section (and has not for
years)."
Iain Sandoe confirms it is also unnecessary for their old darwin support.
llvm-svn: 211500
Rafael Espindola [Mon, 23 Jun 2014 14:22:55 +0000 (14:22 +0000)]
Remove a temporary hack.
Amusingly this survived a lot longer than the CFI transition. We don't even
support non-cfi assemblers any more.
llvm-svn: 211498
Ulrich Weigand [Mon, 23 Jun 2014 14:15:53 +0000 (14:15 +0000)]
[PowerPC] Refactor getMinCallFrameSize / getMinCallArgumentsSize
As of r211495, the only remaining users of getMinCallFrameSize are in
core ABI code (LowerFormalParameter / LowerCall). This is actually a
good thing, since the details of the parameter save area are ABI specific.
With the new ELFv2 ABI in particular, the rules defining the size of the
save area will become significantly more complex, so it wouldn't make
sense to implement those outside ABI code that has all required
information.
In preparation, this patch eliminates the getMinCallFrameSize (and
associated getMinCallArgumentsSize) routines, and inlines them into all
callers. Note that since nearly all call arguments are constant, this
allows simplifying the inlined copies to a single line everywhere.
No change in generate code expected.
llvm-svn: 211497
Jeroen Ketema [Mon, 23 Jun 2014 14:15:39 +0000 (14:15 +0000)]
Protect functions taking double by #ifdef cl_khr_fp64
Also change the order of the functions to be consistent with
the order in the header files.
llvm-svn: 211496
Ulrich Weigand [Mon, 23 Jun 2014 13:47:52 +0000 (13:47 +0000)]
[PowerPC] Allow stack frames without parameter save area
The PPCFrameLowering::determineFrameLayout routine currently ensures
that every function that allocates a stack frame provides space for the
parameter save area (via PPCFrameLowering::getMinCallFrameSize).
This is actually not necessary. There may be functions that never call
another routine but still allocate a frame; those do not require the
parameter save area. In the future, with the ELFv2 ABI, even some
routines that do call other functions do not need to allocate the
parameter save area.
While it is not a bug to allocate the parameter area when it is not
needed, it is better to avoid it to save stack space.
Note that when any particular function call requires the parameter save
area, this space will already have been included by ABI code in the size
the CALLSEQ_START insn is annotated with, and therefore included in the
size returned by MFI->getMaxCallFrameSize().
This means that determineFrameLayout simply does not need to care about
the parameter save area. (It still needs to ensure that every frame
provides the linkage area.) This is implemented by this patch.
Note that this exposed a bug in the new fast-isel code where the parameter
area was *not* included in the CALLSEQ_START size; this is also fixed.
A couple of test cases needed to be adapted for the new (smaller) stack
frame size those tests now see.
llvm-svn: 211495
Ulrich Weigand [Mon, 23 Jun 2014 13:21:43 +0000 (13:21 +0000)]
[PowerPC] Fix IsDarwin arg in PPCFrameLowering:: calls
As remarked in the commit message to r211493, in several places
throughout the 64-bit SVR4 ABI code there are calls to
PPCFrameLowering::getLinkageSize and getMinCallFrameSize
using an incorrect IsDarwin argument of "true".
(Some of those were made explicit by the above refactoring patch, others
have been there all along.)
This patch fixes those places to pass "false" for IsDarwin.
No change in generated code expected.
llvm-svn: 211494
Ulrich Weigand [Mon, 23 Jun 2014 13:08:27 +0000 (13:08 +0000)]
[PowerPC] Refactor setMinReservedArea and CalculateParameterAndLinkageAreaSize
The PPCISelLowering.cpp routines PPCTargetLowering::setMinReservedArea and
CalculateParameterAndLinkageAreaSize are currently used as subroutines
from both 64-bit SVR4 and Darwin ABI code.
However, the two ABIs are already quite different w.r.t. AltiVec
conventions, and they will become more different when the ELFv2 ABI is
supported. Also, in general it seems better to disentangle ABI support
routines for different ABIs to avoid accidentally affecting one ABI when
intending to change only the other.
(Actually, the current code strictly speaking already contains a bug:
these routines call PPCFrameLowering::getMinCallFrameSize and
PPCFrameLowering::getLinkageSize with the IsDarwin parameter set to
"true" even on 64-bit SVR4. This bug currently has no adverse effect
since those routines always return the same for 64-bit SVR4 and 64-bit
Darwin, but it still seems wrong ... I'll fix this in a follow-up
commit shortly.)
To remove this code sharing, I'm simply inlining both routines into all
call sites (there are just two each, one for 64-bit SVR4 and one for
Darwin), and simplifying due to constant parameters where possible.
A small piece of code that *does* make sense to share is refactored into
the new routine EnsureStackAlignment, now also called from 32-bit SVR4
ABI code.
No change in generated code is expected.
llvm-svn: 211493
Ulrich Weigand [Mon, 23 Jun 2014 12:36:34 +0000 (12:36 +0000)]
[PowerPC] Fix on-stack AltiVec arguments with 64-bit SVR4
Current 64-bit SVR4 code seems to have some remnants of Darwin code
in AltiVec argument handing. This had the effect that AltiVec arguments
(or subsequent arguments) were not correctly placed in the parameter area
in some cases.
The correct behaviour with the 64-bit SVR4 ABI is:
- All AltiVec arguments take up space in the parameter area, just like
any other arguments, whether vararg or not.
- They are always 16-byte aligned, skipping a parameter area doubleword
(and the associated GPR, if any), if necessary.
This patch implements the correct behaviour and adds a test case.
(Verified against GCC behaviour via the ABI compat test suite.)
llvm-svn: 211492
Simon Atanasyan [Mon, 23 Jun 2014 12:28:11 +0000 (12:28 +0000)]
[Mips] Make rel-dynamic-03.test test case independent from external input files.
llvm-svn: 211491
Tim Northover [Mon, 23 Jun 2014 09:20:02 +0000 (09:20 +0000)]
ARM: mark UBFX as not allowing PC.
Strictly, it's unpredictable. But we don't quite model that yet and an error is
better than ignoring the issue. This one somehow got left out before though.
rdar://problem/
15997748
llvm-svn: 211490
Alexey Bataev [Mon, 23 Jun 2014 08:21:53 +0000 (08:21 +0000)]
[OPENMP] Reformatting and code improvement.
llvm-svn: 211489
Daniel Jasper [Mon, 23 Jun 2014 07:36:25 +0000 (07:36 +0000)]
clang-format: [proto] Add required space before absolute references.
llvm-svn: 211488
Daniel Jasper [Mon, 23 Jun 2014 07:36:18 +0000 (07:36 +0000)]
clang-format: Fix corner case in pointer/reference detection.
llvm-svn: 211487
David Majnemer [Mon, 23 Jun 2014 02:17:16 +0000 (02:17 +0000)]
MC: Cleanup parseMSInlineAsm
Utilize range based for-loops to simplify some code.
Use insert() instead of a loop for simplicity/efficiency.
No functionality change.
llvm-svn: 211486
David Majnemer [Mon, 23 Jun 2014 02:16:41 +0000 (02:16 +0000)]
Parse: Simplify construction of the clobber list
This avoids going over the clobber list twice.
No functionality change.
llvm-svn: 211485
David Majnemer [Mon, 23 Jun 2014 02:16:38 +0000 (02:16 +0000)]
StaticAnalyzer: Switch a loop to a range-based for
Merely a code simplification, no functionality change.
llvm-svn: 211484
David Majnemer [Mon, 23 Jun 2014 02:16:34 +0000 (02:16 +0000)]
AST: Add ranges for AsmStmt's inputs and outputs
No functionality change.
llvm-svn: 211483
Alp Toker [Sun, 22 Jun 2014 23:28:54 +0000 (23:28 +0000)]
cindex.py: remove obsolete workaround and FIXME
clang_getCursorSpelling() doesn't assert on non-declarations any more and the
behaviour is covered by c-index tests.
Passes nosetests.
llvm-svn: 211482
Saleem Abdulrasool [Sun, 22 Jun 2014 22:25:01 +0000 (22:25 +0000)]
MC: adjust text section flags for WoA
Correct the section flags for code built for Windows on ARM with
`-ffunction-sections`. Windows on ARM uses solely Thumb-2 instructions, and
indicates that the function is thumb by placing it in a text section that has
IMAGE_SCN_MEM_16BIT flag set.
When we encounter a .section directive, a new section is constructed. This may
be a text segment. In order to identify that we need the additional flag,
expose the target triple through the ObjectFileInfo as this information is lost
otherwise.
Since any modern ARM targeting environment on Windows would be Thumb-2 (Windows
ARM NT or Windows Embedded Compact), introducing a new flag to indicate the
section attribute seems to be a bit overkill. Simply depend on the target
triple. Since there is one location that this information is currently needed,
creating a target specific assembly parser and delegating the parsing of section
switches also feels a bit heavy handed. If it turns out that this information
ends up changing additional behaviour, then it may be worth considering that
alternative.
llvm-svn: 211481
NAKAMURA Takumi [Sun, 22 Jun 2014 22:00:56 +0000 (22:00 +0000)]
Revert r211399, "Generate native unwind info on Win64"
It broke Legacy JIT Tests on x86_64-{mingw32|msvc}, aka Windows x64.
llvm-svn: 211480
Alp Toker [Sun, 22 Jun 2014 21:58:33 +0000 (21:58 +0000)]
DiagnosticIDs: use diagnostic severities to simplify extension handling
llvm-svn: 211479
Jan Vesely [Sun, 22 Jun 2014 21:43:01 +0000 (21:43 +0000)]
R600: Use LowerSDIVREM for i64 node replace
v2: move div/rem node replacement to R600ISelLowering
make lowerSDIVREM protected
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
llvm-svn: 211478
Jan Vesely [Sun, 22 Jun 2014 21:43:00 +0000 (21:43 +0000)]
R600: Implement custom SDIVREM.
Instead of separate SDIV/SREM. SDIV used UDIV which in turn used UDIVREM anyway.
SREM used SDIV(UDIV->UDIVREM)+MUL+SUB, using UDIVREM directly is more efficient.
v2: Don't use all caps names
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
llvm-svn: 211477
Jan Vesely [Sun, 22 Jun 2014 21:42:58 +0000 (21:42 +0000)]
R600: Add udivrem test
v2: move < %s to the end of the line
space after ;
add v4i32 test
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
llvm-svn: 211476
Alp Toker [Sun, 22 Jun 2014 21:16:50 +0000 (21:16 +0000)]
Fix the category name for hash-warnings and hash-errors
llvm-svn: 211475
Justin Bogner [Sun, 22 Jun 2014 20:35:10 +0000 (20:35 +0000)]
Driver: Skip the -ivfsoverlay argument in driver crash diags
llvm-svn: 211474
David Majnemer [Sun, 22 Jun 2014 19:05:33 +0000 (19:05 +0000)]
Revert "Revert r211402 (and r211408,r211410), "CodeGen: Refactor dynamic_cast and typeid" It crashes msvc codegen in clang/test/SemaCXX/undefined-internal.cpp."
This reverts commit r211467 which reverted r211408,r211410, it caused
crashes in test/SemaCXX/undefined-internal.cpp for i686-win32 targets.
llvm-svn: 211473
Filipe Cabecinhas [Sun, 22 Jun 2014 17:21:37 +0000 (17:21 +0000)]
Fix PR20087 by using the source index when changing the vector load
llvm-svn: 211472
Richard Smith [Sun, 22 Jun 2014 16:00:05 +0000 (16:00 +0000)]
[cxx_status] Minor wording tweaks.
llvm-svn: 211471
Richard Smith [Sun, 22 Jun 2014 15:56:23 +0000 (15:56 +0000)]
[cxx_status] Be a bit more precise.
llvm-svn: 211470
Richard Smith [Sun, 22 Jun 2014 15:54:54 +0000 (15:54 +0000)]
Fix dead link.
llvm-svn: 211469
Sylvestre Ledru [Sun, 22 Jun 2014 13:18:53 +0000 (13:18 +0000)]
Remove useless declaration
llvm-svn: 211468
NAKAMURA Takumi [Sun, 22 Jun 2014 12:42:29 +0000 (12:42 +0000)]
Revert r211402 (and r211408,r211410), "CodeGen: Refactor dynamic_cast and typeid" It crashes msvc codegen in clang/test/SemaCXX/undefined-internal.cpp.
It is reproducible with:
$ clang -cc1 -triple i686-win32 -emit-llvm-only clang/test/SemaCXX/undefined-internal.cpp
llvm-svn: 211467
NAKAMURA Takumi [Sun, 22 Jun 2014 12:35:39 +0000 (12:35 +0000)]
Introduce a Lit feature "debug_frame" and apply it to llvm/test/MC/ELF/cfi-version.ll.
.debug_frame is not emitted for targeting Windows x64.
llvm-svn: 211466
Benjamin Kramer [Sun, 22 Jun 2014 12:22:04 +0000 (12:22 +0000)]
Add a description to the test from r211433 explaining why it's written that way.
llvm-svn: 211465
Benjamin Kramer [Sun, 22 Jun 2014 12:16:35 +0000 (12:16 +0000)]
Remove unused diagnostic and diagnostic group.
llvm-svn: 211464
Simon Atanasyan [Sun, 22 Jun 2014 11:58:08 +0000 (11:58 +0000)]
[Mips] Make rel-dynamic-01.test test case independent from external input files.
llvm-svn: 211463
Alp Toker [Sun, 22 Jun 2014 10:08:06 +0000 (10:08 +0000)]
TextDiagnosticPrinter: use the mapped level for remark flag computation
Custom diagnostics don't have a builtin class so this wouldn't have worked.
Reduces surface area of remark-related changes.
No test coverage.
llvm-svn: 211462
Alp Toker [Sun, 22 Jun 2014 04:31:15 +0000 (04:31 +0000)]
Enable WindowsToolChain on all native Windows builds
Make binaries built by MSVC, mingw and clang functionally equivalent. The
checks are trivially performed at runtime to eliminate functional differences
between supported configurations that used to be hard-coded.
llvm-svn: 211461
Arnold Schwaighofer [Sun, 22 Jun 2014 03:38:59 +0000 (03:38 +0000)]
LoopVectorizer: Fix a dominance issue
The induction variables start value needs to be defined before we branch
(overflow check) to the scalar preheader where we used it.
llvm-svn: 211460
Alp Toker [Sun, 22 Jun 2014 03:27:52 +0000 (03:27 +0000)]
WindowsToolChain: decouple build environment from the toolchain
Don't try to find the MSVC version that the binaries were built with. Doing so
defeats testing by causing invalid test passes on the build servers.
Whichever Visual Studio (or clang-cl.exe) edition was used to build the clang
package, it's strictly orthogonal and has no relation to software versions
available on the user's PC.
llvm-svn: 211459
Alp Toker [Sun, 22 Jun 2014 03:27:45 +0000 (03:27 +0000)]
Make WindowsToolChain portable
De-conditionalize as much as possible so we can start to fix this code.
No change in functionality.
llvm-svn: 211458
Stepan Dyatkovskiy [Sun, 22 Jun 2014 01:53:30 +0000 (01:53 +0000)]
MergeFunctions Pass, removed DenseMap helpers.
Patch removes rest part of code related to old implementation.
This patch belongs to patch series that improves MergeFunctions
performance time from O(N*N) to O(N*log(N)).
This one was the final patch.
llvm-svn: 211457
Stepan Dyatkovskiy [Sun, 22 Jun 2014 00:57:09 +0000 (00:57 +0000)]
MergeFunctions Pass, updated header comments.
Added short description for new comparison algorithm, that introduces
total ordering among functions set.
This patch belongs to patch series that improves MergeFunctions
performance time from O(N*N) to O(N*log(N)).
llvm-svn: 211456
Weiming Zhao [Sun, 22 Jun 2014 00:33:44 +0000 (00:33 +0000)]
Report error for non-zero data in .bss
User may initialize a var with non-zero value and specify .bss section.
E.g. : int a __attribute__((section(".bss"))) = 2;
This patch converts an assertion to error report for better user
experience.
Differential Revision: http://reviews.llvm.org/D4199
llvm-svn: 211455
Sylvestre Ledru [Sat, 21 Jun 2014 23:51:07 +0000 (23:51 +0000)]
Remove useless call
llvm-svn: 211454
Jordan Rose [Sat, 21 Jun 2014 23:50:40 +0000 (23:50 +0000)]
[analyzer] Check for NULL passed to CFAutorelease.
Patch by Sean McBride, tests adjusted by me.
llvm-svn: 211453
Sylvestre Ledru [Sat, 21 Jun 2014 23:48:45 +0000 (23:48 +0000)]
Simplify the code (variable bValid is not really interesting)
llvm-svn: 211452
Sylvestre Ledru [Sat, 21 Jun 2014 23:47:20 +0000 (23:47 +0000)]
Remove useless declaration
llvm-svn: 211451
Alp Toker [Sat, 21 Jun 2014 23:33:00 +0000 (23:33 +0000)]
Track changes from clang r211448.
llvm-svn: 211450
Alp Toker [Sat, 21 Jun 2014 23:32:05 +0000 (23:32 +0000)]
Make MS i128 suffix test from r211446 more robust
We want to catch both negative and positive failure conditions.
llvm-svn: 211449
Alp Toker [Sat, 21 Jun 2014 23:31:59 +0000 (23:31 +0000)]
DiagnosticRenderer: emit basic notes as real diagnostics
Fixes terminal column wrapping and vestigial 'note:' prefixes that would appear
when using emitBasicNote().
llvm-svn: 211448
Alp Toker [Sat, 21 Jun 2014 23:31:52 +0000 (23:31 +0000)]
TextDiagnostic: print remark level diagnostics in bold too
The purpose of bolding these is to make them visually distinct from
continuations (supplemental note diagnostics). Therefore, the bolding applies
to all severities _including_ remarks -- it's not in any way an indicator of
priority. Also simplify and comment.
No tests.
llvm-svn: 211447
David Majnemer [Sat, 21 Jun 2014 22:49:50 +0000 (22:49 +0000)]
The i128 suffix isn't always available.
This Lexer test unconditionally used the i128 integer literal suffix.
This suffix is only available to targets that have 128-bit arithmetic
support.
llvm-svn: 211446
Stepan Dyatkovskiy [Sat, 21 Jun 2014 20:54:36 +0000 (20:54 +0000)]
MergeFunctions Pass, FnSet has been replaced with FnTree.
Patch activates new implementation.
So from now, merging process should take time O(N*log(N)).
Where N size of module (we are free to measure it in
functions or in instructions). Internally FnTree represents
binary tree. So every lookup operation takes O(log(N)) time.
It is still not the last patch in series, we also have to
clean-up pass from old code, and update pass comments.
This patch belongs to patch series that improves MergeFunctions
performance time from O(N*N) to O(N*log(N)).
llvm-svn: 211445
Stepan Dyatkovskiy [Sat, 21 Jun 2014 20:13:24 +0000 (20:13 +0000)]
MergeFunctions Pass, removed unused methods from old implementation.
Patch removed next old FunctionComparator methods:
* enumerate
* isEquivalentOperation
* isEquivalentGEP
* isEquivalentType
This patch belongs to patch series that improves MergeFunctions
performance time from O(N*N) to O(N*log(N)).
llvm-svn: 211444
Stepan Dyatkovskiy [Sat, 21 Jun 2014 19:07:51 +0000 (19:07 +0000)]
MergeFunctions, doSanityCheck: fixed body comments.
llvm-svn: 211443
Stepan Dyatkovskiy [Sat, 21 Jun 2014 18:58:11 +0000 (18:58 +0000)]
MergeFunctions Pass, introduced sanity check, that checks order relation,
introduced among functions set.
This patch belongs to patch series that improves MergeFunctions
performance time from O(N*N) to O(N*log(N)).
llvm-svn: 211442
David Majnemer [Sat, 21 Jun 2014 18:46:07 +0000 (18:46 +0000)]
Lex: Use the correct types for MS integer suffixes
Something went wrong with r211426, it is an older version of this code
and should not have been committed. It was reverted with r211434.
Original commit message:
We didn't properly implement support for the sized integer suffixes.
Suffixes like i16 were essentially ignored instead of mapping them to
the appropriately sized integer type.
This fixes PR20008.
Differential Revision: http://reviews.llvm.org/D4132
llvm-svn: 211441
Yabin Hu [Sat, 21 Jun 2014 18:35:33 +0000 (18:35 +0000)]
Add "Yabin Hu" to CREDITS.txt
llvm-svn: 211440
Argyrios Kyrtzidis [Sat, 21 Jun 2014 18:28:44 +0000 (18:28 +0000)]
[test] Add '-target' option to fix bot failure.
llvm-svn: 211439
Argyrios Kyrtzidis [Sat, 21 Jun 2014 18:16:40 +0000 (18:16 +0000)]
[PCH] Remove the BackingIvarReferencedInAccessor field from DECL_OBJC_IVAR abbreviation record.
Patch by Yiding Jia!
llvm-svn: 211438
Stepan Dyatkovskiy [Sat, 21 Jun 2014 17:55:51 +0000 (17:55 +0000)]
MergeFunctions Pass, introduced total ordering among top-level comparison
methods.
Patch changes return type of FunctionComparator::compare() and
FunctionComparator::compare(const BasicBlock*, const BasicBlock*)
methods from bool (equal or not) to {-1, 0, 1} (less, equal, great).
This patch belongs to patch series that improves MergeFunctions
performance time from O(N*N) to O(N*log(N)).
llvm-svn: 211437
Benjamin Kramer [Sat, 21 Jun 2014 13:46:25 +0000 (13:46 +0000)]
LoopUnrollRuntime: Check for overflow in the trip count calculation.
Fixes PR19823.
llvm-svn: 211436
Benjamin Kramer [Sat, 21 Jun 2014 12:56:42 +0000 (12:56 +0000)]
Legalizer: Add support for splitting insert_subvectors.
We handle this by spilling the whole thing to the stack and doing the
insertion as a store.
PR19492. This happens in real code because the vectorizer creates v2i128 when AVX is enabled.
llvm-svn: 211435
Rafael Espindola [Sat, 21 Jun 2014 12:39:25 +0000 (12:39 +0000)]
Revert "Lex: Use the correct types for MS integer suffixes"
This reverts commit r211426.
This broke the arm bots. The crash can be reproduced on X86 by running.
./bin/clang -cc1 -fsyntax-only -verify -fms-extensions ~/llvm/clang/test/Lexer/ms-extensions.c -triple arm-linux
llvm-svn: 211434
Benjamin Kramer [Sat, 21 Jun 2014 11:47:18 +0000 (11:47 +0000)]
SCEVExpander: Fold constant PHIs harder. The logic below only understands proper IVs.
PR20093.
llvm-svn: 211433
Jeroen Ketema [Sat, 21 Jun 2014 09:20:31 +0000 (09:20 +0000)]
Fix breakage after r211259
While we are here introduce the proper headers for the error code.
Reviewed-by: Tom Stellard <tom@stellard.net>
llvm-svn: 211432
Simon Atanasyan [Sat, 21 Jun 2014 08:36:12 +0000 (08:36 +0000)]
[Mips] Remove redundant checking from the RelocationPass::isDynamic() function.
No functional changes.
llvm-svn: 211431
Richard Trieu [Sat, 21 Jun 2014 02:43:02 +0000 (02:43 +0000)]
Add back functionality removed in r210497.
Instead of asserting, output a message stating that a null pointer was found.
llvm-svn: 211430
Dmitry Vyukov [Sat, 21 Jun 2014 02:10:17 +0000 (02:10 +0000)]
tsan: fix code formatting
llvm-svn: 211429
Saleem Abdulrasool [Sat, 21 Jun 2014 01:41:21 +0000 (01:41 +0000)]
builtins: assembly routines are not static
Storage Class 3 is static storage. These symbols need to be marked as external
(storage class 2) so that they can be referenced. Note that this external is
not the same as ELF "external" visibility, which is indicated by DLL Storage
Class (i.e. __declspec(dllexport) or __declspec(dllimport)).
llvm-svn: 211428
Andrea Di Biagio [Sat, 21 Jun 2014 01:31:15 +0000 (01:31 +0000)]
[X86] Add ISel patterns to select SSE3/AVX ADDSUB instructions.
This patch adds ISel patterns to select SSE3/AVX ADDSUB instructions
from a sequence of "vadd + vsub + blend".
Example:
///
typedef float float4 __attribute__((ext_vector_type(4)));
float4 foo(float4 A, float4 B) {
float4 X = A - B;
float4 Y = A + B;
return (float4){X[0], Y[1], X[2], Y[3]};
}
///
Before this patch, (with flag -mcpu=corei7) llc produced the following
assembly sequence:
movaps %xmm0, %xmm2
addps %xmm1, %xmm2
subps %xmm1, %xmm0
blendps $10, %xmm2, %xmm0
With this patch, we now get a single
addsubps %xmm1, %xmm0
llvm-svn: 211427
David Majnemer [Sat, 21 Jun 2014 00:51:59 +0000 (00:51 +0000)]
Lex: Use the correct types for MS integer suffixes
We didn't properly implement support for the sized integer suffixes.
Suffixes like i16 were essentially ignored instead of mapping them to
the appropriately sized integer type.
This fixes PR20008.
Differential Revision: http://reviews.llvm.org/D4132
llvm-svn: 211426
Todd Fiala [Sat, 21 Jun 2014 00:48:09 +0000 (00:48 +0000)]
Fix a gdbremote bug in _M/_m stub support detection.
When a stub reported $#00 (unsupported) for _M and _m
packets, the unsupported response was not handled and
the client then marked the _M/_m commands as definitely
supported. However, they would always fail, preventing
lldb's fallback InferiorCallMmap-based allocation strategy
from being used to attempt to allocate memory in the inferior
process space.
llvm-svn: 211425
Zachary Turner [Sat, 21 Jun 2014 00:24:51 +0000 (00:24 +0000)]
Fix the MinGW builder. Apparently std::call_once and
std::recursive_mutex are not available on MinGW and breaks the
builder. Revert to using a function local static and sys::Mutex
just to get the tree green until we figure out a better solution.
llvm-svn: 211424
Rafael Espindola [Fri, 20 Jun 2014 23:54:32 +0000 (23:54 +0000)]
Always use a temp symbol for CIE.
Fixes pr19185.
llvm-svn: 211423