platform/upstream/llvm.git
9 years ago[dsymutil] Fix test patterns.
Frederic Riss [Wed, 5 Aug 2015 18:45:13 +0000 (18:45 +0000)]
[dsymutil] Fix test patterns.

Depending on the filesystem paths, the YAML dump might quote paths.
Account for that in the regex patterns.

llvm-svn: 244094

9 years agoMIR Parser: Extract the IR constant parsing code into a new method. NFC.
Alex Lorenz [Wed, 5 Aug 2015 18:44:00 +0000 (18:44 +0000)]
MIR Parser: Extract the IR constant parsing code into a new method. NFC.

This commit extracts the code that parses the IR constant values into a new
method named 'parseIRConstant' in the 'MIParser' class. The new method will
be reused by the code that parses the typed integer immediate machine operands.

llvm-svn: 244093

9 years ago[AArch64] Enable thread sanitizer on clang
Renato Golin [Wed, 5 Aug 2015 18:42:41 +0000 (18:42 +0000)]
[AArch64] Enable thread sanitizer on clang

With this option, clang can use -fsanitize=thread on AArch64.

Patch by Adhemerval Zanella.

llvm-svn: 244091

9 years ago[Hexagon] Implement TargetTransformInfo for Hexagon
Krzysztof Parzyszek [Wed, 5 Aug 2015 18:35:37 +0000 (18:35 +0000)]
[Hexagon] Implement TargetTransformInfo for Hexagon

Author: Brendon Cahoon <bcahoon@codeaurora.org>
llvm-svn: 244089

9 years ago[AArch64] Fixes broken bot fue to TSAN patch
Renato Golin [Wed, 5 Aug 2015 18:34:20 +0000 (18:34 +0000)]
[AArch64] Fixes broken bot fue to TSAN patch

Patch by Adhemerval Zanella.

llvm-svn: 244088

9 years ago[dsymutil] Implement support for handling mach-o universal binaries as main input...
Frederic Riss [Wed, 5 Aug 2015 18:27:44 +0000 (18:27 +0000)]
[dsymutil] Implement support for handling mach-o universal binaries as main input/output.

The DWARF linker isn't touched by this, the implementation links
individual files and merges them together into a fat binary by
calling out to the 'lipo' utility.

The main change is that the MachODebugMapParser can now return
multiple debug maps for a single binary.

The test just verifies that lipo would be invoked correctly, but
doesn't actually generate a binary. This mimics the way clang
tests its external iplatform tools integration.

llvm-svn: 244087

9 years ago[dsymutil] Introduce exit helper. NFC.
Frederic Riss [Wed, 5 Aug 2015 18:27:38 +0000 (18:27 +0000)]
[dsymutil] Introduce exit helper. NFC.

llvm-dsymutil will start creating temporary files in a followup
commit. To ease the correct cleanup of this files, introduce a
helper called to exit dsymutil.

llvm-svn: 244086

9 years ago[dsymutil] Split some logic into a helper function. NFC
Frederic Riss [Wed, 5 Aug 2015 18:27:34 +0000 (18:27 +0000)]
[dsymutil] Split some logic into a helper function. NFC

llvm-svn: 244085

9 years ago[libFuzzer] use data-flow feedback from strcmp
Kostya Serebryany [Wed, 5 Aug 2015 18:23:01 +0000 (18:23 +0000)]
[libFuzzer] use data-flow feedback from strcmp

llvm-svn: 244084

9 years ago[libFuzzer] add weak hooks for strcmp
Kostya Serebryany [Wed, 5 Aug 2015 18:20:54 +0000 (18:20 +0000)]
[libFuzzer] add weak hooks for strcmp

llvm-svn: 244083

9 years ago[libFuzzer/DFSan] add more __sanitizer callbacks to dfsan blacklist
Kostya Serebryany [Wed, 5 Aug 2015 18:20:15 +0000 (18:20 +0000)]
[libFuzzer/DFSan] add more __sanitizer callbacks to dfsan blacklist

llvm-svn: 244082

9 years agoMIR Parser: Report an error when parsing duplicate register flags.
Alex Lorenz [Wed, 5 Aug 2015 18:09:03 +0000 (18:09 +0000)]
MIR Parser: Report an error when parsing duplicate register flags.

llvm-svn: 244081

9 years ago[TTI] Make the cost APIs in TargetTransformInfo consistently use 'int'
Chandler Carruth [Wed, 5 Aug 2015 18:08:10 +0000 (18:08 +0000)]
[TTI] Make the cost APIs in TargetTransformInfo consistently use 'int'
rather than 'unsigned' for their costs.

For something like costs in particular there is a natural "negative"
value, that of savings or saved cost. As a consequence, there is a lot
of code that subtracts or creates negative values based on cost, all of
which is prone to awkwardness or bugs when dealing with an unsigned
type. Similarly, we *never* want these values to wrap, as that would
cause Very Bad code generation (likely percieved as an infinite loop as
we try to emit over 2^32 instructions or some such insanity).

