Rafael Espindola [Thu, 21 May 2015 19:54:44 +0000 (19:54 +0000)]
writeSymbolTable now only needs a MCContext.
It used to use an MCAssembler just to record the alignment of the sections.
llvm-svn: 237944
Rafael Espindola [Thu, 21 May 2015 19:46:39 +0000 (19:46 +0000)]
Pass a const MCAssembler to writeSectionHeader.
It never creates sections, so it can use Asm.getSectionData instead of
Asm.getOrCreateSectionData.
llvm-svn: 237943
Alex Lorenz [Thu, 21 May 2015 19:45:02 +0000 (19:45 +0000)]
YAML: Null terminate block scalar's value.
The commit null terminates the string value in the `yaml::BlockScalarNode`
class.
This change is motivated by the initial MIR serialization commit (r237708)
that I reverted in r237730 because the LLVM IR source from the block
scalar node wasn't terminated by a null character and thus the buildbots
failed on one testcase sometimes. This change enables me to recommit
the reverted commit.
llvm-svn: 237942
Peter Collingbourne [Thu, 21 May 2015 19:44:44 +0000 (19:44 +0000)]
Revert r237766, "Support: Introduce LLVM_FALLTHROUGH macro."
The value of this macro seems to be very low unless we actually start
using it everywhere, and I don't have immediate plans to make that
happen.
llvm-svn: 237941
Rafael Espindola [Thu, 21 May 2015 19:42:35 +0000 (19:42 +0000)]
Remove unused argument. NFC.
llvm-svn: 237940
Derek Schuff [Thu, 21 May 2015 19:40:19 +0000 (19:40 +0000)]
Fix StreamingMemoryObject to respect known object size.
The existing code for method StreamingMemoryObject.fetchToPos does not respect
the corresonding call to setKnownObjectSize(). As a result, it allows the
StreamingMemoryObject to read bytes past the object size.
This patch provides a test case, and code to fix the problem.
Patch by Karl Schimpf
Differential Revision: http://reviews.llvm.org/D8931
llvm-svn: 237939
Rafael Espindola [Thu, 21 May 2015 19:36:43 +0000 (19:36 +0000)]
Fetch alignment directly out of MCSection. NFC.
llvm-svn: 237938
Nemanja Ivanovic [Thu, 21 May 2015 19:32:49 +0000 (19:32 +0000)]
Add support for VSX scalar single-precision arithmetic in the PPC target
http://reviews.llvm.org/D9891
Following up on the VSX single precision loads and stores added earlier, this
adds support for elementary arithmetic operations on single precision values
in VSX registers. These instructions utilize the new VSSRC register class.
Instructions added:
xsaddsp
xsdivsp
xsmulsp
xsresp
xsrsqrtesp
xssqrtsp
xssubsp
llvm-svn: 237937
Rafael Espindola [Thu, 21 May 2015 19:20:38 +0000 (19:20 +0000)]
Move alignment from MCSectionData to MCSection.
This starts merging MCSection and MCSectionData.
There are a few issues with the current split between MCSection and
MCSectionData.
* It optimizes the the not as important case. We want the production
of .o files to be really fast, but the split puts the information used
for .o emission in a separate data structure.
* The ELF/COFF/MachO hierarchy is not represented in MCSectionData,
leading to some ad-hoc ways to represent the various flags.
* It makes it harder to remember where each item is.
The attached patch starts merging the two by moving the alignment from
MCSectionData to MCSection.
Most of the patch is actually just dropping 'const', since
MCSectionData is mutable, but MCSection was not.
llvm-svn: 237936
Vince Harron [Thu, 21 May 2015 19:09:29 +0000 (19:09 +0000)]
dotest.py - debug feature that helps find dosep races
SUMMARY
dosep.py starts lots and lots of dotest instances.
This option helps you find if two (or more) dotest instances are using
the same directory at the same time.
Enable it to cause test failures and stderr messages if dotest
instances try to run in the same directory simultaneously.
It is disabled by default because it litters the test directories with
".dirlock" files
TEST PLAN
Set lldbtest.debug_confirm_directory_exclusivity = True
run ./dosep.py
Differential Revision: http://reviews.llvm.org/D9868
llvm-svn: 237935
Tobias Grosser [Thu, 21 May 2015 19:02:44 +0000 (19:02 +0000)]
Replace low-level constraint building with higher level functions
Instead of explicitly building constraints and adding them to our maps we
now use functions like map_order_le to add the relevant information to the
maps.
llvm-svn: 237934
Vince Harron [Thu, 21 May 2015 18:55:39 +0000 (18:55 +0000)]
XPASS a bunch of GdbRemote/LldbGdbServer tests
Depends on r237932
"Fixed intermittent failures in TestGdbRemote*/TestLldbGdbServer"
Test Plan:
Ran dosep 100x, no failures in these tests
Differential Revision: http://reviews.llvm.org/D9892
llvm-svn: 237933
Vince Harron [Thu, 21 May 2015 18:54:12 +0000 (18:54 +0000)]
Fixed intermittent failures in TestGdbRemote*/TestLldbGdbServer
test/tools/lldb-server/commandline/Test* were actually executing in
their parent directory. This looks fine at first because they aren't
compiling an inferior executable.
Unfortunately, they still call "make clean" during their cleanup,
which is likely causing all kinds of havok in tests running in the
parent directory
Differential Revision: http://reviews.llvm.org/D9869
llvm-svn: 237932
Vince Harron [Thu, 21 May 2015 18:51:20 +0000 (18:51 +0000)]
Re-enable packet logging for GdbRemote/LldbServer tests
Creates logs in session dir
Differential Revision: http://reviews.llvm.org/D9847
llvm-svn: 237931
Benjamin Kramer [Thu, 21 May 2015 18:32:07 +0000 (18:32 +0000)]
[LoopDistribute] Remove a layer of pointer indirection.
Just store InstPartitions directly into the std::list. No functional change
intended.
llvm-svn: 237930
Douglas Gregor [Thu, 21 May 2015 18:28:18 +0000 (18:28 +0000)]
Itanium mangler: don't trip an assertion when unresolved members have implicit bases.
When we find a member of the current instantation, the base of the
unresolved member expression is implicit; use nullptr for such
bases. This is not a change in behavior: the AST already contains null
in such cases, so non-asserts builds do the right thing already. Fixes
rdar://problem/
21020559.
llvm-svn: 237929
Vince Harron [Thu, 21 May 2015 18:21:07 +0000 (18:21 +0000)]
Fix lldb executable discovery on OS X
It was broken by r237632
Differential Revision: http://reviews.llvm.org/D9846
llvm-svn: 237928
Siva Chandra [Thu, 21 May 2015 18:20:46 +0000 (18:20 +0000)]
[TestChangeValueAPI] Remove expectedFailureGcc decorator.
Test Plan: dotest.py -C <clang|gcc> -p TestChangeValueAPI
Reviewers: vharron
Reviewed By: vharron
Subscribers: lldb-commits
Differential Revision: http://reviews.llvm.org/D9116
llvm-svn: 237927
Vince Harron [Thu, 21 May 2015 18:20:21 +0000 (18:20 +0000)]
dotest.py - log session to a file instead of a StringIO class
That way, if the test gets killed (by a dosep timeout) we get to see the session
trace
Test Plan:
Run dotest.py
Kill it while it's running, check the session dir for Test* files
Differential Revision: http://reviews.llvm.org/D9845
llvm-svn: 237926
Vince Harron [Thu, 21 May 2015 18:18:52 +0000 (18:18 +0000)]
Add logging for XTIMEOUT/UnexpectedSuccess
If an expected timeout test times out, touch
<session-dir>/ExpectedTimeout-<test-name>
If an expected timeout test passes, touch
<session-dir>/UnexpectedCompletion-<test-name>
Differential Revision: http://reviews.llvm.org/D9843
llvm-svn: 237925
Vince Harron [Thu, 21 May 2015 18:15:09 +0000 (18:15 +0000)]
Modify dosep.py to add default session dir parameter
This ensures that all spawned dotest instances store their traces
in the same location.
Test Plan:
run dosep.py with and without a -s option for dotest
cd lldb/test
./dosep.py
./dosep.py -o '-s /tmp/traces'
Differential Revision: http://reviews.llvm.org/D9839
llvm-svn: 237923
Siva Chandra [Thu, 21 May 2015 18:12:19 +0000 (18:12 +0000)]
[TestBuiltinTrap] Change skipIfGcc to expectedFailure for GCC <= 4.6.
Test Plan: dotest.py -C gcc -p TestBuiltinTrap
Reviewers: vharron
Reviewed By: vharron
Subscribers: lldb-commits
Differential Revision: http://reviews.llvm.org/D9117
llvm-svn: 237922
Vince Harron [Thu, 21 May 2015 18:07:16 +0000 (18:07 +0000)]
TestInlineStepping - made XFAIL more specific
Differential Revision: http://reviews.llvm.org/D9828
llvm-svn: 237921
Adrian McCarthy [Thu, 21 May 2015 17:47:58 +0000 (17:47 +0000)]
Update Makefile to reflect that TestNumThreads now uses std::thread instead of pthreads.
llvm-svn: 237919
Sanjay Patel [Thu, 21 May 2015 17:43:26 +0000 (17:43 +0000)]
use range-based for-loops; NFCI
llvm-svn: 237918
Sanjay Patel [Thu, 21 May 2015 17:22:45 +0000 (17:22 +0000)]
use range-based for-loops; NFCI
llvm-svn: 237917
Jonathan Peyton [Thu, 21 May 2015 17:20:01 +0000 (17:20 +0000)]
Fix task team synchronization
The fix simply syncs up the new threads to have the same task_state and
task_team as the old threads. The master thread is skipped,
because it shouldn't at this point have the team's task_team value yet
-- it should still have parent_team's task_team. It gets pointed at
the new team's task_team later, after __kmp_allocate_team returns, and
the master has stored a memo of it's old task_state.
llvm-svn: 237916
Rafael Espindola [Thu, 21 May 2015 17:09:22 +0000 (17:09 +0000)]
Fix warning on builds without asserts.
llvm-svn: 237915
Sanjay Patel [Thu, 21 May 2015 17:04:17 +0000 (17:04 +0000)]
use range-based for-loop
llvm-svn: 237914
Rafael Espindola [Thu, 21 May 2015 17:00:40 +0000 (17:00 +0000)]
Avoid unnecessary section switching. NFC.
llvm-svn: 237913
Rafael Espindola [Thu, 21 May 2015 16:52:32 +0000 (16:52 +0000)]
Remove yet another method of creating begin and end symbol for sections.
I missed this one when first unifying how we handle begin and end symbols.
llvm-svn: 237912
Sanjay Patel [Thu, 21 May 2015 16:42:22 +0000 (16:42 +0000)]
don't repeat function names in comments; NFC
llvm-svn: 237911
Pete Cooper [Thu, 21 May 2015 16:40:18 +0000 (16:40 +0000)]
Size enum so we can store it as 16-bits and avoid casts. NFC
llvm-svn: 237910
Rafael Espindola [Thu, 21 May 2015 16:19:32 +0000 (16:19 +0000)]
Use existing helper for adding a section. NFC.
llvm-svn: 237909
Sanjay Patel [Thu, 21 May 2015 16:00:50 +0000 (16:00 +0000)]
use range-based for-loop; NFCI
llvm-svn: 237908
Robert Flack [Thu, 21 May 2015 15:44:24 +0000 (15:44 +0000)]
Only check for matching arch and UUID when looking for dsym in vincinity of executable.
ModuleSpecs::FindMatchingModuleSpec looks for matching filenames but when
looking for the dSYM we should only be looking for a matching architecture and
and UUID. Jason pointed out this mistake in http://reviews.llvm.org/D9174 when
this function was incorrectly converted to not be Mac specific.
Test Plan:
Running LLDB on test/lang/c/shared_lib_stripped_symbols/a.out in a debugger I've
verified LocateDSYMInVincinityOfExecutable correctly locates the matching dSYM.
Differential Revision: http://reviews.llvm.org/D9896
llvm-svn: 237907
Manuel Klimek [Thu, 21 May 2015 15:38:25 +0000 (15:38 +0000)]
std::sort must be called with a strict weak ordering.
Found by a debug enabled stl.
llvm-svn: 237906
Alexander Kornienko [Thu, 21 May 2015 14:08:56 +0000 (14:08 +0000)]
[clang-tidy] Disable google-readability-casting for .c files and their headers.
Some people have reasons to compile their .c files as C++ in some configurations
(e.g. for testing purposes), so just looking at LangOptions is not enough. This
patch disables the check on all .c files (and also for the headers included from
.c files).
llvm-svn: 237905
Tamas Berghammer [Thu, 21 May 2015 14:04:17 +0000 (14:04 +0000)]
Add bug number for TestEvents
llvm-svn: 237904
Elena Demikhovsky [Thu, 21 May 2015 14:01:32 +0000 (14:01 +0000)]
AVX-512: Enabled SSE intrinsics on AVX-512.
Predicate UseAVX depricates pattern selection on AVX-512.
This predicate is necessary for DAG selection to select EVEX form.
But mapping SSE intrinsics to AVX-512 instructions is not ready yet.
So I replaced UseAVX with HasAVX for intrinsics patterns.
llvm-svn: 237903
Renato Golin [Thu, 21 May 2015 13:52:20 +0000 (13:52 +0000)]
Make Triple::parseARMArch use ARMTargetParser
Simplifying Triple::parseARMArch, leaving all the parsing to ARMTargetParser.
This commit also adds AArch64 detection to ARMTargetParser canonicalization,
and a two RedHat arch names (v{6,7}hl, meaning hard-float / little-endian).
Adding enough unit tests to cover the basics. Clang checks fine.
llvm-svn: 237902
Tamas Berghammer [Thu, 21 May 2015 13:44:40 +0000 (13:44 +0000)]
Handle aggregate return types in SysV-arm ABI
Differential revision: http://reviews.llvm.org/D9910
llvm-svn: 237901
Tamas Berghammer [Thu, 21 May 2015 13:34:46 +0000 (13:34 +0000)]
Add float/double return value handling to SysV-arm ABI
This is neccessary for evaluating expressions with float/double return
value and for displaying float/double return values in case of a thread
step out.
Differential revision: http://reviews.llvm.org/D9907
llvm-svn: 237900
Igor Laevsky [Thu, 21 May 2015 13:02:14 +0000 (13:02 +0000)]
[RewriteStatepointsForGC] Fix debug assertion during derivable pointer rematerialization
Correct assertion would be that there is no other uses from chain we are currently cloning. It is ok to have other uses of values not from this chain.
Differential Revision: http://reviews.llvm.org/D9882
llvm-svn: 237899
Denis Protivensky [Thu, 21 May 2015 12:52:00 +0000 (12:52 +0000)]
[ARM] Add dynamic symbols to the dynamic library writer
llvm-svn: 237898
Artur Pilipenko [Thu, 21 May 2015 12:51:38 +0000 (12:51 +0000)]
Fix memory-dereferenceable.ll test
One of the testcases introduced by D9365 had incorrect !dereferenceable metadata on load. It must fail but it doesn't due to incorrect order of CHECK/CHECK-NOT commands in test. Fixed both.
Reviewed By: sanjoy
Differential Revision: http://reviews.llvm.org/D9877
llvm-svn: 237897
Denis Protivensky [Thu, 21 May 2015 12:31:15 +0000 (12:31 +0000)]
[ARM] Remove useless file with writer's instantiation stub
llvm-svn: 237896
Manuel Klimek [Thu, 21 May 2015 12:23:34 +0000 (12:23 +0000)]
clang-format: [JS] Better support for fat arrows.
Assigns a token type (TT_JsFatArrow) to => tokens, and uses that to
more easily recognize and format fat arrow functions.
Improves function parsing to better recognize formal parameter
lists and return type declarations.
Recognizes arrow functions and parse function bodies as child blocks.
Patch by Martin Probst.
llvm-svn: 237895
John Brawn [Thu, 21 May 2015 12:19:49 +0000 (12:19 +0000)]
[ARM] Restructure cpu handling in the driver to mostly use the triple
Using the target cpu to determine some behaviour is sprinkled in
several places in the driver, but in almost all the information that
is needed can be found in the triple. Restructure things so that the
triple is used, and the cpu is only used if the exact cpu name is
needed.
Also add a check that the -mcpu argument is valid, and correct the
-march argument checking so that it handles -march=native correctly. I
would have liked to move these checks into the computation of the
triple, but the triple is calculated several times in several places
and that would lead to multiple error messages for the same thing.
Differential Revision: http://reviews.llvm.org/D9879
llvm-svn: 237894
Artur Pilipenko [Thu, 21 May 2015 11:57:38 +0000 (11:57 +0000)]
Test commit. Fix typo in MemDerefPrinter.cpp comment.
llvm-svn: 237893
Denis Protivensky [Thu, 21 May 2015 11:50:54 +0000 (11:50 +0000)]
[ARM] Remove unused field in executable writer
llvm-svn: 237892
Denis Protivensky [Thu, 21 May 2015 11:16:40 +0000 (11:16 +0000)]
[ARM] Move out common Writer functionality to ARMELFWriter
llvm-svn: 237891
Renato Golin [Thu, 21 May 2015 10:47:56 +0000 (10:47 +0000)]
Remove unnecessary FIXME comment
It has been fixed by commit r237797.
llvm-svn: 237890
Simon Pilgrim [Thu, 21 May 2015 10:22:10 +0000 (10:22 +0000)]
Fixed unused variable warning in non-assert builds from rL237885
llvm-svn: 237889
Tamas Berghammer [Thu, 21 May 2015 10:16:55 +0000 (10:16 +0000)]
XFAIL TestEvents on Linux bacuse it is flaky
llvm-svn: 237888
Pavel Labath [Thu, 21 May 2015 10:15:57 +0000 (10:15 +0000)]
XFAILing TestRaise on darwin due to an apparent bug
llvm-svn: 237887
Denis Protivensky [Thu, 21 May 2015 10:11:27 +0000 (10:11 +0000)]
[ELF] Move start/end atom method assignment to OutputELFWriter. NFC
llvm-svn: 237886
Simon Pilgrim [Thu, 21 May 2015 10:05:03 +0000 (10:05 +0000)]
[X86][SSE] Improve support for 128-bit vector sign extension
This patch improves support for sign extension of the lower lanes of vectors of integers by making use of the SSE41 pmovsx* sign extension instructions where possible, and optimizing the sign extension by shifts on pre-SSE41 targets (avoiding the use of i64 arithmetic shifts which require scalarization).
It converts SIGN_EXTEND nodes to SIGN_EXTEND_VECTOR_INREG where necessary, that more closely matches the pmovsx* instruction than the default approach of using SIGN_EXTEND_INREG which splits the operation (into an ANY_EXTEND lowered to a shuffle followed by shifts) making instruction matching difficult during lowering. Necessary support for SIGN_EXTEND_VECTOR_INREG has been added to the DAGCombiner.
Differential Revision: http://reviews.llvm.org/D9848
llvm-svn: 237885
Toma Tabacu [Thu, 21 May 2015 10:04:39 +0000 (10:04 +0000)]
[mips] [IAS] Add 2 missing CHECK directives for fixups in mips-expansions.s.
llvm-svn: 237884
Denis Protivensky [Thu, 21 May 2015 09:52:21 +0000 (09:52 +0000)]
[ARM] Remove unused fields in dynamic library writer
llvm-svn: 237883
Alexey Bataev [Thu, 21 May 2015 09:47:46 +0000 (09:47 +0000)]
[OPENMP] Fixed codegen for parameters privatization.
For parameters we shall take a derived type of parameters, not the original one.
llvm-svn: 237882
Denis Protivensky [Thu, 21 May 2015 09:28:25 +0000 (09:28 +0000)]
[ARM] Add skeleton implementation of DSO linking
llvm-svn: 237881
Pavel Labath [Thu, 21 May 2015 08:32:18 +0000 (08:32 +0000)]
[NativeProcessLinux] Fix handling of SIGSTOP
Summary:
Previously, NPL tried to reinject SIGSTOP into the inferior in an attempt to get the process to
start in the group-stop state. This was:
a) wrong (reinjection should be controlled by "process handle" lldb setting)
b) racy (it should use Resume for transparent resuming instead of RequestResume)
c) broken (llgs crashed on inferior SIGSTOP)
With this change, SIGSTOP is handled just like any other signal delivered to the inferior: we
stop all threads and report signal reception to lldb. SIGSTOP reinjection does not behave the
same way as it would outside the debugger, but simulating this is a hard problem and is not
normally necessary.
Test Plan: I have added a test which verifies we get SIGSTOP reports and we do not crash.
Reviewers: ovyalov, chaoren
Subscribers: lldb-commits
Differential Revision: http://reviews.llvm.org/D9852
llvm-svn: 237880
Alexey Bataev [Thu, 21 May 2015 07:59:51 +0000 (07:59 +0000)]
[OPENMP] Fixed codegen for lastprivate LCV in worksharing constructs.
If loop control variable in a worksharing construct is marked as lastprivate, we should copy last calculated value of private counter back to original variable.
llvm-svn: 237879
Vince Harron [Thu, 21 May 2015 05:57:28 +0000 (05:57 +0000)]
trivial log print fix
llvm-svn: 237878
Hal Finkel [Thu, 21 May 2015 04:32:56 +0000 (04:32 +0000)]
[TableGen] Resolve complex def names inside multiclasses
We had not been trying hard enough to resolve def names inside multiclasses
that had complex concatenations, etc. Now we'll try harder.
Patch by Amaury Sechet!
llvm-svn: 237877
Duncan P. N. Exon Smith [Thu, 21 May 2015 02:41:23 +0000 (02:41 +0000)]
AsmPrinter: Compute absolute label difference directly
Create a low-overhead path for `EmitLabelDifference()` that emits a
emits an absolute number when (1) the output is an object stream and (2)
the two symbols are in the same data fragment.
This drops memory usage on Mach-O from 975 MB down to 919 MB (5.8%).
The only call is when `!doesDwarfUseRelocationsAcrossSections()` --
i.e., on Mach-O -- since otherwise an absolute offset from the start of
the section needs a relocation. (`EmitLabelDifference()` is cheaper on
ELF anyway, since it creates 1 fewer temp symbol, and it gets called far
less often. It's not clear to me if this is even a bottleneck there.)
(I'm looking at `llc` memory usage on `verify-uselistorder.lto.opt.bc`;
see r236629 for details.)
llvm-svn: 237876
Duncan P. N. Exon Smith [Thu, 21 May 2015 01:59:58 +0000 (01:59 +0000)]
MC: Initialize MCSymbolData::Offset directly
Try to fix miscompile after r237873. Looks like this union
initialization isn't legal (or at least not supported).
llvm-svn: 237875
Ahmed Bougacha [Thu, 21 May 2015 01:43:39 +0000 (01:43 +0000)]
[MemCpyOpt] Do move the memset, but look at its dest's dependencies.
In effect a partial revert of r237858, which was a dumb shortcut.
Looking at the dependencies of the destination should be the proper
fix: if the new memset would depend on anything other than itself,
the transformation isn't correct.
llvm-svn: 237874
Duncan P. N. Exon Smith [Thu, 21 May 2015 01:33:03 +0000 (01:33 +0000)]
MC: Simplify MCSymbolData initialization and remove MCSymbol pointer
Finally remove the `MCSymbolData::Symbol` pointer. It was still being
used to track whether `MCSymbolData` had been initialized, but this is
better tracked by the bitfield in `MCSymbol`.
The only caller of `MCSymbolData::initialize()` was `MCAssembler`, which
(other than `Symbol`) passed in all-0 values. Replace all that
indirection with a default constructor.
The main point is a cleanup (and there's more cleanup to do), but there
are also some small memory savings. I measured ~989 MB down to ~975 MB,
cutting a little over 1% off the top of `llc`.
(I'm looking at `llc` memory usage on `verify-uselistorder.lto.opt.bc`;
see r236629 for details.)
llvm-svn: 237873
Richard Smith [Thu, 21 May 2015 01:26:53 +0000 (01:26 +0000)]
Avoid using a C++11 library feature not present in libstdc++4.7.
llvm-svn: 237872
Richard Smith [Thu, 21 May 2015 01:20:10 +0000 (01:20 +0000)]
[modules] If we re-enter a submodule from within itself (when submodule
visibility is enabled) or leave and re-enter it, restore the macro and module
visibility state from last time we were in that submodule.
This allows mutually-#including header files to stand a chance at being
modularized with local visibility enabled.
llvm-svn: 237871
Alexey Samsonov [Thu, 21 May 2015 01:07:52 +0000 (01:07 +0000)]
[Driver] Improve unused-argument diagnostic for extra sanitizer features.
Don't print unused-argument warning for sanitizer-specific feature flag
if this sanitizer was eanbled, and later disabled in the command line.
For example, now:
clang -fsanitize=address -fsanitize-coverage=bb -fno-sanitize=address a.cc
doesn't print warning, but
clang -fsanitize-coverage=bb
does. Same holds for -fsanitize-address-field-padding= and
-fsanitize-memory-track-origins= flags.
Fixes PR23604.
llvm-svn: 237870
Swaroop Sridhar [Thu, 21 May 2015 00:50:10 +0000 (00:50 +0000)]
Document the CoreCLR GC Strategy
Add notead about the CoreCLR GC Strategy to the
Garbage Collection document.
llvm-svn: 237869
Duncan P. N. Exon Smith [Thu, 21 May 2015 00:49:09 +0000 (00:49 +0000)]
MC: Make MCSymbolData::Symbol private
Make the back-pointer from `MCSymbolData` to `MCSymbol` private,
preparing to remove the back pointer entirely. I've already updated all
the users, although for now it's still used to indicate whether
`MCSymbol::Data` has been initialized.
llvm-svn: 237868
Duncan P. N. Exon Smith [Thu, 21 May 2015 00:39:24 +0000 (00:39 +0000)]
MC: Remove last use of MCSymbolData::getSymbol(), NFC
Remove the last use of `MCSymbolData::getSymbol()`. There's some
*really* hairy stuff going on in `MachObjectWriter::WriteNList()` that I
want to come back to. In particular, it updates `Symbol` to point at
its aliasee (if any), but leaves `Data` behind, and it's not clear
whether everything makes sense there.
For now I've left the logic unchanged by adding `OrigSymbol` and moving
the FIXME from r237750 up a bit higher. I've filed PR23598 to track
looking into this.
llvm-svn: 237867
Jim Ingham [Thu, 21 May 2015 00:27:01 +0000 (00:27 +0000)]
Fix the logic in DynamicLoaderMacOSXDYLD::Clear that would only remove the old dyld notification
breakpoint only if the process it was for is still alive. We need to always remove this because
it has a pointer to the old loader, and if we ever hit it we will crash. I also put in a sanity
check in the callback function to make sure we don't invoke it if the process is wrong.
<rdar://problem/
21006189>
llvm-svn: 237866
Greg Clayton [Thu, 21 May 2015 00:26:58 +0000 (00:26 +0000)]
Fixed an issue with expressions that define types in the expression. We must currently touch the members of the struct in the right order or our ClangASTImporter::DeportType() will copy the resulting type into the target AST incorrectly. This is a work around for <rdar://problem/
21049838> which the copy type issue so that it doesn't happen.
<rdar://problem/
20902950>
llvm-svn: 237865
Chaoren Lin [Thu, 21 May 2015 00:19:15 +0000 (00:19 +0000)]
Using -pthread instead of -lpthread to appease GCC.
llvm-svn: 237864
Reid Kleckner [Thu, 21 May 2015 00:13:09 +0000 (00:13 +0000)]
Rename a helper template function to 'bytes' to avoid a C++17 STL conflict
MSVC 2015 includes the std::data() template function added to C++17. ADL
causes both cl.exe and clang-cl to prefer std::data over our static
helper here, and we get errors about converting int64_t* to StringRef.
Renaming it to bytes avoids the ambiguity.
llvm-svn: 237863
Reid Kleckner [Thu, 21 May 2015 00:12:53 +0000 (00:12 +0000)]
Work around overloading bug in MSVC 2015
MSVC 2015 appears to be unable to find the correct operator== here. I
haven't yet filed a bug with Microsoft as I've been unable to create a
reduced test case.
llvm-svn: 237862
Ahmed Bougacha [Thu, 21 May 2015 00:08:35 +0000 (00:08 +0000)]
[MemCpyOpt] Pass Instruction to IRBuilder, no need for NextNode. NFC.
We're erasing the instructions anyway.
llvm-svn: 237861
David Blaikie [Thu, 21 May 2015 00:06:38 +0000 (00:06 +0000)]
[opaque pointer type] Pass explicit pointee type in another case of GEP constant folding
llvm-svn: 237860
Andrew Kaylor [Wed, 20 May 2015 23:58:44 +0000 (23:58 +0000)]
Fix build error
llvm-svn: 237859
Ahmed Bougacha [Wed, 20 May 2015 23:55:16 +0000 (23:55 +0000)]
[MemCpyOpt] Don't move the memset when optimizing memset+memcpy.
Fixes PR23599, another miscompile introduced by r235232: when there is
another dependency on the destination of the created memset (i.e., the
part of the original destination that the memcpy doesn't depend on)
between the memcpy and the original memset, we would insert the created
memset after the memcpy, and thus after the other dependency.
Instead, insert the created memset right after the old one.
llvm-svn: 237858
Lang Hames [Wed, 20 May 2015 23:44:37 +0000 (23:44 +0000)]
[LLD] Make lastOrdinal atomic to avoid race conditions.
No test case: We don't have a good way to test race conditions.
llvm-svn: 237857
Richard Trieu [Wed, 20 May 2015 23:29:18 +0000 (23:29 +0000)]
Check for bool-like conversion in conditional expressions.
Add a check for bool-like conversions for the condition expression of
conditional operators. This is similiar to the checking of condition
expressions of if statements, for-loops, while-loops, and do-while loops.
Specificially, this is to fix the problem of assert("message") not triggering
-Wstring-conversion when the assert macro uses a conditional operator.
llvm-svn: 237856
Andrew Kaylor [Wed, 20 May 2015 23:28:03 +0000 (23:28 +0000)]
Fix build warning
llvm-svn: 237855
Andrew Kaylor [Wed, 20 May 2015 23:22:24 +0000 (23:22 +0000)]
[WinEH] C++ EH state numbering fixes
Differential Revision: http://reviews.llvm.org/D9787
llvm-svn: 237854
Reid Kleckner [Wed, 20 May 2015 23:08:04 +0000 (23:08 +0000)]
[WinEH] Store pointers to the LSDA in the exception registration object
We aren't yet emitting the LSDA yet, so this will still fail to
assemble.
llvm-svn: 237852
Pete Cooper [Wed, 20 May 2015 22:51:27 +0000 (22:51 +0000)]
Don't generate comments in the DebugLocStream unless required. NFC.
The ByteStreamer here wasn't taking account of whether the asm streamer was text based and verbose. Only with that combination should we emit comments.
This change makes sure that we only actually convert a Twine to a string using Twine::str() if we need the comment. This saves about 10000 small allocations on a test case involving the verify-use_list-order bitcode going through llc with debug info.
Note, this is NFC as the comments would ultimately never be emitted unless required.
Reviewed by Duncan Exon Smith and David Blaikie.
llvm-svn: 237851
Richard Smith [Wed, 20 May 2015 22:48:44 +0000 (22:48 +0000)]
[OpenMP] Make default OpenMP library (the one selected with just -fopenmp)
configurable in the CMake build. There shouldn't be any change in default
behavior.
Derived from a patch by Daniel Jasper!
llvm-svn: 237850
Pete Cooper [Wed, 20 May 2015 22:37:48 +0000 (22:37 +0000)]
Revert "Add bool to DebugLocDwarfExpression to control emitting comments."
This reverts commit
0037b6bcbc874aa1b93d7ce3ad8dba3753ee2d9d (r237827).
David Blaikie suggested some alternatives to this which are better. Reverting to apply a better solution later.
llvm-svn: 237849
Nick Kledzik [Wed, 20 May 2015 22:37:46 +0000 (22:37 +0000)]
[darwin] fix libcompiler_rt.dylib build
The dylib build of compiler-rt has been broken on darwin since the
directory restructuring to push some things down into /builtins/.
llvm-svn: 237848
Lang Hames [Wed, 20 May 2015 22:35:20 +0000 (22:35 +0000)]
[LLD] Fix an out-of-order-initialization bug that was introduced in r237841 by
moving a field in MachOLinkingContext.
llvm-svn: 237847
Lang Hames [Wed, 20 May 2015 22:33:34 +0000 (22:33 +0000)]
[LLD] Revert r237842 - it went in without a proper commit message.
llvm-svn: 237846
Jonathan Peyton [Wed, 20 May 2015 22:33:24 +0000 (22:33 +0000)]
Change CMake variable prefix to LIBOMP
Cached CMake variables need to have a prefix so they don't collide with other
projects. This change (a lot of simple changes) simply prefixes cached variables
with LIBOMP_ and sets all of these variables to UPPERCASE which is convention.
e.g., os => LIBOMP_OS, ompt_support => LIBOMP_OMPT_SUPPORT.
Differential Revision: http://reviews.llvm.org/D9829
llvm-svn: 237845
Adrian McCarthy [Wed, 20 May 2015 22:32:44 +0000 (22:32 +0000)]
Have TestNumThreads use std::thread instead of pthreads so that it can work cross-platform.
llvm-svn: 237844
Hans Wennborg [Wed, 20 May 2015 22:31:55 +0000 (22:31 +0000)]
Revert r237828 "[X86] Remove unused node after morphing it from shr to and."
This caused assertions during DAG combine: PR23601.
llvm-svn: 237843
Lang Hames [Wed, 20 May 2015 22:26:06 +0000 (22:26 +0000)]
y
llvm-svn: 237842