- Oct 21, 2014
-
-
Rafael Espindola authored
Every target we support has support for assembly that looks like a = b - c .long a What is special about MachO is that the above combination suppresses the production of a relocation. With this change we avoid producing the intermediary labels when they don't add any value. llvm-svn: 220256
-
Paul Robinson authored
When functions are inlined, instructions without debug information are attributed to the call site's DebugLoc. After inlining, inlined static allocas are moved to the caller's entry block, adjacent to the caller's original static alloca instructions. By retaining the call site's DebugLoc, these instructions could cause instructions that were subsequently inserted at the entry block to pick up the same DebugLoc. Patch by Wolfgang Pieb! llvm-svn: 220255
-
Greg Clayton authored
There were many issues with synchronous mode that we discovered when started to try and add a "batch" mode. There was a race condition where the event handling thread might consume events when in sync mode and other times the Process::WaitForProcessToStop() would consume them. This also led to places where the Process IO handler might or might not get popped when it needed to be. llvm-svn: 220254
-
Rafael Espindola authored
llvm-svn: 220253
-
Chandler Carruth authored
the CGO build environment. This lets things like -rpath propagate down to the C++ code that is built along side the Go bindings when testing them. Patch by Peter Collingbourne, and verified that it works by me. llvm-svn: 220252
-
David Blaikie authored
llvm-svn: 220251
-
Rafael Espindola authored
It had exactly one caller in a position where we know hasSetDirective is true. llvm-svn: 220250
-
Lang Hames authored
(See e.g. http://bb.pgr.jp/builders/cmake-llvm-x86_64-linux/builds/17653) llvm-svn: 220249
-
Philip Reames authored
Our metadata scheme lazily assigns IDs to string metadata, but we have a mechanism to preassign them as well. Using a preassigned ID is helpful since we get compile time type checking, and avoid some (minimal) string construction and comparison. This change adds enum value for three existing metadata types: + MD_nontemporal = 9, // "nontemporal" + MD_mem_parallel_loop_access = 10, // "llvm.mem.parallel_loop_access" + MD_nonnull = 11 // "nonnull" I went through an updated various uses as well. I made no attempt to get all uses; I focused on the ones which were easily grepable and easily to translate. For example, there were several items in LoopInfo.cpp I chose not to update. llvm-svn: 220248
-
Alexey Samsonov authored
llvm-svn: 220247
-
Philip Reames authored
Range metadata applies to loads, call, and invokes. We were validating that metadata applied to loads was correct according to the LangRef, but we were not validating metadata applied to calls or invokes. This change extracts the checking functionality to a common location, reuses it for all valid locations, and adds a simple test to ensure a misused range on a call gets reported. llvm-svn: 220246
-
Lang Hames authored
symbol table. Patch by Anthony Pesch. Thanks Anthony! llvm-svn: 220245
-
Richard Smith authored
This is long-since overdue, and matches GCC 5.0. This should also be backwards-compatible, because we already supported all of C11 as an extension in C99 mode. llvm-svn: 220244
-
Hans Wennborg authored
In environments where PATH was set to point to the VS installation, Clang would override that by looking in the registry and finding the latest VS installation. If the environment is set up to point to a VS installation, that should take precedence. Reverting this until we can fix it. llvm-svn: 220243
-
Quentin Colombet authored
X86 code to lower VSELECT messed a bit with the bits set in the mask of VSELECT when it knows it can be lowered into BLEND. Indeed, only the high bits need to be set for those and it optimizes those accordingly. However, when the mask is a compile time constant, the lowering will be handled by the generic optimizer and those modifications will generate bad code in the generic optimizer. This patch fixes that by preventing the optimization if the VSELECT will be handled by the generic optimizer. <rdar://problem/18675020> llvm-svn: 220242
-
Justin Bogner authored
List the module cache we use for crashdumps as a tempfile. This simplifies how we pick up this directory when generating the actual crash diagnostic and removes some duplicate logic. llvm-svn: 220241
-
Philip Reames authored
The newly introduced 'nonnull' metadata is analogous to existing 'nonnull' attributes, but applies to load instructions rather than call arguments or returns. Long term, it would be nice to combine these into a single construct. The value of the load is allowed to vary between successive loads, but null is not a valid value to be loaded by any load marked nonnull. Reviewed by: Hal Finkel Differential Revision: http://reviews.llvm.org/D5220 llvm-svn: 220240
-
Simon Pilgrim authored
This patch improves support for commutative instructions in the x86 memory folding implementation by attempting to fold a commuted version of the instruction if the original folding fails - if that folding fails as well the instruction is 're-commuted' back to its original order before returning. Updated version of r219584 (reverted in r219595) - the commutation attempt now explicitly ensures that neither of the commuted source operands are tied to the destination operand / register, which was the source of all the regressions that occurred with the original patch attempt. Added additional regression test case provided by Joerg Sonnenberger. Differential Revision: http://reviews.llvm.org/D5818 llvm-svn: 220239
-
Justin Bogner authored
In practice there's only ever one temporary output file when generating a crashdump, but even if there were many iterating over each and creating a duplicate run script for each one wouldn't make very much sense. This updates the behaviour to only generate the script once, based on the first filename. This should make it more reasonable to generate extra output files to include in the crashdump going forward, so I've also added a FIXME to look into doing just that with the extra module crashdump files. llvm-svn: 220238
-
Rafael Espindola authored
llvm-svn: 220237
-
Tim Northover authored
The previous code had a few problems, motivating the choices here. 1. It could create instructions clobbering CPSR, but the incoming MachineInstr didn't reflect this. A potential source of corruption. This is why the patch has a new PseudoInst for before lowering. 2. Similarly, there was some code to handle the incoming instruction not being ARMCC::AL, but this would have caused massive problems if it was actually invoked when a complex offset needing more than one instruction was requested. 3. It wasn't designed to handle unaligned pointers (or offsets). These should probably be minimised anyway, but the code needs to deal with them properly regardless. 4. It had some rather dubious ad-hoc code to avoid calling emitThumbRegPlusImmediate, a function which should be designed to do precisely this job. We seem to cover the common cases correctly now, and hopefully can enhance emitThumbRegPlusImmediate to handle any extra optimisations we need to add in future. llvm-svn: 220236
-
Justin Bogner authored
This just flattens an if block by returning early on the "else" condition. llvm-svn: 220235
-
Justin Bogner authored
We currently use a null FailingCommand when generating crash reports as an indication that the cause is FORCE_CLANG_DIAGNOSTICS_CRASH, the environment variable that exists to test crash dumps. This means that our tests don't actually cover real crashes at all, and adds a more complicated code path that's only used in the tests. Instead, we can have the driver synthesize that every command failed and just call generateCompilationDiagnostics normally. llvm-svn: 220234
-
Alexey Samsonov authored
llvm-svn: 220233
-
Alexey Samsonov authored
llvm-svn: 220232
-
Alexey Samsonov authored
llvm-svn: 220231
-
Alexey Samsonov authored
llvm-svn: 220230
-
David Blaikie authored
Post commit review feedback from Yaron Keren. llvm-svn: 220229
-
Alexey Samsonov authored
llvm-svn: 220228
-
Dan Liew authored
execution of a shell command. This can happen for example if the ``RUN:`` line calls a python script which can work correctly under Linux/OSX but will not work under Windows. A more useful error message is now shown rather than an unhelpful backtrace. llvm-svn: 220227
-
Zachary Turner authored
Typically clang finds Visual Studio by the user explicitly setting up a Visual Studio environment via vcvarsall. But we still try to behave intelligently and fallback to different methods of finding Visual Studio when this is not done. This patch improves various fallback codepaths to make Visual Studio locating more robust. Specifically, this patch: * Adds support for searching environment variables for VS 12.0 * Correctly locates include folders for Windows SDK 8.x (this was previously broken, and would cause clang to error) * Prefers locating link.exe in the same location as cl.exe. This is helpful in case another link.exe is in the path earlier than Visual Studio (e.g. GnuWin32) * Minor cleanup in the registry reading code to make it more robust in the presence of long pathnames. llvm-svn: 220226
-
Robert Khasanov authored
Thanks Juergen Ributzka for notice. llvm-svn: 220224
-
David Blaikie authored
PR21312: Fix a regression in non-type template parameters of function type that are static member functions. llvm-svn: 220221
-
Sean Callanan authored
look through 'self' at its ivars. It produces surprising results. <rdar://problem/18698760> llvm-svn: 220220
-
Ed Maste authored
r219978 fixed this test to work on Darwin, and removed the expected failure decorator, but it then started running (and failing) on FreeBSD. I'd think @dsym_test should skip the test on all non-Darwin operating systems. It seems not to be the case, so for now skip it the same way as done for other @dsym_test tests. llvm-svn: 220219
-
Zachary Turner authored
Differential Revision: http://reviews.llvm.org/D5849 Reviewed by: Jason Molenda llvm-svn: 220218
-
Zachary Turner authored
Differential Revision: http://reviews.llvm.org/D5805 Reviewed by: Greg Clayton llvm-svn: 220217
-
David Blaikie authored
llvm-svn: 220216
-
Hal Finkel authored
Clang supports __restrict__ as a function qualifier, but DeclaratorChunk::FunctionTypeInfo lacked a field to track the qualifier's source location (as we do with volatile, etc.). This was the subject of a FIXME in GetFullTypeForDeclarator (in SemaType.cpp). This should also prove useful as we add more warnings regarding questionable uses of the restrict qualifier. There is no significant functional change (except for an improved source range associated with the err_invalid_qualified_function_type diagnostic fixit generated by GetFullTypeForDeclarator). llvm-svn: 220215
-
Ben Langmuir authored
Now that we no longer add mappings when there are no local entities, there is no need to always bump the size of the tables that correspond to ContinuousRangeMaps. llvm-svn: 220208
-