All around 'int' seems a much better fit for these basic metrics. I've
added asserts to ensure that at least the TTI interface never returns
negative numbers here. If we ever have a use case for negative numbers,
we can remove this, but this way a bug where someone used '-1' to
produce a 'very large' cost will be caught by the assert.

This passes all tests, and is also UBSan clean.

No functional change intended.

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

llvm-svn: 244080

9 years agoClaim arguments that belong to 'clang_ignored_gcc_optimization_f_Group'
Douglas Katzman [Wed, 5 Aug 2015 18:03:47 +0000 (18:03 +0000)]
Claim arguments that belong to 'clang_ignored_gcc_optimization_f_Group'

This seems preferable to printing two warnings per unsupported option-
one warning about not supporting it, and one about not using it.
It also makes the '-Wno-' option do what you mean.

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

llvm-svn: 244079

9 years ago[GMR] Teach the conservative path of GMR to catch even more easy cases.
Chandler Carruth [Wed, 5 Aug 2015 17:58:30 +0000 (17:58 +0000)]
[GMR] Teach the conservative path of GMR to catch even more easy cases.

In PR24288 it was pointed out that the easy case of a non-escaping
global and something that *obviously* required an escape sometimes is
hidden behind PHIs (or selects in theory). Because we have this binary
test, we can easily just check that all possible input values satisfy
the requirement. This is done with a (very small) recursion through PHIs
and selects. With this, the specific example from the PR is correctly
folded by GVN.

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

llvm-svn: 244078

9 years agoTry to fix sanitizer_win.cc compile error on 64-bit after r243895
Hans Wennborg [Wed, 5 Aug 2015 17:55:26 +0000 (17:55 +0000)]
Try to fix sanitizer_win.cc compile error on 64-bit after r243895

llvm-svn: 244077

9 years ago[test] Attempt a change to see if it fixes the test for the windows bot.
Argyrios Kyrtzidis [Wed, 5 Aug 2015 17:52:57 +0000 (17:52 +0000)]
[test] Attempt a change to see if it fixes the test for the windows bot.

llvm-svn: 244076

9 years agoMIR Serialization: Serialize the 'early-clobber' register operand flag.
Alex Lorenz [Wed, 5 Aug 2015 17:49:03 +0000 (17:49 +0000)]
MIR Serialization: Serialize the 'early-clobber' register operand flag.

llvm-svn: 244075

9 years agoMove BB succ_iterator to be inside TerminatorInst. NFC.
Pete Cooper [Wed, 5 Aug 2015 17:43:01 +0000 (17:43 +0000)]
Move BB succ_iterator to be inside TerminatorInst.  NFC.

To get the successors of a BB we currently do successors(BB) which
ultimately walks the successors of the BB's terminator.

This moves the iterator to TerminatorInst as thats what we're actually
using to do the iteration, and adds a member function to TerminatorInst
to allow us to iterate directly over successors given an instruction.

For example, we can now do

  for (auto *Succ : BI->successors())

instead of

  for (unsigned i = 0, e = BI->getNumSuccessors(); i != e; ++i)

Reviewed by Tobias Grosser.

llvm-svn: 244074

9 years agoStatic Android build doesn't need shared libs.
Chaoren Lin [Wed, 5 Aug 2015 17:42:46 +0000 (17:42 +0000)]
Static Android build doesn't need shared libs.

llvm-svn: 244073

9 years agoAllow sysroot and python to be specified for Android build.
Chaoren Lin [Wed, 5 Aug 2015 17:42:44 +0000 (17:42 +0000)]
Allow sysroot and python to be specified for Android build.

llvm-svn: 244072

9 years agoMIR Serialization: Serialize the 'debug-use' register operand flag.
Alex Lorenz [Wed, 5 Aug 2015 17:41:17 +0000 (17:41 +0000)]
MIR Serialization: Serialize the 'debug-use' register operand flag.

llvm-svn: 244071

9 years ago[CMake] First pass at adding support for clang bootstrap builds to CMake
Chris Bieneman [Wed, 5 Aug 2015 17:38:12 +0000 (17:38 +0000)]
[CMake] First pass at adding support for clang bootstrap builds to CMake

Summary:
This patch adds a new CLANG_ENABLE_BOOTSTRAP option to CMake which adds targets for building a stage2 bootstrap compiler. The targets are:

bootstrap-configure
bootstrap-build
bootstrap (same as bootstrap-configure and bootstrap-build)
bootstrap-install
bootstrap-check-llvm
bootstrap-check-clang
bootstrap-check-all

If you are using 3.3.20150708 or greater it utilizes the ninja USES_TERMINAL_* settings on the external project so that the output is properly buffered.

Reviewers: bogner, chandlerc

Subscribers: filcab, cfe-commits

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

llvm-svn: 244070

