Commit Graph

199708 Commits

Author SHA1 Message Date
Pete Cooper 46361a1ea1 Change x86 CMOVE_F to read it source, not write it.
This was breaking sqlite with the machine verifier because operand 0 was a def according to tablegen, but didn't have the 'isDef' flag set.

Looking at the ISA, its clear that this operand is a source as writing to st(0) is implicit.  So move the operand to the correct place in the td file.

rdar://problem/20751584

llvm-svn: 236183
2015-04-29 23:51:33 +00:00
Richard Smith 63a41277fe Fix build after Clang API change in r236176.
llvm-svn: 236182
2015-04-29 23:46:48 +00:00
Richard Smith f5ec2acca9 Add an assert to get information on buildbot failure.
llvm-svn: 236181
2015-04-29 23:40:48 +00:00
Jonathan Roelofs 10b3acf215 Fix doxygen comment typo. NFC
llvm-svn: 236180
2015-04-29 23:33:32 +00:00
Eric Christopher fb481a4054 Propagate a terrible hack to the sparc target feature handling code
by erasing the soft-float target feature if the rest of the front
end added it because of defaults or the soft float option.

Add some testing for some of the targets that implement this hack.

llvm-svn: 236179
2015-04-29 23:32:17 +00:00
Richard Smith 3d5925b0e4 Fix unused variable warning.
llvm-svn: 236178
2015-04-29 23:26:13 +00:00
Zachary Turner b74e279fe1 Fix build broken by r236174.
Apparently va_list is literally a char* on Windows.

llvm-svn: 236177
2015-04-29 23:24:12 +00:00
Richard Smith 20e883e59b [modules] Stop trying to fake up a linear MacroDirective history.
Modules builds fundamentally have a non-linear macro history. In the interest
of better source fidelity, represent the macro definition information
faithfully: we have a linear macro directive history within each module, and at
any point we have a unique "latest" local macro directive and a collection of
visible imported directives. This also removes the attendent complexity of
attempting to create a correct MacroDirective history (which we got wrong
in the general case).

No functionality change intended.

llvm-svn: 236176
2015-04-29 23:20:19 +00:00
David Blaikie bf0a42ac09 [opaque pointer type] Store the value type of an alloca
llvm-svn: 236175
2015-04-29 23:00:35 +00:00
Zachary Turner c1592658d5 Introduce a NullLog class, which ignores all messages.
The purpose of this class is so that GetLogIfAllCategoriesSet
can always return an instance of some class, whether it be a real
logging class or a "null" class, which ignores messages.  Code
that is littered with if statements that only log if the pointer
is non-null can get very unwieldy very quickly, so this should
help code readability in such circumstances.

Since I'm in this code anyway, I'm also deleting the
PrintfWithFlags methods, as well as all the flags, since they
appear to be dead code that have been superceded by newer
mechanisms and all the flags are simply ignored.

llvm-svn: 236174
2015-04-29 22:55:28 +00:00
Rick Foos 2688a49981 XFAIL Hexagon until more codegen in place.
Summary:
Hexagon is being updated, but there is not enough to pass these tests.
These sections are now on top of Colin's list.

Test Plan: Ran changes on hexagon-build-03.

Reviewers: colinl, rfoos

Reviewed By: rfoos

Subscribers: cfe-commits

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

llvm-svn: 236173
2015-04-29 22:54:40 +00:00
Reid Kleckner bcda1cd45a [WinEH] Start EH preparation for 32-bit x86, it uses no arguments
32-bit x86 MSVC-style exceptions are functionaly similar to 64-bit, but
they take no arguments. Instead, they implicitly use the value of EBP
passed in by the caller as a pointer to the parent's frame. In LLVM, we
can represent this as llvm.frameaddress(1), and feed that into all of
our calls to llvm.framerecover.

The next steps are:
- Add an alloca to the fs:00 linked list of handlers
- Add something like llvm.sjlj.lsda or generalize it to store in the
  alloca
- Move state number calculation to WinEHPrepare, arrange for
  FunctionLoweringInfo to call it
- Use the state numbers to insert explicit loads and stores in the IR

llvm-svn: 236172
2015-04-29 22:49:54 +00:00
Sanjay Patel 04b0e92766 generalize binop reassociation; NFC
Move the fold introduced in r236031:
http://reviews.llvm.org/rL236031

