summaryrefslogtreecommitdiffstats
path: root/clang/lib/Basic
Commit message (Collapse)AuthorAgeFilesLines
* Objective-C migrator: some cleanup.Fariborz Jahanian2013-07-241-0/+3
| | | | | | | | Expose static type of init/alloc/retain with instance type as well. Ad-hoc cases are coming next. llvm-svn: 187068
* ObjC migrator: more knobs toward doingFariborz Jahanian2013-07-231-1/+1
| | | | | | instancetype migration. llvm-svn: 187000
* ObjC migrator: Define family of methodsFariborz Jahanian2013-07-231-0/+33
| | | | | | | which are candidate for migrating to 'instancetype'. wip. llvm-svn: 186981
* Add a -fno-math-builtin option to the Clang -cc1Eli Bendersky2013-07-231-3/+18
| | | | llvm-svn: 186899
* Replace 'unsigned short' with 'uint16_t' in a packed data structure for ↵Craig Topper2013-07-211-1/+1
| | | | | | consistency with other fields and to be explicit about bit count. llvm-svn: 186796
* Revert r186649 because it wasn't unnecessary and add a comment.Craig Topper2013-07-211-7/+11
| | | | llvm-svn: 186795
* DiagnosticIDs: Forbid Diag ID from being validDavid Majnemer2013-07-201-8/+4
| | | | | | | | | | Diag ID is used throughout clang as a sentinel id meaning "this is an invalid diagnostic id." Confusingly, Diag ID maps to a valid, usable, diagnostic id. Instead, start diagnostic ids at ID one. Incidently, remove an unused element from StaticDiagInfo. llvm-svn: 186760
* [SystemZ] Add -march= command-line optionRichard Sandiford2013-07-191-0/+11
| | | | llvm-svn: 186694
* Remove unnecessary IsFirst variable from debug codde in GetDiagInfo.Craig Topper2013-07-191-11/+7
| | | | llvm-svn: 186649
* OpenMP: basic support for #pragma omp parallelAlexey Bataev2013-07-191-1/+86
| | | | llvm-svn: 186647
* Update for llvm API change.Rafael Espindola2013-07-161-8/+4
| | | | llvm-svn: 186448
* Use llvm::array_lengthof to replace sizeof(array)/sizeof(array[0]).Craig Topper2013-07-151-4/+4
| | | | llvm-svn: 186300
* Replace C++0x in a comment with C++11Craig Topper2013-07-141-1/+1
| | | | llvm-svn: 186287
* Simplify GetBuiltinNames by hoising the NoBuiltins argument out of it.Eli Bendersky2013-07-111-4/+3
| | | | llvm-svn: 186106
* Use SmallVectorImpl::reverse_iterator instead of SmallVector to avoid ↵Craig Topper2013-07-081-2/+2
| | | | | | specifying the vector size. llvm-svn: 185784
* Use SmallVectorImpl instead of SmallVector for iterators and references to ↵Craig Topper2013-07-041-1/+1
| | | | | | avoid specifying the vector size unnecessarily. llvm-svn: 185610
* [PowerPC] FreeBSD does not require f128 in its data layout string.Bill Schmidt2013-07-031-1/+1
| | | | | | Long double is 64 bits on FreeBSD PPC, so the f128 entry is superfluous. llvm-svn: 185582
* Dont define __LONG_DOUBLE_128__ unless LongDoubleWidth is really 128bits width.Roman Divacky2013-07-031-1/+2
| | | | | | It's not the case on ie. FreeBSD. llvm-svn: 185572
* Fix MSP430 builtin types.Anton Korobeynikov2013-07-011-3/+3
| | | | | | Patch by Job Noorman! llvm-svn: 185362
* Driver: Push triple objects around instead of going to std::string all the time.Benjamin Kramer2013-06-292-308/+276
| | | | | | No functionality change. llvm-svn: 185261
* Add support for passing v8fp options via -mfpu.Joey Gouly2013-06-271-1/+1
| | | | llvm-svn: 185075
* Add support for passing '-target armv8' through the Driver.Joey Gouly2013-06-261-0/+1
| | | | llvm-svn: 184970
* Fix a couple of PPC predefined macros that I spotted while driving byChandler Carruth2013-06-251-2/+2
| | | | | | | | this code. These aren't technically standard predefines for the platform but apparantly lots of folks use them as they show up within LLVM's own codebase. ;] This may even fix some self host issues w/ the JIT!!! llvm-svn: 184830
* [NVPTX] Add NVPTX register constraintsJustin Holewinski2013-06-211-3/+12
| | | | llvm-svn: 184578
* This patch adds new private headers to the module map. PrivateLawrence Crowl2013-06-201-2/+9
| | | | | | | headers may be included from within the module, but not from outside the module. llvm-svn: 184471
* size_t on Darwin AAPCS targets is "unsigned long". <rdar://problem/14136459>Bob Wilson2013-06-181-0/+3
| | | | | | | | Some embedded targets use ARM's AAPCS with iOS header files that define size_t as unsigned long, which conflicts with the usual AAPCS definition of size_t as unsigned int. llvm-svn: 184171
* Use atomic instructions on Bitrig armv6. Patch by Patrick Wildt.Rafael Espindola2013-06-171-1/+3
| | | | llvm-svn: 184113
* Emit native implementations of atomic operations on FreeBSD/armv6.Ed Schouten2013-06-151-2/+2
| | | | | | | | | | | | Just like on Linux, FreeBSD/armv6 assumes the system supports ldrex/strex unconditionally. It is also used by the kernel. We can therefore enable support for it, like we do on Linux. While there, change one of the unit tests to explicitly test against armv5 instead of armv7, as it actually tests whether libcalls are emitted. llvm-svn: 184040
* cleanup (address some more review comments for r183474):Adrian Prantl2013-06-101-6/+6
| | | | | | | | - reduce default buffer size to 64, which will still be large enough to hold any property names found in the wild. - get rid of the /*static*/ comments. llvm-svn: 183697
* address some comments on r183474:Adrian Prantl2013-06-071-10/+14
| | | | | | | | | | - factor the name construction part out from constructSetterName - rename constructSetterName to the more appropriate constructSetterSelector no functionality change intended. rdar://problem/14035789 llvm-svn: 183582
* Thread the 'Invalid' out parameter through SourceManager::getSLocEntry() and ↵Argyrios Kyrtzidis2013-06-071-1/+4
| | | | | | | | callees of SourceManager::getSLocEntryByID(). Also add an 'Invalid' check in SourceManager::computeMacroArgsCache(). llvm-svn: 183538
* Do not report -Wasm-operand-widths for ARM output operands. <rdar://14050337>Bob Wilson2013-06-031-2/+1
| | | | | | | | | We're getting reports of this warning getting triggered in cases where it is not adding any value. There is no asm operand modifier that you can use to silence it, and there's really nothing wrong with having an LDRB, for example, with a "char" output. llvm-svn: 183172
* Disable non-standard library builtins in non-gnu language modes.Benjamin Kramer2013-05-311-5/+4
| | | | | | Fixes PR16138. llvm-svn: 183015
* Make isBeforeInTranslationUnit consistent in the face of failures to get a ↵Argyrios Kyrtzidis2013-05-251-1/+1
| | | | | | valid FileID (V2). llvm-svn: 182698
* Make isBeforeInTranslationUnit consistent in the face of failures to get a ↵Argyrios Kyrtzidis2013-05-241-1/+4
| | | | | | | | valid FileID. Suggested by Jordan. llvm-svn: 182695
* Add some safety checks in a couple of SourceManager functions.Argyrios Kyrtzidis2013-05-241-5/+14
| | | | | | This is to address crash in rdar://13932308 llvm-svn: 182681
* Replace Count{Leading,Trailing}Zeros_{32,64} with count{Leading,Trailing}Zeros.Michael J. Spencer2013-05-241-1/+1
| | | | llvm-svn: 182675
* OpenBSD/sparc64 uses long long for int64_t and intmax_t.Jakob Stoklund Olesen2013-05-191-3/+10
| | | | | | Other operating systems, including FreeBSD and NetBSD, use long. llvm-svn: 182215
* [Lexer] Improve Lexer::getSourceText() when the given range deals with ↵Argyrios Kyrtzidis2013-05-161-0/+108
| | | | | | | | function macro arguments. This is a modified version of a patch by Manuel Klimek. llvm-svn: 182055
* fix PR 15726: ptrdiff_t should be int on PowerPC DarwinDavid Fang2013-05-161-0/+1
| | | | llvm-svn: 182029
* Use correct types for SPARC v9.Jakob Stoklund Olesen2013-05-151-0/+5
| | | | | | It's an LP64 platform. llvm-svn: 181867
* Use atomic instructions on linux thumb v7.Rafael Espindola2013-05-141-3/+17
| | | | | | | This matches gcc's behaviour. The patch also explicitly parses the version so that this keeps working when we add support for v8. llvm-svn: 181750
* Use atomic instructions on ARM linux.Rafael Espindola2013-05-131-1/+16
| | | | | | | | | This is safe given how the pre-v6 atomic ops funcions in libgcc are implemented. This fixes pr15429. llvm-svn: 181728
* OpenMP threadprivate with qualified names.Alexey Bataev2013-05-131-1/+2
| | | | llvm-svn: 181683
* Add SystemZ supportUlrich Weigand2013-05-061-0/+102
| | | | | | | | | | | | | | This patch then adds all the usual platform-specific pieces for SystemZ: driver support, basic target info, register names and constraints, ABI info and vararg support. It also adds new tests to verify pre-defined macros and inline asm, and updates a test for the minimum alignment change. This version of the patch incorporates feedback from reviews by Eric Christopher and John McCall. Thanks to all reviewers! Patch by Richard Sandiford. llvm-svn: 181211
* Allow targets to define minimum alignment for global variablesUlrich Weigand2013-05-061-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds a new common code feature that allows platform code to request minimum alignment of global symbols. The background for this is that on SystemZ, the most efficient way to load addresses of global symbol is the LOAD ADDRESS RELATIVE LONG (LARL) instruction. This instruction provides PC-relative addressing, but only to *even* addresses. For this reason, existing compilers will guarantee that global symbols are always aligned to at least 2. [ Since symbols would otherwise already use a default alignment based on their type, this will usually only affect global objects of character type or character arrays. ] GCC also allows creating symbols without that extra alignment by using explicit "aligned" attributes (which then need to be used on both definition and each use of the symbol). To enable support for this with Clang, this patch adds a TargetInfo::MinGlobalAlign variable that provides a global minimum for the alignment of every global object (unless overridden via explicit alignment attribute), and adds code to respect this setting. Within this patch, no platform actually sets the value to anything but the default 1, resulting in no change in behaviour on any existing target. This version of the patch incorporates feedback from reviews by Eric Christopher and John McCall. Thanks to all reviewers! Patch by Richard Sandiford. llvm-svn: 181210
* AArch64: teach Clang about __clear_cache intrinsicTim Northover2013-05-041-2/+12
| | | | | | | libgcc provides a __clear_cache intrinsic on AArch64, much like it does on 32-bit ARM. llvm-svn: 181111
* Revert r177218.Argyrios Kyrtzidis2013-05-031-1/+0
| | | | | | Per discussion in cfe-commits, asserting may be a better way than introducing a special test flag. llvm-svn: 181073
* Remove DiagnosticConsumer::clone(), a bad idea that is now unused.Douglas Gregor2013-05-031-5/+0
| | | | llvm-svn: 181070
* When building a module, forward diagnostics to the outer diagnostic consumer.Douglas Gregor2013-05-031-0/+22
| | | | | | | | | | | | | | | Previously, we would clone the current diagnostic consumer to produce a new diagnostic consumer to use when building a module. The problem here is that we end up losing diagnostics for important diagnostic consumers, such as serialized diagnostics (where we'd end up with two diagnostic consumers writing the same output file). With forwarding, the diagnostics from all of the different modules being built get forwarded to the one serialized-diagnostic consumer and are emitted in a sane way. Fixes <rdar://problem/13663996>. llvm-svn: 181067
OpenPOWER on IntegriCloud