9 years agoFlush stderr on dosep status update for Windows.
Chaoren Lin [Wed, 5 Aug 2015 17:36:54 +0000 (17:36 +0000)]
Flush stderr on dosep status update for Windows.

llvm-svn: 244069

9 years agoMIR Parser: Simplify the handling of quoted tokens. NFC.
Alex Lorenz [Wed, 5 Aug 2015 17:35:55 +0000 (17:35 +0000)]
MIR Parser: Simplify the handling of quoted tokens. NFC.

The machine instructions lexer should not expose the difference between quoted
and unquoted tokens to the parser.

llvm-svn: 244068

9 years ago[AArch64] Register AArch64DeadRegisterDefinition pass with LLVM pass manager.
Chad Rosier [Wed, 5 Aug 2015 17:35:34 +0000 (17:35 +0000)]
[AArch64] Register AArch64DeadRegisterDefinition pass with LLVM pass manager.

llvm-svn: 244067

9 years ago[test/Index] Update libclang tests to use libclang for creating PCH files.
Argyrios Kyrtzidis [Wed, 5 Aug 2015 17:23:59 +0000 (17:23 +0000)]
[test/Index] Update libclang tests to use libclang for creating PCH files.

This is consistent and tests the primary configuration we want to test, libclang
creating and consuming PCH files.

llvm-svn: 244066

9 years agoFix a tiny bug in -no-canonical-prefixes that somehow we have never
Chandler Carruth [Wed, 5 Aug 2015 17:07:33 +0000 (17:07 +0000)]
Fix a tiny bug in -no-canonical-prefixes that somehow we have never
noticed until now.

The code for setting up the driver's InstalledDir didn't respect
-no-canonical-prefixes. Because of this, there are a few places in the
driver where we would unexpectedly form absolute paths, notably when
searching for and finding GCC installations to use, etc. The fix is
straightforward, and I've added this path to '-v' both so we can test it
sanely and so that it will be substantially more obvious the next time
someone has to debug something here.

Note that there is another bug that we don't actually *canonicalize* the
installed directory! I don't really want to fix that because I don't
have a realistic way to test the usage of this mode. I suspect that
folks using the shared module cache would care about getting this right
though, and so they might want to address it. I've left the appropriate
FIXMEs so that it is clear what to change, and I've updated the test
code to make it clear what is happening here.

llvm-svn: 244065

9 years ago[Sparc] Fix disassembly of popc instruction.
James Y Knight [Wed, 5 Aug 2015 17:00:30 +0000 (17:00 +0000)]
[Sparc] Fix disassembly of popc instruction.

And add tests.

Patch by David Wiberg!

llvm-svn: 244064

9 years agoAdd missing atomic libcall support.
James Y Knight [Wed, 5 Aug 2015 16:57:36 +0000 (16:57 +0000)]
Add missing atomic libcall support.

Support for emitting libcalls for __atomic_fetch_nand and
__atomic_{add,sub,and,or,xor,nand}_fetch was missing; add it, and some
test cases.

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

llvm-svn: 244063

9 years agoAMDGPU/SI: Remove EXECReg
Matt Arsenault [Wed, 5 Aug 2015 16:42:57 +0000 (16:42 +0000)]
AMDGPU/SI: Remove EXECReg

For the same reasons as the other physical registers.

llvm-svn: 244062

9 years agoAMDGPU: Remove SCCReg.
Matt Arsenault [Wed, 5 Aug 2015 16:42:54 +0000 (16:42 +0000)]
AMDGPU: Remove SCCReg.

These should be handled as a physical register rather
than a virtual register class with one member.

llvm-svn: 244061

9 years ago[AArch64] Register (existing) AArch64BranchRelaxation pass with LLVM pass manager.
Chad Rosier [Wed, 5 Aug 2015 16:12:10 +0000 (16:12 +0000)]
[AArch64] Register (existing) AArch64BranchRelaxation pass with LLVM pass manager.

Summary: Among other things, this allows -print-after-all/-print-before-all to
dump IR around this pass.

llvm-svn: 244060

9 years agoForce the MachO generated for Darwin to have VERSION_MIN load command
Steven Wu [Wed, 5 Aug 2015 15:36:38 +0000 (15:36 +0000)]
Force the MachO generated for Darwin to have VERSION_MIN load command

On Darwin, it is required to stamp the object file with VERSION_MIN load
command. This commit will provide a VERSRION_MIN load command to the
MachO file that doesn't specify the version itself by inferring from
Target Triple.

llvm-svn: 244059

9 years agotest-release.sh: Fix naming of OpenMP runtime tarball
Hans Wennborg [Wed, 5 Aug 2015 15:36:07 +0000 (15:36 +0000)]
test-release.sh: Fix naming of OpenMP runtime tarball

llvm-svn: 244058

