Tim Northover [Wed, 2 Apr 2014 14:39:11 +0000 (14:39 +0000)]
ARM64: use GOT for weak symbols & PIC.
Weak symbols cannot use the small code model's usual ADRP sequences since the
instruction simply may not be able to encode a value of 0.
This redirects them to use the GOT, which hopefully linkers are able to cope
with even in the static relocation model.
llvm-svn: 205426
Tim Northover [Wed, 2 Apr 2014 14:39:07 +0000 (14:39 +0000)]
ARM64: fix lowering of fp128 fptosi/fptoui
We were creating libcall nodes that returned an MVT::f128, when these
particular operations actually return an int of some stripe.
llvm-svn: 205425
Tim Northover [Wed, 2 Apr 2014 14:39:02 +0000 (14:39 +0000)]
SLPVectorizer: compare entire intrinsic for SLP compatibility.
Some Intrinsics are overloaded to the extent that return type equality (all
that's been checked up to now) does not guarantee that the arguments are the
same. In these cases SLP vectorizer should not recurse into the operands, which
can be achieved by comparing them as "Function *" rather than simply the ID.
llvm-svn: 205424
Tim Northover [Wed, 2 Apr 2014 14:38:58 +0000 (14:38 +0000)]
ARM64: make sure first argument to INSERT_SUBVECTOR has right type.
Again, coalescing and other optimisations swiftly made the MachineInstrs
consistent again, but when compiled at -O0 a bad INSERT_SUBREGISTER was
produced.
llvm-svn: 205423
Tim Northover [Wed, 2 Apr 2014 14:38:54 +0000 (14:38 +0000)]
ARM64: convert fp16 narrowing ISel to pseudo-instruction
The previous attempt was fine with optimisations, but was actually rather
cavalier with its types. When compiled at -O0, it produced invalid COPY
MachineInstrs.
llvm-svn: 205422
Job Noorman [Wed, 2 Apr 2014 13:13:56 +0000 (13:13 +0000)]
Mark FPB as a reserved register when needed.
llvm-svn: 205421
Samuel Benzaquen [Wed, 2 Apr 2014 13:12:14 +0000 (13:12 +0000)]
Add matcher for ExprWithCleanups.
Summary: Add matcher for ExprWithCleanups.
Reviewers: klimek
CC: cfe-commits, klimek
Differential Revision: http://llvm-reviews.chandlerc.com/D3248
llvm-svn: 205420
Samuel Benzaquen [Wed, 2 Apr 2014 13:11:45 +0000 (13:11 +0000)]
Add support for named values in the parser.
Summary:
Add support for named values in the parser.
This allows injection of arbitrary constants using a custom Sema object.
Completions are not supported right now.
Will be used by clang_query to support the 'let' command.
Usage example:
clang_query> let unique_ptr recordDecl(hasName("unique_ptr"))
clang_query> match varDecl(hasType(unique_ptr))
Reviewers: klimek, pcc
CC: cfe-commits, klimek
Differential Revision: http://llvm-reviews.chandlerc.com/D3229
llvm-svn: 205419
Alexey Samsonov [Wed, 2 Apr 2014 13:09:22 +0000 (13:09 +0000)]
[ASan] Fix incompatible runtimes check: don't iterate /proc/self/maps on every call to __asan_init
llvm-svn: 205418
Evgeniy Stepanov [Wed, 2 Apr 2014 12:38:13 +0000 (12:38 +0000)]
[msan] Add missing test for r205413.
llvm-svn: 205417
Rafael Espindola [Wed, 2 Apr 2014 12:15:20 +0000 (12:15 +0000)]
Work around gold bug sourceware.org/PR16794.
llvm-svn: 205416
Evgeniy Stepanov [Wed, 2 Apr 2014 11:55:24 +0000 (11:55 +0000)]
[msan] Kill __msan_print_param_shadow.
It does not do what it's name says, and what it actually does is hard to
describe, and is not useful at all.
llvm-svn: 205415
Andreas Simbuerger [Wed, 2 Apr 2014 11:54:01 +0000 (11:54 +0000)]
Replace INVALID/INVALID_NOVERIFY with diagnostics.
This replaces the ancient INVALID/INVALID_NOVERIFY macros with a real
function.
The new invalid(..) function uses small diagnostic objects that are
generated on demand. We can store arbitrary additional information per
error type and generate useful debug/error messages on the fly.
Use it as follows:
if (/* Some error condition (ReportFoo) */)
invalid<ReportFoo>(Context, /*Assert=*/true/false,
(/* List of helpful diagnostic objects */));
Where ReportFoo is a subclass of RejectReason that is able to take the
list of helpful diagnostic objects in its constructor.
The implementation of invalid will create the report and fire
an assertion, if necessary.
llvm-svn: 205414
Evgeniy Stepanov [Wed, 2 Apr 2014 11:50:42 +0000 (11:50 +0000)]
[msan] Add __msan_check_mem_is_initialized.
An assert()-like function that checks that a memory range is fully initialized.
llvm-svn: 205413
Evgeniy Stepanov [Wed, 2 Apr 2014 11:06:35 +0000 (11:06 +0000)]
[msan] Precise origin handling in __unaligned_(load|store)*.
llvm-svn: 205412
Alexey Samsonov [Wed, 2 Apr 2014 09:36:36 +0000 (09:36 +0000)]
[ASan] One more attempt to fix Android build
llvm-svn: 205411
Evgeniy Stepanov [Wed, 2 Apr 2014 09:17:55 +0000 (09:17 +0000)]
[msan] clang-format several unit tests
llvm-svn: 205410
Renato Golin [Wed, 2 Apr 2014 09:03:43 +0000 (09:03 +0000)]
Remove duplicated DMB instructions
ARM specific optimiztion, finding places in ARM machine code where 2 dmbs
follow one another, and eliminating one of them.
Patch by Reinoud Elhorst.
llvm-svn: 205409
Daniel Jasper [Wed, 2 Apr 2014 08:52:06 +0000 (08:52 +0000)]
Fix regex bug in clang-tidy.
Also make tests slightly less dependent on default flags. Once we have
implemented configuration file support, we might want to store the
clang-tidy configuration for the tests there.
llvm-svn: 205408
Daniel Jasper [Wed, 2 Apr 2014 08:27:12 +0000 (08:27 +0000)]
Disable a few clang-tidy checks by default.
The goal is to be able to run clang-tidy on LLVM files without further
configuration for now. Once llvm.org/PR19306 is addressed, we can add a
configuration file instead and choose other defaults.
llvm-svn: 205407
Rui Ueyama [Wed, 2 Apr 2014 06:59:28 +0000 (06:59 +0000)]
Remove a function that's not defined.
llvm-svn: 205406
Andrew MacPherson [Wed, 2 Apr 2014 06:57:45 +0000 (06:57 +0000)]
Use getpgid() with waitpid() in case the process pgid is not equal to its pid, as is the case with a forked subprocess. Also a couple of fixes for unit test failures from Todd Fiala.
llvm-svn: 205405
Rui Ueyama [Wed, 2 Apr 2014 06:54:46 +0000 (06:54 +0000)]
s/llvm::dyn_cast/dyn_cast/
llvm-svn: 205404
Rui Ueyama [Wed, 2 Apr 2014 06:54:43 +0000 (06:54 +0000)]
Use cast<T> instead of dyn_cast<T>.
llvm-svn: 205403
Rui Ueyama [Wed, 2 Apr 2014 06:43:08 +0000 (06:43 +0000)]
Remove unused variables.
llvm-svn: 205402
Rui Ueyama [Wed, 2 Apr 2014 06:38:46 +0000 (06:38 +0000)]
Remove dead code.
llvm-svn: 205401
David Blaikie [Wed, 2 Apr 2014 06:18:49 +0000 (06:18 +0000)]
Some more anonymous namespace diagnostics to switch to ()
llvm-svn: 205400
Rui Ueyama [Wed, 2 Apr 2014 06:18:12 +0000 (06:18 +0000)]
Devirtualize Resolver.
No one inherits Resolver. Virtualizing the member functions was just
making it inefficient.
llvm-svn: 205399
David Blaikie [Wed, 2 Apr 2014 05:58:29 +0000 (05:58 +0000)]
Render anonymous entities as '(anonymous <thing>)' (and lambdas as '(lambda at ... )')
For namespaces, this is consistent with mangling and GCC's debug info
behavior. For structs, GCC uses <anonymous struct> but we prefer
consistency between all anonymous entities but don't want to confuse
them with template arguments, etc, so we'll just go with parens in all
cases.
llvm-svn: 205398
Rui Ueyama [Wed, 2 Apr 2014 05:57:19 +0000 (05:57 +0000)]
Remove dead code.
llvm-svn: 205397
David Blaikie [Wed, 2 Apr 2014 05:48:29 +0000 (05:48 +0000)]
Add the location of Decls to ast dump.
While investigating some debug info issues, Eric and I came across a
particular template case where the location of a decl was quite
different from the range of the same decl. It might've been rather
helpful if the dumper had actually showed us this.
llvm-svn: 205396
Shankar Easwaran [Wed, 2 Apr 2014 05:45:52 +0000 (05:45 +0000)]
[TODO] revisit features TODO in the driver
llvm-svn: 205395
Rui Ueyama [Wed, 2 Apr 2014 05:03:40 +0000 (05:03 +0000)]
Move nextFile() from LinkingContext to InputGraph.
LinkingContext and InputGraph are unnecessarily entangled. Most linker
input file data, e.g. the vector containing input files, the next index
of the input file, etc. are managed by InputGraph, but only the current
input file is for no obvious reason managed by LinkingContext.
This patch is to move code from LinkingContext to InputGraph to fix it.
It's now clear who's reponsible for managing input file state, which is
InputGraph, and LinkingContext is now free from that responsibility.
It improves the readability as we now have fewer dependencies between
classes. No functionality change.
Differential Revision: http://llvm-reviews.chandlerc.com/D3259
llvm-svn: 205394
Yaron Keren [Wed, 2 Apr 2014 04:27:51 +0000 (04:27 +0000)]
Added isTargetWindowsMSVC(), renamed isTargetMingw() to isTargetWindowsGNU()
and isTargetCygwin() to isTargetWindowsCygwin() to be consistent with the
four Windows environments in Triple.h.
Suggestion by Saleem Abdulrasool!
llvm-svn: 205393
Shankar Easwaran [Wed, 2 Apr 2014 03:57:39 +0000 (03:57 +0000)]
[ELF] Create Attribute class associated with Input files.
The attribute class holds positional attributes for Input files specified on the
command line for the Gnu flavor.
llvm-svn: 205392
Shankar Easwaran [Wed, 2 Apr 2014 03:57:37 +0000 (03:57 +0000)]
[ELF] Add -z muldefs option.
This adds -z muldefs option which is widely used over
--allow-multiple-definition.
This option is supported by the GNU linker.
llvm-svn: 205391
Saleem Abdulrasool [Wed, 2 Apr 2014 03:51:35 +0000 (03:51 +0000)]
sanitise sign comparisons
This is a mechanical change addressing the various sign comparison warnings that
are identified by both clang and gcc. This helps cleanup some of the warning
spew that occurs during builds.
llvm-svn: 205390
Saleem Abdulrasool [Wed, 2 Apr 2014 03:51:16 +0000 (03:51 +0000)]
build: ignore pragma warnings with GCC
GCC does not support '#pragma mark'. Add -Wno-unknown-pragmas if the compiler
supports it.
llvm-svn: 205389
Rui Ueyama [Wed, 2 Apr 2014 02:57:39 +0000 (02:57 +0000)]
Remove unused function.
llvm-svn: 205388
Hal Finkel [Wed, 2 Apr 2014 02:34:49 +0000 (02:34 +0000)]
[LoopVectorizer] Count dependencies of consecutive pointers as uniforms
For the purpose of calculating the cost of the loop at various vectorization
factors, we need to count dependencies of consecutive pointers as uniforms
(which means that the VF = 1 cost is used for all overall VF values).
For example, the TSVC benchmark function s173 has:
...
%3 = add nsw i64 %indvars.iv, 16000
%arrayidx8 = getelementptr inbounds %struct.GlobalData* @global_data, i64 0, i32 0, i64 %3
...
and we must realize that the add will be a scalar in order to correctly deduce
it to be profitable to vectorize this on PowerPC with VSX enabled. In fact, all
dependencies of a consecutive pointer must be a scalar (uniform), and so we
simply need to add all consecutive pointers to the worklist that currently
detects collects uniforms.
Fixes PR19296.
llvm-svn: 205387
David Blaikie [Wed, 2 Apr 2014 02:04:51 +0000 (02:04 +0000)]
Adjust comments regarding non-relocated abbrev offset in debug_info.dwo
I'm not sure the comment in the implementation really adds a lot of
value (it's clear that we emit zero when no symbol is provided, but it
doesn't explain why we would do that). Happy to iterate.
llvm-svn: 205386
David Blaikie [Wed, 2 Apr 2014 01:50:20 +0000 (01:50 +0000)]
Split debug_loc and debug_loc.dwo emission into two separate functions
Based on code review feedback from Eric Christopher on r204697
llvm-svn: 205385
Rui Ueyama [Wed, 2 Apr 2014 01:49:44 +0000 (01:49 +0000)]
Fix indentation.
llvm-svn: 205384
Rui Ueyama [Wed, 2 Apr 2014 01:47:38 +0000 (01:47 +0000)]
Remove unused function.
llvm-svn: 205383
David Blaikie [Wed, 2 Apr 2014 01:43:18 +0000 (01:43 +0000)]
DebugInfo: Introduce DebugLocList to encapsulate a list of DebugLocEntries and an MC Label to refer to them
This removes the magic-number-esque code creating/retrieving the same
label for a debug_loc entry from two places and removes the last small
piece of reusable logic from emitDebugLoc so that there will be less
duplication when refactoring it into two functions (one for debug_loc,
the other for debug_loc.dwo).
llvm-svn: 205382
Jim Ingham [Wed, 2 Apr 2014 01:05:27 +0000 (01:05 +0000)]
Test case for the previous commit.
llvm-svn: 205381
Jim Ingham [Wed, 2 Apr 2014 01:04:55 +0000 (01:04 +0000)]
Add the ability to set python breakpoint commands from the SBBreakpoint & SBBreakpointLocation API's.
You can either provide the function name, or function body text.
Also propagate the compilation error up from where it is checked so we can report compilation errors.
<rdar://problem/9898371>
llvm-svn: 205380
Quentin Colombet [Wed, 2 Apr 2014 01:02:28 +0000 (01:02 +0000)]
[ARM64][CollectLOH] Add some comments to explain how the LOHs
framework works (for the compiler part), since the design
document is not available.
llvm-svn: 205379
Reid Kleckner [Wed, 2 Apr 2014 00:16:53 +0000 (00:16 +0000)]
Fix type mismatch assertion related to inalloca and PR19287
Augment the test case from r205217 to catch this related bug.
Fixes the Windows self-host which was failing on VariantValue.cpp.
llvm-svn: 205378
Rui Ueyama [Wed, 2 Apr 2014 00:14:33 +0000 (00:14 +0000)]
De-virtualize InputGraph's member functions.
There's no class derived from InputGraph. Making member functions virtual
just makes it a bit inefficient.
llvm-svn: 205377
Rui Ueyama [Tue, 1 Apr 2014 23:58:17 +0000 (23:58 +0000)]
Remove unused enum Position::ANY and third parameter of insertElementAt().
insertElementAt()'s third parameter is not only unused but also ignored
if you pass Position::END. The actual meaning of the parameter was obscure.
Differential Revision: http://llvm-reviews.chandlerc.com/D3256
llvm-svn: 205376
Rui Ueyama [Tue, 1 Apr 2014 23:55:20 +0000 (23:55 +0000)]
Merge ELFGroup with Group.
Group class is designed for GNU LD's --start-group and --end-group. There's
no obvious need to have two classes for it -- one as an abstract base class
and the other as a concrete class.
llvm-svn: 205375
Adrian Prantl [Tue, 1 Apr 2014 23:34:45 +0000 (23:34 +0000)]
Add a doxygen comment to DebugLocEntry::Merge.
llvm-svn: 205374
David Blaikie [Tue, 1 Apr 2014 23:19:23 +0000 (23:19 +0000)]
DebugLocEntry: Actually merge the loc entry when returning true.
Seems we didn't have any test coverage for merging... awesome. So I
added some - but hit an llvm-objdump bug while I was there. I'm choosing
not to shave that yak right now.
Code review feedback/bug catch by Adrian Prantl in r205360.
llvm-svn: 205373
Rui Ueyama [Tue, 1 Apr 2014 23:17:28 +0000 (23:17 +0000)]
Rename insertOneElementAt -> insertElementAt.
insertElementsAt() is removed, so "One" in insertOneElementAt() no longer
make much sense. Rename it for brevity.
llvm-svn: 205372
Rui Ueyama [Tue, 1 Apr 2014 23:10:14 +0000 (23:10 +0000)]
Remove duplicate code in unit tests carried in from main code.
llvm-svn: 205371
Eric Christopher [Tue, 1 Apr 2014 22:54:59 +0000 (22:54 +0000)]
Harden this test against windows/changes.
llvm-svn: 205370
Rui Ueyama [Tue, 1 Apr 2014 22:42:38 +0000 (22:42 +0000)]
Simplify InputGraphTest.
llvm-svn: 205369
Eric Christopher [Tue, 1 Apr 2014 22:25:28 +0000 (22:25 +0000)]
Partially revert r204517 and fix a different way:
We don't want to encourage the code to emit a lexical block for
a function that needs one in order for the line table to change,
we need to grab the line information from the body of the pattern
that we were instantiated from, this code should do that.
Modify the test case to ensure that we're still looking in the
right place for all of the scopes and also that we haven't
created a lexical block where we didn't need one.
llvm-svn: 205368
David Blaikie [Tue, 1 Apr 2014 22:25:09 +0000 (22:25 +0000)]
Fix accidental fallthrough in DebugLocEntry::hasSameValueOrLocation
No test case (this would invoke UB by examining uninitialized members,
etc, at best - and this code is apparently untested anyway - I'm about
to fix that)
Code review feedback from Adrian Prantl on r205360.
llvm-svn: 205367
Rui Ueyama [Tue, 1 Apr 2014 22:11:18 +0000 (22:11 +0000)]
Inline empty constructor.
llvm-svn: 205366
David Blaikie [Tue, 1 Apr 2014 22:06:18 +0000 (22:06 +0000)]
Remove unused function DebugLocEntry::isEmpty
llvm-svn: 205365
David Blaikie [Tue, 1 Apr 2014 22:04:07 +0000 (22:04 +0000)]
Refactor out the comparison of the location/value in a DebugLocEntry
llvm-svn: 205364
Rui Ueyama [Tue, 1 Apr 2014 21:55:36 +0000 (21:55 +0000)]
Greatly simplify InputGraph.
InputGraph has too many knobs and controls that are not being used. This
patch is to remove dead code, unused features and a class. There are two
things that worth noting, besides simple dead code removal:
1. ControlNode class is removed. We had it as the base class of Group
class, but it provides no functionality particularly meaningful. We now
have shallower class hierarchy that is easier to understand.
2. InputGraph provides a feature to replace a node with its internal data.
It is being used to "expand" some type of node, such as a Linker Script
node, with its actual files. We used to have two options when replacing
it -- ExpandOnly or ExpandAndReplace. ExpandOnly was to expand it but not
remove the node from the tree. There is no use of that option in the code,
so it was a dead feature.
Differential Revision: http://llvm-reviews.chandlerc.com/D3252
llvm-svn: 205363
Greg Fitzgerald [Tue, 1 Apr 2014 21:54:56 +0000 (21:54 +0000)]
Allow the user to override the compiler used for testing
Change-Id: I76d4708a26f17185efb746f4b836aa32f3f8a44f
llvm-svn: 205362
David Blaikie [Tue, 1 Apr 2014 21:54:52 +0000 (21:54 +0000)]
Add inequality operator for MachineLocation.
Fixes the build I broke in r205360
llvm-svn: 205361
David Blaikie [Tue, 1 Apr 2014 21:49:04 +0000 (21:49 +0000)]
DebugInfo: Split DebugLocEntry into its own file.
It seems big enough that it deserves its own file - but it is header
only, so there's no need for another cpp file, etc.
llvm-svn: 205360
Aaron Ballman [Tue, 1 Apr 2014 21:43:23 +0000 (21:43 +0000)]
Updating the capability attribute diagnostics to be more capability-neutral. Instead of using terminology such as "lock", "unlock" and "locked", the new terminology is "acquire", "release" and "held". Additionally, the capability attribute's name argument is now reported as part of the diagnostic, instead of hard coding as "mutex."
llvm-svn: 205359
Adrian Prantl [Tue, 1 Apr 2014 21:04:24 +0000 (21:04 +0000)]
Add a comment about the DIDescriptor class hierarchy.
llvm-svn: 205358
Adrian Prantl [Tue, 1 Apr 2014 21:04:18 +0000 (21:04 +0000)]
DwarfDebug: Prevent DebugLocEntry merging from coalescing two different
constants into only the first one.
rdar://
14874886.
llvm-svn: 205357
Enrico Granata [Tue, 1 Apr 2014 19:37:14 +0000 (19:37 +0000)]
Use continue instead of next
llvm-svn: 205354
Fariborz Jahanian [Tue, 1 Apr 2014 19:32:35 +0000 (19:32 +0000)]
Objective-C modern translator. Fix declaration of
__NSConstantStringImpl's length field to accomodate
window's 64bit LLP64 mode. // rdar://
16489050
llvm-svn: 205353
Hal Finkel [Tue, 1 Apr 2014 19:24:27 +0000 (19:24 +0000)]
[PowerPC] Add some missing VSX bitcast patterns
llvm-svn: 205352
Richard Smith [Tue, 1 Apr 2014 19:18:16 +0000 (19:18 +0000)]
Simplify FunctionDecl::getMinRequiredArguments().
llvm-svn: 205351
Rui Ueyama [Tue, 1 Apr 2014 19:00:21 +0000 (19:00 +0000)]
Remove dynamic casts.
Asserting with cast<T> did not actually make much sense because there was no
need to use dynamic casting in the first place. We could make the compiler to
statically type check these objects.
llvm-svn: 205350
Yaron Keren [Tue, 1 Apr 2014 18:52:55 +0000 (18:52 +0000)]
If isKnownWindowsMSVCEnvironment then getOS == Triple::Win32 and
Environment == Triple::MSVC so it will never be MinGW or Cygwin.
llvm-svn: 205349
Hal Finkel [Tue, 1 Apr 2014 18:50:34 +0000 (18:50 +0000)]
Implement X86TTI::getUnrollingPreferences
This provides an initial implementation of getUnrollingPreferences for x86.
getUnrollingPreferences is used by the generic (concatenation) unroller, which
is distinct from the unrolling done by the loop vectorizer. Many modern x86
cores have some kind of uop cache and loop-stream detector (LSD) used to
efficiently dispatch small loops, and taking full advantage of this requires
unrolling small loops (small here means 10s of uops).
These caches also have limits on the number of taken branches in the loop, and
so we also cap the loop unrolling factor based on the maximum "depth" of the
loop. This is currently calculated with a partial DFS traversal (partial
because it will stop early if the path length grows too much). This is still an
approximation, and one that is both conservative (because it does not account
for branches eliminated via block placement) and optimistic (because it is only
recording the maximum depth over minimum paths). Nevertheless, because the
loops that fit in these uop caches are so small, it is not clear how much the
details matter.
The original set of patches posted for review produced the following test-suite
performance results (from the TSVC benchmark) at that time:
ControlLoops-dbl - 13% speedup
ControlLoops-flt - 15% speedup
Reductions-dbl - 7.5% speedup
llvm-svn: 205348
Hal Finkel [Tue, 1 Apr 2014 18:50:30 +0000 (18:50 +0000)]
Add some additional fields to TTI::UnrollingPreferences
In preparation for an upcoming commit implementing unrolling preferences for
x86, this adds additional fields to the UnrollingPreferences structure:
- PartialThreshold and PartialOptSizeThreshold - Like Threshold and
OptSizeThreshold, but used when not fully unrolling. These are necessary
because we need different thresholds for full unrolling from those used when
partially unrolling (the full unrolling thresholds are generally going to be
larger).
- MaxCount - A cap on the unrolling factor when partially unrolling. This can
be used by a target to prevent the unrolled loop from exceeding some
resource limit independent of the loop size (such as number of branches).
There should be no functionality change for any in-tree targets.
llvm-svn: 205347
Hal Finkel [Tue, 1 Apr 2014 18:50:06 +0000 (18:50 +0000)]
Use TopTTI->getGEPCost from within getUserCost
The implementation of getUserCost had duplicated (and hard-coded) the default
logic in getGEPCost. Instead, it is better to use getGEPCost directly, which
limits the default logic to the implementation of one function, and allows
targets to override the behavior.
No functionality change intended.
llvm-svn: 205346
Ed Maste [Tue, 1 Apr 2014 18:47:58 +0000 (18:47 +0000)]
Use libc++ on FreeBSD as on Darwin
llvm-svn: 205345
Joerg Sonnenberger [Tue, 1 Apr 2014 18:39:58 +0000 (18:39 +0000)]
Move __addsf3 and __adddf3 into the corresponding blocks that define
fp_t.
llvm-svn: 205344
Kai Nacke [Tue, 1 Apr 2014 18:35:26 +0000 (18:35 +0000)]
[mips] Add Octeon cnMips instructions mtmX and mtpX
Adds the Octeon cnMips instructions "load multiplier register MPLx" and "load product register Px".
Includes tests.
Reviews by: Daniel.Sanders@imgtec.com
llvm-svn: 205343
Reid Kleckner [Tue, 1 Apr 2014 18:34:21 +0000 (18:34 +0000)]
Support segmented stacks on Win64
Identical to Win32 method except the GS segment register is used for TLS
instead of FS and pvArbitrary is at TEB offset 0x28 instead of 0x14.
llvm-svn: 205342
Matt Arsenault [Tue, 1 Apr 2014 18:34:13 +0000 (18:34 +0000)]
Fix missing RUN line in test
llvm-svn: 205341
Richard Smith [Tue, 1 Apr 2014 18:33:50 +0000 (18:33 +0000)]
Fix self-referential comment.
llvm-svn: 205340
Richard Smith [Tue, 1 Apr 2014 18:32:16 +0000 (18:32 +0000)]
More tests for DR1.
llvm-svn: 205339
Yaron Keren [Tue, 1 Apr 2014 18:15:34 +0000 (18:15 +0000)]
isTargetWindows() renamed to isTargetKnownWindowsMSVC()
to reflect its current functionality.
Based on Takumi NAKAMURA suggestion.
llvm-svn: 205338
Ed Maste [Tue, 1 Apr 2014 18:14:06 +0000 (18:14 +0000)]
Implement ProcessMonitor::Kill for Linux
On FreeBSD ptrace(PT_KILL) is used to terminate the traced process
(as if PT_CONTINUE had been used with SIGKILL as the signal to be
delivered), and is the desired behaviour for ProcessPOSIX::DoDestroy.
On Linux, after ptrace(PTRACE_KILL) the traced process still exists
and can be interrogated. It is only upon resume that it exits as though
it received SIGKILL.
As the Linux PTRACE_KILL behaviour is not used by LLDB, rename
BringProcessIntoLimbo to Kill, and change the implementation to simply
call kill() instead of using ptrace.
Thanks to Todd F for testing (Ubuntu 12.04, gcc 4.8.2).
Sponsored by: DARPA, AFRL
Differential Revision: http://llvm-reviews.chandlerc.com/D3159
llvm-svn: 205337
Matt Arsenault [Tue, 1 Apr 2014 18:13:26 +0000 (18:13 +0000)]
Make isSetCCEquivalent respect the TargetBooleanContents
llvm-svn: 205336
Matt Arsenault [Tue, 1 Apr 2014 18:13:22 +0000 (18:13 +0000)]
Add helpers for checking if a value is a target boolean constant.
llvm-svn: 205335
Ed Maste [Tue, 1 Apr 2014 18:06:45 +0000 (18:06 +0000)]
Add mips64 to the list of 64-bit Host architectures
llvm-svn: 205333
Rui Ueyama [Tue, 1 Apr 2014 18:04:56 +0000 (18:04 +0000)]
s/dyn_cast/cast/ where return value should never be null.
cast<X> asserts the type is correct and does not return null on failure.
So we should use cast<X> rather than dyn_cast<X> at such places where we
don't expect type conversion could fail.
llvm-svn: 205332
Adrian Prantl [Tue, 1 Apr 2014 17:52:06 +0000 (17:52 +0000)]
Debug info: fix a crash when emitting IndirectFieldDecls, which were
previously not handled at all.
rdar://problem/
16348575
llvm-svn: 205331
Ed Maste [Tue, 1 Apr 2014 17:27:25 +0000 (17:27 +0000)]
mips64: clean up register context storage
Store the gpr data in a DataBufferHeap and use a DataExtractor to
extract register values with appropriate endianness. This avoids hard-
coding the register count, and with some further work would allow this
class to provide generic register context storage for any CPU.
llvm-svn: 205329
Jordan Rose [Tue, 1 Apr 2014 16:40:06 +0000 (16:40 +0000)]
[analyzer] Extract a helper for finding the target region for a C++ constructor.
No functionality change.
Patch by Alex McCarthy!
llvm-svn: 205328
Jordan Rose [Tue, 1 Apr 2014 16:39:59 +0000 (16:39 +0000)]
[analyzer] Remove incorrect workaround for unimplemented temporary destructors.
If we're trying to get the zero element region of something that's not a region,
we should be returning UnknownVal, which is what ProgramState::getLValue will
do for us.
Patch by Alex McCarthy!
llvm-svn: 205327
Jordan Rose [Tue, 1 Apr 2014 16:39:33 +0000 (16:39 +0000)]
[analyzer] Fix a CFG printing bug.
Also, add several destructor-related tests. Most of them don't work yet, but it's
good to have them recorded.
Patch by Alex McCarthy!
llvm-svn: 205326
Aaron Ballman [Tue, 1 Apr 2014 16:30:35 +0000 (16:30 +0000)]
Fixing the MSVC 2012 build bot, which cannot do initializer lists yet. Amends r205307.
llvm-svn: 205325
David Blaikie [Tue, 1 Apr 2014 16:17:41 +0000 (16:17 +0000)]
DebugInfo: Factor out common functionality for rendering debug_loc and debug_loc.dwo location list entries
In preparation for refactoring this function into two, one for
debug_loc, one for debug_loc.dwo.
llvm-svn: 205324
David Blaikie [Tue, 1 Apr 2014 16:13:29 +0000 (16:13 +0000)]
Cleanup remaining use of removed variable to fix the build
llvm-svn: 205323