Matt Arsenault [Thu, 11 Aug 2016 19:18:50 +0000 (19:18 +0000)]
AMDGPU: Prune includes
llvm-svn: 278391
Krzysztof Parzyszek [Thu, 11 Aug 2016 19:12:18 +0000 (19:12 +0000)]
[Hexagon] Standardize "select" pseudo-instructions
- PS_pselect: general register pairs
- PS_vselect: vector registers (+ 128B version)
- PS_wselect: vector register pairs (+ 128B version)
llvm-svn: 278390
Ivan Krasin [Thu, 11 Aug 2016 19:09:02 +0000 (19:09 +0000)]
WholeProgramDevirt: generate more detailed and accurate remarks.
Summary:
Keep track of all methods for which we have devirtualized at least
one call and then print them sorted alphabetically. That allows to
avoid duplicates and also makes the order deterministic.
Add optimization names into the remarks, so that it's easier to
understand how has each method been devirtualized.
Fix a bug when wrong methods could have been reported for
tryVirtualConstProp.
Reviewers: kcc, mehdi_amini
Differential Revision: https://reviews.llvm.org/D23297
llvm-svn: 278389
Marshall Clow [Thu, 11 Aug 2016 18:46:24 +0000 (18:46 +0000)]
Remove test for the sign of a NaN - doesn't work on MIPS, not strictly legal. Fixes bug 28936
llvm-svn: 278387
Pete Cooper [Thu, 11 Aug 2016 18:46:21 +0000 (18:46 +0000)]
Change all the libSystem test files to be dylibs instead of normalized files. Currently NFC.
A future commit will change when we choose to add an LC_LOAD_DYLIB to the final image. Currently
we do this when an atom is used, but we need to do it when a dylib is referenced on the cmdline as
this matches ld64.
To allow this change, libsystem (and other future yaml files representing dylibs) need to be dylibs
so that the loader can see to add them to the referenced dylib list.
llvm-svn: 278386
Pete Cooper [Thu, 11 Aug 2016 18:43:42 +0000 (18:43 +0000)]
Fix one more test missed by r278372. The next commit will update libsystem in a way which broke without this fix as it referenced the wrong file
llvm-svn: 278385
Wei Mi [Thu, 11 Aug 2016 18:42:56 +0000 (18:42 +0000)]
Remove the restriction that MachineSinking is now stopped by "insert_subreg,
subreg_to_reg, and reg_sequence" instructions.
This is to solve PR28852. The restriction was added at 2010 to make better register
coalescing. We assumed that it was not necessary any more. Testing results on x86
supported the assumption.
We will look closely to any performance impact it will bring and will be prepared
to help analyzing performance problem found on other architectures.
Differential Revision: https://reviews.llvm.org/D23210
llvm-svn: 278384
Krzysztof Parzyszek [Thu, 11 Aug 2016 18:42:06 +0000 (18:42 +0000)]
If-conversion incorrectly calculates liveness of redefined registers
Differential Revision: https://reviews.llvm.org/D23207
llvm-svn: 278383
Devin Coughlin [Thu, 11 Aug 2016 18:41:29 +0000 (18:41 +0000)]
[analyzer] Teach RetainCountChecker about CVFooRetain
Change the retain count checker to treat CoreFoundation-style "CV"-prefixed
reference types from CoreVideo similarly to CoreGraphics types. With this
change, we treat CVFooRetain() on a CVFooRef type as a retain. CVFooRelease()
APIs are annotated as consuming their parameter, so this change prevents false
positives about incorrect decrements of reference counts.
<rdar://problem/
27116090>
llvm-svn: 278382
Pete Cooper [Thu, 11 Aug 2016 18:41:14 +0000 (18:41 +0000)]
Fix off-by-one error in default currentVersion.
A version of 0x1000 is 0.16.0, not 1.0.0 as the comment said. Fix the
value to match the comment, and also the one test case which had this
wrong.
llvm-svn: 278381
Barnabas Bittner [Thu, 11 Aug 2016 18:34:29 +0000 (18:34 +0000)]
Test commit
llvm-svn: 278380
Bruno Cardoso Lopes [Thu, 11 Aug 2016 18:33:15 +0000 (18:33 +0000)]
[Sema] Add more strict check for sizeof diagnostics for bzero
Follow-up from r278264 after Joerg's feedback.
Since bzero is not standard, be more strict: also check if the first
argument is a pointer, which harden the check for when it does not come
originally from a builtin.
llvm-svn: 278379
Andrew Kaylor [Thu, 11 Aug 2016 18:28:33 +0000 (18:28 +0000)]
Target independent codesize heuristics for Loop Idiom Recognition
Patch by Sunita Marathe
Differential Revision: https://reviews.llvm.org/D21449
llvm-svn: 278378
Easwaran Raman [Thu, 11 Aug 2016 18:24:08 +0000 (18:24 +0000)]
Add a new method to create SimpleInliner instance and make pre-inliner use this.
This adds a createFunctionInliningPass pass that takes an InlineParams object and use this to create the pre-inliner pass. This prevents the regular inliner's threshold flag from influencing the preinliner.
Differential revision: https://reviews.llvm.org/D23377
llvm-svn: 278377
Krzysztof Parzyszek [Thu, 11 Aug 2016 18:15:16 +0000 (18:15 +0000)]
[Hexagon] Skip byval arguments when checking parameter attributes
From the point of view of register assignment, byval parameters are
ignored: a byval parameter is not going to be assigned to a register,
and it will not affect the assignments of subsequent parameters.
When matching registers with parameters in the bit tracker, make sure
to skip byval parameters before advancing the registers.
llvm-svn: 278375
Zachary Turner [Thu, 11 Aug 2016 18:10:40 +0000 (18:10 +0000)]
Modify coding conventions to mention include ordering.
llvm-svn: 278373
Pete Cooper [Thu, 11 Aug 2016 18:08:59 +0000 (18:08 +0000)]
Have one version of libSystem for each arch. NFC.
An upcoming commit will change how we choose to reference a dylib. Currently
dylibs are only given an LC_LOAD_DYLIB in the final image if an atom is used.
This is different from ld64 which adds the load command when the dylib is referenced
on the cmdline.
In order to change this behaviour, we need libSystem.yaml to actually contain a mach header
so that it is parsed as a dylib, instead of currently being parsed as a normalised file.
To get a mach header, we also require an arch, so now we have one libsystem per arch and
all the tests have been updated to choose the correct one.
llvm-svn: 278372
Dominic Chen [Thu, 11 Aug 2016 17:52:40 +0000 (17:52 +0000)]
Improve virtual register handling when computing debug information
Summary: Some backends, like WebAssembly, use virtual registers instead of physical registers. This crashes the DbgValueHistoryCalculator pass, which assumes that all registers are physical. Instead, skip virtual registers when iterating aliases, and assume that they are clobbered.
Reviewers: dexonsmith, dschuff, aprantl
Subscribers: yurydelendik, llvm-commits, jfb, sunfish
Differential Revision: https://reviews.llvm.org/D22590
llvm-svn: 278371
Michael Kuperstein [Thu, 11 Aug 2016 17:38:33 +0000 (17:38 +0000)]
Make TwoAddressInstructionPass::rescheduleMIBelowKill subreg-aware
This fixes PR28824.
Differential Revision: https://reviews.llvm.org/D23220
llvm-svn: 278370
Matt Arsenault [Thu, 11 Aug 2016 17:31:42 +0000 (17:31 +0000)]
AMDGPU: Fix crashes on memory functions
llvm-svn: 278369
Vedant Kumar [Thu, 11 Aug 2016 17:28:37 +0000 (17:28 +0000)]
[InstrumentationRuntime] Refactor the API (Part 2/N) (NFCI)
Factor out some common logic used to find the runtime library in a list
of modules.
Differential Revision: https://reviews.llvm.org/D23150
llvm-svn: 278368
Vedant Kumar [Thu, 11 Aug 2016 17:28:33 +0000 (17:28 +0000)]
[InstrumentationRuntime] Refactor the API (Part 1/N) (NFCI)
Adapters for instrumentation runtimes have to do two basic things:
1) Load a runtime library.
2) Install breakpoints in that library.
This logic is duplicated in the adapters for asan and tsan. Factor it
out and document bits of it to make it easier to add new adapters.
I tested this with check-lldb, and double-checked
testcases/functionalities/{a,t}san.
Differential Revision: https://reviews.llvm.org/D23043
llvm-svn: 278367
Matt Arsenault [Thu, 11 Aug 2016 17:22:59 +0000 (17:22 +0000)]
AArch64: Assert on analyzeBranch failing
llvm-svn: 278366
Michael Kuperstein [Thu, 11 Aug 2016 17:20:20 +0000 (17:20 +0000)]
[AliasSetTracker] Delete dead code
Deletes unused remove() and containsPointer() interfaces. NFC.
Differential Revision: https://reviews.llvm.org/D23360
llvm-svn: 278365
Eugene Zelenko [Thu, 11 Aug 2016 17:20:18 +0000 (17:20 +0000)]
Fix some Clang-tidy modernize and Include What You Use warnings.
Differential revision: https://reviews.llvm.org/D23291
llvm-svn: 278364
Teresa Johnson [Thu, 11 Aug 2016 17:19:53 +0000 (17:19 +0000)]
Add move ops to satisfy MSVC.
Try to appease MSVC bot:
http://lab.llvm.org:8011/builders/sanitizer-windows/builds/27164/steps/run%20tests/logs/stdio
llvm-svn: 278363
Matt Arsenault [Thu, 11 Aug 2016 17:15:32 +0000 (17:15 +0000)]
AMDGPU: Remove custom getSubReg
This was kind of confusing, the subregister
class shouldn't really be necessary.
llvm-svn: 278362
Matt Arsenault [Thu, 11 Aug 2016 17:15:28 +0000 (17:15 +0000)]
AMDGPU: Remove unused tracking of flat instructions
llvm-svn: 278361
Wei Ding [Thu, 11 Aug 2016 17:14:17 +0000 (17:14 +0000)]
AMDGPU : Fix SAD related instruction LIT tests function atttibute issues.
Differential Revision: http://reviews.llvm.org/D23133
llvm-svn: 278360
Simon Atanasyan [Thu, 11 Aug 2016 17:07:46 +0000 (17:07 +0000)]
[ELF][MIPS] Add more tests for ELF flags calculation. NFC
llvm-svn: 278359
Simon Atanasyan [Thu, 11 Aug 2016 17:07:43 +0000 (17:07 +0000)]
[ELF][MIPS] Separate different tests by empty lines. NFC
llvm-svn: 278358
Saleem Abdulrasool [Thu, 11 Aug 2016 16:58:12 +0000 (16:58 +0000)]
test: relax the FS test a slight bit to be more reliable
Some filesystems track atime always. This relaxes the test to accept either a
filesystem which does not accurately track atime or does track the atime
accurately. This allows the test to pass on filesystems mounted with
`strictatime` on Linux or on macOS.
llvm-svn: 278357
Sebastian Pop [Thu, 11 Aug 2016 16:51:48 +0000 (16:51 +0000)]
Add 'inline' attribute to __init to inline the basic_string's constructor
basic_string's constructor calls init which was not getting inlined. This
prevented optimization of const string as init would appear as a call in between
a string's def and use.
Patch by Laxman Sole and Aditya Kumar.
Differential Revision: https://reviews.llvm.org/D22782
llvm-svn: 278356
Duncan P. N. Exon Smith [Thu, 11 Aug 2016 16:40:03 +0000 (16:40 +0000)]
Hexagon: Avoid dereferencing end() in HexagonCopyToCombine::findPairable
Check for end() before skipping through debug values. This avoids
dereferencing end() when the instruction is the final one in the basic
block. (It still assumes that a debug value will not be the final
instruction in the basic block. No tests seemed to violate that.)
Many Hexagon tests trigger this, but they happen to magically pass right
now. I found this because WIP patches for PR26753 convert them into
crashes.
llvm-svn: 278355
Wei Ding [Thu, 11 Aug 2016 16:33:53 +0000 (16:33 +0000)]
AMDGPU : Add LLVM intrinsics for SAD related instructions.
Differential Revision: http://reviews.llvm.org/D23133
llvm-svn: 278354
Teresa Johnson [Thu, 11 Aug 2016 16:29:47 +0000 (16:29 +0000)]
Add (hopefully last) remaining missing dependences to llvm-lto2
There are still a few missing symbols reported by:
http://bb.pgr.jp/builders/i686-mingw32-RA-on-linux/builds/15535/steps/build_llvmclang/logs/stdio
http://bb.pgr.jp/builders/i686-mingw32-RA-on-linux/builds/15535/steps/build_llvmclang/logs/stdio
This should hopefully take care of them.
llvm-svn: 278353
Simon Atanasyan [Thu, 11 Aug 2016 16:25:17 +0000 (16:25 +0000)]
[ELF][MIPS] Recognize and print machine name in case of input incompatibility
llvm-svn: 278352
Tim Northover [Thu, 11 Aug 2016 16:21:29 +0000 (16:21 +0000)]
GlobalISel: clear vreg mapping after translating each function
Otherwise we only materialize (shared) constants in the first function they
appear in. This doesn't go well.
llvm-svn: 278351
Reid Kleckner [Thu, 11 Aug 2016 16:00:43 +0000 (16:00 +0000)]
Remove FIXME about asserting on the end iterator
After machine block placement, MBBs may not have terminators, and it is
appropriate to check for the end iterator here. We can fold the check
into the next if, as well. This look is really just looking for BBs that
end in CATCHRET.
llvm-svn: 278350
Teresa Johnson [Thu, 11 Aug 2016 15:58:49 +0000 (15:58 +0000)]
More missing llvm-lto2 dependencies
Follow-on to r278341: Update CMakeLists.txt to match LLVMBuild.txt
llvm-svn: 278349
Lang Hames [Thu, 11 Aug 2016 15:56:23 +0000 (15:56 +0000)]
[MCJIT] Improve documentation and error handling for MCJIT::runFunction.
ExecutionEngine::runFunction is supposed to allow execution of arbitrary
function types, but MCJIT can only reasonably support a limited subset of
main-linke function types. This patch documents this limitation, and fixes
MCJIT::runFunction to abort with a meaningful error at runtime if called with
an unsupported function type.
llvm-svn: 278348
Duncan P. N. Exon Smith [Thu, 11 Aug 2016 15:51:29 +0000 (15:51 +0000)]
X86: Use operator lookup for operator==, NFC
Avoid relying on the MachineInstrBundleIterator operator== being
implemented as a member function.
llvm-svn: 278347
Duncan P. N. Exon Smith [Thu, 11 Aug 2016 15:45:04 +0000 (15:45 +0000)]
IR: Don't cast the end iterator to Instruction*
End iterators are usually sentinels, not actually Instruction* at all.
Stop casting to it just to get an iterator back.
There is likely no observable functionality change here right now
(although this is relying on UB, I doubt it was triggering anything),
but I'll be removing the cast soon.
llvm-svn: 278346
Pavel Labath [Thu, 11 Aug 2016 15:31:30 +0000 (15:31 +0000)]
Fix unit tests on windows
Python headers need to be included before PosixApi.h
llvm-svn: 278345
Duncan P. N. Exon Smith [Thu, 11 Aug 2016 15:29:02 +0000 (15:29 +0000)]
CodeGen: Check for a terminator in llvm::getFuncletMembership
Check for an end iterator from MachineBasicBlock::getFirstTerminator in
llvm::getFuncletMembership. If this is turned into an assertion, it
fires in 48 X86 testcases (for example,
CodeGen/X86/regalloc-spill-at-ehpad.ll).
Since this is likely a latent bug (shouldn't all basic blocks end with a
terminator?) I've filed PR28938.
llvm-svn: 278344
Matthew Simpson [Thu, 11 Aug 2016 15:28:45 +0000 (15:28 +0000)]
[SLP] Make RecursionMaxDepth a command line option (NFC)
llvm-svn: 278343
Sanjay Patel [Thu, 11 Aug 2016 15:23:56 +0000 (15:23 +0000)]
fix comment; NFC
llvm-svn: 278342
Teresa Johnson [Thu, 11 Aug 2016 15:23:05 +0000 (15:23 +0000)]
Fix bot failure from r278338 due to missing dependences
Add some missing dependences to the llvm-lto2 tool to attempt to appease
missing symbols in link from bot:
http://bb.pgr.jp/builders/i686-mingw32-RA-on-linux/builds/15527
llvm-svn: 278341
Sanjay Patel [Thu, 11 Aug 2016 15:21:21 +0000 (15:21 +0000)]
use auto* with dyn_cast ; NFC
llvm-svn: 278340
Sanjay Patel [Thu, 11 Aug 2016 15:16:06 +0000 (15:16 +0000)]
getParent()->getParent() == getFunction() ; NFC
llvm-svn: 278339
Teresa Johnson [Thu, 11 Aug 2016 14:58:12 +0000 (14:58 +0000)]
Restore "Resolution-based LTO API."
This restores commit r278330, with fixes for a few bot failures:
- Fix a late change I had made to the save temps output file that I
missed due to existing files sitting on my disk
- Fix a bunch of Windows bot failures with "ambiguous call to overloaded
function" due to confusion between llvm::make_unique vs
std::make_unique (preface the new make_unique calls with "llvm::")
- Attempt to fix a modules bot failure by adding a missing include
to LTO/Config.h.
Original change:
Resolution-based LTO API.
Summary:
This introduces a resolution-based LTO API. The main advantage of this API over
existing APIs is that it allows the linker to supply a resolution for each
symbol in each object, rather than the combined object as a whole. This will
become increasingly important for use cases such as ThinLTO which require us
to process symbol resolutions in a more complicated way than just adjusting
linkage.
Patch by Peter Collingbourne.
Reviewers: rafael, tejohnson, mehdi_amini
Subscribers: lhames, tejohnson, mehdi_amini, llvm-commits
Differential Revision: https://reviews.llvm.org/D20268
llvm-svn: 278338
Ehsan Amiri [Thu, 11 Aug 2016 14:51:14 +0000 (14:51 +0000)]
revert 278334
llvm-svn: 278337
Valery Pykhtin [Thu, 11 Aug 2016 14:22:05 +0000 (14:22 +0000)]
Revert "[AMDGPU] fix failure on printing of non-existing instruction operands."
This reverts revision 278333, newly added test failed.
llvm-svn: 278336
Pavel Labath [Thu, 11 Aug 2016 14:12:10 +0000 (14:12 +0000)]
Make sure files include what they use (part 2/2)
This makes lldb still compile on linux after a project-wide clang-format
llvm-svn: 278335
Ehsan Amiri [Thu, 11 Aug 2016 13:51:20 +0000 (13:51 +0000)]
Extend trip count instead of truncating IV in LFTR, when legal
When legal, extending trip count in the loop control logic generates better code compared to truncating IV. This is because
(1) extending trip count is a loop invariant operation (see genLoopLimit where we prove trip count is loop invariant).
(2) Scalar Evolution seems to have problems understanding trunc when computing loop trip count. So removing them allows better analysis performed in Scalar Evolution. (In particular this fixes PR 28363 which is the motivation for this change).
I am not going to perform any performance test. Any degradation caused by this should be an indication of a bug elsewhere.
To prove legality, we rely on SCEV to prove zext(trunc(IV)) == IV (or similarly for sext). If this holds, we can prove equivalence of trunc(IV)==ExitCnt (1) and IV == zext(ExitCnt). Simply take zext of boths sides of (1) and apply the proven equivalence.
https://reviews.llvm.org/D23075
llvm-svn: 278334
Valery Pykhtin [Thu, 11 Aug 2016 13:49:46 +0000 (13:49 +0000)]
[AMDGPU] fix failure on printing of non-existing instruction operands.
Differential revision: https://reviews.llvm.org/D23323
llvm-svn: 278333
Andrey Churbanov [Thu, 11 Aug 2016 13:04:00 +0000 (13:04 +0000)]
Fixes for hierarchical barrier (possible hang if team size changed).
Differential Revision: http://reviews.llvm.org/D23175
llvm-svn: 278332
Teresa Johnson [Thu, 11 Aug 2016 13:03:56 +0000 (13:03 +0000)]
Revert "Resolution-based LTO API."
This reverts commit r278330.
I made a change to the save temps output that is causing issues with the
bots. Didn't realize this because I had older output files sitting on
disk in my test output directory.
llvm-svn: 278331
Teresa Johnson [Thu, 11 Aug 2016 12:56:40 +0000 (12:56 +0000)]
Resolution-based LTO API.
Summary:
This introduces a resolution-based LTO API. The main advantage of this API over
existing APIs is that it allows the linker to supply a resolution for each
symbol in each object, rather than the combined object as a whole. This will
become increasingly important for use cases such as ThinLTO which require us
to process symbol resolutions in a more complicated way than just adjusting
linkage.
Patch by Peter Collingbourne.
Reviewers: rafael, tejohnson, mehdi_amini
Subscribers: lhames, tejohnson, mehdi_amini, llvm-commits
Differential Revision: https://reviews.llvm.org/D20268
Address review comments
llvm-svn: 278330
Simon Pilgrim [Thu, 11 Aug 2016 12:19:43 +0000 (12:19 +0000)]
Fixed VS2015 (Update 3) warning - differing const/volatile qualifiers for overridden function
Dropped the const qualifier to match llvm::CallLowering::lowerCall
llvm-svn: 278329
Igor Breger [Thu, 11 Aug 2016 12:13:46 +0000 (12:13 +0000)]
[AVX512] Fix extractelement i1 lowering.
The previous implementation (not custom) doesn't enforce zeroing off upper bits. The assumption is that i1 PRODUCER (truncate and extractelement) must zero all upper bits, so i1 CONSUMER instructions ( test, zext, save, etc) can be done without additional zeroing.
Make extractelement i1 lowering custom for all vector i1.
Differential Revision: http://reviews.llvm.org/D23246
llvm-svn: 278328
Davide Italiano [Thu, 11 Aug 2016 10:50:01 +0000 (10:50 +0000)]
[Core] Retire addReplacement() member function.
llvm-svn: 278327
Omair Javaid [Thu, 11 Aug 2016 10:35:05 +0000 (10:35 +0000)]
Make sure LldbGdbServerTestCase is built in arm mode to avoid failures due thumb instructions
Differential revision: https://reviews.llvm.org/D23395
llvm-svn: 278326
Pavel Labath [Thu, 11 Aug 2016 09:22:22 +0000 (09:22 +0000)]
Remove a double send of eRunPacketSent event
I accidentaly added the send both to the base class and the derived class in my refactor. Fix
that.
llvm-svn: 278325
Kirill Bobyrev [Thu, 11 Aug 2016 08:18:39 +0000 (08:18 +0000)]
[clang-tidy] fix readability-else-after-return test
As pointed by Yung Douglas, exceptions in
test/clang-tidy/readability-else-after-return.cpp are causing PS4 bots to be
red, because exceptions aren't enabled by default on PS4 target. This patch is a
fix.
llvm-svn: 278324
Eric Fiselier [Thu, 11 Aug 2016 08:15:35 +0000 (08:15 +0000)]
Unbreak C++03 build.
llvm-svn: 278323
Eugene Leviant [Thu, 11 Aug 2016 07:56:43 +0000 (07:56 +0000)]
[ELF] Symbol assignment within output section description
llvm-svn: 278322
Marina Yatsina [Thu, 11 Aug 2016 07:32:08 +0000 (07:32 +0000)]
Avoid false dependencies of undef machine operands
This patch helps avoid false dependencies on undef registers by updating the machine instructions' undef operand to use a register that the instruction is truly dependent on, or use a register with clearance higher than Pref.
Pseudo example:
loop:
xmm0 = ...
xmm1 = vcvtsi2sdl eax, xmm0<undef>
... = inst xmm0
jmp loop
In this example, selecting xmm0 as the undef register creates false dependency between loop iterations.
This false dependency cannot be solved by inserting an xor before vcvtsi2sdl because xmm0 is alive at the point of the vcvtsi2sdl instruction.
Selecting a different register instead of xmm0, especially a register that is not used in the loop, will eliminate this problem.
Differential Revision: https://reviews.llvm.org/D22466
llvm-svn: 278321
Amjad Aboud [Thu, 11 Aug 2016 07:22:53 +0000 (07:22 +0000)]
[Debug Info] Added a LIT test that covers the fix committed in rL277290.
Differential Revision: http://reviews.llvm.org/D23056
llvm-svn: 278320
Eric Fiselier [Thu, 11 Aug 2016 07:04:14 +0000 (07:04 +0000)]
Refactor test archetypes implementation.
llvm-svn: 278319
Craig Topper [Thu, 11 Aug 2016 06:04:07 +0000 (06:04 +0000)]
[AVX-512] Promote 512-bit integer loads to v8i64 similar to what is done for 128/256-bit vectors for overall consistency.
llvm-svn: 278318
Craig Topper [Thu, 11 Aug 2016 06:04:04 +0000 (06:04 +0000)]
[AVX-512] Add patterns to allow EVEX encoded stores of v16i16/v8i16/v16i8/v32i8 even when BWI is not supported.
llvm-svn: 278317
Craig Topper [Thu, 11 Aug 2016 06:04:00 +0000 (06:04 +0000)]
[AVX-512] Fix the 128-bit and 256-bit nontemporal load patterns with elements type other than i64. These loads have all been promoted to v2i64/v4i64 loads so we need bitcasts or we end up selecting VMOVDQA32/VMOVDQU32 instead.
llvm-svn: 278316
Saleem Abdulrasool [Thu, 11 Aug 2016 05:31:07 +0000 (05:31 +0000)]
bindings: expose diagnostic formatting to Python
This makes it easier for tools using the Python libclang bindings to display
diagnostics in a manner consistent with clang.
Patch by Omar Sandoval!
llvm-svn: 278315
Xinliang David Li [Thu, 11 Aug 2016 05:09:30 +0000 (05:09 +0000)]
[Profile] improve warning control option
Change --no-pgo-warn-missing to -pgo-warn-missing-function
and negate the default. /NFC
Add more test to make sure the warning is off by default
llvm-svn: 278314
Dominic Chen [Thu, 11 Aug 2016 04:10:56 +0000 (04:10 +0000)]
[WebAssembly] Cleanup trailing whitespace
Summary: Test for commit access.
Subscribers: jfb, dschuff
Differential Revision: https://reviews.llvm.org/D23392
llvm-svn: 278313
Easwaran Raman [Thu, 11 Aug 2016 03:58:05 +0000 (03:58 +0000)]
Make more fields of InlineParams Optional.
Differential revision: https://reviews.llvm.org/D23386
llvm-svn: 278312
Eric Fiselier [Thu, 11 Aug 2016 03:33:41 +0000 (03:33 +0000)]
Add missing REQUIRES for C++14
llvm-svn: 278311
Eric Fiselier [Thu, 11 Aug 2016 03:13:11 +0000 (03:13 +0000)]
[libcxx] Add std::any
Summary:
This patch adds std::any by moving/adapting <experimental/any>.
This patch also implements the std::any parts of p0032r3 (http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2016/p0032r3.pdf)
and LWG 2509 (http://cplusplus.github.io/LWG/lwg-defects.html#2509).
I plan to push it in a day or two if there are no comments.
Reviewers: mclow.lists, EricWF
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D22733
llvm-svn: 278310
Sanjoy Das [Thu, 11 Aug 2016 00:56:46 +0000 (00:56 +0000)]
[Statepoints] Minor cosmetic change; NFC
The verification failure message was missing a space.
llvm-svn: 278309
Evgeniy Stepanov [Thu, 11 Aug 2016 00:26:29 +0000 (00:26 +0000)]
[asan] abort_on_error=1 by default on Android.
With this change, the default behavior on error is to call abort()
instead of _exit(). This should help the OS to capture a tombstone of
the error.
RAM usage of the lit test suite goes up because of all the tombstone
gathering, so I'm limiting the parallelism of the test target.
Previously it was based on the number of the CPUs on the host
machine, which is definitely wrong.
llvm-svn: 278308
Chris Bieneman [Thu, 11 Aug 2016 00:20:03 +0000 (00:20 +0000)]
[MachOYAML] Don't output empty ExportTrie
The YAML representation was always outputting the root node of an export trie even if the trie was empty. While this doesn't really have any functional impact, it does add visual clutter to the yaml file.
llvm-svn: 278307
Chris Bieneman [Thu, 11 Aug 2016 00:19:51 +0000 (00:19 +0000)]
[Order Files] Don't use empty order files
LD64 does optimization on symbol layouts that gets disabled whenever an order file is passed (even if it is empty). This change prevents disabling that optimization, and still enables iterative generation and usage of order files.
If the order file is empty it does not setup the order file flags, instead it sets the empty order file as a configuration dependency. When the order file changes it will then trigger a re-configuration that adds the linker flag.
llvm-svn: 278306
Jim Ingham [Thu, 11 Aug 2016 00:15:28 +0000 (00:15 +0000)]
dlopen & dlclose can't throw C++ or ObjC exceptions, so don't do the extra work of
setting & deleting the breakpoints to watch for this.
<rdar://problem/
27780214>
llvm-svn: 278305
Greg Clayton [Wed, 10 Aug 2016 23:25:57 +0000 (23:25 +0000)]
Fix a problem where if a uint64_t value is placed into a python dictionary and sent up to LLDB and converted to StructuredData, it would not be able to parse the full 64 bit value. A number like 0xf000000000000000L could be placed into a dictionary, and sent to LLDB and it would end up being 0xffffffffffffffff since it would overflow a int64_t. We leave the old code there, but if it overflows, we treat the number like a uint64_t and get it to decode correctly. Added a gtest to cover this so we don't regress. I verified the gtest failed prior to the fix, and it succeeds after it.
<rdar://problem/
27409265>
llvm-svn: 278304
Tim Northover [Wed, 10 Aug 2016 23:02:41 +0000 (23:02 +0000)]
GlobalISel: support same ConstantExprs as Instructions.
It's more than just inttoptr, but the others can't be tested until we have
support for non-trivial constants (they currently get unavoidably folded to a
ConstantInt).
llvm-svn: 278303
Greg Clayton [Wed, 10 Aug 2016 22:55:26 +0000 (22:55 +0000)]
Make pascal debugging work again.
<rdar://problem/
27652051>
llvm-svn: 278302
Eric Fiselier [Wed, 10 Aug 2016 22:45:26 +0000 (22:45 +0000)]
Implement LWG 2148: Make non-enum default hash specialization well-formed
Summary:
This patch removes the static_assert for non-enum types in the primary hash template. Instead non-enum types create a hash<T> specialization that is not constructible nor callable.
See also:
* http://cplusplus.github.io/LWG/lwg-active.html#2543
* https://llvm.org/bugs/show_bug.cgi?id=28917
Reviewers: mclow.lists, EricWF
Subscribers: mehdi_amini, cfe-commits
Differential Revision: https://reviews.llvm.org/D23331
llvm-svn: 278300
Greg Clayton [Wed, 10 Aug 2016 22:43:48 +0000 (22:43 +0000)]
Centralize all select() calls into one place so that we can take advantage of system specific optimizations to deal with more file descriptors than FD_SETSIZE on some systems.
<rdar://problem/
25325383>
https://reviews.llvm.org/D22950
llvm-svn: 278299
Tim Shen [Wed, 10 Aug 2016 22:35:38 +0000 (22:35 +0000)]
[ADT] Move LLVM_ATTRIBUTE_UNUSED_RESULT to the function, otherwise gcc 4.8 complains about it.
It's a fix for the original patch r278251.
llvm-svn: 278298
Lang Hames [Wed, 10 Aug 2016 22:15:09 +0000 (22:15 +0000)]
[lld][MachO] Fix LC_SEGEMENT[_64] filesize computation in -r mode.
Using vmsize to populate this file works when outputing MachO images, but fails
when outputting relocatable objects. This patch fixes the computation to use
file offsets, which works for both output types.
Fixes <rdar://problem/
27727666>
llvm-svn: 278297
Tim Northover [Wed, 10 Aug 2016 22:13:48 +0000 (22:13 +0000)]
GlobalISel: add tests forgotten in r278293.
llvm-svn: 278296
Eugene Zelenko [Wed, 10 Aug 2016 22:00:49 +0000 (22:00 +0000)]
[Documentation] Improve consistency.
Mention Clang-rename Emacs integration in release notes.
llvm-svn: 278295
Sanjoy Das [Wed, 10 Aug 2016 21:48:24 +0000 (21:48 +0000)]
[LangRef] Fix formatting (no semantic change)
llvm-svn: 278294
Tim Northover [Wed, 10 Aug 2016 21:44:01 +0000 (21:44 +0000)]
GlobalISel: implement simple function calls on AArch64.
We're still limited in the arguments we support, but this at least handles the
basic cases.
llvm-svn: 278293
Adhemerval Zanella [Wed, 10 Aug 2016 21:39:28 +0000 (21:39 +0000)]
tsan: Remove __pointer_chk_guard@GLIBC_PRIVATE requirement for AArch64
Current AArch64 {sig}{set,long}jmp interposing requires accessing glibc
private __pointer_chk_guard to get process xor mask to demangled the
internal {sig}jmp_buf function pointers.
It causes some packing issues, as described in gcc PR#71042 [1], and is
is not a godd practice to rely on a private glibc namespace (since ABI is
not meant to be stable).
This patch fixes it by changing how libtsan obtains the guarded pointer
value: at initialization a specific routine issues a setjmp call and
using the mangled function pointer and the original value derive the
random guarded pointer.
Checked on aarch64 39-bit VMA.
[1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71042
llvm-svn: 278292
Changpeng Fang [Wed, 10 Aug 2016 21:15:30 +0000 (21:15 +0000)]
AMDGPU/SI: Implement amdgcn image intrinsics with sampler
Summary:
This patch define and implement amdgcn image intrinsics with sampler.
1. define vdata type to be llvm_anyfloat_ty, address type to be llvm_anyfloat_ty,
and rsrc type to be llvm_anyint_ty. As a result, we expect the intrinsics name
to have three suffixes to overload each of these three types;
2. D128 as well as two other flags are implied in the three types, for example,
if you use v8i32 as resource type, then r128 is 0!
3. don't expose TFE flag, and other flags are exposed in the instruction order:
unrm, glc, slc, lwe and da.
Differential Revision: http://reviews.llvm.org/D22838
Reviewed by:
arsenm and tstellarAMD
llvm-svn: 278291
Piotr Padlewski [Wed, 10 Aug 2016 21:15:22 +0000 (21:15 +0000)]
Changed sign of LastCallToStaticBouns
Summary:
I think it is much better this way.
When I firstly saw line:
Cost += InlineConstants::LastCallToStaticBonus;
I though that this is a bug, because everywhere where the cost is being reduced
it is usuing -=.
Reviewers: eraman, tejohnson, mehdi_amini
Subscribers: llvm-commits, mehdi_amini
Differential Revision: https://reviews.llvm.org/D23222
llvm-svn: 278290
Todd Fiala [Wed, 10 Aug 2016 21:07:48 +0000 (21:07 +0000)]
xfailed TestObjCNewSyntax.py on macOS for gmodules
Tracked by:
rdar://
27792848
llvm-svn: 278289
Kyle Butt [Wed, 10 Aug 2016 21:03:27 +0000 (21:03 +0000)]
Codegen: Don't tail-duplicate blocks with un-analyzable fallthrough.
If AnalyzeBranch can't analyze a block and it is possible to
fallthrough, then duplicating the block doesn't make sense, as only one
block can be the layout predecessor for the un-analyzable fallthrough.
Submitted wit a test case, but NOTE: the test case doesn't currently
fail. However, the test case fails with D20505 and would have saved me
some time debugging.
llvm-svn: 278288