9 years ago[AArch64] Make the naming of the Address Type Promotion pass consistent.
Chad Rosier [Wed, 5 Aug 2015 15:32:23 +0000 (15:32 +0000)]
[AArch64] Make the naming of the Address Type Promotion pass consistent.

llvm-svn: 244057

9 years ago[AArch64] Register (existing) AArch64AdvSIMDScalar pass with LLVM pass manager.
Chad Rosier [Wed, 5 Aug 2015 15:18:58 +0000 (15:18 +0000)]
[AArch64] Register (existing) AArch64AdvSIMDScalar pass with LLVM pass manager.

Summary: Among other things, this allows -print-after-all/-print-before-all to
dump IR around this pass.

IIRC, this pass is off by default, but it's still helpful when debugging.

llvm-svn: 244056

9 years ago[tsan] Enable tsan for aarch64
Adhemerval Zanella [Wed, 5 Aug 2015 15:17:59 +0000 (15:17 +0000)]
[tsan] Enable tsan for aarch64

This patch enabled TSAN for aarch64 with 39-bit VMA layout.  As defined by
tsan_platform.h the layout used is:

0000 4000 00 - 0200 0000 00: main binary
2000 0000 00 - 4000 0000 00: shadow memory
4000 0000 00 - 5000 0000 00: metainfo
5000 0000 00 - 6000 0000 00: -
6000 0000 00 - 6200 0000 00: traces
6200 0000 00 - 7d00 0000 00: -
7d00 0000 00 - 7e00 0000 00: heap
7e00 0000 00 - 7fff ffff ff: modules and main thread stack

Which gives it about 8GB for main binary, 4GB for heap and 8GB for
modules and main thread stack.

Most of tests are passing, with the exception of:

 * ignore_lib0, ignore_lib1, ignore_lib3 due a kernel limitation for
   no support to make mmap page non-executable.

 * longjmp tests due missing specialized assembly routines.

These tests are xfail for now.

The only tsan issue still showing is:

  rtl/TsanRtlTest/Posix.ThreadLocalAccesses

Which still required further investigation.  The test is disable for
aarch64 for now.

llvm-svn: 244055

9 years ago[asan] Enable asan for aarch64
Adhemerval Zanella [Wed, 5 Aug 2015 15:13:33 +0000 (15:13 +0000)]
[asan] Enable asan for aarch64

This patch enables asan for aarch64/linux.  It marks it as 'unstable-release',
since some tests are failing due either kernel missing support of non-executable
pages in mmap or environment instability (infinite loop in juno reference
boards).

It sets decorate_proc_maps test to require stable-release, since the test expects
the shadow memory to not be executable and the support for aarch64 is only
added recently by Linux (da141706aea52c1a9 - 4.0).

It also XFAIL static_tls test for aarch64 linker may omit the __tls_get_addr call
as a TLS optimization.

llvm-svn: 244054

9 years agorevert r243687: enable fast-math-flag propagation to DAG nodes
Sanjay Patel [Wed, 5 Aug 2015 15:12:03 +0000 (15:12 +0000)]
revert r243687: enable fast-math-flag propagation to DAG nodes

We can't propagate FMF partially without breaking DAG-level CSE. We either need to
relax CSE to account for mismatched FMF as a temporary work-around or fully propagate
FMF throughout the DAG.

Surprisingly, there are no existing regression tests for this, but here's an example:

  define float @fmf(float %a, float %b) {
    %mul1 = fmul fast float %a, %b
    %nega = fsub fast float 0.0, %a
    %mul2 = fmul fast float %nega, %b
    %abx2 = fsub fast float %mul1, %mul2
    ret float %abx2
  }

$ llc -o - badflags.ll -march=x86-64 -mattr=fma -enable-unsafe-fp-math -enable-fmf-dag=0
...
    vmulss    %xmm1, %xmm0, %xmm0
    vaddss    %xmm0, %xmm0, %xmm0
    retq

$ llc -o - badflags.ll -march=x86-64 -mattr=fma -enable-unsafe-fp-math -enable-fmf-dag=1
...
    vmulss    %xmm1, %xmm0, %xmm2
    vfmadd213ss    %xmm2, %xmm1, %xmm0  <--- failed to recognize that (a * b) was already calculated
    retq

llvm-svn: 244053

9 years ago[SHAVE] uppercase the CHECK prefixes in 'lit' tests. NFC
Douglas Katzman [Wed, 5 Aug 2015 15:08:54 +0000 (15:08 +0000)]
[SHAVE] uppercase the CHECK prefixes in 'lit' tests. NFC

llvm-svn: 244052

9 years agoDelete trailing whitespace
Douglas Katzman [Wed, 5 Aug 2015 15:08:53 +0000 (15:08 +0000)]
Delete trailing whitespace

llvm-svn: 244051

9 years agoAdd bare minimum to get a working i386 linux program.
Rafael Espindola [Wed, 5 Aug 2015 15:08:40 +0000 (15:08 +0000)]
Add bare minimum to get a working i386 linux program.

