Commit Graph

190695 Commits

Author SHA1 Message Date
Evgeniy Stepanov 4448007885 [asan] More verbose output from one of the tests.
Trying to debug a buildbot-only failure.

llvm-svn: 226270
2015-01-16 12:08:32 +00:00
Toma Tabacu f476200c63 [mips] Remove a redundant semicolon and add space before curly brackets. NFC.
llvm-svn: 226269
2015-01-16 10:45:15 +00:00
Evgeniy Stepanov 82d3ef1617 [asan] Fix asan_options-include test.
Wrong include order.

llvm-svn: 226268
2015-01-16 10:30:53 +00:00
Evgeniy Stepanov 29235e374c [sanitizer] Fix bashism in check_lint.sh.
llvm-svn: 226267
2015-01-16 10:20:49 +00:00
Evgeniy Stepanov e0009356ba [sanitizer] Cleanup linter temporary files.
llvm-svn: 226266
2015-01-16 10:09:56 +00:00
Simon Atanasyan 6cea6473b3 [ELF] Remove TargetHandler and DefaultTargetHandler constructors
These classes contain only abstract virtual functions. Explicit
constructors are redundant.

llvm-svn: 226265
2015-01-16 09:40:21 +00:00
Simon Pilgrim 367db8eec6 [X86] Refactored stack memory folding tests to explicitly force register spilling
The current 'big vectors' stack folded reload testing pattern is very bulky and makes it difficult to test all instructions as big vectors will tend to use only the ymm instruction implementations.

This patch changes the tests to use a nop call that lists explicit xmm registers as sideeffects, with this we can force a partial register spill of the relevant registers and then check that the reload is correctly folded. The asm generated only adds the forced spill, a nop instruction and a couple of extra labels (a fraction of the current approach).

More exhaustive tests will follow shortly, I've added some extra tests (the xmm versions of some of the existing folding tests) as a starting point.

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

llvm-svn: 226264
2015-01-16 09:32:54 +00:00
Evgeniy Stepanov db20539d3a [sanitizer] Fix compiler warning in the flag parser code.
llvm-svn: 226263
2015-01-16 09:32:31 +00:00
Simon Atanasyan c7c4b26c11 [ELF] Remove unused class field
No functional changes.

llvm-svn: 226262
2015-01-16 08:58:14 +00:00
Simon Atanasyan 49a055336b [ELF] s/_context/_ctx/ and clang-format the code
No functional changes.

llvm-svn: 226261
2015-01-16 08:58:09 +00:00
Simon Atanasyan 7bdd62b2cd [ELF] Make the unhandledReferenceType() protected method
No functional changes.

llvm-svn: 226260
2015-01-16 08:58:03 +00:00
Simon Atanasyan 8a9c8b1968 [ELF] Make `TargetRelocationHandler` a regular non-template class
This class defines a relocation handler interface. The interface does
not depend on the template argument so the argument is redundant.

llvm-svn: 226259
2015-01-16 08:57:58 +00:00
Simon Atanasyan 42f0e789ed [PPC] Remove redundant `virtual` keyword
No functional changes.

llvm-svn: 226258
2015-01-16 08:57:45 +00:00
Simon Atanasyan 53d940335c [PPC] Remove unused class field PPCTargetRelocationHandler::_ppcTargetLayout
No functional changes.

llvm-svn: 226257
2015-01-16 08:57:39 +00:00
Simon Atanasyan c46de4ba3b [Mips] Use ELFLinkingContext class instead of MipsLinkingContext where possible
No functional changes.

llvm-svn: 226256
2015-01-16 08:57:33 +00:00
Simon Atanasyan 0f049c1a7c [Mips] Make MipsLinkingContext owner of MipsELFFlagsMerger
That reduce class dependencies and simplify the code a bit.
No functional changes.

llvm-svn: 226255
2015-01-16 08:57:26 +00:00
Simon Atanasyan 157432bcb2 [Mips] Remove redundant namespace names
No functional changes.

llvm-svn: 226254
2015-01-16 08:57:17 +00:00
Simon Atanasyan 48b0bca7e8 [Mips] Allow linking object files with MIPS32 and MIPS64 instructions
If object files satisfy O32 ABI they can be linked together even if some
of them contains MIPS64 or MIPS64R2 instructions.

llvm-svn: 226253
2015-01-16 08:57:08 +00:00
Timur Iskhodzhanov 60b721363c Revert r226242 - Revert Revert Don't create new comdats in CodeGen
This breaks AddressSanitizer (ninja check-asan) on Windows

llvm-svn: 226251
2015-01-16 08:38:45 +00:00
Alexey Bataev 24b04aa393 [OPENMP] Fixed data-sharing attributes processing for variables with global
storage.
This fix allows to use non-constant global variables, static local variables and static data
members in data-sharing attribute clauses in parallel and task regions.