to its own helper function, so we can use it for other binops.

This is a preliminary step before partially solving:
https://llvm.org/bugs/show_bug.cgi?id=21768
https://llvm.org/bugs/show_bug.cgi?id=23116

llvm-svn: 236171
2015-04-29 22:30:02 +00:00
Jason Molenda 3114703b5c Don't force a vendor check in ProcessMachCore::CanDebug() -- if this
is a Mach-O file and it is a Mach-O core file, activate the 
ProcessMachCore plugin.
<rdar://problem/20739989> 

llvm-svn: 236170
2015-04-29 22:17:45 +00:00
Jason Molenda 0e78cab17b Update to build sysv-arm/sysv-arm64/sblanguageinfo/registercontextlinux_arm64.
llvm-svn: 236169
2015-04-29 22:16:19 +00:00
Justin Bogner 2d2faae647 profile: Use unique directory for tests that write default profile file
Fix a couple of new tests that were reverted because they were causing
intermittent test failures since they were writing the same default
"default.profraw" file. Fixed by creating a unique directory and
running tests in that directory.

Patch by Teresa Johnson. Thanks!

llvm-svn: 236168
2015-04-29 21:56:35 +00:00
Reid Kleckner be9843ce54 Revert r236128, LLVM isn't falling back in the right way
llvm-svn: 236167
2015-04-29 21:55:21 +00:00
Pat Gavlin 022c5acad8 Run StatepointLowering.{cpp,h} through clang-format.
llvm-svn: 236166
2015-04-29 21:52:45 +00:00
Alexey Samsonov 3965cdeb39 [UBSan] Disable vptr.cpp on Darwin again.
llvm-svn: 236165
2015-04-29 21:51:23 +00:00
Chris Bieneman 3e3ef2f28c [NFC] Updating FileCheck to reduce the std::vector interface used via cl::list.
llvm-svn: 236164
2015-04-29 21:45:24 +00:00
Chris Bieneman 664294cf37 [NFC] Converting to range-based for.
llvm-svn: 236163
2015-04-29 21:45:22 +00:00
David Blaikie 881b23402e [opaque pointer type] update for LLVM API change
llvm-svn: 236161
2015-04-29 21:22:47 +00:00
David Blaikie f64246be72 [opaque pointer type] Pass GlobalAlias the actual pointer type rather than decomposing it into pointee type + address space
Many of the callers already have the pointer type anyway, and for the
couple of callers that don't it's pretty easy to call PointerType::get
on the pointee type and address space.

This avoids LLParser from using PointerType::getElementType when parsing
GlobalAliases from IR.

llvm-svn: 236160
2015-04-29 21:22:39 +00:00
Nico Weber 6e0ebaea1f Revert r236060, it caused PR23375.
llvm-svn: 236159
2015-04-29 21:16:40 +00:00
Rafael Espindola 59f0e3182d Inline FragmentWriter into the only user.
llvm-svn: 236158
2015-04-29 21:13:30 +00:00
Rafael Espindola 91fd2778b0 Write the symbol table directly to the output file.
There is no need to first accumulate it in fragments.

llvm-svn: 236157
2015-04-29 21:09:32 +00:00
Sanjay Patel caf5180ff7 tidy up; NFC
llvm-svn: 236156
2015-04-29 21:01:41 +00:00
Richard Smith 0ae6b2b839 Stop assuming a 64-bit target here.
llvm-svn: 236155
2015-04-29 20:49:22 +00:00
Ed Schouten 8fd97a3ade Make the .eh_frame_hdr code work on FreeBSD as well.
We currently only include <link.h> on CloudABI and Linux. We can enable
it on FreeBSD as well, as it also supports the dl_iterate_phdr()
function that's provided by <link.h>.

FreeBSD, however, does not provide the ElfW() macro. Instead, the
host-specific ELF datastructures are named just Elf_XXX in addition to
the host-independent Elf32_XXX and Elf64_XXX types.

Differential Revision:	http://reviews.llvm.org/D8169
Approved by:	emaste

llvm-svn: 236154
2015-04-29 20:43:44 +00:00
Rafael Espindola 8c7829b82f Use pwrite to write the number of sections.
This avoids having to compute the number upfront, which will be used in the
next patch.