llvm-svn: 244050

9 years agoOfficially end my reign as owner of the driver.
Chad Rosier [Wed, 5 Aug 2015 14:52:01 +0000 (14:52 +0000)]
Officially end my reign as owner of the driver.

llvm-svn: 244049

9 years agoMake this less error prone by using a #define. NFC.
Chad Rosier [Wed, 5 Aug 2015 14:48:44 +0000 (14:48 +0000)]
Make this less error prone by using a #define. NFC.

llvm-svn: 244048

9 years agoUpdate some links so that they don't point at the (private) WG21 Wiki
Marshall Clow [Wed, 5 Aug 2015 14:36:42 +0000 (14:36 +0000)]
Update some links so that they don't point at the (private) WG21 Wiki

llvm-svn: 244047

9 years ago[AArch64] Register (existing) AArch64ExpandPseudo pass with LLVM pass manager.
Chad Rosier [Wed, 5 Aug 2015 14:22:53 +0000 (14:22 +0000)]
[AArch64] Register (existing) AArch64ExpandPseudo pass with LLVM pass manager.

Summary: Among other things, this allows -print-after-all/-print-before-all to
dump IR around this pass.

llvm-svn: 244046

9 years ago[AA] Use CallSite cast idiom. No functionality change.
Benjamin Kramer [Wed, 5 Aug 2015 14:16:44 +0000 (14:16 +0000)]
[AA] Use CallSite cast idiom. No functionality change.

llvm-svn: 244045

9 years ago[YAMLTraits] Use StringRef::copy. No functionality change.
Benjamin Kramer [Wed, 5 Aug 2015 14:16:38 +0000 (14:16 +0000)]
[YAMLTraits] Use StringRef::copy. No functionality change.

llvm-svn: 244044

9 years ago[IR] Simplify code with ArrayRef::copy. No functionality change.
Benjamin Kramer [Wed, 5 Aug 2015 14:16:28 +0000 (14:16 +0000)]
[IR] Simplify code with ArrayRef::copy. No functionality change.

llvm-svn: 244043

9 years agoFor now we only have on Chunk type. Simplify.
Rafael Espindola [Wed, 5 Aug 2015 13:55:34 +0000 (13:55 +0000)]
For now we only have on Chunk type. Simplify.

The others we have in sight are
* common symbols.
* entries in SHF_MERGE sections.

They will have a substantially different treatment. It is not clear if it is
worth it putting them all in a single list just to dispatch based on the kind on
the other side.

I hope to implement common symbols soon, and then we will be in a position
to have a concrete discussion. For now this is simpler for the the implemented
features.

llvm-svn: 244042

9 years ago[AArch64] Register (existing) AArch64LoadStoreOpt pass with LLVM pass manager.
Chad Rosier [Wed, 5 Aug 2015 13:44:51 +0000 (13:44 +0000)]
[AArch64] Register (existing) AArch64LoadStoreOpt pass with LLVM pass manager.

Summary: Among other things, this allows -print-after-all/-print-before-all to
dump IR around this pass.

This is the AArch64 version of r243052.

llvm-svn: 244041

9 years agoDelete dead code.
Rafael Espindola [Wed, 5 Aug 2015 13:26:54 +0000 (13:26 +0000)]
Delete dead code.

llvm-svn: 244040

9 years agoBug 24332 - Fix the build of lldb under GNU/Linux when using autotools
Sylvestre Ledru [Wed, 5 Aug 2015 12:46:53 +0000 (12:46 +0000)]
Bug 24332 - Fix the build of lldb under GNU/Linux when using autotools

Reviewers: loladiro, jingham, emaste, zturner, brucem

Subscribers: tberghammer, danalbert, srhines, zturner, lldb-commits

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

llvm-svn: 244039

9 years agoUpdate comment. NFC.
Chad Rosier [Wed, 5 Aug 2015 12:40:13 +0000 (12:40 +0000)]
Update comment. NFC.

llvm-svn: 244038

9 years agoRename asm tests to .s. NFC.
Rafael Espindola [Wed, 5 Aug 2015 12:14:51 +0000 (12:14 +0000)]
Rename asm tests to .s. NFC.

llvm-svn: 244037

9 years agoAdd AST matchers for narrowing constructors that are default, copy, or move construct...
Aaron Ballman [Wed, 5 Aug 2015 12:11:30 +0000 (12:11 +0000)]
Add AST matchers for narrowing constructors that are default, copy, or move constructors, as well as functionality to determine whether a ctor initializer is a base initializer.

llvm-svn: 244036

9 years agolld elf2: Diagnose trying to mix incompatible files.
Rafael Espindola [Wed, 5 Aug 2015 12:03:34 +0000 (12:03 +0000)]
lld elf2: Diagnose trying to mix incompatible files.

This is also a step in instantiating the writer with the correct template
argument.

llvm-svn: 244035

