summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Placate gcc's -Wreturn-typeMatt Beaumont-Gay2012-01-271-0/+1
| | | | llvm-svn: 149104
* <rdar://problem/10760649>Greg Clayton2012-01-272-1/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixed another double file descriptor close issue that could occur when destroying a ProcessGDBRemote() object. There was a race which was detected by our fd_interposing library: error: /Applications/Xcode.app/Contents/MacOS/Xcode (pid=55222): close (fd=60) resulted in EBADF: 0 libFDInterposing.dylib 0x00000001082be8ca close$__interposed__ + 666 1 LLDB 0x00000001194fde91 lldb_private::ConnectionFileDescriptor::Close(int&, lldb_private::Error*) + 97 2 LLDB 0x00000001194fddcd lldb_private::ConnectionFileDescriptor::Disconnect(lldb_private::Error*) + 143 3 LLDB 0x00000001194fe249 lldb_private::ConnectionFileDescriptor::Read(void*, unsigned long, unsigned int, lldb::ConnectionStatus&, lldb_private::Error*) + 835 4 LLDB 0x00000001194fc320 lldb_private::Communication::Read(void*, unsigned long, unsigned int, lldb::ConnectionStatus&, lldb_private::Error*) + 634 5 LLDB 0x000000011959c7f4 GDBRemoteCommunication::WaitForPacketWithTimeoutMicroSecondsNoLock(StringExtractorGDBRemote&, unsigned int) + 228 6 LLDB 0x000000011959c6b5 GDBRemoteCommunication::WaitForPacketWithTimeoutMicroSeconds(StringExtractorGDBRemote&, unsigned int) + 49 7 LLDB 0x0000000119629a71 GDBRemoteCommunicationClient::SendContinuePacketAndWaitForResponse(ProcessGDBRemote*, char const*, unsigned long, StringExtractorGDBRemote&) + 509 8 LLDB 0x00000001195a4076 ProcessGDBRemote::AsyncThread(void*) + 514 9 LLDB 0x0000000119568094 ThreadCreateTrampoline(void*) + 91 10 libsystem_c.dylib 0x00007fff8ca028bf _pthread_start + 335 11 libsystem_c.dylib 0x00007fff8ca05b75 thread_start + 13 fd=60 was previously closed with this event: pid=55222: close (fd=60) => 0 0 libFDInterposing.dylib 0x00000001082be870 close$__interposed__ + 576 1 LLDB 0x00000001194fde91 lldb_private::ConnectionFileDescriptor::Close(int&, lldb_private::Error*) + 97 2 LLDB 0x00000001194fddcd lldb_private::ConnectionFileDescriptor::Disconnect(lldb_private::Error*) + 143 3 LLDB 0x00000001194fbf00 lldb_private::Communication::Disconnect(lldb_private::Error*) + 92 4 LLDB 0x00000001195a2a77 ProcessGDBRemote::StopAsyncThread() + 89 5 LLDB 0x00000001195a2bf6 ProcessGDBRemote::DoDestroy() + 310 6 LLDB 0x00000001195f938d lldb_private::Process::Destroy() + 85 7 LLDB 0x0000000118819b48 lldb::SBProcess::Kill() + 72 8 DebuggerLLDB 0x0000000117264358 DBGLLDBSessionThread(void*) + 4450 9 LLDB 0x0000000119568094 ThreadCreateTrampoline(void*) + 91 10 libsystem_c.dylib 0x00007fff8ca028bf _pthread_start + 335 11 libsystem_c.dylib 0x00007fff8ca05b75 thread_start + 13 fd=60 was created with this event: pid=55222: socket (domain = 2, type = 1, protocol = 6) => fd=60 0 libFDInterposing.dylib 0x00000001082bc968 socket$__interposed__ + 600 1 LLDB 0x00000001194fd75f lldb_private::ConnectionFileDescriptor::ConnectTCP(char const*, lldb_private::Error*) + 179 ..... llvm-svn: 149103
* Better user diagnostics for more ARM MachO relocation errors.Jim Grosbach2012-01-271-4/+8
| | | | llvm-svn: 149102
* Better diagnostic for malformed .org assembly directive.Jim Grosbach2012-01-279-19/+26
| | | | | | Provide source line number information. llvm-svn: 149101
* test/Driver/prefixed-tools.c: Disable this on win32 hosts, msvc and mingw.NAKAMURA Takumi2012-01-271-0/+4
| | | | | | | It had failed on Win32 due to inability of executing shell scripts. Still it fails even with mingw MSYS bash. llvm-svn: 149100
* test/Driver/prefixed-tools.c: Fix newline at end-of-file.NAKAMURA Takumi2012-01-271-1/+1
| | | | llvm-svn: 149099
* <rdar://problem/10750012>Greg Clayton2012-01-276-95/+5
| | | | | | | | Remove a pseudo terminal master open and slave file descriptor that was being used for pythong stdin. It was not hooked up correctly and was causing file descriptor leaks. llvm-svn: 149098
* Rewrite instruction operands in AdjustCopiesBackFrom. Fixes PR11861.Lang Hames2012-01-272-4/+27
| | | | llvm-svn: 149097
* Tidy up.Jim Grosbach2012-01-261-1/+1
| | | | llvm-svn: 149096
* Turn off implicit truncation warning for compound assignment to bitfields; ↵Eli Friedman2012-01-262-2/+4
| | | | | | | | it might be reasonable in some cases, but it clearly doesn't make sense in some cases, like the included testcase. <rdar://problem/10238797>, part 2. llvm-svn: 149095
* Teach ccc-analyzer about -fobjc-abi-version.Ted Kremenek2012-01-261-1/+2
| | | | llvm-svn: 149094
* Keep source information, if available, around for ARM Fixups.Jim Grosbach2012-01-263-9/+15
| | | | | | | | | | | | | | | | | Adjust an example MachObjectWriter diagnostic to use the information to issue a better message. Before: LLVM ERROR: unknown ARM fixup kind! After: x.s:6:5: error: unsupported relocation on symbol beq bar ^ rdar://9800182 llvm-svn: 149093
* Add simple support for keeping MCFixup source information.Jim Grosbach2012-01-264-2/+38
| | | | | | | Can be used to issue more user friendly diagnostics for faulty relocation constructs and such. llvm-svn: 149092
* llvm-mc pass through SourceMgr to MCContext.Jim Grosbach2012-01-261-1/+1
| | | | llvm-svn: 149091
* Add SourceMgr to MCContext for backend diagnostics.Jim Grosbach2012-01-262-3/+7
| | | | llvm-svn: 149090
* Make the bitfield implicit truncation warning slightly more aggressive, and ↵Eli Friedman2012-01-262-10/+21
| | | | | | make the printed warning a bit more accurate. The new behavior matches gcc's -Wconversion. <rdar://problem/10238797>. llvm-svn: 149089
* Handle call-clobbered ymm registers on Win64.Jakob Stoklund Olesen2012-01-263-1/+56
| | | | | | | | | | | | | | The Win64 calling convention has xmm6-15 as callee-saved while still clobbering all ymm registers. Add a YMM_HI_6_15 pseudo-register that aliases the clobbered part of the ymm registers, and mark that as call-clobbered. This allows live xmm registers across calls. This hack wouldn't be necessary with RegisterMask operands representing the call clobbers, but they are not quite operational yet. llvm-svn: 149088
* Remove the ToolTriple logic in NetBSD, which was completely broken byJoerg Sonnenberger2012-01-263-14/+8
| | | | | | | | the recent refactoring. All interesting NetBSD release have a GNU as version on i386 that supports --32, so don't bother with the conditional setting of it. llvm-svn: 149087
* Make clz/ctz builtins defined for zero on ARM targets. rdar://10732455Bob Wilson2012-01-264-4/+18
| | | | | | | | | | | | | | | | ARM supports clz and ctz directly and both operations have well-defined results for zero. There is no disadvantage in performance to using the defined-at-zero versions of llvm.ctlz/cttz intrinsics. We're running into ARM-specific code written with the assumption that __builtin_clz(0) == 32, even though that value is technically undefined. The code is failing now because of llvm optimizations that are taking advantage of the undef behavior (specifically svn r147255). There's nothing wrong with that optimization on x86 where any incorrect assumptions about __builtin_clz(0) will quickly be exposed. For ARM, though, optimizations based on that undef behavior are likely to cause subtle bugs. Other targets with defined-at-zero clz/ctz support may want to override the default behavior as well. llvm-svn: 149086
* Use -H on darwin as well.Eric Christopher2012-01-261-1/+1
| | | | | | Patch by Liang Wang! llvm-svn: 149085
* Remove obviously incorrect branch.Joerg Sonnenberger2012-01-261-2/+1
| | | | llvm-svn: 149084
* Keep track of the original target the user specified beforeJoerg Sonnenberger2012-01-269-68/+123
| | | | | | | | | | normalization. This used to be captured in DefaultTargetTriple and is used for the (optional) $triple-$tool lookup for cross-compilation. Do this properly by making it an attribute of the toolchain and use it in combination with the computed triple as index for the toolchain lookup. llvm-svn: 149083
* progress making the world safe to ConstantDataVector. WhileChris Lattner2012-01-264-64/+93
| | | | | | | | we're at it, allow PatternMatch's "neg" pattern to match integer vector negations, and enhance ComputeNumSigned bits to handle shl of vectors. llvm-svn: 149082
* Change references to 'const ProgramState *' to typedef 'ProgramStateRef'.Ted Kremenek2012-01-2674-713/+722
| | | | | | | | At this point this is largely cosmetic, but it opens the door to replace ProgramStateRef with a smart pointer that more eagerly acts in the role of reclaiming unused ProgramState objects. llvm-svn: 149081
* Fixed formats being able to be applied recursively when using:Greg Clayton2012-01-266-36/+69
| | | | | | | | target variable -f <format> [args] frame variable -f <format> [args] expression -f <format> -- expr llvm-svn: 149080
* objc-arc: introduce -no-finalize-removal which in gc mode,Fariborz Jahanian2012-01-267-5/+245
| | | | | | | | leaves "finalize' behind and in arc mode, does not include it. This allows the migrated source to be compiled in both gc and arc mode. // rdar://10532441 llvm-svn: 149079
* tidy up forward declarations.Chris Lattner2012-01-262-9/+5
| | | | llvm-svn: 149078
* smallvectorize and ArrayRef'ize some stuff.Chris Lattner2012-01-262-5/+5
| | | | llvm-svn: 149077
* Reduce a lot of code duplication by implementing Chris Lattner2012-01-261-138/+16
| | | | | | | | | ConstantExpr::getWithOperandReplaced and ConstantExpr::replaceUsesOfWithOnConstant in terms of ConstantExpr::getWithOperands. While we're at it, make sure that ConstantExpr::getWithOperands covers all instructions: it was missing insert/extractvalue. llvm-svn: 149076
* Update comment for r149070.Chad Rosier2012-01-261-3/+1
| | | | llvm-svn: 149075
* Don't suppress access-control or invalid-type diagnostics from aJohn McCall2012-01-263-4/+19
| | | | | | | | | | | | | declarator just because we were able to build an invalid decl for it. The invalid-type diagnostics, in particular, are still useful to know, and may indicate something about why the decl is invalid. Also, recover from an illegal pointer/reference-to-unqualified-retainable type using __strong instead of __autoreleasing; in general, a random object is much more likely to be __strong, so this avoids unnecessary cascading errors in the most common case. llvm-svn: 149074
* Remove unneeded default caseTobias Grosser2012-01-261-2/+0
| | | | | | This silences a clang warning. llvm-svn: 149073
* Try harder to get X7 definedDouglas Gregor2012-01-261-0/+1
| | | | llvm-svn: 149072
* Change HasMutableFields to HasOnlyCMembers and consider that a tag insideArgyrios Kyrtzidis2012-01-262-5/+8
| | | | | | another tag does not break C-like-ness. rdar://10756831 llvm-svn: 149071
* Replace the use of isPredicable() with isPredicated() inChad Rosier2012-01-262-3/+46
| | | | | | | | | MachineBasicBlock::canFallThrough(). We're interested in the state of the instruction (i.e., is this a barrier or not?), not if the instruction is predicable or not. rdar://10501092 llvm-svn: 149070
* Clear kill flags before propagating a copy.Jakob Stoklund Olesen2012-01-264-1/+145
| | | | | | | | | | The live range of the source register may be extended when a redundant copy is eliminated. Make sure any kill flags between the two copies are cleared. This fixes PR11765. llvm-svn: 149069
* Darwin-specific templates for the output tests.Alexander Potapenko2012-01-264-1/+29
| | | | | | These should fix the output tests on Mac. llvm-svn: 149068
* Don't separately serialize the list of instance variables in anDouglas Gregor2012-01-262-13/+0
| | | | | | Objective-C class. The AST reader just throws away this data anyway! llvm-svn: 149067
* Force layout of more of the unions and structures in this testDouglas Gregor2012-01-261-1/+7
| | | | llvm-svn: 149066
* objc: 'id' and block pointer compare in mergeTypes isFariborz Jahanian2012-01-262-3/+12
| | | | | | made symmetrical. // rdar://10734265 llvm-svn: 149065
* More accurate atos execution which depends on the file type (EXECUTE, DYLIB) ↵Alexander Potapenko2012-01-261-14/+49
| | | | | | | | of the binary. More Linux-like output on Mac (to match more output tests). llvm-svn: 149064
* Fix a bug in AsanProcMaps on Mac: on 64 bits the program was trying to read ↵Alexander Potapenko2012-01-262-11/+22
| | | | | | twice as many segment load commands as the binary actually contained. llvm-svn: 149063
* Tidy up. Fix mismatched return types for error handling.Jim Grosbach2012-01-261-8/+4
| | | | llvm-svn: 149062
* comment tweaksGabor Greif2012-01-261-15/+15
| | | | llvm-svn: 149060
* AST/ExprConstant.cpp: Silence a warning on ms cl.exe. "bool" does not prefer ↵NAKAMURA Takumi2012-01-261-1/+1
| | | | | | to be compared to integer. llvm-svn: 149059
* Suppress any warnings from this test. They aren't interesting, and theyChandler Carruth2012-01-261-3/+3
| | | | | | | | | | end up in the same output file as the layout stuff. There may even be a race condition which is causing this output to confuse the FileCheck in some cases. I actually don't know how on earth the parsing of the layout file even works given that there are diagnostics in the middle of it. ;] llvm-svn: 149058
* Add support for the R_ARM_TARGET1 relocation, which should be given to ↵James Molloy2012-01-268-3/+44
| | | | | | | | relocations applied to all C++ constructors and destructors. This enables the linker to match concrete relocation types (absolute or relative) with whatever library or C++ support code is being linked against. llvm-svn: 149057
* Fix for the following bug in AVX codegen for double-to-int conversions:Victor Umansky2012-01-263-3/+22
| | | | | | | | | | | | | . "fptosi" and "fptoui" IR instructions are defined with round-to-zero rounding mode. . Currently for AVX mode for <4xdouble> and <8xdouble> the "VCVTPD2DQ.128" and "VCVTPD2DQ.256" instructions are selected (for .fp_to_sint. DAG node operation ) by AVX codegen. However they use round-to-nearest-even rounding mode. . Consequently, the conversion produces incorrect numbers. The fix is to replace selection of VCVTPD2DQ instructions with VCVTTPD2DQ instructions. The latter use truncate (i.e. round-to-zero) rounding mode. As .fp_to_sint. DAG node operation is used only for lowering of "fptosi" and "fptoui" IR instructions, the fix in X86InstrSSE.td definition file doesn.t have an impact on other LLVM flows. The patch includes changes in the .td file, LIT test for the changes and a fix in a legacy LIT test (which produced asm code conflicting with LLVN IR spec). llvm-svn: 149056
* Extend the ExternalASTSource interface to allow the AST source toDouglas Gregor2012-01-2613-45/+694
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | provide the layout of records, rather than letting Clang compute the layout itself. LLDB provides the motivation for this feature: because various layout-altering attributes (packed, aligned, etc.) don't get reliably get placed into DWARF, the record layouts computed by LLDB from the reconstructed records differ from the actual layouts, and badness occurs. This interface lets the DWARF data drive layout, so we don't need the attributes preserved to get the answer write. The testing methodology for this change is fun. I've introduced a variant of -fdump-record-layouts called -fdump-record-layouts-simple that always has the simple C format and provides size/alignment/field offsets. There is also a -cc1 option -foverride-record-layout=<file> to take the output of -fdump-record-layouts-simple and parse it to produce a set of overridden layouts, which is introduced into the AST via a testing-only ExternalASTSource (called LayoutOverrideSource). Each test contains a number of records to lay out, which use various layout-changing attributes, and then dumps the layouts. We then run the test again, using the preprocessor to eliminate the layout-changing attributes entirely (which would give us different layouts for the records), but supplying the previously-computed record layouts. Finally, we diff the layouts produced from the two runs to be sure that they are identical. Note that this code makes the assumption that we don't *have* to provide the offsets of bases or virtual bases to get the layout right, because the alignment attributes don't affect it. I believe this assumption holds, but if it does not, we can extend LayoutOverrideSource to also provide base offset information. Fixes the Clang side of <rdar://problem/10169539>. llvm-svn: 149055
* Add HasXOP predicate check covering a bunch of XOP intrinsic patterns.Craig Topper2012-01-261-0/+2
| | | | llvm-svn: 149054
OpenPOWER on IntegriCloud