Elena Demikhovsky [Thu, 30 Apr 2015 08:38:48 +0000 (08:38 +0000)]
Masked gather and scatter - added DAGCombine visitors
and AVX-512 instruction selection patterns.
All other patches, including tests will follow.
http://reviews.llvm.org/D7665
llvm-svn: 236211
Alexey Bataev [Thu, 30 Apr 2015 08:35:10 +0000 (08:35 +0000)]
[OPENMP] Mark test as not compatible with MS Windows.
llvm-svn: 236210
Simon Pilgrim [Thu, 30 Apr 2015 08:23:16 +0000 (08:23 +0000)]
[SSE] Fix for MUL v16i8 on pre-SSE41 targets (PR23369).
Sign extension of i8 to i16 was placing the unpacked bytes in the lower byte instead of the upper byte.
llvm-svn: 236209
Ilia K [Thu, 30 Apr 2015 07:14:24 +0000 (07:14 +0000)]
Add -data-info-line command (MI)
Summary: Add -data-info-line command + test
Test Plan: ./dotest.py -v --executable $BUILDDIR/bin/lldb tools/lldb-mi/
Reviewers: abidh
Reviewed By: abidh
Subscribers: lldb-commits, abidh
Differential Revision: http://reviews.llvm.org/D9276
llvm-svn: 236208
Alexey Bataev [Thu, 30 Apr 2015 06:51:57 +0000 (06:51 +0000)]
[OPENMP] Codegen for 'private' clause in 'task' directive.
For tasks codegen for private/firstprivate variables are different rather than for other directives.
1. Build an internal structure of privates for each private variable:
struct .kmp_privates_t. {
Ty1 var1;
...
Tyn varn;
};
2. Add a new field to kmp_task_t type with list of privates.
struct kmp_task_t {
void * shareds;
kmp_routine_entry_t routine;
kmp_int32 part_id;
kmp_routine_entry_t destructors;
.kmp_privates_t. privates;
};
3. Create a function with destructors calls for all privates after end of task region.
kmp_int32 .omp_task_destructor.(kmp_int32 gtid, kmp_task_t *tt) {
~Destructor(&tt->privates.var1);
...
~Destructor(&tt->privates.varn);
return 0;
}
4. Perform default initialization of all private fields (no initialization for POD data, default constructor calls for classes) + provide address of a destructor function after kmpc_omp_task_alloc() and before kmpc_omp_task() calls.
kmp_task_t *new_task = __kmpc_omp_task_alloc(ident_t *, kmp_int32 gtid, kmp_int32 flags, size_t sizeof_kmp_task_t, size_t sizeof_shareds, kmp_routine_entry_t *task_entry);
DefaultConstructor(new_task->privates.var1);
new_task->shareds.var1_ref = &new_task->privates.var1;
...
DefaultConstructor(new_task->privates.varn);
new_task->shareds.varn_ref = &new_task->privates.varn;
new_task->destructors = .omp_task_destructor.;
kmp_int32 __kmpc_omp_task(ident_t *, kmp_int32 gtid, kmp_task_t *new_task)
Differential Revision: http://reviews.llvm.org/D9322
llvm-svn: 236207
Craig Topper [Thu, 30 Apr 2015 05:54:22 +0000 (05:54 +0000)]
[TableGen] Cleanup formatting by moving operators from beginning of line to end of previous line. NFC
llvm-svn: 236206
Craig Topper [Thu, 30 Apr 2015 05:54:20 +0000 (05:54 +0000)]
[TableGen] Used range-based for loop. NFC.
llvm-svn: 236205
Craig Topper [Thu, 30 Apr 2015 05:12:52 +0000 (05:12 +0000)]
[TableGen] Merge a variable assignment and a return to drop curly braces. Fold an assignment into an if. Use auto on the result of a couple dyn_casts. NFC
llvm-svn: 236204
Sanjoy Das [Thu, 30 Apr 2015 04:56:04 +0000 (04:56 +0000)]
[InstCombine] Add new rule for MIN(MAX(~A, ~B), ~C) et. al.
Summary:
Optimizing these well are especially interesting for IRCE since it
"clamps" values by generating this sort of pattern through SCEV
expressions.
Depends on D9352.
Reviewers: majnemer
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D9353
llvm-svn: 236203
Sanjoy Das [Thu, 30 Apr 2015 04:56:00 +0000 (04:56 +0000)]
[InstCombine] Add a new formula for SMIN.
Summary:
After this change `MatchSelectPattern` recognizes the following form
of SMIN:
Y >s C ? ~Y : ~C == ~Y <s ~C ? ~Y : ~C = SMIN(~Y, ~C)
Reviewers: majnemer
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D9352
llvm-svn: 236202
Alexey Bataev [Thu, 30 Apr 2015 04:23:23 +0000 (04:23 +0000)]
[OPENMP] Allow to use global variables as lcv in loop-based directives.
For proper codegen we need to capture variable in the OpenMP region. In loop-based directives loop control variables are private by default and they must be captured in this region. There was a problem with capturing of globals, used as lcv, as they was not marked as private by default.
Differential Revision: http://reviews.llvm.org/D9336
llvm-svn: 236201
Filipe Cabecinhas [Thu, 30 Apr 2015 04:09:41 +0000 (04:09 +0000)]
Don't overflow GCTable
Summary: Bug found with AFL fuzz.
Reviewers: rafael, dexonsmith
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D9361
llvm-svn: 236200
Owen Anderson [Thu, 30 Apr 2015 04:06:32 +0000 (04:06 +0000)]
Semantically revert r236031, which is not a good idea for in-order targets.
At the least it should be guarded by some kind of target hook.
It also introduced catastrophic compile time and code quality
regressions on some out of tree targets (test case still being
reduced/sanitized).
Sanjay agreed with reverting this patch until these issues can be
resolved.
llvm-svn: 236199
Alexey Bataev [Thu, 30 Apr 2015 03:47:32 +0000 (03:47 +0000)]
[OPENMP] Fixed codegen for 'copyprivate' clause.
Fixed initialization of 'single' region completion + changed type of the third argument of __kmpc_copyprivate() runtime function to size_t.
llvm-svn: 236198
Richard Smith [Thu, 30 Apr 2015 02:16:23 +0000 (02:16 +0000)]
Remove dead code: a MacroDirective can't be imported or ambiguous any more.
llvm-svn: 236197
Hans Wennborg [Thu, 30 Apr 2015 01:59:04 +0000 (01:59 +0000)]
XFAIL test/CodeGen/Generic/MachineBranchProb.ll on Hexagon (PR23377)
llvm-svn: 236196
Alexey Samsonov [Thu, 30 Apr 2015 01:21:57 +0000 (01:21 +0000)]
[UBSan] Make stacktrace-matching CHECK-lines in tests Linux-specific.
Darwin doesn't yet allow to print stack trace, as it lacks the slow
unwinder. This is one more attempt to fix vptr.cpp on Mac OS X.
llvm-svn: 236195
Richard Smith [Thu, 30 Apr 2015 01:15:19 +0000 (01:15 +0000)]
Remove XFAIL now that this test passes (fixed by r236184).
llvm-svn: 236194
Filipe Cabecinhas [Thu, 30 Apr 2015 01:13:31 +0000 (01:13 +0000)]
Make sure Op->getType() is a PointerType before we cast<> it.
Bug found with AFL fuzz.
llvm-svn: 236193
Hans Wennborg [Thu, 30 Apr 2015 00:57:37 +0000 (00:57 +0000)]
Switch lowering: use profile info to build weight-balanced binary search trees
This will cause hot nodes to appear closer to the root.
The literature says building the tree like this makes it a near-optimal (in
terms of search time given key frequencies) binary search tree. In LLVM's case,
we can do up to 3 comparisons in each leaf node, so it might be better to opt
for lower tree height in some cases; that's something to look into in the
future.
Differential Revision: http://reviews.llvm.org/D9318
llvm-svn: 236192
Richard Smith [Thu, 30 Apr 2015 00:57:08 +0000 (00:57 +0000)]
Fix use of uninitialized variable, found by ubsan selfhost.
llvm-svn: 236191
Filipe Cabecinhas [Thu, 30 Apr 2015 00:52:42 +0000 (00:52 +0000)]
Make sure we don't resize(0) when we get a fwdref with Idx == UINT_MAX
Make it an error instead.
Bug found with AFL fuzz.
llvm-svn: 236190
Rafael Espindola [Thu, 30 Apr 2015 00:45:46 +0000 (00:45 +0000)]
Store relocations in a map from MCSectionELF.
Saves finding the MCSectionData just to do a map lookup.
llvm-svn: 236189
Sean Callanan [Thu, 30 Apr 2015 00:44:21 +0000 (00:44 +0000)]
Use a more reliable method to determine whether
a FileID corresponds to a real file or to a
memory buffer. The old method didn't work when
Clang was built Release, which meant it wasn't
a very good method at all.
llvm-svn: 236188
Rafael Espindola [Thu, 30 Apr 2015 00:30:40 +0000 (00:30 +0000)]
Write relocations directly to the output stream. NFC.
llvm-svn: 236187
Ahmed Bougacha [Thu, 30 Apr 2015 00:07:34 +0000 (00:07 +0000)]
Flip r236172 testcase RUN option ordering for BSD sed(1). NFC.
llvm-svn: 236186
Chaoren Lin [Wed, 29 Apr 2015 23:59:22 +0000 (23:59 +0000)]
Add CMAKE_EXECUTABLE_SUFFIX to build with Android toolchain on Windows.
Reviewers: vharron, zturner, flackr
Subscribers: tberghammer, lldb-commits
Differential Revision: http://reviews.llvm.org/D9177
llvm-svn: 236185
NAKAMURA Takumi [Wed, 29 Apr 2015 23:55:46 +0000 (23:55 +0000)]
Update clang/test/CodeGenCXX/copy-constructor-synthesis-2.cpp to pass for targeting i686.
r236155 missed the suffix in "@llvm.memcpy.p0i8.p0i8.i32".
llvm-svn: 236184
Pete Cooper [Wed, 29 Apr 2015 23:51:33 +0000 (23:51 +0000)]
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
Richard Smith [Wed, 29 Apr 2015 23:46:48 +0000 (23:46 +0000)]
Fix build after Clang API change in r236176.
llvm-svn: 236182
Richard Smith [Wed, 29 Apr 2015 23:40:48 +0000 (23:40 +0000)]
Add an assert to get information on buildbot failure.
llvm-svn: 236181
Jonathan Roelofs [Wed, 29 Apr 2015 23:33:32 +0000 (23:33 +0000)]
Fix doxygen comment typo. NFC
llvm-svn: 236180
Eric Christopher [Wed, 29 Apr 2015 23:32:17 +0000 (23:32 +0000)]
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
Richard Smith [Wed, 29 Apr 2015 23:26:13 +0000 (23:26 +0000)]
Fix unused variable warning.
llvm-svn: 236178
Zachary Turner [Wed, 29 Apr 2015 23:24:12 +0000 (23:24 +0000)]
Fix build broken by r236174.
Apparently va_list is literally a char* on Windows.
llvm-svn: 236177
Richard Smith [Wed, 29 Apr 2015 23:20:19 +0000 (23:20 +0000)]
[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
David Blaikie [Wed, 29 Apr 2015 23:00:35 +0000 (23:00 +0000)]
[opaque pointer type] Store the value type of an alloca
llvm-svn: 236175
Zachary Turner [Wed, 29 Apr 2015 22:55:28 +0000 (22:55 +0000)]
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
Rick Foos [Wed, 29 Apr 2015 22:54:40 +0000 (22:54 +0000)]
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
Reid Kleckner [Wed, 29 Apr 2015 22:49:54 +0000 (22:49 +0000)]
[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
Sanjay Patel [Wed, 29 Apr 2015 22:30:02 +0000 (22:30 +0000)]
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
Jason Molenda [Wed, 29 Apr 2015 22:17:45 +0000 (22:17 +0000)]
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
Jason Molenda [Wed, 29 Apr 2015 22:16:19 +0000 (22:16 +0000)]
Update to build sysv-arm/sysv-arm64/sblanguageinfo/registercontextlinux_arm64.
llvm-svn: 236169
Justin Bogner [Wed, 29 Apr 2015 21:56:35 +0000 (21:56 +0000)]
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
Reid Kleckner [Wed, 29 Apr 2015 21:55:21 +0000 (21:55 +0000)]
Revert r236128, LLVM isn't falling back in the right way
llvm-svn: 236167
Pat Gavlin [Wed, 29 Apr 2015 21:52:45 +0000 (21:52 +0000)]
Run StatepointLowering.{cpp,h} through clang-format.
llvm-svn: 236166
Alexey Samsonov [Wed, 29 Apr 2015 21:51:23 +0000 (21:51 +0000)]
[UBSan] Disable vptr.cpp on Darwin again.
llvm-svn: 236165
Chris Bieneman [Wed, 29 Apr 2015 21:45:24 +0000 (21:45 +0000)]
[NFC] Updating FileCheck to reduce the std::vector interface used via cl::list.
llvm-svn: 236164
Chris Bieneman [Wed, 29 Apr 2015 21:45:22 +0000 (21:45 +0000)]
[NFC] Converting to range-based for.
llvm-svn: 236163
David Blaikie [Wed, 29 Apr 2015 21:22:47 +0000 (21:22 +0000)]
[opaque pointer type] update for LLVM API change
llvm-svn: 236161
David Blaikie [Wed, 29 Apr 2015 21:22:39 +0000 (21:22 +0000)]
[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
Nico Weber [Wed, 29 Apr 2015 21:16:40 +0000 (21:16 +0000)]
Revert r236060, it caused PR23375.
llvm-svn: 236159
Rafael Espindola [Wed, 29 Apr 2015 21:13:30 +0000 (21:13 +0000)]
Inline FragmentWriter into the only user.
llvm-svn: 236158
Rafael Espindola [Wed, 29 Apr 2015 21:09:32 +0000 (21:09 +0000)]
Write the symbol table directly to the output file.
There is no need to first accumulate it in fragments.
llvm-svn: 236157
Sanjay Patel [Wed, 29 Apr 2015 21:01:41 +0000 (21:01 +0000)]
tidy up; NFC
llvm-svn: 236156
Richard Smith [Wed, 29 Apr 2015 20:49:22 +0000 (20:49 +0000)]
Stop assuming a 64-bit target here.
llvm-svn: 236155
Ed Schouten [Wed, 29 Apr 2015 20:43:44 +0000 (20:43 +0000)]
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
Rafael Espindola [Wed, 29 Apr 2015 20:39:37 +0000 (20:39 +0000)]
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
Alexey Samsonov [Wed, 29 Apr 2015 20:39:12 +0000 (20:39 +0000)]
[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
Alexey Samsonov [Wed, 29 Apr 2015 20:39:10 +0000 (20:39 +0000)]
[UBSan] Add a testcase for __ubsan_default_options() function.
llvm-svn: 236151
Sanjay Patel [Wed, 29 Apr 2015 20:38:02 +0000 (20:38 +0000)]
too much space again; NFC
llvm-svn: 236150
Davide Italiano [Wed, 29 Apr 2015 20:35:58 +0000 (20:35 +0000)]
[GNU] Remove -x/-X from the list of options to be implemented.
llvm-svn: 236149
Rafael Espindola [Wed, 29 Apr 2015 20:34:31 +0000 (20:34 +0000)]
Write the string table directly to the output file.
There is no need to accumulate it in fragments first.
llvm-svn: 236148
Sanjay Patel [Wed, 29 Apr 2015 20:32:57 +0000 (20:32 +0000)]
too much space; NFC
llvm-svn: 236147
Douglas Katzman [Wed, 29 Apr 2015 20:30:57 +0000 (20:30 +0000)]
[Sparc] Really add sparcel architecture support.
Mostly copy-and-paste from Sparc v8 architecture.
Differential Revision: http://reviews.llvm.org/D8741
llvm-svn: 236146
Rafael Espindola [Wed, 29 Apr 2015 20:25:24 +0000 (20:25 +0000)]
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
Jonathan Roelofs [Wed, 29 Apr 2015 20:06:41 +0000 (20:06 +0000)]
Clean up docs references to './configure' in preparation for deprecating in-source builds
http://reviews.llvm.org/D8787
llvm-svn: 236144
Manman Ren [Wed, 29 Apr 2015 20:03:38 +0000 (20:03 +0000)]
[AArch64] Refactor out codes that depend on specific CS save sequence.
No functionality change.
llvm-svn: 236143
Richard Smith [Wed, 29 Apr 2015 19:26:57 +0000 (19:26 +0000)]
PR23373: A defaulted union copy constructor that is not trivial must still be
emitted as a memcpy.
llvm-svn: 236142
Rafael Espindola [Wed, 29 Apr 2015 19:20:10 +0000 (19:20 +0000)]
Avoid a few const_cast.
llvm-svn: 236141
Tim Northover [Wed, 29 Apr 2015 19:16:38 +0000 (19:16 +0000)]
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
Douglas Katzman [Wed, 29 Apr 2015 19:15:08 +0000 (19:15 +0000)]
New architecture name - 'sparcel' for Sparc little-endian.
Differential Revision: http://reviews.llvm.org/D9263
llvm-svn: 236139
Chaoren Lin [Wed, 29 Apr 2015 19:01:43 +0000 (19:01 +0000)]
lldb-gdbserver should not use unnamed pipes on Windows.
llvm-svn: 236138
Douglas Katzman [Wed, 29 Apr 2015 18:48:29 +0000 (18:48 +0000)]
Make Sparc assembler accept parenthesized constant expressions.
Differential Revision: http://reviews.llvm.org/D9087
llvm-svn: 236137
Chaoren Lin [Wed, 29 Apr 2015 18:25:18 +0000 (18:25 +0000)]
Expose Close{Read/Write}FileDescriptor for pipes.
llvm-svn: 236136
Ahmed Bougacha [Wed, 29 Apr 2015 17:49:05 +0000 (17:49 +0000)]
Re-XFAIL UBSan vptr testcase on darwin.
Partial revert of r235961; the test still fails on Green Dragon bots.
llvm-svn: 236135
Richard Smith [Wed, 29 Apr 2015 17:48:08 +0000 (17:48 +0000)]
Revert r236063 due to regression with -fdelayed-template-parsing.
llvm-svn: 236134
Chaoren Lin [Wed, 29 Apr 2015 17:36:58 +0000 (17:36 +0000)]
Add file descriptor constructor for PipePosix.
llvm-svn: 236133
Chaoren Lin [Wed, 29 Apr 2015 17:24:48 +0000 (17:24 +0000)]
Remove trap code from disassembly.
Summary:
NativeProcessProtocol uses ReadMemory internally for setting/checking
breakpoints but also for generic memory reads (Handle_m), this change adds a
ReadMemoryWithoutTrap for that purpose. Also fixes a bunch of misuses of addr_t
as size/length.
Test Plan: `disassemble` no longer shows the trap code.
Reviewers: jingham, vharron, clayborg
Reviewed By: clayborg
Subscribers: lldb-commits
Differential Revision: http://reviews.llvm.org/D9330
llvm-svn: 236132
Zoran Jovanovic [Wed, 29 Apr 2015 17:23:22 +0000 (17:23 +0000)]
[mips][microMIPSr6] Implement MUL, MUH, MULU and MUHU instructions
Differential Revision: http://reviews.llvm.org/D8894
llvm-svn: 236131
Dmitry Vyukov [Wed, 29 Apr 2015 17:22:43 +0000 (17:22 +0000)]
tsan: add another test for setuid
llvm-svn: 236130
Andrew Kaylor [Wed, 29 Apr 2015 17:21:26 +0000 (17:21 +0000)]
[WinEH] Fix minor bug in begincatch block splitting
llvm-svn: 236129
Reid Kleckner [Wed, 29 Apr 2015 17:17:17 +0000 (17:17 +0000)]
Re-land r236052, the linker errors were fixed by LLVM r236123
Basic __finally blocks don't cause linker errors anymore (although they
are miscompiled).
llvm-svn: 236128
Duncan P. N. Exon Smith [Wed, 29 Apr 2015 17:02:14 +0000 (17:02 +0000)]
Update polly for LLVM rename of debug info metadata with DI* prefix
Ran the same rename-md-di-prefix.sh script attached to PR23080 as in
LLVM r236120 and CFE r236121.
llvm-svn: 236127
Reid Kleckner [Wed, 29 Apr 2015 16:54:11 +0000 (16:54 +0000)]
Disable failing TestDevNull test on Windows
llvm-svn: 236126
Adrian Prantl [Wed, 29 Apr 2015 16:52:31 +0000 (16:52 +0000)]
Debug Info: Represent local anonymous unions as anonymous unions
and as artificial local variables in the debug info.
This is a follow-up to r236059. We can't get rid of the local variables
entirely because the gdb buildbot depends on them, but we can mark them
as artificial while still emitting the correct debug info. As I learned
from review comments other compilers also follow this model.
A paired commit in LLVM temporarily relaxes the debug info verifier to
not check the integrity of DW_OP_bit_pieces of artificial variables.
rdar://problem/
20730771
llvm-svn: 236125
Adrian Prantl [Wed, 29 Apr 2015 16:52:17 +0000 (16:52 +0000)]
Temporarily relax a check in the debug info verifier.
The clang frontend helps out GDB by emitting the members of local anonymous
unions as artificial local variables with shared storage. When SROA splits
the storage for artificial local variables that are smaller than the entire
union, the overhang piece will be outside of the allotted space for the
variable and this check fails.
rdar://problem/
20730771
llvm-svn: 236124
Reid Kleckner [Wed, 29 Apr 2015 16:46:01 +0000 (16:46 +0000)]
[X86] Avoid mangling frameescape labels
x86 Windows uses the '_' prefix for all global symbols, and this was
mistakenly being applied to frameescape labels, which are not externally
visible global symbols. They use the private global prefix 'L'.
The *right* way to fix this is probably to stop masquerading this label
as an ExternalSymbol and create a new SDNode type. These labels are not
"external", and we know they will be resolved by assembly time. Having a
custom SDNode type would allow us to do better X86 address mode
matching, so it's probably worth doing eventually.
llvm-svn: 236123
Andrey Churbanov [Wed, 29 Apr 2015 16:42:24 +0000 (16:42 +0000)]
These are the actual changes in the runtime to issue OMPT-related functions. All of them are surrounded by #if OMPT_SUPPORT and can be disabled (which is the default).
llvm-svn: 236122
Duncan P. N. Exon Smith [Wed, 29 Apr 2015 16:40:08 +0000 (16:40 +0000)]
DebugInfo: Metadata constructs now start with DI*
LLVM r236120 renamed debug info IR constructs to use a `DI` prefix, now
that the `DIDescriptor` hierarchy has been gone for about a week. This
commit was generated using the rename-md-di-nodes.sh upgrade script
attached to PR23080, followed by running clang-format-diff.py on the
`lib/` portion of the patch.
llvm-svn: 236121
Duncan P. N. Exon Smith [Wed, 29 Apr 2015 16:38:44 +0000 (16:38 +0000)]
IR: Give 'DI' prefix to debug info metadata
Finish off PR23080 by renaming the debug info IR constructs from `MD*`
to `DI*`. The last of the `DIDescriptor` classes were deleted in
r235356, and the last of the related typedefs removed in r235413, so
this has all baked for about a week.
Note: If you have out-of-tree code (like a frontend), I recommend that
you get everything compiling and tests passing with the *previous*
commit before updating to this one. It'll be easier to keep track of
what code is using the `DIDescriptor` hierarchy and what you've already
updated, and I think you're extremely unlikely to insert bugs. YMMV of
course.
Back to *this* commit: I did this using the rename-md-di-nodes.sh
upgrade script I've attached to PR23080 (both code and testcases) and
filtered through clang-format-diff.py. I edited the tests for
test/Assembler/invalid-generic-debug-node-*.ll by hand since the columns
were off-by-three. It should work on your out-of-tree testcases (and
code, if you've followed the advice in the previous paragraph).
Some of the tests are in badly named files now (e.g.,
test/Assembler/invalid-mdcompositetype-missing-tag.ll should be
'dicompositetype'); I'll come back and move the files in a follow-up
commit.
llvm-svn: 236120
Jan Vesely [Wed, 29 Apr 2015 16:30:46 +0000 (16:30 +0000)]
CodeGen: Default overflow operations to expand so we don't have to assume targets are lying
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
Reviewed-by: ab
Differential Revision: http://reviews.llvm.org/D9265
llvm-svn: 236119
Zoran Jovanovic [Wed, 29 Apr 2015 16:22:46 +0000 (16:22 +0000)]
[mips][microMIPSr6] Implement SUB and SUBU instructions
Differential Revision: http://reviews.llvm.org/D8764
llvm-svn: 236118
Andrey Churbanov [Wed, 29 Apr 2015 16:22:07 +0000 (16:22 +0000)]
This patch contains the new files for OMPT and the needed changes to the build infrastructure
llvm-svn: 236117
Eric Fiselier [Wed, 29 Apr 2015 15:53:03 +0000 (15:53 +0000)]
Fix syntax error in CMake created when a variable is not defined.
llvm-svn: 236115
Andrey Churbanov [Wed, 29 Apr 2015 15:52:19 +0000 (15:52 +0000)]
This is a preparation patch to get information about the actual release status from nested locks for OMPT.
llvm-svn: 236114
Tom Stellard [Wed, 29 Apr 2015 15:37:06 +0000 (15:37 +0000)]
Allow compilation depending to the LLVM version
It allows to keep temporary compatibilty with older version.
For exemple, this can be use when change are not to large.
Patch by: EdB
llvm-svn: 236113
Zoran Jovanovic [Wed, 29 Apr 2015 15:11:07 +0000 (15:11 +0000)]
[mips][microMIPSr6] Implement ADD, ADDU and ADDIU instructions
Differential Revision: http://reviews.llvm.org/D8704
llvm-svn: 236111
Adrian Prantl [Wed, 29 Apr 2015 15:05:50 +0000 (15:05 +0000)]
Revert "Debug Info: Represent local anonymous unions as anonymous unions"
This reverts commit r236059 as it breaks the gdb buildbot.
llvm-svn: 236110
James Y Knight [Wed, 29 Apr 2015 14:54:44 +0000 (14:54 +0000)]
Sparc: Prefer reg+reg address encoding when only one register used.
Reg+%g0 is preferred to Reg+imm0 by the manual, and is what GCC produces.
Futhermore, reg+imm is invalid for the (not yet supported) "alternate
address space" instructions.
Differential Revision: http://reviews.llvm.org/D8753
llvm-svn: 236107