9 years agoD11156: Fix comments by eliminating possible trademark conflicts
Andrey Churbanov [Wed, 5 Aug 2015 12:00:07 +0000 (12:00 +0000)]
D11156: Fix comments by eliminating possible trademark conflicts

llvm-svn: 244034

9 years agoUse ELFOSABI_NONE. This matches both bfd ld and gold.
Rafael Espindola [Wed, 5 Aug 2015 11:55:52 +0000 (11:55 +0000)]
Use ELFOSABI_NONE. This matches both bfd ld and gold.

llvm-svn: 244033

9 years agoDrop unnecessary static_cast.
Rafael Espindola [Wed, 5 Aug 2015 11:53:59 +0000 (11:53 +0000)]
Drop unnecessary static_cast.

ELFT::TargetEndianness already has the correct type.

llvm-svn: 244032

9 years agoD11301: Remove the __kmp_invoke_microtask() that relies on libffi
Andrey Churbanov [Wed, 5 Aug 2015 11:23:10 +0000 (11:23 +0000)]
D11301: Remove the __kmp_invoke_microtask() that relies on libffi

llvm-svn: 244031

9 years agoD11159: Fixing the stack offset functionality
Andrey Churbanov [Wed, 5 Aug 2015 11:12:45 +0000 (11:12 +0000)]
D11159: Fixing the stack offset functionality

llvm-svn: 244030

9 years agoARMISelDAGToDAG.cpp had this self-contradictory code:
Artyom Skrobov [Wed, 5 Aug 2015 11:02:14 +0000 (11:02 +0000)]
ARMISelDAGToDAG.cpp had this self-contradictory code:

  return StringSwitch<int>(Flags)
          .Case("g", 0x1)
          .Case("nzcvq", 0x2)
          .Case("nzcvqg", 0x3)
          .Default(-1);
...

  // The _g and _nzcvqg versions are only valid if the DSP extension is
  // available.
  if (!Subtarget->hasThumb2DSP() && (Mask & 0x2))
    return -1;

ARMARM confirms that the comment is right, and the code was wrong.

llvm-svn: 244029

9 years ago[AST] ArrayRefize template param list info setters. No functionality change intended.
Benjamin Kramer [Wed, 5 Aug 2015 09:40:49 +0000 (09:40 +0000)]
[AST] ArrayRefize template param list info setters. No functionality change intended.

llvm-svn: 244028

9 years ago[AST] ArrayRefize BlockDecl::setCaptures. No functionality change intended.
Benjamin Kramer [Wed, 5 Aug 2015 09:40:35 +0000 (09:40 +0000)]
[AST] ArrayRefize BlockDecl::setCaptures. No functionality change intended.

llvm-svn: 244027

9 years ago[AST] ArrayRefize template argument packs. No functionality change intended.
Benjamin Kramer [Wed, 5 Aug 2015 09:40:22 +0000 (09:40 +0000)]
[AST] ArrayRefize template argument packs. No functionality change intended.

llvm-svn: 244026

9 years ago[Comments] Replace custom ArrayRef copying with ArrayRef::copy. NFC.
Benjamin Kramer [Wed, 5 Aug 2015 09:40:04 +0000 (09:40 +0000)]
[Comments] Replace custom ArrayRef copying with ArrayRef::copy. NFC.

llvm-svn: 244025

9 years ago[Parse] ArrayRefize PragmaLoopHintInfo. No functionality change.
Benjamin Kramer [Wed, 5 Aug 2015 09:39:57 +0000 (09:39 +0000)]
[Parse] ArrayRefize PragmaLoopHintInfo. No functionality change.

llvm-svn: 244024

9 years ago[ArrayRefTest] Work around a GCC 4.8 internal compiler error.
Benjamin Kramer [Wed, 5 Aug 2015 09:39:41 +0000 (09:39 +0000)]
[ArrayRefTest] Work around a GCC 4.8 internal compiler error.

llvm-svn: 244023

9 years ago[InstCombine] Added more specific SSE2/AVX2 vector shift tests.
Simon Pilgrim [Wed, 5 Aug 2015 08:21:38 +0000 (08:21 +0000)]
[InstCombine] Added more specific SSE2/AVX2 vector shift tests.

llvm-svn: 244022

9 years agoFixed line endings.
Simon Pilgrim [Wed, 5 Aug 2015 08:18:00 +0000 (08:18 +0000)]
Fixed line endings.

llvm-svn: 244021

9 years ago[MachineCombiner] Don't use the opcode-only form of computeInstrLatency
Hal Finkel [Wed, 5 Aug 2015 07:45:28 +0000 (07:45 +0000)]
[MachineCombiner] Don't use the opcode-only form of computeInstrLatency

In r242277, I updated the MachineCombiner to work with itineraries, but I
missed a call that is scheduling-model-only (the opcode-only form of
computeInstrLatency). Using the form that takes an MI* allows this to work with
itineraries (and should be NFC for subtargets with scheduling models).

