summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Reapply Eli's r127852 now that the pre-RA scheduler can spill EFLAGS.Andrew Trick2011-03-233-16/+103
| | | | | | (target-specific branchless method for double-width relational comparisons on x86) llvm-svn: 128175
* Split out relocation resolution into target-specific bits.Jim Grosbach2011-03-231-3/+71
| | | | llvm-svn: 128173
* The high bit of a Thumb2 ADR's offset is stored in bit 26, not bit 25.Owen Anderson2011-03-231-1/+1
| | | | | | This fixes 464.h264ref with the integrated assembler. llvm-svn: 128172
* Fix double-free of Module.Jim Grosbach2011-03-231-1/+0
| | | | | | | | The ExecutionEngine constructor already added the module, so there's no need to call addModule() directly. Doing so causes a double-free of the Module at program termination. llvm-svn: 128171
* Fix CFG-construction bug when run from ↵Ted Kremenek2011-03-232-9/+31
| | | | | | | | AnalysisBasedWarnings::IssueWarnings() where block-level expressions that need to be recorded in the Stmt*->CFGBlock* map were not always done so. Fixes <rdar://problem/9171946>. llvm-svn: 128170
* Fix a bug introduced by my patch yesterday: BL is a 4-byte instructions like ↵Owen Anderson2011-03-231-3/+2
| | | | | | BLX, rather than a 2-byte instruction like B. llvm-svn: 128169
* Unbreak testDouglas Gregor2011-03-232-6/+13
| | | | llvm-svn: 128168
* Silence clang warnings.Johnny Chen2011-03-231-0/+8
| | | | llvm-svn: 128167
* Ensure that def-side physreg copies are scheduled above any other usesAndrew Trick2011-03-231-0/+9
| | | | | | | | | so the scheduler can't create new interferences on the copies themselves. Prior to this fix the scheduler could get stuck in a loop creating copies. Fixes PR9509. llvm-svn: 128164
* whitespaceAndrew Trick2011-03-231-2/+2
| | | | llvm-svn: 128163
* Turns out that the test failure wrt:Johnny Chen2011-03-235-14/+37
| | | | | | | | | | | | | | | | | | | | | | | rdar://problem/9173060 lldb hangs while running unique-types disappears if running with clang version >= 3. Modify the TestUniqueTypes.py to detect if we are running with clang version < 3 and, if true, skip the test. Update the lldbtest.system() function to return a tuple of (stdoutdata, stderrdata) since we need the stderr data from "clang -v" command. Modify existing clients of lldbtest.system() to now use, for example: # First, capture the golden output emitted by the oracle, i.e., the # series of printf statements. - go = system("./a.out", sender=self) + go = system("./a.out", sender=self)[0] # This golden list contains a list of (variable, value) pairs extracted # from the golden output. gl = [] And add two utility functions to lldbutil.py. llvm-svn: 128162
* Start of relocation resolution for the runtime dyld library.Jim Grosbach2011-03-231-21/+130
| | | | llvm-svn: 128161
* Make sure to report any errors from the runtime dyld.Jim Grosbach2011-03-231-1/+2
| | | | llvm-svn: 128160
* Support for Transparent unions used as overloadableFariborz Jahanian2011-03-234-2/+79
| | | | | | | function parameter. // rdar:// 9129552 and PR9406. llvm-svn: 128159
* Add a test for !ptr-to-member (should fail)Marshall Clow2011-03-231-2/+3
| | | | llvm-svn: 128158
* Revert r128156 because of CodeGenObjC/messages.m and Coverage/codegen-gnu.m.Andrew Trick2011-03-231-9/+10
| | | | llvm-svn: 128157
* Remove the redundant loads / stores to globals that we were generating for ↵David Chisnall2011-03-231-10/+9
| | | | | | selectors (GNU runtimes). llvm-svn: 128156
* Don't coalesce identical DBG_VALUE instructions prematurely.Jakob Stoklund Olesen2011-03-231-3/+1
| | | | | | | | Each of these instructions may have a RegsClobberInsn entry that can't be ignored. Consecutive ranges are coalesced later when DwarfDebug::emitDebugLoc merges entries. llvm-svn: 128155
* Supports building with a list of targets that does not containOscar Fuentes2011-03-233-22/+27
| | | | | | X86. Fixes PR9533. llvm-svn: 128154
* PTX: Improve support for 64-bit addressingJustin Holewinski2011-03-233-21/+72
| | | | | | | | | - Fix bug in ADDRrr/ADDRri/ADDRii selection for 64-bit addresses - Add comparison selection for i64 - Add zext selection for i32 -> i64 - Add shl/shr/sha support for i64 llvm-svn: 128153
* Initial work on refactoring GNU runtime code (long overdue - it's quite obviousDavid Chisnall2011-03-231-298/+349
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | that I hadn't used C++ for several years before writing most of this code). Still lots more to do. This set of changes includes: - Remove the distinction between typed and untyped selectors. More accurately reflect what the runtime does, by using typed selectors everywhere, with an empty type field if the types are unknown. Now we just store a small list of types for each selector (in theory, this should always be exactly one, but this constraint was not enforced back in 1986 when it should have been). - Add some consistency to how runtime functions are created. These are all generated via the LazyRuntimeFunction class (which might be useful outside CGObjCGNU - feel free to move it into a header if it is). This function stores the types of a function, looks it up the first time it's used, and caches the result. This means that we're now not wasting time constructing the llvm::FunctionType every time some of the functions are looked up, but also not inserting references to runtime functions into the module if they're not actually used. - Started separating out the fragile and non-fragile ABI behaviours into two subclasses of CGObjCGNU: CGObjCGCC for the legacy GCC runtime ABI and CGObjCGNUstep for the new GNUstep ABI. Not all of the differences in behaviour are factored out yet, but they will be in future commits. - Removed all of the CodeGen:: things: we've been using namespace CodeGen in this file for ages, so having explicit namespace specifiers is just a bit confusing. - Added a few more comments. - Used llvm::StringRef instead of std::string in a few places. - Finally got around to storing the module path in the module structure. The ABI says that the compiler should do this, although it's not used in the runtime or exposed outside the runtime, so it's pretty useless. Still to do: - We currently have two code paths for generating try blocks, one for ObjC and one for ObjC++. Not only are these substantially similar, they are also very similar to the CGObjCMac version. These need factoring out into a single parameterised implementation, either in CGObjCRuntime or CodeGenFunction. The EmitObjCXXTryStmt() function was added so that the changes to fix a bug in time for the 2.9 release would be self-contained and reduce the chances of breaking anything else, but these should be done properly as soon as possible. - Split up some large functions (e.g. GenerateClass()) into smaller functions for generating the various data structures. - The method lookup code into the two subclasses, removing the conditionals in the message send functions. - Add doxygen comments on the remaining undocumented functions. - We seem to be generating global pointer variables for selectors, then storing a pointer to the selector, then generating a load of this pointer (and then a load of the real selector later) every time a static selector is used. I can only assume I was asleep or drunk when I did this - we should just be referencing the selectors directly in the selector array. llvm-svn: 128152
* Test case for r128150.Devang Patel2011-03-231-0/+23
| | | | llvm-svn: 128151
* Update type cache when a type is completed.Devang Patel2011-03-234-5/+28
| | | | | | Radar 9168773 llvm-svn: 128150
* Revert r128140 for now.Anders Carlsson2011-03-232-52/+0
| | | | llvm-svn: 128149
* Teach DelayedDiagnostic to copy its string, rather than hope that theDouglas Gregor2011-03-234-17/+55
| | | | | | | string itself lives longer than the DelayedDiagnostic. Fixes a recent use-after-free regression due to my availability attribute work. llvm-svn: 128148
* Ignore weak_import on Objective-C property and method declarations onDouglas Gregor2011-03-232-5/+5
| | | | | | all platforms, not just darwin. Fixes the regression in this test case. llvm-svn: 128147
* Fix PR9464 by correcting some math that just happened to be right in most casesCameron Zwarich2011-03-232-11/+26
| | | | | | that were hit in practice. llvm-svn: 128146
* Notify the delegate before removing dead values from a live interval.Jakob Stoklund Olesen2011-03-231-0/+2
| | | | | | The register allocator needs to know when the range shrinks. llvm-svn: 128145
* Allow the allocation of empty live ranges that have uses.Jakob Stoklund Olesen2011-03-231-1/+8
| | | | | | Empty ranges may represent undef values. llvm-svn: 128144
* Dump the register map before rewriting.Jakob Stoklund Olesen2011-03-231-1/+1
| | | | llvm-svn: 128143
* switch a few Driver APIs to use llvm::ArrayRef, cleaning up code.Chris Lattner2011-03-234-15/+12
| | | | llvm-svn: 128142
* remove a dead variable.Chris Lattner2011-03-231-1/+0
| | | | llvm-svn: 128141
* A global variable with internal linkage where all uses are in one function ↵Anders Carlsson2011-03-232-0/+52
| | | | | | and whose address is never taken is a non-escaping local object and can't alias anything else. llvm-svn: 128140
* Fix crash in clang_getInstantiationLoc() when ↵Ted Kremenek2011-03-232-9/+32
| | | | | | | | SourceManager::getInstantiationLoc() can return a SourceLocatin with an invalid FileID on invalid code. Fixes <rdar://problem/9164623>. llvm-svn: 128139
* std::vector::data() is not portable to VS. Use a gross hack instead.Ted Kremenek2011-03-231-1/+3
| | | | llvm-svn: 128138
* linux: simple support for process input and outputStephen Wilson2011-03-233-0/+72
| | | | llvm-svn: 128137
* Eliminate a pile of "type qualifiers ignored on function return type" warnings.Stephen Wilson2011-03-232-2/+2
| | | | llvm-svn: 128136
* Update autogen'd LLDB_vers.c.Stephen Wilson2011-03-231-1/+1
| | | | | | | | The makefile build uses scripts/generate-vers.pl to build an appropriate LLDB_vers.c file. The declarations for these symbols now carry a liblldb_core prefix so update the script to generate the correct names. llvm-svn: 128135
* Add a missing include needed on Linux and remove a trailing comma.Stephen Wilson2011-03-232-3/+4
| | | | llvm-svn: 128134
* linux: add Host/linux subdirectoryStephen Wilson2011-03-234-1/+55
| | | | | | | Start putting linux specific host code in its own directory. For now, just implement Host::GetOSVersion. llvm-svn: 128133
* Added block number and name to isel debug output.Andrew Trick2011-03-231-12/+25
| | | | | | | | I'm tired of doing this manually for each checkout. If anyone knows a better way debug isel for non-trivial tests feel free to revert and let me know how to do it. llvm-svn: 128132
* Checked in a modified test script to go with rdar://problem/9173060:Johnny Chen2011-03-231-0/+8
| | | | | | test suite: lldb hangs while running unique-types llvm-svn: 128131
* Update the Clang attribute emitter to handle attributes of 'version'Douglas Gregor2011-03-231-0/+46
| | | | | | | kind, and fix serialization/deserialization of IdentifierInfo attributes. These are requires for the new 'availability' attribute. llvm-svn: 128130
* Convert OffsetFromNearestVBast parameter of InitializeVTablePointer(s) toKen Dyck2011-03-232-14/+15
| | | | | | CharUnits. No change in functionality intended. llvm-svn: 128129
* linux: PlatformLinux improvementsStephen Wilson2011-03-232-10/+100
| | | | | | | Add a few missing virtual methods to PlatformLinux and have it register itself with PluginManager. llvm-svn: 128128
* Implement a new 'availability' attribute, that allows one to specifyDouglas Gregor2011-03-2345-109/+1060
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | which versions of an OS provide a certain facility. For example, void foo() __attribute__((availability(macosx,introduced=10.2,deprecated=10.4,obsoleted=10.6))); says that the function "foo" was introduced in 10.2, deprecated in 10.4, and completely obsoleted in 10.6. This attribute ties in with the deployment targets (e.g., -mmacosx-version-min=10.1 specifies that we want to deploy back to Mac OS X 10.1). There are several concrete behaviors that this attribute enables, as illustrated with the function foo() above: - If we choose a deployment target >= Mac OS X 10.4, uses of "foo" will result in a deprecation warning, as if we had placed attribute((deprecated)) on it (but with a better diagnostic) - If we choose a deployment target >= Mac OS X 10.6, uses of "foo" will result in an "unavailable" warning (in C)/error (in C++), as if we had placed attribute((unavailable)) on it - If we choose a deployment target prior to 10.2, foo() is weak-imported (if it is a kind of entity that can be weak imported), as if we had placed the weak_import attribute on it. Naturally, there can be multiple availability attributes on a declaration, for different platforms; only the current platform matters when checking availability attributes. The only platforms this attribute currently works for are "ios" and "macosx", since we already have -mxxxx-version-min flags for them and we have experience there with macro tricks translating down to the deprecated/unavailable/weak_import attributes. The end goal is to open this up to other platforms, and even extension to other "platforms" that are really libraries (say, through a #pragma clang define_system), but that hasn't yet been designed and we may want to shake out more issues with this narrower problem first. Addresses <rdar://problem/6690412>. As a drive-by bug-fix, if an entity is both deprecated and unavailable, we only emit the "unavailable" diagnostic. llvm-svn: 128127
* Convert NonVirtual parameter of ApplyNonVirtualAndVirtualOffset() toKen Dyck2011-03-231-8/+11
| | | | | | CharUnits. No change in functionality intended. llvm-svn: 128126
* Fix test suite failures by modifying the script for testing abbreviations.Johnny Chen2011-03-231-2/+2
| | | | | | Failures were due to new commands introduced. llvm-svn: 128125
* Fix compile warnings wrt LLDBWrapPython.cpp.Johnny Chen2011-03-231-2/+2
| | | | llvm-svn: 128124
* Added new platform commands:Greg Clayton2011-03-2319-135/+848
| | | | | | | | | | | | | | | | platform connect <args> platform disconnect Each platform can decide the args they want to use for "platform connect". I will need to add a function that gets the connect options for the current platform as each one can have different options and argument counts. Hooked up more functionality in the PlatformMacOSX and PlatformRemoteiOS. Also started an platform agnostic PlatformRemoteGDBServer.cpp which can end up being used by one or more actual platforms. It can also be specialized and allow for platform specific commands. llvm-svn: 128123
OpenPOWER on IntegriCloud