llvm-svn: 236153
2015-04-29 20:39:37 +00:00
Alexey Samsonov 299c21474c [UBSan] Various improvements to vptr.cpp test case
* Remove __ubsan_default_options, so that test would work on Darwin
* Fix unintentional undefined behavior in the code (missing return)
* Build the test with -fno-sanitize-recover to distinguish expected
  failures and expected passes by return code.

llvm-svn: 236152
2015-04-29 20:39:12 +00:00
Alexey Samsonov ff46ebe5a4 [UBSan] Add a testcase for __ubsan_default_options() function.
llvm-svn: 236151
2015-04-29 20:39:10 +00:00
Sanjay Patel ee6678119d too much space again; NFC
llvm-svn: 236150
2015-04-29 20:38:02 +00:00
Davide Italiano f14fbcbf91 [GNU] Remove -x/-X from the list of options to be implemented.
llvm-svn: 236149
2015-04-29 20:35:58 +00:00
Rafael Espindola 88abc39d70 Write the string table directly to the output file.
There is no need to accumulate it in fragments first.

llvm-svn: 236148
2015-04-29 20:34:31 +00:00
Sanjay Patel 435efaadff too much space; NFC
llvm-svn: 236147
2015-04-29 20:32:57 +00:00
Douglas Katzman 9160e78ac8 [Sparc] Really add sparcel architecture support.
Mostly copy-and-paste from Sparc v8 architecture.

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

llvm-svn: 236146
2015-04-29 20:30:57 +00:00
Rafael Espindola 88d1f632cf Write the section header string table directly to the output stream.
Instead of accumulating the content in a fragment first, just write it
to the output stream.

Also put it first in the section table, so that we never have to worry
about its index being >= SHN_LORESERVE.

llvm-svn: 236145
2015-04-29 20:25:24 +00:00
Jonathan Roelofs cf1ba1d8c0 Clean up docs references to './configure' in preparation for deprecating in-source builds
http://reviews.llvm.org/D8787

llvm-svn: 236144
2015-04-29 20:06:41 +00:00
Manman Ren 0e20822887 [AArch64] Refactor out codes that depend on specific CS save sequence.
No functionality change.

llvm-svn: 236143
2015-04-29 20:03:38 +00:00
Richard Smith 419bd09415 PR23373: A defaulted union copy constructor that is not trivial must still be
emitted as a memcpy.

llvm-svn: 236142
2015-04-29 19:26:57 +00:00
Rafael Espindola ae7e4995ca Avoid a few const_cast.
llvm-svn: 236141
2015-04-29 19:20:10 +00:00
Tim Northover 5211715360 ARM: mark branch-like instructions with correct flags.
There's probably no way to test BXJ, but if the compiler ever did emit it
during CodeGen it would have to be a block terminator so "isBranch" is
appropriate.

BLX is more tricky. Clearly a call, but it affects surprisingly little.

rdar://18719544

llvm-svn: 236140
2015-04-29 19:16:38 +00:00
Douglas Katzman e0ff282d18 New architecture name - 'sparcel' for Sparc little-endian.
Differential Revision: http://reviews.llvm.org/D9263

llvm-svn: 236139
2015-04-29 19:15:08 +00:00
Chaoren Lin 4dc65069a1 lldb-gdbserver should not use unnamed pipes on Windows.
llvm-svn: 236138
2015-04-29 19:01:43 +00:00
Douglas Katzman 9cb88b73c6 Make Sparc assembler accept parenthesized constant expressions.
Differential Revision: http://reviews.llvm.org/D9087

llvm-svn: 236137
2015-04-29 18:48:29 +00:00
Chaoren Lin 66f2e12f7a Expose Close{Read/Write}FileDescriptor for pipes.
llvm-svn: 236136
2015-04-29 18:25:18 +00:00
Ahmed Bougacha 69b5f93cb5 Re-XFAIL UBSan vptr testcase on darwin.
Partial revert of r235961; the test still fails on Green Dragon bots.

llvm-svn: 236135
2015-04-29 17:49:05 +00:00
Richard Smith 6282b215cc Revert r236063 due to regression with -fdelayed-template-parsing.
llvm-svn: 236134
2015-04-29 17:48:08 +00:00
Chaoren Lin a52f48412d Add file descriptor constructor for PipePosix.
llvm-svn: 236133
2015-04-29 17:36:58 +00:00