llvm-svn: 244020

9 years ago[llvm-objdump] Call exit(1) on error, i.e. fail early.
Davide Italiano [Wed, 5 Aug 2015 07:18:31 +0000 (07:18 +0000)]
[llvm-objdump] Call exit(1) on error, i.e. fail early.

Previously we kept going on partly corrupted input, which might result
in garbage being printed, or even worse, random crashes.
Rafael mentioned that this is the GNU behavior as well, but after some
discussion we both agreed it's probably better to emit a reasonable
error message and exit. As a side-effect of this commit, now we don't
rely on global state for error codes anymore. objdump was the last tool
in the toolchain which needed to be converted. Hopefully the old behavior
won't sneak into the tree again.

llvm-svn: 244019

9 years agoDon't repeat function names in comments. NFC.
Filipe Cabecinhas [Wed, 5 Aug 2015 06:19:26 +0000 (06:19 +0000)]
Don't repeat function names in comments. NFC.

llvm-svn: 244018

9 years agounittests/ADT/ArrayRefTest.cpp: Suppress r243995 on g++-4.8 for now to unbreak bots.
NAKAMURA Takumi [Wed, 5 Aug 2015 06:11:23 +0000 (06:11 +0000)]
unittests/ADT/ArrayRefTest.cpp: Suppress r243995 on g++-4.8 for now to unbreak bots.

For example of mingw-w64-g++-4.8.1,

  llvm/unittests/ADT/ArrayRefTest.cpp: In member function 'virtual void {anonymous}::ArrayRefTest_AllocatorCopy_Test::TestBody()':
  llvm/unittests/ADT/ArrayRefTest.cpp:56:40: internal compiler error: in count_type_elements, at expr.c:5523
     } Array3Src[] = {{"hello"}, {"world"}};
                                          ^
  Please submit a full bug report,
  with preprocessed source if appropriate.

llvm-svn: 244017

9 years agoWindows/COM.inc: Fix emacs mode in the first line.
NAKAMURA Takumi [Wed, 5 Aug 2015 06:11:08 +0000 (06:11 +0000)]
Windows/COM.inc: Fix emacs mode in the first line.

llvm-svn: 244016

9 years agoTemporarily revert r244012 while we see if it's really necessary.
Eric Christopher [Wed, 5 Aug 2015 05:32:22 +0000 (05:32 +0000)]
Temporarily revert r244012 while we see if it's really necessary.
Add a comment explaining the current theory as to why we'd need
the -lole32 on the link line.

llvm-svn: 244015

9 years agoRemove autoconf checks for sigsetjmp and siglongjmp as they appear to
Eric Christopher [Wed, 5 Aug 2015 04:50:46 +0000 (04:50 +0000)]
Remove autoconf checks for sigsetjmp and siglongjmp as they appear to
be unused.

llvm-svn: 244014

9 years agoRemove the apparently unused rand48 configure checks and associated m4.
Eric Christopher [Wed, 5 Aug 2015 04:50:43 +0000 (04:50 +0000)]
Remove the apparently unused rand48 configure checks and associated m4.

llvm-svn: 244013

9 years agoRemove obsolete configure check for libole32 as we don't appear to use
Eric Christopher [Wed, 5 Aug 2015 04:50:40 +0000 (04:50 +0000)]
Remove obsolete configure check for libole32 as we don't appear to use
it anymore.

llvm-svn: 244012

9 years agoRemove the unused header check for utime.h.
Eric Christopher [Wed, 5 Aug 2015 04:50:37 +0000 (04:50 +0000)]
Remove the unused header check for utime.h.

llvm-svn: 244011

9 years agoUpdate links to lists.llvm.org.
Tanya Lattner [Wed, 5 Aug 2015 04:19:04 +0000 (04:19 +0000)]
Update links to lists.llvm.org.

llvm-svn: 244009

9 years agoUpdate to lists.llvm.org
Tanya Lattner [Wed, 5 Aug 2015 04:04:09 +0000 (04:04 +0000)]
Update to lists.llvm.org

llvm-svn: 244008

9 years agoUpdate to new lists.llvm.org
Tanya Lattner [Wed, 5 Aug 2015 04:03:05 +0000 (04:03 +0000)]
Update to new lists.llvm.org

llvm-svn: 244007

9 years agoUpdate to new lists.llvm.org
Tanya Lattner [Wed, 5 Aug 2015 04:02:43 +0000 (04:02 +0000)]
Update to new lists.llvm.org

llvm-svn: 244006

9 years agoUpdate to new lists.llvm.org
Tanya Lattner [Wed, 5 Aug 2015 04:01:47 +0000 (04:01 +0000)]
Update to new lists.llvm.org

llvm-svn: 244005

9 years agoUpdate to new lists.llvm.org
Tanya Lattner [Wed, 5 Aug 2015 04:01:26 +0000 (04:01 +0000)]
Update to new lists.llvm.org

