summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Add a few const's (thanks Zachary) and return shared or unique pointersJim Ingham2016-09-1317-78/+98
| | | | | | in places where they help prevent leaks. llvm-svn: 281288
* Handle empty message in static_asserts.Richard Trieu2016-09-131-2/+3
| | | | llvm-svn: 281287
* Fix interaction between serialization and c++1z feature.Richard Trieu2016-09-134-1/+13
| | | | | | | | In c++1z, static_assert is not required to have a StringLiteral message, where previously it was required. Update the AST Reader to be able to handle a null StringLiteral. llvm-svn: 281286
* Update Clang for D20147 ("DebugInfo: New metadata representation for global ↵Peter Collingbourne2016-09-1331-134/+158
| | | | | | | | variables.") Differential Revision: http://reviews.llvm.org/D20415 llvm-svn: 281285
* DebugInfo: New metadata representation for global variables.Peter Collingbourne2016-09-13159-796/+922
| | | | | | | | | | | | | This patch reverses the edge from DIGlobalVariable to GlobalVariable. This will allow us to more easily preserve debug info metadata when manipulating global variables. Fixes PR30362. A program for upgrading test cases is attached to that bug. Differential Revision: http://reviews.llvm.org/D20147 llvm-svn: 281284
* [DAG] Refactor BUILD_VECTOR combine to make it easier to extend. NFCI.Michael Kuperstein2016-09-131-123/+156
| | | | | | | This should make it easier to add cases that we currently don't cover, like supporting more kinds of type mismatches and more than 2 input vectors. llvm-svn: 281283
* Fix an issue where LLDB was not masking enough bits off of objc classes ↵Enrico Granata2016-09-131-1/+14
| | | | | | | | data() pointers, effectively rendering us unable to generate descriptors for some classes Fixes rdar://27758358 llvm-svn: 281282
* X86: Conditional tail calls should not have isBarrier = 1Hans Wennborg2016-09-133-21/+62
| | | | | | | | | | That confuses e.g. machine basic block placement, which then doesn't realize that control can fall through a block that ends with a conditional tail call. Instead, isBranch=1 should be set. Also, mark EFLAGS as used by these instructions. llvm-svn: 281281
* Temporarily Revert "[MC] Defer asm errors to post-statement failure" as it's ↵Eric Christopher2016-09-1316-517/+830
| | | | | | | | causing errors on the sanitizer bots. This reverts commit r281249. llvm-svn: 281280
* Revert "Add -fdiagnostics-show-hotness"Adam Nemet2016-09-139-127/+1
| | | | | | | | This reverts commit r281276. Many bots are failing. llvm-svn: 281279
* [DebugInfo] Deduplicate debug info limiting logicReid Kleckner2016-09-133-25/+23
| | | | | | | | | | | | | We should be doing the same checks when a type is completed as we do when a complete type is used during emission. Previously, we duplicated the logic, and it got out of sync. This could be observed with dllimported classes. Also reduce a test case for this slightly. Implementing review feedback from David Blaikie on r281057. llvm-svn: 281278
* [Sema] Fix PR30346: relax __builtin_object_size checks.George Burgess IV2016-09-123-11/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch makes us act more conservatively when trying to determine the objectsize for an array at the end of an object. This is in response to code like the following: ``` struct sockaddr { /* snip */ char sa_data[14]; }; void foo(const char *s) { size_t slen = strlen(s) + 1; size_t added_len = slen <= 14 ? 0 : slen - 14; struct sockaddr *sa = malloc(sizeof(struct sockaddr) + added_len); strcpy(sa->sa_data, s); // ... } ``` `__builtin_object_size(sa->sa_data, 1)` would return 14, when there could be more than 14 bytes at `sa->sa_data`. Code like this is apparently not uncommon. FreeBSD's manual even explicitly mentions this pattern: https://www.freebsd.org/doc/en/books/developers-handbook/sockets-essential-functions.html (section 7.5.1.1.2). In light of this, we now just give up on any array at the end of an object if we can't find the object's initial allocation. I lack numbers for how much more conservative we actually become as a result of this change, so I chose the fix that would make us as compatible with GCC as possible. If we want to be more aggressive, I'm happy to consider some kind of whitelist or something instead. llvm-svn: 281277
* Add -fdiagnostics-show-hotnessAdam Nemet2016-09-129-1/+127
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: I've recently added the ability for optimization remarks to include the hotness of the corresponding code region. This uses PGO and allows filtering of the optimization remarks by relevance. The idea was first discussed here: http://thread.gmane.org/gmane.comp.compilers.llvm.devel/98334 The general goal is to produce a YAML file with the remarks. Then, an external tool could dynamically filter these by hotness and perhaps by other things. That said it makes sense to also expose this at the more basic level where we just include the hotness info with each optimization remark. For example, in D22694, the clang flag was pretty useful to measure the overhead of the additional analyses required to include hotness. (Without the flag we don't even run the analyses.) For the record, Hal has already expressed support for the idea of this patch on IRC. Differential Revision: https://reviews.llvm.org/D23284 llvm-svn: 281276
* Fix a long comment lineAdam Nemet2016-09-121-1/+1
| | | | llvm-svn: 281275
* [OptDiag] Add getHotness accessorAdam Nemet2016-09-121-0/+1
| | | | llvm-svn: 281274
* This is the main part of a change to add breakpoint save and restore to lldb.Jim Ingham2016-09-1223-255/+1859
| | | | | | | | | | | | | | | Still to come: 1) SB API's 2) Testcases 3) Loose ends: a) serialize Thread options b) serialize Exception resolvers 4) "break list --file" should list breakpoints contained in a file and "break read -f 1 3 5" should then read in only those breakpoints. <rdar://problem/12611863> llvm-svn: 281273
* [LVI] Complete the abstract of the cache layer [NFCI]Philip Reames2016-09-121-72/+94
| | | | | | | | Convert the previous introduced is-a relationship between the LVICache and LVIImple clases into a has-a relationship and hide all the implementation details of the cache from the lazy query layer. The only slightly concerning change here is removing the addition of a queried block into the SeenBlock set in LVIImpl::getBlockValue. As far as I can tell, this was effectively dead code. I think it *used* to be the case that getCachedValueInfo wasn't const and might end up inserting elements in the cache during lookup. That's no longer true and hasn't been for a while. I did fixup the const usage to make that more obvious. llvm-svn: 281272
* [CMake] Fix linker-as-ld to symlink instead of copy lldChris Bieneman2016-09-121-2/+2
| | | | | | | | | | | | Summary: This test fails if you're building with BUILD_SHARED_LIBS because the LLVM libraries are found via @rpath. Symlinking instead of copying should be sufficiently robust for the test case. Reviewers: llvm-commits Subscribers: davide Differential Revision: https://reviews.llvm.org/D24476 llvm-svn: 281271
* add more tests for PR30273Sanjay Patel2016-09-121-2/+32
| | | | llvm-svn: 281270
* [ORC] Clang-format RPCSerialization.h.Lang Hames2016-09-121-29/+26
| | | | llvm-svn: 281269
* [ORC] Add some more documentation to RPCSerialization.h.Lang Hames2016-09-121-21/+58
| | | | llvm-svn: 281268
* [LVI] Sink a couple more cache manipulation routines into the cache itself ↵Philip Reames2016-09-121-36/+45
| | | | | | | | [NFCI] The only interesting bit here is the refactor of the handle callback and even that's pretty straight-forward. llvm-svn: 281267
* [LVI] Abstract out the actual cache logic [NFCI]Philip Reames2016-09-121-89/+97
| | | | | | Seperate the caching logic from the implementation of the lazy analysis. For the moment, the lazy analysis impl has a is-a relationship with the cache; this will change to a has-a relationship shortly. This was done as two steps merely to keep the changes simple and the diff understandable. llvm-svn: 281266
* Add comments.Rui Ueyama2016-09-122-0/+7
| | | | llvm-svn: 281265
* config: Use _LIBCPP_TYPE_VIS_ONLY with enum classShoaib Meenai2016-09-121-1/+1
| | | | | | | | | | | An enum class has associated type info. In the Microsoft ABI, type info is emitted in the COMDAT section and isn't exported, so clang rightfully complains about __declspec(dllexport) being unused for an enum class. On other platforms, we still want to export the type info. Differential Revision: https://reviews.llvm.org/D24065 llvm-svn: 281264
* Revert r281215, it caused PR30358.Nico Weber2016-09-129-232/+26
| | | | llvm-svn: 281263
* attempt to unbreak build after r281254Nico Weber2016-09-121-0/+1
| | | | llvm-svn: 281262
* CodeGen: use some range-based for loopsSaleem Abdulrasool2016-09-121-14/+10
| | | | | | | Use range-based for loops to simplify the logic. Add an explicit check for MachO as the inline asm uses MachO specific directives. llvm-svn: 281261
* [MachO] Factor out a fair amount of duplicated code. NFCI.Davide Italiano2016-09-121-26/+14
| | | | llvm-svn: 281260
* Add a couple of test files missed in r281258.Richard Smith2016-09-122-0/+10
| | | | llvm-svn: 281259
* [modules] When we merge two definitions of a function, mark the retainedRichard Smith2016-09-126-24/+62
| | | | | | | definition as visible in the discarded definition's module, as we do for other kinds of definition. llvm-svn: 281258
* [ORC] Add missing <thread> header to RPCSerialization.h.Lang Hames2016-09-121-0/+1
| | | | llvm-svn: 281257
* [Cmake] Use Cmake's default RPATH for unittest.Davide Italiano2016-09-121-0/+2
| | | | | | | | | | | | | Similarly to what was done in r280791 for llvm/. This should fix a bunch of failures I saw while trying a BUILD_SHARED_LIBS build on MacOS. Still there are some failures, but this is a step forward. Thanks a lot to Chris Bieneman for the suggested fix (in PR30345) llvm-svn: 281256
* [sanitizer] replace CHECK with CHECK_XY in two places for better diagnosticsKostya Serebryany2016-09-121-2/+2
| | | | llvm-svn: 281255
* [ORC] Replace the serialize/deserialize function pair with a SerializationTraitsLang Hames2016-09-124-167/+360
| | | | | | | | | | | class. SerializationTraits provides serialize and deserialize methods corresponding to the earlier functions, but also provides a name for the type. In future, this name will be used to render function signatures as strings, which will in turn be used to negotiate and verify API support between RPC clients and servers. llvm-svn: 281254
* Fix the bug introduced in r281252.Dehao Chen2016-09-121-1/+1
| | | | llvm-svn: 281253
* Lower consecutive select instructions correctly.Dehao Chen2016-09-122-23/+119
| | | | | | | | | | | | Summary: If consecutive select instructions are lowered separately in CGP, it will introduce redundant condition check and branches that cannot be removed by later optimization phases. This patch lowers all consecutive select instructions at the same to to avoid inefficent code as demonstrated in https://llvm.org/bugs/show_bug.cgi?id=29095 Reviewers: davidxl Subscribers: vsk, llvm-commits Differential Revision: https://reviews.llvm.org/D24147 llvm-svn: 281252
* xfail TestQueues.py and TestDarwinLogFilterMatchMessage.pyTodd Fiala2016-09-122-0/+9
| | | | | | | | | | | | | | It looks like the message-content-retrieval aspect of DarwinLog support is flaky, not just the regex match against it. Slightly less frequently than the regex matching, I am seeing the direct string-match variant of log-message-content matching also fail. Tracked by: llvm.org/pr30299 rdar://28237450 llvm-svn: 281251
* config: Fix typo in commentShoaib Meenai2016-09-121-1/+1
| | | | | | Testing commit access. NFC. llvm-svn: 281250
* [MC] Defer asm errors to post-statement failureNirav Dave2016-09-1216-830/+517
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Allow errors to be deferred and emitted as part of clean up to simplify and shorten Assembly parser code. This will allow error messages to be emitted in helper functions and be modified by the caller which has better context. As part of this many minor cleanups to the Parser: * Unify parser cleanup on error * Add Workaround for incorrect return values in ParseDirective instances * Tighten checks on error-signifying return values for parser functions and fix in-tree TargetParsers to be more consistent with the changes. * Fix AArch64 test cases checking for spurious error messages that are now fixed. These changes should be backwards compatible with current Target Parsers so long as the error status are correctly returned in appropriate functions. Reviewers: rnk, majnemer Subscribers: aemerson, jyknight, llvm-commits Differential Revision: https://reviews.llvm.org/D24047 llvm-svn: 281249
* [InstCombine] add test for PR30327Sanjay Patel2016-09-121-0/+14
| | | | llvm-svn: 281248
* [InstCombine] regenerate checksSanjay Patel2016-09-121-4/+7
| | | | llvm-svn: 281247
* AVX-512: Added a test for -O0 mode. NFC.Elena Demikhovsky2016-09-121-0/+52
| | | | llvm-svn: 281246
* Fix bitmask upper bounds checkJonathan Peyton2016-09-123-25/+18
| | | | | | | | | | | | Rather than checking KMP_CPU_SETSIZE, which doesn't exist when using Hwloc, we use the get_max_proc() function which can vary based on the operating system. For example on Windows with multiple processor groups, it might be the case that the highest bit possible in the bitmask is not equal to the number of hardware threads on the machine but something higher than that. Differential Revision: https://reviews.llvm.org/D24206 llvm-svn: 281245
* AVX-512: Simplified masked_gather_scatter test. NFC.Elena Demikhovsky2016-09-121-183/+6
| | | | llvm-svn: 281244
* fix Xcode build after r281226Todd Fiala2016-09-121-1/+1
| | | | llvm-svn: 281243
* Remove -fvisibility=hidden and FORCE_STATIC.Michael Kruse2016-09-122-21/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | The flag -fvisibility=hidden flag was used for the integrated Integer Set Library (and PPCG) to keep their definitions local to Polly. The motivation was the be loaded into a DragonEgg-powered GCC, where GCC might itself use ISL for its Graphite extension. The symbols of Polly's ISL and GCC's ISL would clash. The DragonEgg project is not actively developed anymore, but Polly's unittests need to call ISL functions to set up a testing environment. Unfortunately, the -fvisibility=hidden flag means that the ISL symbols are not available to the gtest executable as it resides outside of libPolly when linked dynamically. Currently, CMake links a second copy of ISL into the unittests which leads to subtle bugs. What got observed is that two isl_ids for isl_id_none exist, one for each library instance. Because isl_id's are compared by address, isl_id_none could happen to be different from isl_id_none, depending on which library instance set the address and does the comparison. Also remove the FORCE_STATIC flag which was introduced to keep the ISL symbols visible inside the same libPolly shared object, even when build with BUILD_SHARED_LIBS. Differential Revision: https://reviews.llvm.org/D24460 llvm-svn: 281242
* Diagnostics reference: "error:" should be red, not orange.Richard Smith2016-09-122-2/+2
| | | | llvm-svn: 281241
* Fix test failure in r281232Hemant Kulkarni2016-09-122-0/+0
| | | | llvm-svn: 281240
* [SE] Clean up device and host memory slicesJason Henline2016-09-124-22/+35
| | | | | | | | | | | | | | | | | | | Summary: * Add LLVM_ATTRIBUTE_UNUSED_RESULT used to slicing methods in order to emphasize that the slicing is not done in place. * Change device memory slice function name from `drop_front` to `slice` in order to match the naming convention of `llvm::ArrayRef` and host memory slice. * Change the parameter names of host memory slice functions to `DropCount` and `TakeCount` to match device memory slice declarations. Reviewers: jlebar Subscribers: jprice, parallel_libs-commits Differential Revision: https://reviews.llvm.org/D24464 llvm-svn: 281239
OpenPOWER on IntegriCloud