summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* IntEqClasses: Let join() return the new leaderMatthias Braun2016-01-082-5/+7
| | | | | | | | The new leader is known anyway so we can return it for some micro optimization in code where it is easy to pass along the result to the next join(). llvm-svn: 257130
* LiveInterval: A LiveRange is enough for ConnectedVNInfoEqClasses::Classify()Matthias Braun2016-01-084-10/+10
| | | | llvm-svn: 257129
* [WebAssembly] Minor code cleanups. NFC.Dan Gohman2016-01-084-11/+6
| | | | llvm-svn: 257128
* [WebAssembly] Remove an unused def : Pat.Dan Gohman2016-01-081-6/+4
| | | | | | | WebAssemblyISelLowering.cpp does not wrap jump table nodes inside of WebAssemblywrapper nodes, so this pattern is not currently used. llvm-svn: 257127
* [profile] Add comments to portability macros for readability (NFC)Vedant Kumar2016-01-081-3/+3
| | | | llvm-svn: 257126
* [WebAssembly] Remove unused arguments, unused functions. NFC.Dan Gohman2016-01-084-50/+33
| | | | llvm-svn: 257125
* Sync up InstrProfData.incXinliang David Li2016-01-081-20/+20
| | | | llvm-svn: 257124
* [PGO] : Removing trailing space/define new macro/NFCXinliang David Li2016-01-081-20/+20
| | | | llvm-svn: 257123
* Add some testing for thumb1 and thumb2 inline asm immediate constraintsEric Christopher2016-01-083-2/+53
| | | | | | | | and fix a couple of bugs on inspection. Also fixes PR26061. llvm-svn: 257122
* Change the key name for the libdispatch queue serial number fromJason Molenda2016-01-082-14/+14
| | | | | | | | | "qserial" to "qserialnum" because "qserial" looks a lot like the queue type (either 'serial' or 'concurrent') and can be confusing to read through. debugserver passes these up either in the questionmark ("T") packet, or in the response to the jThreadsInfo packet. llvm-svn: 257121
* Fix a glitch in the Driver's batch mode when used with "attach". Jim Ingham2016-01-086-17/+142
| | | | | | | | | | | | | | Batch mode is supposed to stop execution and return control to the user when an exceptional stop occurs (crash, signal or instrumentation). But attach always stops with a SIGSTOP on OSX (maybe on Linux too?) which would short circuit the rest of the commands given. This change allows a command result object to indicate that it expected to leave the process stopped with an exceptional stop reason, and it is okay for batch mode to keep going. <rdar://problem/22243143> llvm-svn: 257120
* ELF: Simplify Target::isSizeReloc and add comments.Rui Ueyama2016-01-083-11/+12
| | | | | | | | All non-trivial relocation decisions need explanations like this to help readers understand not only how relocations are handled but why they are handled these ways. This is a start. llvm-svn: 257119
* [cmake] Indentation fix (NFC)Vedant Kumar2016-01-081-1/+1
| | | | llvm-svn: 257118
* Performance improvement: Change lldb so that it puts a breakpointJason Molenda2016-01-088-11/+148
| | | | | | | | | | | | | | | | | | | on the first branch instruction after a function return (or the end of a source line), instead of a breakpoint on the return address, to skip an extra stop & start of the inferior process. I changed Process::AdvanceAddressToNextBranchInstruction to not take an optional InstructionList argument - no callers are providing a cached InstructionList today, and if this function was going to do that, the right thing to do would be to fill out / use a DisassemblerSP which is a disassembler with the InstructionList for this address range. http://reviews.llvm.org/D15708 <rdar://problem/23309838> llvm-svn: 257117
* Make sure we don't send qModuleInfo packets unnecessarily.Stephane Sezer2016-01-082-1/+13
| | | | | | | | | | | | | | Summary: Some debug servers don't support it so there's no point in spamming this. Reviewers: clayborg Subscribers: fjricci, lldb-commits Differential Revision: http://reviews.llvm.org/D15972 llvm-svn: 257116
* [llvm-symbolizer] Print out non-address lines verbatim.Mike Aizatsky2016-01-074-16/+30
| | | | | | Differential Revision: http://reviews.llvm.org/D15876 llvm-svn: 257115
* [LiveDebugValues] Replace several lines of code with operator[].Alexey Samsonov2016-01-071-16/+2
| | | | llvm-svn: 257114
* Better scheme to lookup alternate mangled name when looking up function address.Siva Chandra2016-01-0719-96/+205
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This change is relevant for inferiors compiled with GCC. GCC does not emit complete debug info for std::basic_string<...>, and consequently, Clang (the LLDB compiler) does not generate correct mangled names for certain functions. This change removes the hard-coded alternate names in ItaniumABILanguageRuntime.cpp. Before the hard-coded names were put in ItaniumABILanguageRuntime.cpp, one could not evaluate std::string methods (ex. std::string::length). After putting in the hard-coded names, one could evaluate them. However, it did not still enable one to call methods on, say for example, std::vector<string>. This change makes that possible. There is some amount of incompleteness in this change. Consider the following example: std::string hello("hello"), world("world"); std::map<std::string, std::string> m; m[hello] = world; One can still not evaluate the expression "m[hello]" in LLDB. Will address this issue in another pass. Reviewers: jingham, vharron, evgeny777, spyffe, dawn Subscribers: clayborg, dawn, lldb-commits Differential Revision: http://reviews.llvm.org/D12809 llvm-svn: 257113
* Instructions to be redone only if from the same BBAditya Nandakumar2016-01-072-1/+22
| | | | | | | While adding instructions(possible roots) to be redone, make sure they are from the same basic block. llvm-svn: 257112
* WebAssembly: use .skip instead of .zero directiveJF Bastien2016-01-072-5/+9
| | | | | | | | | | | | | | | | | .zero is confusing when used with two arguments. Documentation: This directive emits SIZE 0-valued bytes. SIZE must be an absolute expression. This directive is actually an alias for the '.skip' directive so in can take an optional second argument of the value to store in the bytes instead of zero. Using '.zero' in this way would be confusing however. Ref: https://sourceware.org/bugzilla/show_bug.cgi?id=18353 Hexagon and Sparc do the same, and it's all the same to WebAssembly so let's pick the less confusing of the two. llvm-svn: 257111
* [cmake] Add InstrProfilingWriter to libclang_rt on DarwinVedant Kumar2016-01-071-1/+2
| | | | | | | | | llvmBufferWriter and a few related symbols were missing from libclang_rt on Darwin (PR26002). This should fix the problem. Patch by Dan Peebles! llvm-svn: 257110
* Sync up InstrProfData.inc fileXinliang David Li2016-01-071-7/+12
| | | | llvm-svn: 257109
* [PGO] Minor refactoring /NFCXinliang David Li2016-01-074-16/+21
| | | | | | Move common defs into common header files. llvm-svn: 257108
* Temporarily revert r257105 "[Verifier] Check that debug values have proper size"Keno Fischer2016-01-0727-246/+181
| | | | | | | Looks like there's a case where clang generates debug info that triggers the new verifier check. Reverting while investigating. llvm-svn: 257107
* Ensure safestack overflow test doesn't segfaultDimitry Andric2016-01-071-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: In rL255491, the safestack overflow test was disabled for aarch64, since it "is currently failing on an AArch64 buildbot with a segfault, but it is currently passing on other configuration". While testing on FreeBSD on x86, I also encountered a segfault. This is because the `fct()` function actually writes before and after `buffer`, and on FreeBSD this crashes because `buffer` is usually allocated at the end of a page. That this runs correctly on Linux is probably just by accident. I propose to fix this by adding a pre and post buffer, to act as a safety zone. The pre and post buffers must be accessed in an 'unsafe' way, otherwise -fsanitize=safestack will allocate them on the safe stack, and they will not bookend `buffer` itself. Therefore, I create them large enough for `fct()`, and call it on both of them. On FreeBSD, this makes the test run as expected, without segfaulting, and I suppose this will also fix the segfault on AArch64. I do not have AArch64 testing capabilities, so if someone could try that out, I would be much obliged. Reviewers: pcc, kcc, zatrazz Subscribers: llvm-commits, aemerson, emaste Differential Revision: http://reviews.llvm.org/D15725 llvm-svn: 257106
* [Verifier] Check that debug values have proper sizeKeno Fischer2016-01-0727-181/+246
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Teach the Verifier to make sure that the storage size given to llvm.dbg.declare or the value size given to llvm.dbg.value agree with what is declared in DebugInfo. This is implicitly assumed in a number of passes (e.g. in SROA). Additionally this catches a number of common mistakes, such as passing a pointer when a value was intended or vice versa. One complication comes from stack coloring which modifies the original IR when it merges allocas in order to make sure that if AA falls back to the IR it gets the correct result. However, given this new invariant, indiscriminately replacing one alloca by a different (differently sized one) is no longer valid. Fix this by just undefing out any use of the alloca in a dbg.declare in this case. Additionally, I had to fix a number of test cases. Of particular note: - I regenerated dbg-changes-codegen-branch-folding.ll from the given source as it was affected by the bug fixed in r256077 - two-cus-from-same-file.ll was changed to avoid having a variable-typed debug variable as that would depend on the target, even though this test is supposed to be generic - I had to manually declared size/align for reference type. See also the discussion for D14275/r253186. - fpstack-debuginstr-kill.ll required changing `double` to `long double` - most others were just a question of adding OP_deref Reviewers: aprantl Differential Revision: http://reviews.llvm.org/D14276 llvm-svn: 257105
* Turn off lldb debug tuning by default for FreeBSDDimitry Andric2016-01-072-4/+1
| | | | | | | | | | | | | | | Summary: This is the clang part of D15966. In rL256104, debugger tuning was added to the clang driver, and again the default for FreeBSD was set to lldb. The default needs to be gdb instead. Reviewers: emaste, probinson Subscribers: cfe-commits, emaste Differential Revision: http://reviews.llvm.org/D15967 llvm-svn: 257104
* Turn off lldb debug tuning by default for FreeBSDDimitry Andric2016-01-073-3/+3
| | | | | | | | | | | | | | | | | | | | Summary: In rL242338, debugger tuning was introduced, and the tuning for FreeBSD was set to lldb by default. However, for the foreseeable future we still need to default to gdb tuning, since lldb is not ready for all of FreeBSD's architectures, and some system tools (like objcopy, etc) have not yet been adapted to cope with the lldb tuned format, which has .apple sections. Therefore, let FreeBSD use gdb by default for now. Reviewers: emaste, probinson Subscribers: llvm-commits, emaste Differential Revision: http://reviews.llvm.org/D15966 llvm-svn: 257103
* [SCCP] Don't violate the lattice invariantsDavid Majnemer2016-01-072-15/+68
| | | | | | | | | | We marked values which are 'undef' as constant instead of undefined which violates SCCP's invariants. If we can figure out that a computation results in 'undef', leave it in the undefined state. This fixes PR16052. llvm-svn: 257102
* Fix offset in test case. NFCPete Cooper2016-01-071-2/+2
| | | | | | | | | It wasn't actually pointing to the function at the start of the text section, and so the offset in the binary differed when we passed the file through a second time. The __eh_frame section uses implicit relocations and when reducing this test case from explicit to implicit, I got the offset wrong. This makes sure it is correct. llvm-svn: 257101
* Always generate the fixup content for unwindFDEToFunction as we noPete Cooper2016-01-072-15/+56
| | | | | | longer emit it. llvm-svn: 257100
* Don't emit relocs for the __eh_frame section as they can be implicit.Pete Cooper2016-01-074-8/+209
| | | | | | | | | | | | | | The __eh_frame section contains relocations which can always be implicitly generated. This patch tracks whether sections have only implicitly relocations and skips emitting them to the object file if that is the case. The test case here ensures that this is the case for __eh_frame sections. Reviewed by Lang Hames. http://reviews.llvm.org/D15594 llvm-svn: 257099
* WebAssembly: update expected failures, more assert got resolved.JF Bastien2016-01-071-2/+0
| | | | llvm-svn: 257098
* Properly track that a character literal is UTF-8, and pretty print the ↵Aaron Ballman2016-01-0711-2/+55
| | | | | | prefix properly. llvm-svn: 257097
* Revert "Remove unnecessary type casts."Rui Ueyama2016-01-071-2/+3
| | | | | | | This reverts commit r257080 because it caused GCC to emit "enumeral and non-enumeral type in conditional expression" warning. llvm-svn: 257096
* Add a comment for AMDGPU relocateOne().Rui Ueyama2016-01-071-0/+4
| | | | llvm-svn: 257095
* Fix crash when printing instructions that have a metadata attached but no ↵Mehdi Amini2016-01-073-1/+39
| | | | | | | | | | | | | | | | | | parent. Fix PR24852 (crash with -debug -instcombine) Patch by Than McIntosh <thanm@google.com> Summary: Add guards to the asm writer to prevent crashing when dumping an instruction that has no basic block. Differential Revision: http://reviews.llvm.org/D15798 From: Than McIntosh <thanm@google.com> llvm-svn: 257094
* WebAssembly: update expected failures, assert got resolved by r257084.JF Bastien2016-01-071-18/+0
| | | | llvm-svn: 257093
* [PGO] Simplify coverage mapping loweringXinliang David Li2016-01-073-5/+21
| | | | | | | | | | | | | | | | Coverage mapping data may reference names of functions that are skipped by FE (e.g, unused inline functions). Since those functions are skipped, normal instr-prof function lowering pass won't put those names in the right section, so special handling is needed to walk through coverage mapping structure and recollect the references. With this patch, only names that are skipped are processed. This simplifies the lowering code and it no longer needs to make assumptions coverage mapping data layout. It should also be more efficient. llvm-svn: 257092
* [PGO] Simplify coverage mapping loweringXinliang David Li2016-01-072-23/+17
| | | | | | | | | | | | | | | | Coverage mapping data may reference names of functions that are skipped by FE (e.g, unused inline functions). Since those functions are skipped, normal instr-prof function lowering pass won't put those names in the right section, so special handling is needed to walk through coverage mapping structure and recollect the references. With this patch, only names that are skipped are processed. This simplifies the lowering code and it no longer needs to make assumptions coverage mapping data layout. It should also be more efficient. llvm-svn: 257091
* Remove extraneous "Note t" in comment.Justin Lebar2016-01-071-1/+1
| | | | | | Added in r167571. llvm-svn: 257090
* Remove junk accidentally commited with r257087David Majnemer2016-01-071-1/+1
| | | | llvm-svn: 257089
* Add test for r256912David Majnemer2016-01-071-0/+39
| | | | | | I forgot to add this with the rest of r256912. llvm-svn: 257088
* [SCCP] Can't go from overdefined to constantDavid Majnemer2016-01-072-3/+34
| | | | | | | | The fix for PR23999 made us mark loads of null as producing the constant undef which upsets the lattice. Instead, keep the load as "undefined". This fixes PR26044. llvm-svn: 257087
* [DominatorTree] Remove unnecessary map population. NFC.Michael Liao2016-01-071-10/+2
| | | | | | - The reason of population these maps seems not valid any more. llvm-svn: 257086
* Correcting the comment in a header file; NFC.Aaron Ballman2016-01-071-1/+1
| | | | llvm-svn: 257085
* [WebAssembly] Support combining GEP and FrameIndex offsets in memory operand ↵Derek Schuff2016-01-072-6/+33
| | | | | | | | | | | offset field Previously we only supported putting the FI into memory operand offset fields if there was nothing there already. Now combine them. Differential Revision: http://reviews.llvm.org/D15941 llvm-svn: 257084
* [WebAssembly] Use the default private label prefixes.Dan Gohman2016-01-075-387/+384
| | | | | | | | | The MC assembler doesn't like using the empty string as a private label prefix because then it treats all labels as private. This commit reverts back to the default prefix, which is .L, which is common in ELF targets and consistent with the LLVM name mangler. llvm-svn: 257083
* Fix local variable name.Rui Ueyama2016-01-071-13/+13
| | | | | | | sh_type and sh_flags are valid names as members of ELF structs, but they are not as variables in LLVM. llvm-svn: 257082
* Remove useless local variable.Rui Ueyama2016-01-071-5/+2
| | | | llvm-svn: 257081
OpenPOWER on IntegriCloud