summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* [llvm-readobj] Fix compile error.Simon Atanasyan2014-06-181-1/+1
| | | | llvm-svn: 211151
* [llvm-readobj][ELF] New `-mips-plt-got` command line option to outputSimon Atanasyan2014-06-186-0/+547
| | | | | | | | MIPS GOT section. Patch reviewed by Rafael Espindola. llvm-svn: 211150
* AArch64: re-enable tests that were looking for a non-existent backend.Tim Northover2014-06-1832-32/+32
| | | | | | | | In the final phase of the merge, I managed to disable a bunch of Clang tests accidentally. Fortunately none of them seem to have broken in the interim. llvm-svn: 211149
* [OPENMP] Reformatting and code improvement.Alexey Bataev2014-06-186-74/+86
| | | | llvm-svn: 211147
* Revert "Random Number Generator (llvm)"JF Bastien2014-06-185-128/+1
| | | | | | | | This reverts commit cccba093090d127e0b6d17473b14c264c14c5259. It causes build breakage. llvm-svn: 211146
* Random Number Generator (llvm)JF Bastien2014-06-185-1/+128
| | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Provides an abstraction for a random number generator (RNG) that produces a stream of pseudo-random numbers. The current implementation uses C++11 facilities and is therefore not cryptographically secure. The RNG is salted with the text of the current command line invocation. In addition, a user may specify a seed (reproducible builds). In clang, the seed can be set via -frandom-seed=X In the back end, the seed can be set via -rng-seed=X This is the llvm part of the patch. clang part: D3391 Reviewers: ahomescu, rinon, nicholas, jfb Reviewed By: jfb Subscribers: jfb, perl Differential Revision: http://reviews.llvm.org/D3390 llvm-svn: 211145
* [AArch64] Fix a pattern match failure caused by creating improper CONCAT_VECTOR.Kevin Qin2014-06-182-27/+72
| | | | | | | | | ReconstructShuffle() may wrongly creat a CONCAT_VECTOR trying to concat 2 of v2i32 into v4i16. This commit is to fix this issue and try to generate UZP1 instead of lots of MOV and INS. Patch is initalized by Kevin Qin, and refactored by Tim Northover. llvm-svn: 211144
* Replace some assert(0)'s with llvm_unreachable.Craig Topper2014-06-183-5/+5
| | | | llvm-svn: 211143
* Convert an llvm_unreachable in an 'else' block to a removal of the 'if' and ↵Craig Topper2014-06-181-3/+3
| | | | | | an assertion of its condition. Suggestion from David Blaikie. llvm-svn: 211142
* Replace some assert(0)'s with llvm_unreachable.Craig Topper2014-06-1819-27/+28
| | | | llvm-svn: 211141
* [OPENMP] Initial support for '#pragma omp for' (fixed incompatibility with ↵Alexey Bataev2014-06-1834-236/+2868
| | | | | | MSVC). llvm-svn: 211140
* Replace some assert(0)'s with llvm_unreachable.Craig Topper2014-06-182-7/+7
| | | | llvm-svn: 211139
* Convert assert(0) to llvm_unreachable to silence a warning about Addend ↵Craig Topper2014-06-181-1/+1
| | | | | | being uninitialized in default case. llvm-svn: 211138
* Fix bug in code for avoiding dynamic initialization of dllimport globalsHans Wennborg2014-06-182-1/+18
| | | | | | | | | | | | | When instantiating dllimport variables with dynamic initializers, don't bail out of Sema::InstantiateVariableInitializer without calling PopExpressionEvaluationContext(). This was causing a stale object to stay on the ExprEvalContexts stack, causing subsequent calls to getCurrentMangleNumberContext() to fail, resulting in incorrect numbering of static locals (and probably other broken things). llvm-svn: 211137
* Add locking around the m_owners collection in the breakpoint site. If we ↵Jim Ingham2014-06-182-1/+13
| | | | | | | | | | are in the middle of "BreakpointLocation::ShouldStop" we don't want other commands (like "break disable") to mutate the owners of this breakpoint out from under us. <rdar://problem/17255589> llvm-svn: 211136
* Documentation for #pragma clang loop directive and options vectorize and ↵Tyler Nowicki2014-06-184-1/+85
| | | | | | | | interleave. Reviewed by: Aaron Ballman and Dmitri Gribenko llvm-svn: 211135
* Fix the caller of checkCorrectionVisibility too.Kaelyn Takata2014-06-171-1/+1
| | | | | | | | That's what I get for hurredly splitting the small change out of a much bigger change that had moved where checkCorrectionVisibility was being called. llvm-svn: 211134
* Remove an unused argument from checkCorrectionVisibility.Kaelyn Takata2014-06-171-2/+1
| | | | llvm-svn: 211133
* Objective-C ARC. Do not warn about properties with bothFariborz Jahanian2014-06-174-12/+44
| | | | | | | | | IBOutlet and weak attributes when accessed being unpredictably set to nil because usage of such properties are always single threaded and its ivar cannot be set to nil asynchronously. // rdar://15885642 llvm-svn: 211132
* Add the coverage cflags to the link step as well to make sureEric Christopher2014-06-171-0/+1
| | | | | | that we link in the support libraries. llvm-svn: 211131
* Allow X86FastIsel to cope with 64 bit absolute relocationsLouis Gerbarg2014-06-173-15/+17
| | | | | | | | | | | | This patch is a follow up to r211040 & r211052. Rather than bailing out of fast isel this patch will generate an alternate instruction (movabsq) instead of the leaq. While this will always have enough room to handle the 64 bit displacment it is generally over kill for internal symbols (most displacements will be within 32 bits) but since we have no way of communicating the code model to the the assmebler in order to avoid flagging an absolute leal/leaq as illegal when using a symbolic displacement. llvm-svn: 211130
* Retry building modules that were compiled by other instances and are out-of-dateBen Langmuir2014-06-171-26/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When another clang instance builds a module, it may still be considered "out of date" for the current instance in a couple of cases*. This patch prevents us from giving spurious errors when compilers race to build a module by allowing the module load to fail when the pcm was built by a different compiler instance. * Cases where a module can be out of date despite just having been built: 1) There are different -I paths between invocations that result in finding a different module map file for some dependent module. This is not an error, and should never be diagnosed. <rdar://problem/16843887> 2) There are file system races where the headers making up a module are touched or moved. Although this can sometimes mean trouble, diagnosing it only during a build-race is worse than useless and we cannot detect this in general. It is more robust to just rebuild. This was causing spurious issues in some setups where only the modtime of headers was bumped during a build. <rdar://problem/16157638> llvm-svn: 211129
* Added gdb-remote auxv test for chunked reads.Todd Fiala2014-06-172-0/+82
| | | | | | | | Verifies that a sum of offset,length auxv reads matches a single large read, and that the auxv data extracted from them match. llvm-svn: 211127
* [FastISel][X86] Optimize predicates and fold CMP instructions.Juergen Ributzka2014-06-173-13/+996
| | | | | | | | | This optimizes predicates for certain compares, such as fcmp oeq %x, %x to fcmp ord %x, %x. The latter one is more efficient to generate. The same optimization is applied to conditional branches. llvm-svn: 211126
* Remove more occurrences of the unused-mutex-parameter pattern.Zachary Turner2014-06-171-16/+9
| | | | | | | | | | | | | | | | This pattern loses some of its usefulness when the mutex type is statically polymorphic as opposed to runtime polymorphic, as swapping out the mutex type requires changing a significant number of function parameters, and templatizing the function parameter requires the methods to be defined in the headers. Furthermore, if LLVM is compiled with threads disabled then there may even be no mutex to acquire anyway, so it should not be up to individual APIs to know whether or not acquiring a mutex is required to use those APIs to begin with. It should be up to the user of the API. llvm-svn: 211125
* Those were not the right defines for memory errors, and the right defines aren'tJim Ingham2014-06-171-8/+1
| | | | | | | | available. So going back to a generic error instead. <rdar://problem/17058708> llvm-svn: 211124
* Fix up lldb cmake linker flags for MacOSX.Todd Fiala2014-06-171-1/+2
| | | | | | | | | | | | | | | Change r210035 broke the Darwin cmake build. The initial change was intended to stop the --start-group/--end-group linker flags from being passed to non-gcc/clang-looking compilers, stopping MSVC from warning on linking. That change, however, caused MacOSX cmake-based builds to start using the --start-group/ --end-group flags, even though the MacOSX linker doesn't support them. That broke the MacOSX clang build. The fix keeps the newer check for a gcc-compatible compiler, but specifically excludes MacOSX. llvm-svn: 211123
* Remove dead code.Diego Novillo2014-06-171-11/+0
| | | | | | | | The parsing for -Rpass= had been factored into the function GenerateOptimizationRemarkRegex, but at the time I forgot to remove the original code that just handled OPT_Rpass_EQ. llvm-svn: 211122
* Change libclang initialization to use std::call_once instead ofZachary Turner2014-06-171-12/+11
| | | | | | | hand rolled once-initialization, and rename the mutex to be more descriptive of its actual purpose. llvm-svn: 211121
* R600/SI: Make sure target flags are set on pseudo VOP3 instructionsTom Stellard2014-06-172-14/+14
| | | | llvm-svn: 211120
* lit: simplify population of the actual_inputs arrayHans Wennborg2014-06-171-3/+3
| | | | | | | Add all inputs to the array, except those starting with @, which are treated as response files and expanded. llvm-svn: 211119
* Merge lib/Support/WindowsError.cpp into ib/Support/ErrorHandling.cpp.Rafael Espindola2014-06-173-92/+69
| | | | | | | The OSX ranlib warns on files with no symbols, and lib/Support/WindowsError.cpp was empty when building on non-windows. llvm-svn: 211118
* Add "-format darwin" to llvm-size to be like darwin's size(1) -m output, andKevin Enderby2014-06-174-27/+276
| | | | | | | | | | | | | | | and the -l option for the long format. Also when the object is a Mach-O file and the format is berkeley produce output like darwin’s default size(1) summary berkeley derived output. Like System V format, there are also some small changes in how and where the file names and archive member names are printed for darwin and Mach-O. Like the changes to llvm-nm these are the first steps in seeing if it is possible to make llvm-size produce the same output as darwin's size(1). llvm-svn: 211117
* R600/SI: Match cttz_zero_undefMatt Arsenault2014-06-173-1/+63
| | | | llvm-svn: 211116
* R600/SI: Match ctlz_zero_undefMatt Arsenault2014-06-174-3/+65
| | | | llvm-svn: 211115
* Subject: [PATCH-v5] Detect and mark reduction like statementsJohannes Doerfert2014-06-172-1/+79
| | | | | | | | | + Flag to indicate reduction like statements + Command line option to (dis)allow multiplicative reduction opcodes + Two simple positive test cases, one fp test case w and w/o fast math + One "negative" test case (only reduction like but no reduction) llvm-svn: 211114
* Revert "[OPENMP] Initial support for '#pragma omp for'."Rafael Espindola2014-06-1734-2864/+236
| | | | | | | | This reverts commit r211096. Looks like it broke the msvc build: SemaOpenMP.cpp(140) : error C4519: default template arguments are only allowed on a class template llvm-svn: 211113
* Fix the comment which was backwards.Yaron Keren2014-06-171-1/+1
| | | | llvm-svn: 211112
* mark the old jit tests as unsupported for powerpc64 (for cmake)Will Schmidt2014-06-171-0/+3
| | | | | | | | mark the old JIT tests as unsupported for powerpc64 - CMake style. This follows the style used for hexagon/arm64/aarch64. The equivalent tests still run under the supported MCJIT/* llvm-svn: 211111
* R600: Use LDS and vectors for private memoryTom Stellard2014-06-1725-73/+788
| | | | llvm-svn: 211110
* R600/SI: Add a pattern for llvm.AMDGPU.barrier.globalTom Stellard2014-06-173-1/+16
| | | | llvm-svn: 211109
* SelectionDAG: Expand i64 = FP_TO_SINT i32Tom Stellard2014-06-173-0/+72
| | | | llvm-svn: 211108
* R600/SI: Re-initialize the m0 register after using it for indirect addressingTom Stellard2014-06-171-37/+50
| | | | | | | | | | | | We need to store a value greater than or equal to the number of LDS bytes allocated by the shader in the m0 register in order for LDS instructions to work correctly. We always initialize m0 at the beginning of a shader, but this register is also used for indirect addressing offsets, so we need to re-initialize it any time we use indirect addressing. llvm-svn: 211107
* [PECOFF] Support COMDAT associative sections.Rui Ueyama2014-06-1710-13/+188
| | | | | | | | | | | | | | | | | | | COFF supports a feature similar to ELF's section groups. This patch implements it. In ELF, section groups are identified by their names, and they are treated somewhat differently from regular symbols. In COFF, the feature is realized in a more straightforward way. A section can have an annotation saying "if Nth section is linked, link this section too." I added a new reference type, kindAssociate. If a target atom is coalesced away, the referring atom is removed by Resolver, so that they are treated as a group. Differential Revision: http://reviews.llvm.org/D4028 llvm-svn: 211106
* Added gdb-remote auxv tests.Todd Fiala2014-06-173-8/+233
| | | | | | | | | | | | | | | | | First batch of auxv-related tests from llgs branch. Includes helpers for unescaping gdb-remote binary-escaped data, converting binary data from inferior endian-ness to integral values, etc. Tests on debugserver are expected to be skipped since it doesn't support auxv and the tests are geared to be skipped on platforms that don't broadcast support for the feature in qSupported. (llgs is listed as XFAIL since qSupported support in llgs upstream is not there, so the support check cannot work in upstream llgs.) llvm-svn: 211105
* [FastISel][X86] Fix previous refactoring commit (r211077)Juergen Ributzka2014-06-172-5/+5
| | | | | | | Overlooked that fcmp_une uses an "or" instead of an "and" for combining the flags. llvm-svn: 211104
* Fixed jump threading going to infinite loop.Dinesh Dwivedi2014-06-173-1/+26
| | | | | | | | | This patch add code to remove unreachable blocks from function as they may cause jump threading to stuck in infinite loop. Differential Revision: http://reviews.llvm.org/D3991 llvm-svn: 211103
* Avoid crashing on invalid or unreadable ELF coreEd Maste2014-06-171-1/+2
| | | | | | | | | | Issue discovered during the GSoC 2014 project implementing FreeBSD kernel support. The existing elf-core Process plugin crashed trying to read from /dev/mem (the kernel memory device). Patch by Mike Ma. llvm-svn: 211102
* Rewrite ARM NEON intrinsic emission completely.James Molloy2014-06-176-3185/+2303
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There comes a time in the life of any amateur code generator when dumb string concatenation just won't cut it any more. For NeonEmitter.cpp, that time has come. There were a bunch of magic type codes which meant different things depending on the context. There were a bunch of special cases that really had no reason to be there but the whole thing was so creaky that removing them would cause something weird to fall over. There was a 1000 line switch statement for code generation involving string concatenation, which actually did lexical scoping to an extent (!!) with a bunch of semi-repeated cases. I tried to refactor this three times in three different ways without success. The only way forward was to rewrite the entire thing. Luckily the testing coverage on this stuff is absolutely massive, both with regression tests and the "emperor" random test case generator. The main change is that previously, in arm_neon.td a bunch of "Operation"s were defined with special names. NeonEmitter.cpp knew about these Operations and would emit code based on a huge switch. Actually this doesn't make much sense - the type information was held as strings, so type checking was impossible. Also TableGen's DAG type actually suits this sort of code generation very well (surprising that...) So now every operation is defined in terms of TableGen DAGs. There are a bunch of operators to use, including "op" (a generic unary or binary operator), "call" (to call other intrinsics) and "shuffle" (take a guess...). One of the main advantages of this apart from making it more obvious what is going on, is that we have proper type inference. This has two obvious advantages: 1) TableGen can error on bad intrinsic definitions easier, instead of just generating wrong code. 2) Calls to other intrinsics are typechecked too. So we no longer need to work out whether the thing we call needs to be the Q-lane version or the D-lane version - TableGen knows that itself! Here's an example: before: case OpAbdl: { std::string abd = MangleName("vabd", typestr, ClassS) + "(__a, __b)"; if (typestr[0] != 'U') { // vabd results are always unsigned and must be zero-extended. std::string utype = "U" + typestr.str(); s += "(" + TypeString(proto[0], typestr) + ")"; abd = "(" + TypeString('d', utype) + ")" + abd; s += Extend(utype, abd) + ";"; } else { s += Extend(typestr, abd) + ";"; } break; } after: def OP_ABDL : Op<(cast "R", (call "vmovl", (cast $p0, "U", (call "vabd", $p0, $p1))))>; As an example of what happens if you do something wrong now, here's what happens if you make $p0 unsigned before the call to "vabd" - that is, $p0 -> (cast "U", $p0): arm_neon.td:574:1: error: No compatible intrinsic found - looking up intrinsic 'vabd(uint8x8_t, int8x8_t)' Available overloads: - float64x2_t vabdq_v(float64x2_t, float64x2_t) - float64x1_t vabd_v(float64x1_t, float64x1_t) - float64_t vabdd_f64(float64_t, float64_t) - float32_t vabds_f32(float32_t, float32_t) ... snip ... This makes it seriously easy to work out what you've done wrong in fairly nasty intrinsics. As part of this I've massively beefed up the documentation in arm_neon.td too. Things still to do / on the radar: - Testcase generation. This was implemented in the previous version and not in the new one, because - Autogenerated tests are not being run. The testcase in test/ differs from the autogenerated version. - There were a whole slew of special cases in the testcase generation that just felt (and looked) like hacks. If someone really feels strongly about this, I can try and reimplement it too. - Big endian. That's coming soon and should be a very small diff on top of this one. llvm-svn: 211101
* Move SetTheory from utils/TableGen into lib/TableGen so Clang can use it.James Molloy2014-06-177-5/+5
| | | | llvm-svn: 211100
OpenPOWER on IntegriCloud