- Oct 14, 2015
-
-
Rui Ueyama authored
llvm-svn: 250227
-
Davide Italiano authored
llvm-svn: 250225
-
Chad Rosier authored
llvm-svn: 250224
-
Davide Italiano authored
The documentation says: "You may separate commands using semicolons", so they seem to be optional. Differential Revision: http://reviews.llvm.org/D13703 llvm-svn: 250223
-
Kevin Enderby authored
ArchiveMemberHeader, suggestion by Rafael Espíndola. Also The clang-x86-win2008-selfhost bot still does not like the malformed-machos 00000031.a test, so removing it for now. All the other bots are fine with it however. llvm-svn: 250222
-
Aaron Ballman authored
Exposing an existing checker under the name cert-err61-cpp, as it corresponds to the CERT C++ secure coding rule: https://www.securecoding.cert.org/confluence/display/cplusplus/ERR61-CPP.+Catch+exceptions+by+lvalue+reference llvm-svn: 250221
-
Hal Finkel authored
We'd miss the nop if it really did come right at the end of the buffer (nice off-by-one error). llvm-svn: 250220
-
Joseph Tremoulet authored
Summary: Emit the handler and clause locations immediately after the standard xdata. Clauses are emitted in the same order and format used to communiate them to the CLR Execution Engine. Add a lit test to verify correct table generation on a small but interesting example function. Reviewers: majnemer, andrew.w.kaylor, rnk Subscribers: pgavlin, AndyAyers, llvm-commits Differential Revision: http://reviews.llvm.org/D13451 llvm-svn: 250219
-
Duncan P. N. Exon Smith authored
One of the changes in lib/Target/AMDGPU/AMDGPUMCInstLower.cpp was a new one. Previously, bundle iterators and single-instruction iterators could be compared to each other (comparing on underlying pointers). I changed a comparison from using `MBB->end()` to using `MBB->instr_end()`, since both end iterators should point at the some place anyway. I don't think the implicit conversion between the two iterator types is a good idea since it's fairly easy to accidentally compare to the wrong thing (they aren't always end iterators). Otherwise I would have just added the conversion. Even with that, no there should be functionality change here. llvm-svn: 250218
-
Tobias Grosser authored
We harden one test case by ensuring no additional stores may possibly be introduced between the stores we check for and the basic block terminator statements. We also add a test case for the situation where a value that is passed from a non-affine region to a PHI node does not dominate the exit of the non-affine region. This case has come up in patch reviews, so we make sure it is properly handled today and in the future. llvm-svn: 250217
-
Duncan P. N. Exon Smith authored
llvm-svn: 250216
-
Rui Ueyama authored
llvm-svn: 250215
-
Duncan P. N. Exon Smith authored
llvm-svn: 250214
-
Zachary Turner authored
llvm-svn: 250213
-
Hal Finkel authored
As Rafael suggested in his review of r250190, we can simplify this by writing it like the earlier checks. llvm-svn: 250212
-
Duncan P. N. Exon Smith authored
Remove remaining `ilist_iterator` implicit conversions from LLVMScalarOpts. This change exposed some scary behaviour in lib/Transforms/Scalar/SCCP.cpp around line 1770. This patch changes a call from `Function::begin()` to `&Function::front()`, since the return was immediately being passed into another function that takes a `Function*`. `Function::front()` started to assert, since the function was empty. Note that `Function::end()` does not point at a legal `Function*` -- it points at an `ilist_half_node` -- so the other function was getting garbage before. (I added the missing check for `Function::isDeclaration()`.) Otherwise, no functionality change intended. llvm-svn: 250211
-
Hal Finkel authored
As Rafael pointed out in his review of r250110, -dynamic-linker, -rpath and --export-dynamic are unnecessary. llvm-svn: 250210
-
Hal Finkel authored
Suggested by Rafael in his review of r250100. As Rafael points out, this may grow into a switch in the future, but regardless, calling this on files for other architectures is unnecessary. llvm-svn: 250209
-
Rui Ueyama authored
llvm-svn: 250208
-
Akira Hatanaka authored
This fixes an assert in AArch64AsmParser::MatchAndEmitInstruction. rdar://problem/23081753 llvm-svn: 250207
-
Hal Finkel authored
As Rafael pointed out in his review of r250100, the NOBITS check is no longer the last requirement. llvm-svn: 250206
-
Hal Finkel authored
Revert: "Re: [lld] r249752 - Revert: r249728 - Roll back r249726 and r249723 because they broke buildbots." This has turned out to be unnecessary, and while some ability to set VAStart will be needed at some point, this is not clearly the right direction. llvm-svn: 250205
-
Cong Hou authored
Currently in JumpThreading pass, the branch weight metadata is not updated after CFG modification. Consider the jump threading on PredBB, BB, and SuccBB. After jump threading, the weight on BB->SuccBB should be adjusted as some of it is contributed by the edge PredBB->BB, which doesn't exist anymore. This patch tries to update the edge weight in metadata on BB->SuccBB by scaling it by 1 - Freq(PredBB->BB) / Freq(BB->SuccBB). Differential revision: http://reviews.llvm.org/D10979 llvm-svn: 250204
-
Eric Christopher authored
tests by predefining _MM_MALLOC_H rather than use -ffreestanding. llvm-svn: 250203
-
Eric Christopher authored
llvm-svn: 250202
-
Xinliang David Li authored
[PGO]: Eliminate calls to __llvm_profile_register_function for Linux. On Linux, the profile runtime can use __start_SECTNAME and __stop_SECTNAME symbols defined by the linker to locate the start and end location of a named section (with C name). This eliminates the need for instrumented binary to call __llvm_profile_register_function during start-up time. llvm-svn: 250200
-
Xinliang David Li authored
[PGO]: Eliminate calls to __llvm_profile_register_function for Linux. On Linux, the profile runtime can use __start_SECTNAME and __stop_SECTNAME symbols defined by the linker to locate the start and end location of a named section (with C name). This eliminates the need for instrumented binary to call __llvm_profile_register_function during start-up time. llvm-svn: 250199
-
Jonathan Peyton authored
llvm-svn: 250198
-
Duncan P. N. Exon Smith authored
Remove some of the implicit ilist iterator conversions in LLVMScalarOpts. More to go. llvm-svn: 250197
-
Chris Bieneman authored
[CMake] When building clang as an external project we should pass through all variables that start with COMPILER_RT llvm-svn: 250196
-
Zachary Turner authored
PythonObjects were being incorrectly ref-counted. This problem was pervasive throughout the codebase, leading to an unknown number of memory leaks and potentially use-after-free. The issue stems from the fact that Python native methods can either return "borrowed" references or "owned" references. For the former category, you *must* incref it prior to decrefing it. And for the latter category, you should not incref it before decrefing it. This is mostly an issue when a Python C API method returns a `PyObject` to you, but it can also happen with a method accepts a `PyObject`. Notably, this happens in `PyList_SetItem`, which is documented to "steal" the reference that you give it. So if you pass something to `PyList_SetItem`, you cannot hold onto it unless you incref it first. But since this is one of only two exceptions in the entire API, it's confusing and difficult to remember. Our `PythonObject` class was indiscriminantely increfing every object it received, which means that if you passed it an owned reference, you now have a dangling reference since owned references should not be increfed. We were doing this in quite a few places. There was also a fair amount of manual increfing and decrefing prevalent throughout the codebase, which is easy to get wrong. This patch solves the problem by making any construction of a `PythonObject` from a `PyObject` take a flag which indicates whether it is an owned reference or a borrowed reference. There is no way to construct a `PythonObject` without this flag, and it does not offer a default value, forcing the user to make an explicit decision every time. All manual uses of `PyObject` have been cleaned up throughout the codebase and replaced with `PythonObject` in order to make RAII the predominant pattern when dealing with native Python objects. Differential Revision: http://reviews.llvm.org/D13617 Reviewed By: Greg Clayton llvm-svn: 250195
-
Aaron Ballman authored
Patch by Piotr Dziwinski. llvm-svn: 250194
-
Duncan P. N. Exon Smith authored
llvm-svn: 250193
-
Duncan P. N. Exon Smith authored
llvm-svn: 250192
-
Rui Ueyama authored
"finalize" does not give a hint about what that function is actually going to do. This patch make it more specific by renaming scanShlibUndefined. Also add a comment that we basically ignore undefined symbols in DSOs except this function. llvm-svn: 250191
-
Hal Finkel authored
The fix in r250109 to ensure a strict weak ordering in the section sorting was a bit overzealous. We only use the NOBITS comparison if either A or B is a NOBITS section. Otherwise, we fall through to the target-specific ranking function. Failure to do this causes the sorting to fail in cases where, for example, a .dynamic section happens to end up in between .got and .toc, etc. in the initial ordering (.dynamic has a type SHT_DYNAMIC, compared to SHT_PROGBITS or SHT_NOBITS). llvm-svn: 250190
-
Adrian McCarthy authored
llvm-svn: 250189
-
Adrian McCarthy authored
DifferentialRevision: http://reviews.llvm.org/D13679 llvm-svn: 250188
-
Duncan P. N. Exon Smith authored
llvm-svn: 250187
-
Duncan P. N. Exon Smith authored
llvm-svn: 250186
-