Nemanja Ivanovic [Wed, 5 Oct 2016 19:11:36 +0000 (19:11 +0000)]
Removing optimization from the RUN lines and adjusting the checks
to not rely on optimization.
llvm-svn: 283363
Luke Drummond [Wed, 5 Oct 2016 19:10:47 +0000 (19:10 +0000)]
Add the ability to set breakpoints on named RenderScript reductions
- Add new `lldb_private::lldb_renderscript::RSReduceBreakpointResolver`
class that can set breakpoints on kernels that are constituent
functions of named reduction groups. Also support debugging of subsets
of the the reduction group with the `-t, --function-role` flag which
takes a comma-separated list of reduction function types
outconverter,combiner,initializer,accumulator (defaults to all)
- Add 2 new helper methods to `RenderScriptRuntime`,
1. `CreateReductionBreakpoint(name, types)`: instantiates a new
RSReduceBreakpointResolver and inserts that resolver into the running
process.
2. `PlaceBreakpointOnReduction`: which is a public helper function.
- hook up the above functionality to the command-line with new
`CommandObject*` classes that handle parsing of function roles and
dispatch to the runtime. These are namespaced under the snappy
`language renderscript reduction breakpoint ...` subcommand
- [incidental] Factor multiple common uses of
`FindFirstSymbolWithNameAndType(ConstString(".rs.info")` into static
`IsRenderScriptScriptModule(ModuleSP module)` function, and replace
original uses.
llvm-svn: 283362
Sanjay Patel [Wed, 5 Oct 2016 18:51:12 +0000 (18:51 +0000)]
fix documentation comments; NFC
llvm-svn: 283361
Marshall Clow [Wed, 5 Oct 2016 18:47:18 +0000 (18:47 +0000)]
Comment out failing test while I figure out who is at fault
llvm-svn: 283360
Rafael Espindola [Wed, 5 Oct 2016 18:46:21 +0000 (18:46 +0000)]
Allow the caller to pass in the hash.
If the caller already has the hash we don't have to compute it. This
will be used in lld.
llvm-svn: 283359
Zachary Turner [Wed, 5 Oct 2016 18:40:51 +0000 (18:40 +0000)]
Fix some test failures due to the recent Breakpoint patch.
llvm-svn: 283358
Rafael Espindola [Wed, 5 Oct 2016 18:40:00 +0000 (18:40 +0000)]
Compact SectionPiece.
It is pretty easy to get the data from the InputSection, so we don't
have to store it.
This opens the way for storing the hash instead.
llvm-svn: 283357
Marshall Clow [Wed, 5 Oct 2016 18:36:24 +0000 (18:36 +0000)]
Mark LWG#2679 as complete
llvm-svn: 283356
Reid Kleckner [Wed, 5 Oct 2016 18:36:02 +0000 (18:36 +0000)]
Improve DEBUG_VALUE assembly comments for spilled bitpieces
Previously we would give up when we saw the bitpiece DWARF expression
and print "[complex expression]" when actually we handled bitpiece
expressions outside the loop.
llvm-svn: 283355
Matthew Simpson [Wed, 5 Oct 2016 18:30:36 +0000 (18:30 +0000)]
[LV] Add helper function for predicated block probability (NFC)
The cost model has to estimate the probability of executing predicated blocks.
However, we currently always assume predicated blocks have a 50% chance of
executing (this value is hardcoded in several places throughout the code).
Since we always use the same value, this patch adds a helper function for
getting this uniform probability. The function simplifies some comments and
makes our assumptions more clear. In the future, we may want to extend this
with actual block probability information if it's available.
llvm-svn: 283354
Simon Dardis [Wed, 5 Oct 2016 18:26:19 +0000 (18:26 +0000)]
[mips][ias] fix li macro when values are negated with ~
The integrated assembler evaluates the expressions such as ~0x80000000 to
0xffffffff7fffffff early in the parsing process. This patch adds compatibility
with gas so that li loads the expected value (0x7fffffff) in those cases. This
only occurs iff all the upper 32bits are set and maintains existing checks by
not truncating the result down to 32 bits if any of the the upper bits are not
set.
Reviewers: dsanders, zoran.jovanovic
Differential Review: https://reviews.llvm.org/D23399
llvm-svn: 283353
Dimitar Vlahovski [Wed, 5 Oct 2016 18:11:45 +0000 (18:11 +0000)]
Removing the new Minidump plugin
Tests are failing and build is failing on windows and darwin.
Will fix and commit it later
-------------------------------------------------------------
Revert "xfailing minidump tests again ... :("
This reverts commit
97eade002c9e43c1e0d11475a4888083a8965044.
Revert "Fixing new Minidump plugin tests"
This reverts commit
0dd93b3ab39c8288696001dd50b9a093b813b09c.
Revert "Add the new minidump files to the Xcode project."
This reverts commit
2f638a1d046b8a88e61e212220edc40aecd2ce44.
Revert "xfailing tests for Minidump plugin"
This reverts commit
99311c0b22338a83e6a00c4fbddfd3577914c003.
Revert "Adding a new Minidump post-mortem debugging plugin"
This reverts commit
b09a7e4dae231663095a84dac4be3da00b03a021.
llvm-svn: 283352
Zachary Turner [Wed, 5 Oct 2016 17:58:46 +0000 (17:58 +0000)]
Try to fix Android build.
Seems it doesn't like the implicit conversion from
StringRef[] to ArrayRef<StringRef>.
llvm-svn: 283351
Matthew Simpson [Wed, 5 Oct 2016 17:52:34 +0000 (17:52 +0000)]
[LV] Add isScalarWithPredication helper function (NFC)
This patch adds a single helper function for checking if an instruction will be
scalarized with predication. Such instructions include conditional stores and
instructions that may divide by zero. Existing checks have been updated to use
the new function.
llvm-svn: 283350
Anna Zaks [Wed, 5 Oct 2016 17:42:24 +0000 (17:42 +0000)]
Revert "[asan] Switch to using dynamic shadow offset on iOS"
This reverts commit
b2af965b7924ad793b313996a96633bb72daf629.
Revert as these changes broke a Chromium buildbot.
llvm-svn: 283349
Anna Zaks [Wed, 5 Oct 2016 17:42:02 +0000 (17:42 +0000)]
Revert "[asan] LLVM: Switch to using dynamic shadow offset on iOS"
This reverts commit
abe77a118615cd90b0d7f127e4797096afa2b394.
Revert as these changes broke a Chromium buildbot.
llvm-svn: 283348
Bjorn Pettersson [Wed, 5 Oct 2016 17:40:27 +0000 (17:40 +0000)]
[DAG] Teach computeKnownBits and ComputeNumSignBits in SelectionDAG to look through EXTRACT_VECTOR_ELT.
Summary: Both computeKnownBits and ComputeNumSignBits can now do a simple
look-through of EXTRACT_VECTOR_ELT. It will compute the result based
on the known bits (or known sign bits) for the vector that the element
is extracted from.
Reviewers: bogner, tstellarAMD, mkuper
Subscribers: wdng, RKSimon, jyknight, llvm-commits, nhaehnle
Differential Revision: https://reviews.llvm.org/D25007
llvm-svn: 283347
Bjorn Pettersson [Wed, 5 Oct 2016 17:22:11 +0000 (17:22 +0000)]
Test commit permission. NFC
llvm-svn: 283346
Zachary Turner [Wed, 5 Oct 2016 17:07:47 +0000 (17:07 +0000)]
Convert some breakpoint code to use StringRef.
Differential revision: https://reviews.llvm.org/D25158
llvm-svn: 283345
Zachary Turner [Wed, 5 Oct 2016 17:07:34 +0000 (17:07 +0000)]
Make lldb -Werror clean on Windows.
Differential Revision: https://reviews.llvm.org/D25247
llvm-svn: 283344
Zachary Turner [Wed, 5 Oct 2016 17:07:16 +0000 (17:07 +0000)]
Disable warnings in LLDBWrapPython.cpp with -Werror.
When -Werror is used, we don't have control over the generated
code from SWIG, and it often has warnings. Just disable them for
this file when -Werror is used, they are usually not important
anyway.
Differential revision: https://reviews.llvm.org/D25246
llvm-svn: 283343
Zachary Turner [Wed, 5 Oct 2016 17:04:36 +0000 (17:04 +0000)]
Fix build due to comparison of std::pairs.
llvm-svn: 283342
Marshall Clow [Wed, 5 Oct 2016 17:02:43 +0000 (17:02 +0000)]
Mark LWG#2358 as done
llvm-svn: 283341
Rafael Espindola [Wed, 5 Oct 2016 17:02:09 +0000 (17:02 +0000)]
Simplify setting the Live bit in SectionPiece. NFC.
llvm-svn: 283340
Marshall Clow [Wed, 5 Oct 2016 17:01:16 +0000 (17:01 +0000)]
Make tests for is_empty better. No functional change.
llvm-svn: 283339
Haojian Wu [Wed, 5 Oct 2016 17:00:40 +0000 (17:00 +0000)]
[change-namespace] Pass Style to ChangeNamespaceTool.
llvm-svn: 283338
Zachary Turner [Wed, 5 Oct 2016 16:54:09 +0000 (16:54 +0000)]
Add llvm::enumerate() range adapter.
This allows you to enumerate over a range using a range-based
for while the return type contains the index of the enumeration.
Differential revision: https://reviews.llvm.org/D25124
llvm-svn: 283337
Rafael Espindola [Wed, 5 Oct 2016 16:33:03 +0000 (16:33 +0000)]
Don't pass null to memcpy. Should fix the asan bots.
llvm-svn: 283336
Luke Drummond [Wed, 5 Oct 2016 16:27:48 +0000 (16:27 +0000)]
[RenderScript] reflow/reword some comments and normalize names
Pay more attention to comment alignement (Since _The Great Reformat_ (
a015ff50)
comments are no longer properly aligned) and variable naming conventions.
- Manually reflow and cleanup comments and array literals
- Be more economical with our naming conventions
- Be internally consistent with regard to local variable/member function
naming
llvm-svn: 283335
Simon Dardis [Wed, 5 Oct 2016 16:11:01 +0000 (16:11 +0000)]
Recommit: "[mips] Add rsqrt, recip for MIPS"
Add rsqrt.[ds], recip.[ds] for MIPS. Correct the microMIPS definitions for
architecture support and register usage.
Reviewers: vkalintiris, zoran.jovanoic
Differential Review: https://reviews.llvm.org/D24499
llvm-svn: 283334
Eric Liu [Wed, 5 Oct 2016 15:52:39 +0000 (15:52 +0000)]
[change-namespace] Fixed a bug in getShortestQualifiedNameInNamespace.
Reviewers: hokein
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D25065
llvm-svn: 283333
Eric Liu [Wed, 5 Oct 2016 15:49:01 +0000 (15:49 +0000)]
Make DeletedLines local variables in checkEmptyNamespace.
Summary: Patch by Sam McCall!
Reviewers: djasper
Subscribers: klimek, cfe-commits
Differential Revision: https://reviews.llvm.org/D25162
llvm-svn: 283332
Marshall Clow [Wed, 5 Oct 2016 15:47:13 +0000 (15:47 +0000)]
Add another append test for basic_string
llvm-svn: 283331
Eric Liu [Wed, 5 Oct 2016 15:42:19 +0000 (15:42 +0000)]
[clang-format] append newline after code when inserting new headers at the end of the code which does not end with newline.
Summary:
append newline after code when inserting new headers at the end of the
code which does not end with newline.
Reviewers: djasper
Subscribers: cfe-commits, klimek
Differential Revision: https://reviews.llvm.org/D21026
llvm-svn: 283330
Hans Wennborg [Wed, 5 Oct 2016 15:39:27 +0000 (15:39 +0000)]
Revert r282920 "X86: Allow conditional tail calls in Win64 "leaf" functions (PR26302)"
This is suspected to cause a miscompile in Chromium. Reverting while
investigating.
llvm-svn: 283329
Rafael Espindola [Wed, 5 Oct 2016 15:35:18 +0000 (15:35 +0000)]
Remove redundant check. NFC.
llvm-svn: 283328
Simon Dardis [Wed, 5 Oct 2016 15:28:33 +0000 (15:28 +0000)]
Revert "[mips] Add rsqrt, recip for MIPS"
This reverts commit r282485 which contain two patches instead of
one.
llvm-svn: 283327
Douglas Katzman [Wed, 5 Oct 2016 15:23:35 +0000 (15:23 +0000)]
[X86] Don't randomly encode %rip where illegal
Differential Revision: https://reviews.llvm.org/D25112
llvm-svn: 283326
Marshall Clow [Wed, 5 Oct 2016 15:21:11 +0000 (15:21 +0000)]
Mark LWG issues 2221, 2556 and 2589 as complete
llvm-svn: 283325
Dimitar Vlahovski [Wed, 5 Oct 2016 15:00:29 +0000 (15:00 +0000)]
xfailing minidump tests again ... :(
llvm-svn: 283324
James Molloy [Wed, 5 Oct 2016 14:52:13 +0000 (14:52 +0000)]
[Thumb] Don't try and emit LDRH/LDRB from the constant pool
This is not a valid encoding - these instructions cannot do PC-relative addressing.
The underlying problem here is of whitelist in ARMISelDAGToDAG that unwraps ARMISD::Wrappers during addressing-mode selection. This didn't realise TargetConstantPool was actually possible, so didn't handle it.
llvm-svn: 283323
Douglas Katzman [Wed, 5 Oct 2016 14:46:14 +0000 (14:46 +0000)]
[X86] Fix some tests that didn't assert anything
llvm-svn: 283322
Dimitar Vlahovski [Wed, 5 Oct 2016 14:35:30 +0000 (14:35 +0000)]
Fixing new Minidump plugin tests
llvm-svn: 283321
Luke Drummond [Wed, 5 Oct 2016 14:34:52 +0000 (14:34 +0000)]
cleanup RSCoordinate handling and factor out coordinate parser
- This change updates the signature of
`RenderScriptRuntime::PlaceBreakpointOnKernel` to take a default
RSCoordinate pointer of nullptr. We use this as the predicate value for
the breakpoint coordinate rather than trying to fit a sentinel `-1` into
a signed version.
```
- void
- PlaceBreakpointOnKernel(Stream &strm, const char *name, const std::array<int, 3> coords, Error &error,
- lldb::TargetSP target);
```
```
+ bool
+ PlaceBreakpointOnKernel(lldb::TargetSP target, Stream &messages, const char *name,
+ const lldb_renderscript::RSCoordinate *coords = nullptr);
```
The above change makes the API for setting breakpoints on kernels
cleaner as it returns a failure value rather than modify a sentinel in
the caller. The optional arguments are now last and have a default
(falsey) value.
- RSCoordinate objects are now comparable with operator== and have
zero initializers which should make them easier to work on.
- Added a `FMT_COORD` macro for use in logging format strings which
should make format strings a little less verbose.
llvm-svn: 283320
Oren Ben Simhon [Wed, 5 Oct 2016 14:12:41 +0000 (14:12 +0000)]
Test commit permission
llvm-svn: 283319
Oren Ben Simhon [Wed, 5 Oct 2016 13:48:33 +0000 (13:48 +0000)]
Test commit permission
llvm-svn: 283318
Dylan McKay [Wed, 5 Oct 2016 13:38:29 +0000 (13:38 +0000)]
[AVR] Don't select 'MOVW' instructions when they are not supported
We have a subtarget feature which we were ignoring, which was causing us
to generate unsupported instructions for some older chips.
llvm-svn: 283317
Dylan McKay [Wed, 5 Oct 2016 13:27:30 +0000 (13:27 +0000)]
[AVR] Add AVRRegisterInfo::splitReg function
No tests are included just yet - this is used from the pseudo
instruction expander pass, which hasn't been pulled in-tree yet.
llvm-svn: 283316
Krzysztof Parzyszek [Wed, 5 Oct 2016 13:15:06 +0000 (13:15 +0000)]
Fix machine operand traversal in ScheduleDAGInstrs::fixupKills
llvm-svn: 283315
Michael Zuckerman [Wed, 5 Oct 2016 12:56:06 +0000 (12:56 +0000)]
[Clang][AVX512][BuiltIn]Adding missing intrinsics move_{sd|ss} to clang
Differential Revision: http://reviews.llvm.org/D21021
llvm-svn: 283314
Luke Drummond [Wed, 5 Oct 2016 12:40:49 +0000 (12:40 +0000)]
Delete unused global in ClangExpressionVariable.cpp
Differential Revision: https://reviews.llvm.org/D24793
llvm-svn: 283313
Dylan McKay [Wed, 5 Oct 2016 12:32:24 +0000 (12:32 +0000)]
[AVR] Update return type of dynamic alloca pass
It was recently changed from 'const char*' to StringRef
llvm-svn: 283312
Dylan McKay [Wed, 5 Oct 2016 11:48:56 +0000 (11:48 +0000)]
[AVR] Add the AVR frame lowering code
Summary: This allows AVR to lower frames into assembly code.
Reviewers: arsenm, kparzysz
Subscribers: japaric, wdng, beanz, mgorny
Differential Revision: https://reviews.llvm.org/D25032
llvm-svn: 283311
Dylan McKay [Wed, 5 Oct 2016 10:28:45 +0000 (10:28 +0000)]
[AVR] Split all of the AVR device definitions into a separate file
We have ~500 lines of subtarget feature definitions, they don't belong
in our main TableGen file.
llvm-svn: 283310
Dylan McKay [Wed, 5 Oct 2016 10:23:38 +0000 (10:23 +0000)]
[AVR] Enable the instruction printer in the target definition
llvm-svn: 283309
Dylan McKay [Wed, 5 Oct 2016 10:20:33 +0000 (10:20 +0000)]
[AVR] Add definitions for the ATTiny102 and ATtiny104 chips
llvm-svn: 283308
Eugene Leviant [Wed, 5 Oct 2016 10:10:45 +0000 (10:10 +0000)]
Do not join sections for relocatable object files
Differential revision: https://reviews.llvm.org/D25232
llvm-svn: 283307
Haojian Wu [Wed, 5 Oct 2016 10:04:13 +0000 (10:04 +0000)]
Overhaul clang-include-fixer.el
General overhaul to fix many coding bugs, simplify the code, and improve readability.
* Clarify documentation strings of user options.
* Say that clang-include-fixer-executable is a file to have auto completion.
* Allow user to select available options for clang-include-fixer-input-format. Turn it into a symbol as it's not a free-form string.
* Remove clang-include-fixer-query-mode. This option was apparently used to select between two different operation modes, which is not a typical use case for user options. Provide two separate commands instead.
* Add a face for the overlay highlighting so that users can customize it.
Move user commands to the front so that readers of the code aren't buried in internal functions.
* Make process calls asynchronous. This is possible here because clang-include-fixer doesn't change files in place. This means input is no longer blocked while clang-include-fixer is running.
* Factor out logic in helper functions to keep functions short.
* Add comments where appropriate.
* Provide an alternative buffer replacement strategy for the case that a single line was inserted (the normal case in the case of clang-include-fixer). This keeps point, markers, and other buffer information intact.
* Use let-alist and association lists instead of property lists to shorten the code.
* Instead of highlighting only the first occurrence of a symbol, highlight all occurrences and move point to the closest one.
* Detect qualified names at point.
* Use filepos-to-bufferpos if available.
* Formatting.
Patch by Philipp Stephani!
llvm-svn: 283306
Eugene Leviant [Wed, 5 Oct 2016 09:36:59 +0000 (09:36 +0000)]
[ELF] make KEEP command recognize file patterns
Differential revision: https://reviews.llvm.org/D25242
llvm-svn: 283305
Alex Lorenz [Wed, 5 Oct 2016 09:27:48 +0000 (09:27 +0000)]
[Sema] Packed member warning: Use the typedef name for anonymous structures
This commit improves the packed member warning by showing the name of the
anonymous structure/union when it was defined within a typedef declaration.
rdar://
28498901
Differential Revision: https://reviews.llvm.org/D25106
llvm-svn: 283304
Artem Dergachev [Wed, 5 Oct 2016 08:47:31 +0000 (08:47 +0000)]
[analyzer] Squash a compile error in r283301.
The constexpr string literal trick isn't supported in MSVC2013.
llvm-svn: 283303
Artem Dergachev [Wed, 5 Oct 2016 08:28:25 +0000 (08:28 +0000)]
[analyzer] Improve "Assuming..." diagnostic pieces for logical operators.
Logical short-circuit operators now act like other branch conditions.
If the symbolic value of the left-hand side is not known to be true or false
(based on the previous execution path), the "Assuming" event piece is added
in order to explain that the analyzer is adding a new assumption.
Additionally, when the assumption is made against the right-hand side of
the logical operator (i.e. when the operator itself acts as a condition
in another CFG terminator), the "Assuming..." piece is written out for the
right-hand side of the operator rather than for the whole operator.
This allows expression-specific diagnostic message text to be constructed.
Differential Revision: https://reviews.llvm.org/D25092
llvm-svn: 283302
Artem Dergachev [Wed, 5 Oct 2016 08:19:49 +0000 (08:19 +0000)]
[analyzer] Add "Assuming..." diagnostic pieces for unsupported conditions.
In the analyzer's path-sensitive reports, when a report goes through a branch
and the branch condition cannot be decided to be definitely true or false
(based on the previous execution path), an event piece is added that tells the
user that a new assumption is added upon the symbolic value of the branch
condition. For example, "Assuming 'a' is equal to 3".
The text of the assumption is hand-crafted in various manners depending on
the AST expression. If the AST expression is too complex and the text of
the assumption fails to be constructed, the event piece is omitted.
This causes loss of information and misunderstanding of the report.
Do not omit the event piece even if the expression is too complex;
add a piece with a generic text instead.
Differential Revision: https://reviews.llvm.org/D23300
llvm-svn: 283301
Simon Atanasyan [Wed, 5 Oct 2016 07:49:18 +0000 (07:49 +0000)]
[ELF] Do not merge sections in case of relocatable object generation
Do not merge sections if generating a relocatable object. It makes
the code simpler because we do not need to update relocations addends
to reflect changes introduced by merging. Instead of that we write
such "merge" sections into separate OutputSections and keep SHF_MERGE
/ SHF_STRINGS flags and sh_entsize value to be able to perform merging
later during a final linking.
Differential Revision: http://reviews.llvm.org/D25066
llvm-svn: 283300
Diana Picus [Wed, 5 Oct 2016 07:13:42 +0000 (07:13 +0000)]
[sanitizers] Update sanitizers test to better match glibc internals
Reapply 282061.
One of the tests relying on sem_t's layout gets the wrong value for versions of
glibc newer than 2.21 on platforms that don't have 64-bit atomics (e.g. ARM).
This commit fixes the test to work with:
* versions of glibc >= 2.21 on platforms with 64-bit atomics: unchanged
* versions of glibc >= 2.21 on platforms without 64-bit atomics: the semaphore
value is shifted by SEM_VALUE_SHIFT (which is set to 1 in glibc's internal
headers)
* versions of glibc < 2.21: unchanged
The logic is complicated a bit by the fact that the sanitizers always pick the
oldest version of the symbol available in glibc, which creates discrepancies
between old platforms which contain several versions od the sem_init symbol, and
newer platforms which contain only one.
See the glibc 2.23 sources:
* sysdeps/nptl/internaltypes.h (struct new_sem for glibc >= 2.21 and
struct old_sem for glibc < 2.21)
* nptl/sem_getvalue.c
This was uncovered on one of the new buildbots that we are trying to move to
production.
Differential Revision: https://reviews.llvm.org/D24766
llvm-svn: 283299
Mehdi Amini [Wed, 5 Oct 2016 05:59:29 +0000 (05:59 +0000)]
Re-commit "Use StringRef in Support/Darf APIs (NFC)"
This reverts commit r283285 and re-commit r283275 with
a fix for format("%s", Str); where Str is a StringRef.
llvm-svn: 283298
Dylan McKay [Wed, 5 Oct 2016 05:30:19 +0000 (05:30 +0000)]
[AVR] Add the machine code backend
Summary:
This adds the AVR machine code backend (`AVRAsmBackend.cpp`). This will
allow us to generate machine code from assembled AVR instructions.
Reviewers: arsenm, kparzysz
Subscribers: modocache, japaric, wdng, beanz, mgorny
Differential Revision: https://reviews.llvm.org/D25029
llvm-svn: 283297
Dean Michael Berris [Wed, 5 Oct 2016 05:20:08 +0000 (05:20 +0000)]
[Support][CommandLine] Add cl::getRegisteredSubcommands()
This should allow users of the library to get a range to iterate through
all the subcommands that are registered to the global parser. This
allows users to define subcommands in libraries that self-register to
have dispatch done at a different stage (like main). It allows for
writing code like the following:
for (auto *S : cl::getRegisteredSubcommands()) {
if (*S) {
// Dispatch on S->getName().
}
}
This change also contains tests that show this usage pattern.
Reviewers: zturner, dblaikie, echristo
Subscribers: llvm-commits, mehdi_amini
Differential Revision: https://reviews.llvm.org/D24489
llvm-svn: 283296
Jason Molenda [Wed, 5 Oct 2016 02:29:13 +0000 (02:29 +0000)]
Change Platform::GetRemoteSharedModule so if it's given a ModuleSpec
which specifies a file path and UUID but not an architecture, open
the file at that path and try every one of the architectures in the
file to see if there is a UUID match. Currently we'll pick the
first slice of a multi-architecture file and return that as the
match, and when the UUID doesn't match because it's the wrong
architecture, we'll end up ignoring the file.
<rdar://problem/
28487804>
llvm-svn: 283295
Mehdi Amini [Wed, 5 Oct 2016 01:41:11 +0000 (01:41 +0000)]
Blind attempt to fix windows build after r283290 - Use StringRef in StringSaver API (NFC)
llvm-svn: 283294
Mehdi Amini [Wed, 5 Oct 2016 01:41:06 +0000 (01:41 +0000)]
Use StringRef in ARMConstantPool APIs (NFC)
llvm-svn: 283293
Kyle Butt [Wed, 5 Oct 2016 01:39:29 +0000 (01:39 +0000)]
Revert "Codegen: Tail-duplicate during placement."
This reverts commit
062ace9764953e9769142c1099281a345f9b6bdc.
Issue with loop info and block removal revealed by polly.
I have a fix for this issue already in another patch, I'll re-roll this
together with that fix, and a test case.
llvm-svn: 283292
Mehdi Amini [Wed, 5 Oct 2016 01:37:29 +0000 (01:37 +0000)]
Use StringRef in FastISel API (NFC)
llvm-svn: 283291
Mehdi Amini [Wed, 5 Oct 2016 01:32:41 +0000 (01:32 +0000)]
Use StringRef in StringSaver API (NFC)
llvm-svn: 283290
Jim Ingham [Wed, 5 Oct 2016 01:19:15 +0000 (01:19 +0000)]
The collision of class C and libsystem_c.dylib:C is a failure
worth preserving, but not essential to the purpose of this test
so I broke it into a separate test.
llvm-svn: 283289
Mehdi Amini [Wed, 5 Oct 2016 01:15:04 +0000 (01:15 +0000)]
Use StringRef in ARCRuntimeEntryPoints APIs (NFC)
llvm-svn: 283288
Jim Ingham [Wed, 5 Oct 2016 01:09:43 +0000 (01:09 +0000)]
This test is failing because there's a global symbol "C" in libsystem_c.dylib,
and that is defeating the lookup of the "struct C" here. Adding the bug for that.
llvm-svn: 283287
Kostya Serebryany [Wed, 5 Oct 2016 01:09:40 +0000 (01:09 +0000)]
[libFuzzer] add ShrinkValueProfileTest, move code around, NFC
llvm-svn: 283286
Mehdi Amini [Wed, 5 Oct 2016 01:04:02 +0000 (01:04 +0000)]
Revert "Re-commit "Use StringRef in Support/Darf APIs (NFC)""
One test seems randomly broken: DebugInfo/X86/gnu-public-names.ll
llvm-svn: 283285
Mehdi Amini [Wed, 5 Oct 2016 01:02:34 +0000 (01:02 +0000)]
Use StringRef in MCSectionMachO (NFC)
llvm-svn: 283284
Mehdi Amini [Wed, 5 Oct 2016 01:02:22 +0000 (01:02 +0000)]
Use StringRef in DarwinAsmParser (NFC)
llvm-svn: 283283
Michael Zolotukhin [Wed, 5 Oct 2016 00:44:52 +0000 (00:44 +0000)]
[LoopDistribute] Fix a typo in the pass name.
llvm-svn: 283282
Mehdi Amini [Wed, 5 Oct 2016 00:37:18 +0000 (00:37 +0000)]
Re-commit "Use StringRef in Support/Darf APIs (NFC)"
This reverts commit r283278 and re-commit r283275 with
the update to fix the build on the LLDB side.
llvm-svn: 283281
Justin Lebar [Wed, 5 Oct 2016 00:27:38 +0000 (00:27 +0000)]
[CUDA] Add missing ':' to noexcept.cu test.
llvm-svn: 283280
Kostya Serebryany [Wed, 5 Oct 2016 00:25:17 +0000 (00:25 +0000)]
[libFuzzer] clear the corpus elements if they are evicted (i.e. smaller elements with proper coverage are found). Make sure we never try to mutate empty element. Print the corpus size in bytes in the status lines
llvm-svn: 283279
Mehdi Amini [Wed, 5 Oct 2016 00:21:14 +0000 (00:21 +0000)]
Revert "Use StringRef in Support/Darf APIs (NFC)"
This reverts commit r283275, it broke LLDB Android debug server.
llvm-svn: 283278
Mehdi Amini [Wed, 5 Oct 2016 00:15:18 +0000 (00:15 +0000)]
Use StringRef instead of raw pointers in ARMBuildAttrs (NFC)
llvm-svn: 283277
Jim Ingham [Wed, 5 Oct 2016 00:07:01 +0000 (00:07 +0000)]
Add the new minidump files to the Xcode project.
llvm-svn: 283276
Mehdi Amini [Tue, 4 Oct 2016 23:55:40 +0000 (23:55 +0000)]
Use StringRef in Support/Darf APIs (NFC)
llvm-svn: 283275
Kyle Butt [Tue, 4 Oct 2016 23:54:18 +0000 (23:54 +0000)]
Codegen: Tail-duplicate during placement.
The tail duplication pass uses an assumed layout when making duplication
decisions. This is fine, but passes up duplication opportunities that
may arise when blocks are outlined. Because we want the updated CFG to
affect subsequent placement decisions, this change must occur during
placement.
In order to achieve this goal, TailDuplicationPass is split into a
utility class, TailDuplicator, and the pass itself. The pass delegates
nearly everything to the TailDuplicator object, except for looping over
the blocks in a function. This allows the same code to be used for tail
duplication in both places.
This change, in concert with outlining optional branches, allows
triangle shaped code to perform much better, esepecially when the
taken/untaken branches are correlated, as it creates a second spine when
the tests are small enough.
Issue from previous rollback fixed, and a new test was added for that
case as well.
Differential revision: https://reviews.llvm.org/D18226
llvm-svn: 283274
Mehdi Amini [Tue, 4 Oct 2016 23:47:33 +0000 (23:47 +0000)]
Use StringRef in TableGen (NFC)
llvm-svn: 283273
Justin Lebar [Tue, 4 Oct 2016 23:41:49 +0000 (23:41 +0000)]
[CUDA] Mark device functions as nounwind.
Summary:
This prevents clang from emitting 'invoke's and catch statements.
Things previously mostly worked thanks to TryToMarkNoThrow() in
CodeGenFunction. But this is not a proper IPO, and it doesn't properly
handle cases like mutual recursion.
Fixes bug 30593.
Reviewers: tra
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D25166
llvm-svn: 283272
Justin Lebar [Tue, 4 Oct 2016 23:41:45 +0000 (23:41 +0000)]
[CUDA] Destroy deferred diagnostics before destroying the ASTContext's PartialDiagnostic allocator.
Summary:
This will let us (in a separate patch) allocate deferred diagnostics in
the ASTContext's PartialDiagnostic arena.
Reviewers: rnk
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D25260
llvm-svn: 283271
Kostya Serebryany [Tue, 4 Oct 2016 23:39:58 +0000 (23:39 +0000)]
[asan] When protect_shadow_gap=0, set up the shadow for the shadow gap. This is needed to support NVIDIA CUDA drivers. Unfortunately, I don't know how to test it properly with CUDA on a public build bot, so adding a test that emulates the CUDA behavior.
llvm-svn: 283270
Manuel Jacob [Tue, 4 Oct 2016 23:32:42 +0000 (23:32 +0000)]
[C API] Add LLVMConstExactUDiv and LLVMBuildExactUDiv functions.
Summary:
These are analog to the existing LLVMConstExactSDiv and LLVMBuildExactSDiv
functions.
Reviewers: deadalnix, majnemer
Subscribers: majnemer, llvm-commits
Differential Revision: https://reviews.llvm.org/D25259
llvm-svn: 283269
Mehdi Amini [Tue, 4 Oct 2016 23:31:39 +0000 (23:31 +0000)]
Use StringRef in TableGen emitted API for attribute (NFC)
llvm-svn: 283268
Rafael Espindola [Tue, 4 Oct 2016 22:43:38 +0000 (22:43 +0000)]
Update for llvm change.
llvm-svn: 283267
Rafael Espindola [Tue, 4 Oct 2016 22:43:25 +0000 (22:43 +0000)]
Misc improvements to StringTableBuilder.
This patch adds write methods to StringTableBuilder so that it is
easier to change the underlying implementation.
Using the write methods, avoid creating a temporary buffer when using
mmaped output.
It also uses a more compact key in the DenseMap. Overall this produces
a slightly faster lld:
firefox
master 6.
853419709
patch 6.
841968912 1.00167361138x faster
chromium
master 4.
297280174
patch 4.
298712163 1.00033323147x slower
chromium fast
master 1.
802335952
patch 1.
806872459 1.00251701521x slower
the gold plugin
master 0.3247149
patch 0.
321971644 1.00852017888x faster
clang
master 0.
551279945
patch 0.
543733194 1.01387951128x faster
llvm-as
master 0.
032743458
patch 0.
032143478 1.01866568391x faster
the gold plugin fsds
master 0.
350814247
patch 0.
348571741 1.00643341309x faster
clang fsds
master 0.6281672
patch 0.
621130222 1.01132931187x faster
llvm-as fsds
master 0.
030168899
patch 0.
029797155 1.01247582194x faster
scylla
master 3.
104222518
patch 3.
059590248 1.01458766252x faster
llvm-svn: 283266
Alina Sbirlea [Tue, 4 Oct 2016 22:39:53 +0000 (22:39 +0000)]
[cpu-detection] Copy simplified version of get_cpuid_max to remove dependency to clang's implementation
Summary:
Attempting to fix PR30384.
Take the same approach as in compiler_rt and add a simplified version of __get_cpuid_max.
Including cpuid.h is no longer needed.
Reviewers: echristo, joerg
Subscribers: mehdi_amini, llvm-commits
Differential Revision: https://reviews.llvm.org/D24597
llvm-svn: 283265
Albert Gutowski [Tue, 4 Oct 2016 22:29:49 +0000 (22:29 +0000)]
Separate builtins for x84-64 and i386; implement __mulh and __umulh
Summary: We need x86-64-specific builtins if we want to implement some of the MS intrinsics - winnt.h contains definitions of some functions for i386, but not for x86-64 (for example _InterlockedOr64), which means that we cannot treat them as builtins for both i386 and x86-64, because then we have definitions of builtin functions in winnt.h on i386.
Reviewers: thakis, majnemer, hans, rnk
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D24598
llvm-svn: 283264