llvm-svn: 226250
2015-01-16 07:11:33 +00:00
Vince Harron 76861ea8f7 minor refactoring to remove unneeded/unspecific header files
Differential review: http://reviews.llvm.org/D6919

llvm-svn: 226249
2015-01-16 06:47:43 +00:00
Filipe Cabecinhas 3ca723c9e5 Use report_fatal_error instead of llvm_unreachable, so we don't crash on user input
llvm-svn: 226248
2015-01-16 04:54:12 +00:00
Hal Finkel 52f7c018d3 [PowerPC] Adjust PatchPoints for ppc64le
Bill Schmidt pointed out that some adjustments would be needed to properly
support powerpc64le (using the ELF V2 ABI). For one thing, R11 is not available
as a scratch register, so we need to use R12. R12 is also available under ELF
V1, so to maintain consistency, I flipped the order to make R12 the first
scratch register in the array under both ABIs.

llvm-svn: 226247
2015-01-16 04:40:58 +00:00
Saleem Abdulrasool 6fffd487ee PE/COFF: use dyn_cast for the check of the target
The target may be a synthetic symbol like __ImageBase.  cast_or_null will ensure
that the atom is a DefinedAtom, which is not guaranteed, which was the original
reason for the cast_or_null.  Switch this to dyn_cast, which should enable
building of executables for WoA.  Unfortunately, the issue of missing base
relocations still needs to be investigated.

llvm-svn: 226246
2015-01-16 04:14:33 +00:00
Mehdi Amini 590a2700fc Fix Reassociate handling of constant in presence of undef float
http://reviews.llvm.org/D6993

llvm-svn: 226245
2015-01-16 03:00:58 +00:00
Jason Molenda bcc5785958 Fixes to DNBArchImpl in debugserver to correctly get/set
the register state when debugging AArch32 programs (armv7
programs running on an armv8 processor).  Most notably,
there is no "fpscr" register in the register context -
there is an fpsr and an fpcr.

Also fix a bug where the floating point values could not
be written in armv7 processes.
<rdar://problem/18977767> 

llvm-svn: 226244
2015-01-16 02:31:35 +00:00
Dan Albert e39fb93cf3 Remove triple detection from cmake.
This isn't actually used for anything, and is broken on Darwin
(currently causing build failures now that the triple is passed to aid
cross compiling). Rather than fix unused code, just remove it.

llvm-svn: 226243
2015-01-16 02:27:17 +00:00
Rafael Espindola 67a79e72f5 Revert "Revert Don't create new comdats in CodeGen"
This reverts commit r226173, adding r226038 back.

No change in this commit, but clang was changed to also produce trivial comdats for
costructors, destructors and vtables when needed.

Original message:

Don't create new comdats in CodeGen.

This patch stops the implicit creation of comdats during codegen.

Clang now sets the comdat explicitly when it is required. With this patch clang and gcc
now produce the same result in pr19848.

llvm-svn: 226242
2015-01-16 02:22:55 +00:00
Kevin Enderby 15e9420f69 Work around to get the build bot clang-cmake-armv7-a15-full green by
removing the macho-archive-headers.test added with r226228 that it is
failing on for now while I try to figure out what is going on.

llvm-svn: 226241
2015-01-16 02:08:11 +00:00
Dan Albert 91014006d1 LIBCXXABI_TARGET_TRIPLE won't always be set.
Fixes issue with r226235. Build configuration difference between
libc++ and libc++abi.

llvm-svn: 226240
2015-01-16 01:10:09 +00:00
Kevin Enderby 95f1860d4c Another attempt to fix the build bot clang-cmake-armv7-a15-full failing on
the macho-archive-headers.test added with r226228.

llvm-svn: 226239
2015-01-16 01:09:54 +00:00
Sanjoy Das a1837a342d Add a new pass "inductive range check elimination"
IRCE eliminates range checks of the form

  0 <= A * I + B < Length

by splitting a loop's iteration space into three segments in a way
that the check is completely redundant in the middle segment.  As an
example, IRCE will convert

  len = < known positive >
  for (i = 0; i < n; i++) {
    if (0 <= i && i < len) {
      do_something();
    } else {
      throw_out_of_bounds();
    }
  }

to

  len = < known positive >
  limit = smin(n, len)
  // no first segment
  for (i = 0; i < limit; i++) {
    if (0 <= i && i < len) { // this check is fully redundant
      do_something();
    } else {
      throw_out_of_bounds();
    }
  }
  for (i = limit; i < n; i++) {
    if (0 <= i && i < len) {
      do_something();
    } else {
      throw_out_of_bounds();
    }
  }


IRCE can deal with multiple range checks in the same loop (it takes
the intersection of the ranges that will make each of them redundant
individually).

