summaryrefslogtreecommitdiffstats
path: root/llvm/lib
Commit message (Collapse)AuthorAgeFilesLines
* Optimize concat_vectors(X, undef) -> scalar_to_vector(X).Nadav Rotem2013-10-253-48/+33
| | | | | | | This optimization is not SSE specific so I am moving it to DAGco. The new scalar_to_vector dag node exposed a missing pattern in the AArch64 target that I needed to add. llvm-svn: 193393
* llvm-cov dump to dbgs() instead of outs().Yuchen Wu2013-10-251-13/+14
| | | | llvm-svn: 193390
* Support for reading program counts in llvm-cov.Yuchen Wu2013-10-251-12/+17
| | | | | | | | | | | | | llvm-cov will now be able to read program counts from the GCDA file and output it in the same format as gcov. The program summary tag was identified from gcov-io.h as "\0\0\0\a3". There is currently a bug in GCOVProfiling.cpp which does not generate the run- or program-counting IR, so this change was tested manually by modifying the GCDA file and comparing the gcov and llvm-cov outputs. llvm-svn: 193389
* ARM: Tweak usage of '*vfp' compiler_rt functions.Jim Grosbach2013-10-241-1/+2
| | | | | | | | | Only use them if the subtarget has ARM mode, as these routines are implemented as ARM code. rdar://15302004 llvm-svn: 193381
* MCStreamer: Reimplement the virtual EmitRawText as a protected member, ↵David Blaikie2013-10-243-6/+5
| | | | | | | | | | EmitRawTextImpl, to avoid string literal ambiguities Also improve the implementation of EmitRawText(Twine) so it doesn't bother using the SmallString buffer if the Twine is a simple StringRef anyway. llvm-svn: 193378
* DWARF emission: Remove unnecessary/redundant DIE reference codeDavid Blaikie2013-10-241-7/+0
| | | | | | The default case at the end of the switch handles this just fine. llvm-svn: 193374
* Fix name of variable in comment.Eric Christopher2013-10-241-1/+1
| | | | llvm-svn: 193373
* Grammar.Eric Christopher2013-10-241-1/+1
| | | | llvm-svn: 193372
* Update misleading comment.Eric Christopher2013-10-241-2/+3
| | | | llvm-svn: 193371
* DIEHash: Const correct and use references where non-null/non-rebound.David Blaikie2013-10-243-49/+49
| | | | llvm-svn: 193363
* DIEHash: Do not use shallow type hashing for unnamed typesDavid Blaikie2013-10-241-4/+6
| | | | llvm-svn: 193361
* DIEHash: Refactor ref attribute hashing into smaller functionsDavid Blaikie2013-10-243-68/+98
| | | | llvm-svn: 193360
* Remove unused debug-only member variable.David Blaikie2013-10-241-4/+0
| | | | | | | This may've been used at some point but the 'print' member function grew an Indent parameter that entirely shadows this parameter. llvm-svn: 193358
* Remove class abstraction from ARM struct byval loweringDavid Peixotto2013-10-241-553/+262
| | | | | | | | | | | This commit changes the struct byval lowering for arm to use inline checks for the subtarget instead of a class abstraction to represent the differences. The class abstraction was judged to be too much code for this task. No intended functionality change. llvm-svn: 193357
* Inliner: Handle readonly attribute per argument when adding memcpyTom Stellard2013-10-241-10/+13
| | | | | | Patch by: Vincent Lejeune llvm-svn: 193356
* ARM: Mark double-precision instructions as suchTim Northover2013-10-243-45/+66
| | | | | | | | | | | | This prevents us from silently accepting invalid instructions on (for example) Cortex-M4 with just single-precision VFP support. No tests for the extra Pat Requires because they're essentially assertions: the affected code should have been lowered to libcalls before ISel. rdar://problem/15302004 llvm-svn: 193354
* Reverting my r193344 checkin due to build breakage.John Thompson2013-10-241-11/+0
| | | | llvm-svn: 193350
* Mark vector loops as already vectorizedRenato Golin2013-10-241-0/+4
| | | | | | | | Make sure we mark all loops (scalar and vector) when vectorizing, so that we don't try to vectorize them anymore. Also, set unroll to 1, since this is what we check for on early exit. llvm-svn: 193349
* Added std::string as a built-in type for mapping.John Thompson2013-10-241-0/+11
| | | | llvm-svn: 193344
* ARM: add a couple more NEON predicates.Tim Northover2013-10-241-4/+4
| | | | | | | | The fused multiply instructions were added in VFPv4 but are still NEON instructions, in particular they shouldn't be available on a Cortex-M4 not matter how floaty it is. llvm-svn: 193342
* ARM: mark various aliases with their architecture requirements.Tim Northover2013-10-242-8/+12
| | | | | | | | | | If an alias inherits directly from InstAlias then it doesn't get any default "Requires" values, so llvm-mc will allow it even on architectures that don't support the underlying instruction. This tidies up the obvious VFP and NEON cases I found. llvm-svn: 193340
* ARM: Use non-VFP softcalls on embedded Darwinish targetsTim Northover2013-10-241-1/+1
| | | | | | | | | | | | | The compiler-rt functions __adddf3vfp and so on exist purely to allow Thumb1 code to make use of VFP instructions by switching back to ARM mode, they make no sense for M-class processors which don't even have an ARM mode. Given that justification, in practice this is a platform ABI decision so the actual check is based on that rather than CPU features. rdar://problem/15302004 llvm-svn: 193327
* Replaced non-ASCII character.Yaron Keren2013-10-241-1/+1
| | | | llvm-svn: 193324
* Revert part of r193291, restoring the deletion of loaded objects.Chandler Carruth2013-10-241-0/+9
| | | | | | | | | | | Without this, customers of the MCJIT were leaking memory like crazy. It's not really clear what the *right* memory management is here, so I'm not trying to add lots of tests or other logic, just trying to get us back to a better baseline. I'll follow up on the original commit to figure out the right path forward. llvm-svn: 193323
* ARM: fix assert on unpredictable POP instruction.Tim Northover2013-10-241-3/+2
| | | | | | | | | | | POP instructions are aliased to the ARM LDM variants but have different syntax. This caused two problems: we tried to access a non-existent operand to annotate the '!', and the error message didn't make much sense. With some vigorous hand-waving in the error message both problems can be fixed. llvm-svn: 193322
* Make sure SP is always aligned on a 2 byte boundaryJob Noorman2013-10-241-2/+2
| | | | llvm-svn: 193320
* fix PR17635: false positive with packed structuresNuno Lopes2013-10-242-4/+7
| | | | | | LLVM optimizers may widen accesses to packed structures that overflow the structure itself, but should be in bounds up to the alignment of the object llvm-svn: 193317
* [AArch64] Fix NZCV reg live-in bug in F128CSEL codegen.Amara Emerson2013-10-241-2/+6
| | | | | | | | | When generating the IfTrue basic block during the F128CSEL pseudo-instruction handling, the NZCV live-in for the newly created BB wasn't being added. This caused a fault during MI-sched/live range calculation when the predecessor for the fall-through BB didn't have a live-in for phys-reg as expected. llvm-svn: 193316
* AVX-512: added VCVTPH2PS, VCVTPS2PH with intrinsicsElena Demikhovsky2013-10-241-0/+36
| | | | llvm-svn: 193312
* Fix a bug in LinearFunctionTestReplace that created invalid loop exit checks.Juergen Ributzka2013-10-241-1/+7
| | | | | | Reviewed by Andy llvm-svn: 193303
* Fixed llvm-cov to count edges instead of blocks.Yuchen Wu2013-10-241-2/+11
| | | | | | | | | | | | | | | | | This was a fundamental flaw in llvm-cov where it treated the values in the GCDA files as block counts instead of edge counts. This created incorrect line counts when branching was present. Instead, the edge counts should be summed to obtain the correct block count. The fix was tested using custom test files as well as single source files from the test-suite directory. The behaviour can be verified by reading the GCOV documentation that describes the GCDA spec ("ARC_COUNTS gives the counter values for those arcs that are instrumented") and the header description provided by GCOVProfiling.cpp ("instruments the code that runs to records (sic) the edges between blocks that run and emit a complementary "gcda" file on exit"). llvm-svn: 193299
* Clarify comments in genLoopLimit.Andrew Trick2013-10-241-3/+4
| | | | llvm-svn: 193292
* Optimizing MCJIT module state trackingAndrew Kaylor2013-10-242-122/+209
| | | | | | Patch co-developed with Yaron Keren. llvm-svn: 193291
* (this is a corrected patch)Yaron Keren2013-10-233-2/+4
| | | | | | | | | | | | | | Calling _chkstk is required on ELF as well as COFF on Windows. Without _chkstk, functions requiring large stack crash in initialization code. Previous code tested for COFF format but not Mach-O and this patch modifies the code to test for Windows OS (both Windows target and MingW target) but not Mach-O object format: Looks like macho environment was used to build some EFI code. Credits to Andrew MacPherson. llvm-svn: 193289
* Debug Info: code clean up.Manman Ren2013-10-232-31/+23
| | | | | | | | | | | Since we never insert DIE for DITemplateTypeParameter to a map, there is no need to call getDIE in getOrCreateTemplateTypeParameterDIE. It is also renamed to constructTemplateTypeParameterDIE to match with other construct functions in CompileUnit. Same applies to getOrCreateTemplateValueParameterDIE. llvm-svn: 193287
* Debug Info: code clean up.Manman Ren2013-10-232-5/+5
| | | | | | | Rename createMemberDIE to constructMemberDIE to match other construct functions in CompileUnit. llvm-svn: 193286
* Debug Info: code clean up.Manman Ren2013-10-232-18/+12
| | | | | | | Remove the unneeded return values from createMemberDIE, constructEnumTypeDIE, getOrCreateTemplateTypeParameterDIE, and getOrCreateTemplateValueParameterDIE. llvm-svn: 193285
* Debug Info: code clean up.Manman Ren2013-10-232-18/+18
| | | | | | | | | Unifying the argument ordering of private construct functions in CompileUnit to follow constructTypeDIE(DIE &, DIBasicType), constructTypeDIE(DIE &, DIDerivedType), constructTypeDIE(DIE &, DICompositeType), constructSubrangeDIE and constructArrayTypeDIE. llvm-svn: 193284
* Remove {} from one-line block.Manman Ren2013-10-231-2/+1
| | | | llvm-svn: 193276
* Revert "Calling _chkstk is required on ELF as well as COFF on Windows. ↵Rafael Espindola2013-10-233-4/+2
| | | | | | | | | | Without _chkstk functions requiring large stack crash in initialization code. Previous code tested for COFF format but not Mach-O and this patch modifies the code to test for Windows." This reverts commit r193263. It is causing CodeGen/X86/mingw-alloca.ll to fail. llvm-svn: 193275
* Reduce casting and use a fully covered switch.Rafael Espindola2013-10-231-9/+14
| | | | llvm-svn: 193272
* X86: Custom lower sext v16i8 to v16i16, and the corresponding truncate.Benjamin Kramer2013-10-233-6/+14
| | | | | | Also update the cost model. llvm-svn: 193270
* Fixed comment typo in GCOVProfiling.cppYuchen Wu2013-10-231-1/+1
| | | | llvm-svn: 193268
* Use a map instead of vector to store line counts.Yuchen Wu2013-10-231-22/+10
| | | | | | | | | | | | There are a few motivations for this: - Using a map allows for checking if line is in map. This differentiates unexecutable lines (such as comments) from unexecuted logical lines of code. "#####" is now outputted in this case, in line with gcov. - Source files are no longer read in twice: once when storing the line counts, and once when outputting the data. - Greatly simplifies the function FileInfo::addLineCount(). llvm-svn: 193264
* Calling _chkstk is required on ELF as well as COFF on Windows. Yaron Keren2013-10-233-2/+4
| | | | | | | | | | Without _chkstk functions requiring large stack crash in initialization code. Previous code tested for COFF format but not Mach-O and this patch modifies the code to test for Windows. Credits to Andrew MacPherson. llvm-svn: 193263
* X86: Custom lower zext v16i8 to v16i16.Benjamin Kramer2013-10-232-19/+8
| | | | | | | | | | | | | | | | | On sandy bridge (PR17654) we now get vpxor %xmm1, %xmm1, %xmm1 vpunpckhbw %xmm1, %xmm0, %xmm2 vpunpcklbw %xmm1, %xmm0, %xmm0 vinsertf128 $1, %xmm2, %ymm0, %ymm0 On haswell it's a simple vpmovzxbw %xmm0, %ymm0 There is a maze of duplicated and dead transforms and patterns in this area. Remove the dead custom lowering of zext v8i16 to v8i32, that's already handled by LowerAVXExtend. llvm-svn: 193262
* Fix PR17631Michael Liao2013-10-231-1/+10
| | | | | | | | | - Skip instructions added in prolog. For specific targets, prolog may insert helper function calls (e.g. _chkstk will be called when there're more than 4K bytes allocated on stack). However, these helpers don't use/def YMM/XMM registers. llvm-svn: 193261
* X86: Make concat_vectors combine a bit more conservative.Jim Grosbach2013-10-231-0/+6
| | | | | | Per Nadav's review comments for r192866. llvm-svn: 193252
* Use address-taken to disambiguate global variable and indirect memops.Shuxin Yang2013-10-239-2/+27
| | | | | | | | | | Major steps include: 1). introduces a not-addr-taken bit-field in GlobalVariable 2). GlobalOpt pass sets "not-address-taken" if it proves a global varirable dosen't have its address taken. 3). AA use this info for disambiguation. llvm-svn: 193251
* Support for microMIPS relocations 1.Zoran Jovanovic2013-10-235-13/+118
| | | | llvm-svn: 193247
OpenPOWER on IntegriCloud