llvm-svn: 244004

9 years agoUpdate references to lists.llvm.org
Tanya Lattner [Wed, 5 Aug 2015 03:59:14 +0000 (03:59 +0000)]
Update references to lists.llvm.org

llvm-svn: 244003

9 years agoUpdate references to new lists.llvm.org mailing lists.
Tanya Lattner [Wed, 5 Aug 2015 03:58:00 +0000 (03:58 +0000)]
Update references to new lists.llvm.org mailing lists.

llvm-svn: 244002

9 years agoUpdate references to new lists.llvm.org mailing lists.
Tanya Lattner [Wed, 5 Aug 2015 03:56:44 +0000 (03:56 +0000)]
Update references to new lists.llvm.org mailing lists.

llvm-svn: 244001

9 years agoUpdate mailing list references to lists.llvm.org
Tanya Lattner [Wed, 5 Aug 2015 03:55:23 +0000 (03:55 +0000)]
Update mailing list references to lists.llvm.org

llvm-svn: 244000

9 years agoRename all references to old mailing lists to new lists.llvm.org address.
Tanya Lattner [Wed, 5 Aug 2015 03:51:17 +0000 (03:51 +0000)]
Rename all references to old mailing lists to new lists.llvm.org address.

llvm-svn: 243999

9 years agoAvoid passing nullptr to std::equal.
Yaron Keren [Tue, 4 Aug 2015 15:57:04 +0000 (15:57 +0000)]
Avoid passing nullptr to std::equal.
As documented in the LLVM Coding Standards, indeed MSVC incorrectly asserts
on this in Debug mode. This happens when building clang with Visual C++ and
-triple i686-pc-windows-gnu on these clang regression tests:

 clang/test/CodeGen/2011-03-08-ZeroFieldUnionInitializer.c
 clang/test/CodeGen/empty-union-init.c

llvm-svn: 243996

9 years ago[ArrayRef] Make copy use std::uninitialized_copy.
Benjamin Kramer [Tue, 4 Aug 2015 15:52:56 +0000 (15:52 +0000)]
[ArrayRef] Make copy use std::uninitialized_copy.

std::copy does not work for non-trivially copyable classes when we're
copying into uninitialized memory.

llvm-svn: 243995

9 years agowrap OptSize and MinSize attributes for easier and consistent access (NFCI)
Sanjay Patel [Tue, 4 Aug 2015 15:49:57 +0000 (15:49 +0000)]
wrap OptSize and MinSize attributes for easier and consistent access (NFCI)

Create wrapper methods in the Function class for the OptimizeForSize and MinSize
attributes. We want to hide the logic of "or'ing" them together when optimizing
just for size (-Os).

Currently, we are not consistent about this and rely on a front-end to always set
OptimizeForSize (-Os) if MinSize (-Oz) is on. Thus, there are 18 FIXME changes here
that should be added as follow-on patches with regression tests.

This patch is NFC-intended: it just replaces existing direct accesses of the attributes
by the equivalent wrapper call.

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

llvm-svn: 243994

9 years agoCreate ObjectFile with the correct endian and word size.
Rafael Espindola [Tue, 4 Aug 2015 15:45:54 +0000 (15:45 +0000)]
Create ObjectFile with the correct endian and word size.

The writer is still hard coded to 64 bits le, but with this we can test for
invalid ELF files.

llvm-svn: 243993

9 years ago[CodeGen] Fold memcpy into SmallVector initializer. No functionality change.
Benjamin Kramer [Tue, 4 Aug 2015 15:38:49 +0000 (15:38 +0000)]
[CodeGen] Fold memcpy into SmallVector initializer. No functionality change.

llvm-svn: 243992

9 years ago[RuntimeDyld] Adapt PPC64 relocations to PPC32
Hal Finkel [Tue, 4 Aug 2015 15:29:00 +0000 (15:29 +0000)]
[RuntimeDyld] Adapt PPC64 relocations to PPC32

Begin adapting some of the implemented PPC64 relocations for PPC32 (with a
test case).

Patch by Pierre-Andre Saulais!

llvm-svn: 243991

9 years ago[x86] machine combiner reassociation: mark EFLAGS operand as 'dead'
Sanjay Patel [Tue, 4 Aug 2015 15:21:56 +0000 (15:21 +0000)]
[x86] machine combiner reassociation: mark EFLAGS operand as 'dead'

In the commentary for D11660, I wasn't sure if it was alright to create new
integer machine instructions without also creating the implicit EFLAGS operand.
From what I can see, the implicit operand is always created by the MachineInstrBuilder
based on the instruction type, so we don't have to do that explicitly. However, in
reviewing the debug output, I noticed that the operand was not marked as 'dead'.
The machine combiner should do that to preserve future optimization opportunities
that may be checking for that dead EFLAGS operand themselves.

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

llvm-svn: 243990