Currently IRCE does not do any profitability analysis.  That is a
TODO.

Please note that the status of this pass is *experimental*, and it is
not part of any default pass pipeline.  Having said that, I will love
to get feedback and general input from people interested in trying
this out.

This pass was originally r226201.  It was reverted because it used C++
features not supported by MSVC 2012.

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

llvm-svn: 226238
2015-01-16 01:03:22 +00:00
Dan Albert db56013cd1 [libc++] Add support for cross compiling.
Reviewers: EricWF, jroelofs

Reviewed By: jroelofs

Subscribers: cfe-commits

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

llvm-svn: 226237
2015-01-16 00:55:15 +00:00
Rui Ueyama 18e53ca3dd Use std::recursive_mutex instead of llvm's SmartMutex.
llvm-svn: 226236
2015-01-16 00:55:01 +00:00
Dan Albert 1fc2441447 [libc++abi] Add support for cross compiling.
Reviewers: EricWF, jroelofs

Reviewed By: jroelofs

Subscribers: cfe-commits

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

llvm-svn: 226235
2015-01-16 00:52:11 +00:00
Vince Harron 014bb7da79 Add Socket::Get[Remote/Local]IpAddress and unit tests
Differential Revision: http://reviews.llvm.org/D6917

llvm-svn: 226234
2015-01-16 00:47:08 +00:00
Nico Weber 0a3a7ccb3a Give lldb a clean null build.
`ninja lldb` used to always run "echo -n", which on OS X results in literally
echoing "-n" to the screen.  Just remove the command from add_custom_target,
then it only adds an alias and `ninja lldb` now reports "no work to do".

Other than that, no intended behavior change.

llvm-svn: 226233
2015-01-16 00:35:05 +00:00
Kevin Enderby a975d4df1d This should fix the build bot clang-cmake-armv7-a15-full failing on
the macho-archive-headers.test added with r226228.

llvm-svn: 226232
2015-01-16 00:27:31 +00:00
Jason Molenda 3f194f7997 Add comment regarding which i386 registers are non-volatile instead of
just pointing to the standard document regarding this.

llvm-svn: 226231
2015-01-16 00:27:25 +00:00
Matt Arsenault eeb2a7e688 R600/SI: Add patterns for v_cvt_{flr|rpi}_i32_f32
llvm-svn: 226230
2015-01-15 23:58:35 +00:00
Filipe Cabecinhas c552c9abce Fix edge case when Start overflowed in 32 bit mode
llvm-svn: 226229
2015-01-15 23:50:44 +00:00
Kevin Enderby 13023a1af6 Add the option, -archive-headers, used with -macho to print the Mach-O archive headers to llvm-objdump.
llvm-svn: 226228
2015-01-15 23:19:11 +00:00
Rafael Espindola cb92c19fc4 Use a trivial comdat for C++ tables.
This produces comdats for vtables, typeinfo, typeinfo names, and vtts.

When combined with llvm not producing implicit comdats, not doing this would
cause code bloat on ELF and link errors on COFF.

llvm-svn: 226227
2015-01-15 23:18:01 +00:00
Matt Arsenault 268757ba60 R600/SI: Fix trailing comma with modifiers
Instructions with 1 operand can still use source modifiers,
so make sure we don't print an extra comma afterwards.

llvm-svn: 226226
2015-01-15 23:17:03 +00:00
Rui Ueyama c2836079df Simplify.
llvm-svn: 226225
2015-01-15 23:15:09 +00:00
Colin LeMahieu cd9c4e3e07 [Hexagon] Adding new-value store and bit reverse instructions.
llvm-svn: 226224
2015-01-15 23:10:29 +00:00
Jonathan Roelofs 0c69163a42 Print out environment in lit notes
llvm-svn: 226223
2015-01-15 23:04:37 +00:00
Filipe Cabecinhas e609302ad1 Remove the slashes so they don't fail in some Windows setups
llvm-svn: 226222
2015-01-15 23:04:15 +00:00
Zachary Turner f194c50fc3 Some fixes for thread stepping on Windows.
This hooks up the changes necessary to set the trap flag on the
CPU and properly manage the process and thread's resume state
and private state so that the ThreadPlan does its thing.

Stepping still doesn't work as of this change, because there are
some issues with stack frames where it doesn't update the thread's
frame list correctly when it breaks inside of a function, but
I will try to fix that separately.

llvm-svn: 226221
2015-01-15 22:54:08 +00:00
Zachary Turner 8f3f7beac4 During source manager test, write back the file using binary mode.
On Windows, opening with "w" opens it as text instead of binary.
This causes translation of newline characters, so that "\n" turns
into "\r\n", which in turn leads to git detecting that the file
has changed and wanting to commit it.

llvm-svn: 226220
2015-01-15 22:53:44 +00:00