platform/upstream/llvm.git
12 years agoMaking the Cocoa formatters comply with the new on-disk layout of the Python resource...
Enrico Granata [Wed, 25 Apr 2012 01:39:27 +0000 (01:39 +0000)]
Making the Cocoa formatters comply with the new on-disk layout of the Python resources - This is one of the steps towards making the data formatters work again

llvm-svn: 155526

12 years agoEnsure that lldb/runtime is not a dead point in the Python package hierarchy - This...
Enrico Granata [Wed, 25 Apr 2012 01:26:37 +0000 (01:26 +0000)]
Ensure that lldb/runtime is not a dead point in the Python package hierarchy - This is a first preliminary step in fixing data formatters after Greg's changes to the Python resources on-disk layout

llvm-svn: 155525

12 years agoRemove unneeded files.
Greg Clayton [Wed, 25 Apr 2012 01:25:22 +0000 (01:25 +0000)]
Remove unneeded files.

llvm-svn: 155524

12 years agoMove the source and Makefile into a directory so it will be easier to install.
Greg Clayton [Wed, 25 Apr 2012 01:25:04 +0000 (01:25 +0000)]
Move the source and Makefile into a directory so it will be easier to install.

llvm-svn: 155523

12 years agoDo not use $gp as a dedicated global register if the target ABI is not O32.
Akira Hatanaka [Wed, 25 Apr 2012 01:24:52 +0000 (01:24 +0000)]
Do not use $gp as a dedicated global register if the target ABI is not O32.

llvm-svn: 155522

12 years agoRenaming to rid of the '++' in the test file name and simplify the Makefile.
Johnny Chen [Wed, 25 Apr 2012 01:20:15 +0000 (01:20 +0000)]
Renaming to rid of the '++' in the test file name and simplify the Makefile.

llvm-svn: 155521

12 years agoMake the Makefile stand alone.
Greg Clayton [Wed, 25 Apr 2012 01:19:20 +0000 (01:19 +0000)]
Make the Makefile stand alone.

llvm-svn: 155520

12 years agotypo in declaration from earlier today
Andrew Trick [Wed, 25 Apr 2012 01:11:22 +0000 (01:11 +0000)]
typo in declaration from earlier today

llvm-svn: 155519

12 years agoFix the docs for "breakpoint command add" to specify the arguments passed into the...
Jim Ingham [Wed, 25 Apr 2012 01:05:21 +0000 (01:05 +0000)]
Fix the docs for "breakpoint command add" to specify the arguments passed into the python function.

llvm-svn: 155517

12 years agoRemoved a binary that I accidentally committed.
Sean Callanan [Wed, 25 Apr 2012 01:04:34 +0000 (01:04 +0000)]
Removed a binary that I accidentally committed.

llvm-svn: 155516

12 years agoRecognize Objective-C classes with runtime class
Sean Callanan [Wed, 25 Apr 2012 01:03:57 +0000 (01:03 +0000)]
Recognize Objective-C classes with runtime class
ObjCPlusPlus as Objective-C classes.  Really the
compiler should say they have Objective-C runtime
class, but we should be a little more resilient
(we were refusing to find ivars in those classes
before).

Also added a test case.

llvm-svn: 155515

12 years agoMaked LLDB into a package so we can import things without poluting the global namespace.
Greg Clayton [Wed, 25 Apr 2012 00:58:03 +0000 (00:58 +0000)]
Maked LLDB into a package so we can import things without poluting the global namespace.

Enrico will follow this up with fixing the data formatter test cases that are failing.

llvm-svn: 155514

12 years agoSimplify the known retain count tracking; use a boolean state instead
Dan Gohman [Wed, 25 Apr 2012 00:50:46 +0000 (00:50 +0000)]
Simplify the known retain count tracking; use a boolean state instead
of a precise count. Also, move RRInfo's Partial field into PtrState,
now that it won't increase the size.

llvm-svn: 155513

12 years agoMade it safe to re-import a Python module, allowing
Sean Callanan [Wed, 25 Apr 2012 00:21:42 +0000 (00:21 +0000)]
Made it safe to re-import a Python module, allowing
the same test to be run multiple times in the same
session.

llvm-svn: 155511

12 years agoFixing a bunch of i386 testsuite failures
Enrico Granata [Wed, 25 Apr 2012 00:13:06 +0000 (00:13 +0000)]
Fixing a bunch of i386 testsuite failures

llvm-svn: 155510

12 years agoChange Target::ReadMemoryFromFileCache to not read from the file
Jason Molenda [Wed, 25 Apr 2012 00:06:56 +0000 (00:06 +0000)]
Change Target::ReadMemoryFromFileCache to not read from the file
if the section is marked as encrypted.  It will likely be readable
in live memory.
<rdar://problem/11305675>

llvm-svn: 155509

12 years agoExpand #include_next in float.h from mingw to _msc_ver.
Nico Weber [Tue, 24 Apr 2012 23:43:40 +0000 (23:43 +0000)]
Expand #include_next in float.h from mingw to _msc_ver.

A test for this is checking if this compiles:

    #include <float.h>

    inline bool IsFinite(const double& number) {
     return _finite(number) != 0;
    }

That depends however on either mingw or msvc being installed, and
chapuni tells me there might be issues with float.h on mingw, so
no automated test is added.

llvm-svn: 155507

12 years agoMake the test case more robust in terms of remote testsuite execution.
Johnny Chen [Tue, 24 Apr 2012 23:33:16 +0000 (23:33 +0000)]
Make the test case more robust in terms of remote testsuite execution.

rdar://problem/11312971

llvm-svn: 155505

12 years agoForgo the selector test on i386, where we can't
Sean Callanan [Tue, 24 Apr 2012 23:31:54 +0000 (23:31 +0000)]
Forgo the selector test on i386, where we can't
test whether an object responds to a selector
from outside the process.

llvm-svn: 155504

12 years agoCreate an NSAutoreleasePool correctly in a test
Sean Callanan [Tue, 24 Apr 2012 23:18:47 +0000 (23:18 +0000)]
Create an NSAutoreleasePool correctly in a test
case so that the Objective-C runtime doesn't
complain about lack of one, causing the test case
to fail.

llvm-svn: 155503

12 years agoAdd acos, asin, ceil, fabs, floor, fmax, fmin, round, and tan to the builtin
Chad Rosier [Tue, 24 Apr 2012 23:06:26 +0000 (23:06 +0000)]
Add acos, asin, ceil, fabs, floor, fmax, fmin, round, and tan to the builtin
math library functions.
rdar://11251464

llvm-svn: 155502

12 years agoAdd a suffix rule for compiling objc++ files and a sample directory under test/lang...
Johnny Chen [Tue, 24 Apr 2012 23:05:07 +0000 (23:05 +0000)]
Add a suffix rule for compiling objc++ files and a sample directory under test/lang/objcxx.

llvm-svn: 155501

12 years agoBuild custom predecessor and successor lists for each basic block.
Dan Gohman [Tue, 24 Apr 2012 22:53:18 +0000 (22:53 +0000)]
Build custom predecessor and successor lists for each basic block.
These lists exclude invoke unwind edges and loop backedges which
are being ignored. This makes it easier to ignore them
consistently.

llvm-svn: 155500

12 years agoARM: improved assembler diagnostics for missing CPU features.
Jim Grosbach [Tue, 24 Apr 2012 22:40:08 +0000 (22:40 +0000)]
ARM: improved assembler diagnostics for missing CPU features.

When an instruction match is found, but the subtarget features it
requires are not available (missing floating point unit, or thumb vs arm
mode, for example), issue a diagnostic that identifies what the feature
mismatch is.

rdar://11257547

llvm-svn: 155499

12 years agoAdd atan, atan2, exp, and log to the builtin math library functions.
Chad Rosier [Tue, 24 Apr 2012 22:40:01 +0000 (22:40 +0000)]
Add atan, atan2, exp, and log to the builtin math library functions.

With -fno-math-errno (the default for Darwin) or -ffast-math these library
function can be marked readnone enabling more opportunities for CSE and other
optimizations.
rdar://11251464

llvm-svn: 155498

12 years agoFixing a typo in the previous commit that broke the build
Enrico Granata [Tue, 24 Apr 2012 22:33:23 +0000 (22:33 +0000)]
Fixing a typo in the previous commit that broke the build

llvm-svn: 155497

12 years agoFixing an issue where the expression parser was not correctly freeze-drying bitfields...
Enrico Granata [Tue, 24 Apr 2012 22:15:37 +0000 (22:15 +0000)]
Fixing an issue where the expression parser was not correctly freeze-drying bitfields - This patch ensures that (a) freeze-drying bitfields works correctly and (b) that we actually access bitfields through IR instead of the 'frame var en lieu of expr' shortcut, for added safety in corner cases that may arise

llvm-svn: 155494

12 years agoAlphabetize the builtin math library functions. No functional change intended.
Chad Rosier [Tue, 24 Apr 2012 21:45:50 +0000 (21:45 +0000)]
Alphabetize the builtin math library functions.  No functional change intended.

llvm-svn: 155492

12 years agoAdd a '-R' option, which is similar to '-r', except that the relocated directory...
Johnny Chen [Tue, 24 Apr 2012 21:44:10 +0000 (21:44 +0000)]
Add a '-R' option, which is similar to '-r', except that the relocated directory, if exists, will be removed entirely
before running the test suite.  A usage example looks like this:

test $ ./dotest.py -A x86_64 -R /tmp/x86_64 &
test $ ./dotest.py -A i386 -R /tmp/i386 &

where we would want to run the x86_64 and i386 archs concurrently but relocate the test suite to different directory
hierarchies in order not to stump on each other's intermediate files.

llvm-svn: 155491

12 years agoLet NULL and MSVC headers coexist better.
Nico Weber [Tue, 24 Apr 2012 21:27:01 +0000 (21:27 +0000)]
Let NULL and MSVC headers coexist better.

Fixes the two issues mentioned in PR12146.

llvm-svn: 155490

12 years ago<rdar://problem/11291668>
Greg Clayton [Tue, 24 Apr 2012 21:22:41 +0000 (21:22 +0000)]
<rdar://problem/11291668>

Fixed an issue that would happen when using debug map with DWARF in the .o files where we wouldn't ever track down the actual definition for a type when things were in namespaces. We now serialize the decl context information into an intermediate format which allows us to track down the correct definition for a type regardless of which DWARF symbol file it comes from. We do this by creating a "DWARFDeclContext" object that contains the DW_TAG + name for each item in a decl context which we can then use to veto potential accelerator table matches. For example, the accelerator tables store the basename of the type, so if you have "std::vector<int>", we would end up with an accelerator table entry for the type that contained "vector<int>", which we would then search for using a DWARFDeclContext object that contained:

  [0] DW_TAG_class_type "vector<int>"
  [1] DW_TAG_namespace "std"

This is currently used to track down forward declarations for things like "class a::b::Foo;".

llvm-svn: 155488

12 years agoRecursiveASTVisitor: Visit instantiations of member templates of class
Richard Smith [Tue, 24 Apr 2012 20:39:49 +0000 (20:39 +0000)]
RecursiveASTVisitor: Visit instantiations of member templates of class
templates. In an implicit instantiation of a member class, any member
templates don't get instantiated, so the existing check which only visited
the instantiations of a defined template skipped these templates'
instantiations.

Since there is only a single declaration of a member template of a class
template specialization, just use that to determine whether to visit the
instantiations. This introduces a slight inconsistency in that we will
visit the instantiations of such templates whether or not they are
defined, but we never visit a declared-but-not-defined instantiation, so
this turns out to not matter.

Patch by Daniel Jasper!

llvm-svn: 155487

12 years agoFix a naughty header include that breaks "installed" builds.
Andrew Trick [Tue, 24 Apr 2012 20:36:19 +0000 (20:36 +0000)]
Fix a naughty header include that breaks "installed" builds.

llvm-svn: 155486

12 years agoConstantFoldSelectInstruction swapped the operands of the select.
Nadav Rotem [Tue, 24 Apr 2012 20:18:49 +0000 (20:18 +0000)]
ConstantFoldSelectInstruction swapped the operands of the select.

Fix 12592. Patch by Matt Pharr.

llvm-svn: 155480

12 years agoFix the testcase. We do expect two vblendw on XMMs.
Nadav Rotem [Tue, 24 Apr 2012 19:57:38 +0000 (19:57 +0000)]
Fix the testcase. We do expect two vblendw on XMMs.

llvm-svn: 155477

12 years agoAdd a testcase for 155440
Nadav Rotem [Tue, 24 Apr 2012 19:45:28 +0000 (19:45 +0000)]
Add a testcase for 155440

llvm-svn: 155475

12 years agomodern objc translator: Allow writing of multiple
Fariborz Jahanian [Tue, 24 Apr 2012 19:38:45 +0000 (19:38 +0000)]
modern objc translator: Allow writing of multiple
declaration of __block variables on same lines
with initializers. // rdsr://7547630

llvm-svn: 155473

12 years agoMachineBasicBlock::SplitCriticalEdge() should follow LLVM IR variant and refuse to...
Evan Cheng [Tue, 24 Apr 2012 19:06:55 +0000 (19:06 +0000)]
MachineBasicBlock::SplitCriticalEdge() should follow LLVM IR variant and refuse to break edge to EH landing pad. rdar://11300144

llvm-svn: 155470

12 years agoAdd support for llvm.arm.neon.vmull* intrinsics to InstCombine. This fixes
Lang Hames [Tue, 24 Apr 2012 18:58:36 +0000 (18:58 +0000)]
Add support for llvm.arm.neon.vmull* intrinsics to InstCombine. This fixes
<rdar://problem/11291436>.

llvm-svn: 155468

12 years agoFix a crash on valid (if UB) bitcode that is produced for some global
Chandler Carruth [Tue, 24 Apr 2012 18:42:47 +0000 (18:42 +0000)]
Fix a crash on valid (if UB) bitcode that is produced for some global
constants in C++11 mode. I have no idea why it required such particular
circumstances to get here, the code seems clearly to rely upon unchecked
assumptions.

Specifically, when we decide to form an index into a struct type, we may
have gone through (at least one) zero-length array indexing round, which
would have left the offset un-adjusted, and thus not necessarily valid
for use when indexing the struct type.

This is just an canonicalization step, so the correct thing is to refuse
to canonicalize nonsensical GEPs of this form. Implemented, and test
case added.

Fixes PR12642. Pair debugged and coded with Richard Smith. =] I credit
him with most of the debugging, and preventing me from writing the wrong
code.

llvm-svn: 155466

12 years agoARM: Nuke remnant bogus code.
Jim Grosbach [Tue, 24 Apr 2012 18:39:47 +0000 (18:39 +0000)]
ARM: Nuke remnant bogus code.

r154362 was supposed to delete this bit, but obviously didn't.

rdar://11305594

llvm-svn: 155465

12 years agoRelated to PR1255. Let's begin. I'll commit classes that corresponds to our latest...
Stepan Dyatkovskiy [Tue, 24 Apr 2012 18:31:10 +0000 (18:31 +0000)]
Related to PR1255. Let's begin. I'll commit classes that corresponds to our latest PR1255 discussion posts in llvm-commits.

Strategy.
0. Implement new classes. Classes doesn't affect anything. They still work with ConstantInt base values at this stage.
1. Fictitious replacement of current ConstantInt case values with ConstantRangesSet. Case ranges set will still hold single value, and ConstantInt *getCaseValue() will return it. But additionally implement new method in SwitchInst that allows to work with case ranges. Currenly I think it should be some wrapper that returns either single value or ConstantRangesSet object.
2. Step-by-step replacement of old "ConstantInt* getCaseValue()" with new alternative. Modify algorithms for all passes that works with SwitchInst. But don't modify LLParser and BitcodeReader/Writer. Still hold single value in each ConstantRangesSet object. On this stage some parts of LLVM will use old-style methods, and some ones new-style.
3. After all getCaseValue() usages will removed and whole LLVM and its clients will work in new style - modify LLParser, Reader and Writer. Remove getCaseValue().
4. Replace ConstantInt*-based case ranges set items with APInt ones.

Currently we are on Zero Stage: New classes.
ConstantRangesSet.
I selected ConstantArrays as case ranges set "holder" object (it is a temporary decision, I'll explain why below). The array items are may be ConstantVectors with single item, and ConstantVectors with two items (that means single number and range respectively).
The ConstantInt will used as basic value representation. It will replaced with APInt then. Of course ConstantArray and ConstantVector will go away after ConstantInt => APInt replacement.

New class mandatory features:
- bool isSatisfies(ConstantInt *V) method (need better name?). Returns true if the given value satisfies this case.
- Case's ranges and values enumeration. In some passes we need to analize each case (SwitchLowering for example).

Factory + unified clusterify.
I also propose to implement the factory that allows to build case object with user friendly way. I called it CRSBuilder by now.
Currenly I implemented the factory that allows add,remove pairs of range+successor. It also allows add existing ConstantRangesSet decompiling it to separated ranges. Factory can emit either clusters set (single case range + successor) or the set of "ConstantRangesSet + Successor" pairs.
So you can use it either as builder for new cases set for SwitchInst, or for clusterification of existing cases set.
Just call Factory.optimize() and it emits optimized and sorted clusters collection for you!
I tested clusterification on SelectionDAGBuilder - it works fine. Don't worry it was not included in this patch. Just new classes.
Factory is a template. There are two params: SuccessorClass and IsReadonly. So you can specify what successor you need (BB or MBB). And you can also restrict your factory to use values in read-only mode (SelectionDAGBuilder need IsReadonly=true). Read-only factory couldn't build the cases ranges.

llvm-svn: 155464

12 years agoobjc modern rewriter: allow translation of
Fariborz Jahanian [Tue, 24 Apr 2012 18:16:20 +0000 (18:16 +0000)]
objc modern rewriter: allow translation of
multiple declaration of block variables
(with no initializer) on the same line.

llvm-svn: 155462

12 years agoAVX: Add additional vbroadcast replacement sequences for integers.
Nadav Rotem [Tue, 24 Apr 2012 18:09:59 +0000 (18:09 +0000)]
AVX: Add additional vbroadcast replacement sequences for integers.
Remove the v2f64 patterns because it does not match any vbroadcast
instruction.

llvm-svn: 155461

12 years agocmake: new file
Andrew Trick [Tue, 24 Apr 2012 18:06:49 +0000 (18:06 +0000)]
cmake: new file

llvm-svn: 155460

12 years agomisched: DAG builder must special case earlyclobber
Andrew Trick [Tue, 24 Apr 2012 18:04:41 +0000 (18:04 +0000)]
misched: DAG builder must special case earlyclobber

llvm-svn: 155459

12 years agomisched: try (not too hard) to place debug values where they belong
Andrew Trick [Tue, 24 Apr 2012 18:04:37 +0000 (18:04 +0000)]
misched: try (not too hard) to place debug values where they belong

llvm-svn: 155458

12 years agomisched: ignore debug values during scheduling
Andrew Trick [Tue, 24 Apr 2012 18:04:34 +0000 (18:04 +0000)]
misched: ignore debug values during scheduling

llvm-svn: 155457

12 years agomisched: DAG builder support for tracking register pressure within the current schedu...
Andrew Trick [Tue, 24 Apr 2012 17:56:43 +0000 (17:56 +0000)]
misched: DAG builder support for tracking register pressure within the current scheduling region.

The DAG builder is a convenient place to do it. Hopefully this is more
efficient than a separate traversal over the same region.

llvm-svn: 155456

12 years agoFixed a crasher that occurs when an expression
Sean Callanan [Tue, 24 Apr 2012 17:56:40 +0000 (17:56 +0000)]
Fixed a crasher that occurs when an expression
doesn't return a result.  If that expression can't
be run in the current context (for example, if it
uses a function and there is no running process)
then we used to try to destroy the nonexistent
result variable.  We now only destroy the result
variable if we actually made one.

llvm-svn: 155455

12 years agoRegisterPressure: A utility for computing register pressure within a
Andrew Trick [Tue, 24 Apr 2012 17:53:35 +0000 (17:53 +0000)]
RegisterPressure: A utility for computing register pressure within a
MachineInstr sequence.

This uses the new target interface for tracking register pressure
using pressure sets to model overlapping register classes and
subregisters.

RegisterPressure results can be tracked incrementally or stored at
region boundaries. Global register pressure can be deduced from local
RegisterPressure results if desired.

This is an early, somewhat untested implementation. I'm working on
testing it within the context of a register pressure reducing
MachineScheduler.

llvm-svn: 155454

12 years agoAdd missing test cases for ARM VLD3 (single 3-element structure to all lanes)
Kevin Enderby [Tue, 24 Apr 2012 17:45:56 +0000 (17:45 +0000)]
Add missing test cases for ARM VLD3 (single 3-element structure to all lanes)
instructions.

llvm-svn: 155453

12 years agoChanged 'cause' from 'terminate' to 'uncaught' in default_terminate_handler
Howard Hinnant [Tue, 24 Apr 2012 17:41:51 +0000 (17:41 +0000)]
Changed 'cause' from 'terminate' to 'uncaught' in default_terminate_handler

llvm-svn: 155452

12 years agoobjc modern rewriter: minor refactoring.
Fariborz Jahanian [Tue, 24 Apr 2012 16:45:27 +0000 (16:45 +0000)]
objc modern rewriter: minor refactoring.

llvm-svn: 155449

12 years agoSimplify import/export command line flags.
Tobias Grosser [Tue, 24 Apr 2012 16:12:34 +0000 (16:12 +0000)]
Simplify import/export command line flags.

Instead of -polly-run-import-jscop and -polly-run-export-jscop, we just use
-polly-import and -polly-export.

llvm-svn: 155446

12 years agoUnify the optimizer selection.
Tobias Grosser [Tue, 24 Apr 2012 16:12:30 +0000 (16:12 +0000)]
Unify the optimizer selection.

We now support -polly-optimizer=isl, -polly-optimizer=pocc and
-polly-optimizer=none. The option -polly-no-optimizer is gone.

llvm-svn: 155445

12 years agoAdd missing test cases for ARM VLD4 (single 4-element structure to all lanes)
Kevin Enderby [Tue, 24 Apr 2012 15:55:00 +0000 (15:55 +0000)]
Add missing test cases for ARM VLD4 (single 4-element structure to all lanes)
instructions.

llvm-svn: 155444

12 years agoAdd a FIXME for uncomplete comment
Gabor Greif [Tue, 24 Apr 2012 15:42:03 +0000 (15:42 +0000)]
Add a FIXME for uncomplete comment
fix a typo
add punctuation

llvm-svn: 155443

12 years agoAdding information about what intrinsics still need to be implemented for MSVC compat...
Aaron Ballman [Tue, 24 Apr 2012 12:30:37 +0000 (12:30 +0000)]
Adding information about what intrinsics still need to be implemented for MSVC compatibility.

llvm-svn: 155441

12 years agoAVX2: The BLENDPW instruction selects between vectors of v16i16 using an i8
Nadav Rotem [Tue, 24 Apr 2012 11:27:53 +0000 (11:27 +0000)]
AVX2: The BLENDPW instruction selects between vectors of v16i16 using an i8
immediate. We can't use it here because the shuffle code does not check that
the lower part of the word is identical to the upper part.

llvm-svn: 155440

12 years agoRefactor Thumb ITState handling in ARM Disassembler to more efficiently use its vector
Richard Barton [Tue, 24 Apr 2012 11:13:20 +0000 (11:13 +0000)]
Refactor Thumb ITState handling in ARM Disassembler to more efficiently use its vector

llvm-svn: 155439

12 years agoMake vector tests less sensible to codegen changes
Tobias Grosser [Tue, 24 Apr 2012 11:08:07 +0000 (11:08 +0000)]
Make vector tests less sensible to codegen changes

llvm-svn: 155438

12 years agoAVX: We lower VECTOR_SHUFFLE and BUILD_VECTOR nodes into vbroadcast instructions
Nadav Rotem [Tue, 24 Apr 2012 11:07:03 +0000 (11:07 +0000)]
AVX: We lower VECTOR_SHUFFLE and BUILD_VECTOR nodes into vbroadcast instructions
using the pattern (vbroadcast (i32load src)). In some cases, after we generate
this pattern new users are added to the load node, which prevent the selection
of the blend pattern. This commit provides fallback patterns which perform
in-vector broadcast (using in-vector vbroadcast in AVX2 and pshufd on AVX1).

llvm-svn: 155437

12 years agoAdd a flag to the image info section indicating that the program is compiled for
Bill Wendling [Tue, 24 Apr 2012 11:04:57 +0000 (11:04 +0000)]
Add a flag to the image info section indicating that the program is compiled for
a simulator.

llvm-svn: 155436

12 years agoLook for the 'Is Simulated' module flag. This indicates that the program is compiled...
Bill Wendling [Tue, 24 Apr 2012 11:03:50 +0000 (11:03 +0000)]
Look for the 'Is Simulated' module flag. This indicates that the program is compiled to run on a simulator.

llvm-svn: 155435

12 years agoFileCheck-ize tests.
Bill Wendling [Tue, 24 Apr 2012 10:45:44 +0000 (10:45 +0000)]
FileCheck-ize tests.

llvm-svn: 155434

12 years agoFileCheck-ize these tests.
Bill Wendling [Tue, 24 Apr 2012 10:36:42 +0000 (10:36 +0000)]
FileCheck-ize these tests.

llvm-svn: 155433

12 years agoFileCheck-ize these tests. Harden some of them.
Bill Wendling [Tue, 24 Apr 2012 09:15:38 +0000 (09:15 +0000)]
FileCheck-ize these tests. Harden some of them.

llvm-svn: 155432

12 years agoOnly pass -mcpu, -march, -mfpu to linux-as on ARM.
Evgeniy Stepanov [Tue, 24 Apr 2012 09:05:31 +0000 (09:05 +0000)]
Only pass -mcpu, -march, -mfpu to linux-as on ARM.

llvm-svn: 155431

12 years agoenable TBAA when -fthread-sanitizer is given, even with -O0 or -relaxed-aliasing
Kostya Serebryany [Tue, 24 Apr 2012 06:57:01 +0000 (06:57 +0000)]
enable TBAA when -fthread-sanitizer is given, even with -O0 or  -relaxed-aliasing

llvm-svn: 155430

12 years agoRemove dangling spaces. Fix some other formatting.
Craig Topper [Tue, 24 Apr 2012 06:36:35 +0000 (06:36 +0000)]
Remove dangling spaces. Fix some other formatting.

llvm-svn: 155429

12 years agoSimplify code a bit and make it compile better. Remove unused parameters.
Craig Topper [Tue, 24 Apr 2012 06:02:29 +0000 (06:02 +0000)]
Simplify code a bit and make it compile better. Remove unused parameters.

llvm-svn: 155428

12 years agoFix a typo spotted by Matt.
Chandler Carruth [Tue, 24 Apr 2012 05:59:48 +0000 (05:59 +0000)]
Fix a typo spotted by Matt.

llvm-svn: 155427

12 years agoDon't try to delay parsing the exception specification for a data member of a
Richard Smith [Tue, 24 Apr 2012 05:48:42 +0000 (05:48 +0000)]
Don't try to delay parsing the exception specification for a data member of a
class; we would never actually parse it and attach it to the type.

llvm-svn: 155426

12 years agoIntroduce an initial sketch of a MSVC compatible 'intrin.h' builtin
Chandler Carruth [Tue, 24 Apr 2012 05:23:54 +0000 (05:23 +0000)]
Introduce an initial sketch of a MSVC compatible 'intrin.h' builtin
header, along with a stub test to make sure it compiles in the
appropriate modes.

Thanks to Aaron Ballman for working with me to figure out the initial
strategy here, and to Nico for reviewing and pestering me to actually
commit it.

llvm-svn: 155425

12 years agoPR12629: Cope with parenthesized function types when attaching a delayed
Richard Smith [Tue, 24 Apr 2012 05:06:35 +0000 (05:06 +0000)]
PR12629: Cope with parenthesized function types when attaching a delayed
exception specification to a function.

llvm-svn: 155424

12 years agoAdded support for the LC_ENCRYPTION_INFO load command.
Greg Clayton [Tue, 24 Apr 2012 03:06:13 +0000 (03:06 +0000)]
Added support for the LC_ENCRYPTION_INFO load command.

llvm-svn: 155423

12 years agoReport the command error when we are in "stop on error mode."
Jim Ingham [Tue, 24 Apr 2012 02:25:07 +0000 (02:25 +0000)]
Report the command error when we are in "stop on error mode."

llvm-svn: 155422

12 years agoA small fix for ObjectFileMachO::ParseSymtab() where a pointer
Jason Molenda [Tue, 24 Apr 2012 02:09:58 +0000 (02:09 +0000)]
A small fix for ObjectFileMachO::ParseSymtab() where a pointer
into the middle of a vector was being used after the vector may
have been resized.
<rdar://problem/11284937>

llvm-svn: 155421

12 years agoFixing the test case so that it runs correctly on i386 as well as on x86_64
Enrico Granata [Tue, 24 Apr 2012 02:01:17 +0000 (02:01 +0000)]
Fixing the test case so that it runs correctly on i386 as well as on x86_64

llvm-svn: 155420

12 years agoRemoving the @expectedFailurei386 decorator from test cases that now work as a result...
Enrico Granata [Tue, 24 Apr 2012 01:45:19 +0000 (01:45 +0000)]
Removing the @expectedFailurei386 decorator from test cases that now work as a result of the latest changes to Value.cpp

llvm-svn: 155419

12 years agoThis patch fixes a bug where LLDB was incorrectly setting the address-size on a DataE...
Enrico Granata [Tue, 24 Apr 2012 01:23:23 +0000 (01:23 +0000)]
This patch fixes a bug where LLDB was incorrectly setting the address-size on a DataExtractor to be sizeof(void*) when the ValueObject came out of the expression parser
This worked correctly for 64-bit targets, but broke down data formatters in i386 mode. The formatters would try to read pointers out of the frozen-dried objects,
but were unable to do so because they would try fetching 8 bytes from a DataExtractor with only 4 bytes in it. This patch fixes the issue by always making the pointer-size
for a DataExtractor match the target setting.

llvm-svn: 155418

12 years agoclang/test/Rewriter/objc-modern-boxing.mm: Mark as XFAIL:mingw for now, due to predef...
NAKAMURA Takumi [Tue, 24 Apr 2012 01:19:04 +0000 (01:19 +0000)]
clang/test/Rewriter/objc-modern-boxing.mm: Mark as XFAIL:mingw for now, due to predefined __declspec similar to r155278.

llvm-svn: 155417

12 years agoPass *this in explicitly to save the FileSpec copy construction.
Jim Ingham [Mon, 23 Apr 2012 23:22:24 +0000 (23:22 +0000)]
Pass *this in explicitly to save the FileSpec copy construction.

llvm-svn: 155407

12 years agoAdded the ability to log a message with a backtrace when verbose logging is enabled...
Greg Clayton [Mon, 23 Apr 2012 22:55:20 +0000 (22:55 +0000)]
Added the ability to log a message with a backtrace when verbose logging is enabled to the Module class. Used this new function in the DWARF parser.

llvm-svn: 155404

12 years agoAdd a missing cpu subtype.
Evan Cheng [Mon, 23 Apr 2012 22:41:39 +0000 (22:41 +0000)]
Add a missing cpu subtype.

llvm-svn: 155402

12 years agoTidy up. 80 columns, whitespace, et. al.
Jim Grosbach [Mon, 23 Apr 2012 22:04:10 +0000 (22:04 +0000)]
Tidy up. 80 columns, whitespace, et. al.

llvm-svn: 155399

12 years ago<rdar://problem/11282938>
Greg Clayton [Mon, 23 Apr 2012 22:00:21 +0000 (22:00 +0000)]
<rdar://problem/11282938>

Fixed an issue where we get NULL compile units back from the symbol vendor. We need symbol vendors to be able to quickly give an estimate of the compile units that they have without having to fully vette them first, so anyone getting compile units from a module should be able to deal with a NULL compile unit being returned for a given index.

llvm-svn: 155398

12 years agoOptimize the vector UINT_TO_FP, SINT_TO_FP and FP_TO_SINT operations where the intege...
Nadav Rotem [Mon, 23 Apr 2012 21:53:37 +0000 (21:53 +0000)]
Optimize the vector UINT_TO_FP, SINT_TO_FP and FP_TO_SINT operations where the integer type is i8 (commonly used in graphics).

llvm-svn: 155397

12 years agoThis patch fixes a problem which arose when using the Post-RA scheduler
Preston Gurd [Mon, 23 Apr 2012 21:39:35 +0000 (21:39 +0000)]
This patch fixes a problem which arose when using the Post-RA scheduler
on X86 Atom. Some of our tests failed because the tail merging part of
the BranchFolding pass was creating new basic blocks which did not
contain live-in information. When the anti-dependency code in the Post-RA
scheduler ran, it would sometimes rename the register containing
the function return value because the fact that the return value was
live-in to the subsequent block had been lost. To fix this, it is necessary
to run the RegisterScavenging code in the BranchFolding pass.

This patch makes sure that the register scavenging code is invoked
in the X86 subtarget only when post-RA scheduling is being done.
Post RA scheduling in the X86 subtarget is only done for Atom.

This patch adds a new function to the TargetRegisterClass to control
whether or not live-ins should be preserved during branch folding.
This is necessary in order for the anti-dependency optimizations done
during the PostRASchedulerList pass to work properly when doing
Post-RA scheduling for the X86 in general and for the Intel Atom in particular.

The patch adds and invokes the new function trackLivenessAfterRegAlloc()
instead of using the existing requiresRegisterScavenging().
It changes BranchFolding.cpp to call trackLivenessAfterRegAlloc() instead of
requiresRegisterScavenging(). It changes the all the targets that
implemented requiresRegisterScavenging() to also implement
trackLivenessAfterRegAlloc().

It adds an assertion in the Post RA scheduler to make sure that post RA
liveness information is available when it is needed.

It changes the X86 break-anti-dependencies test to use –mcpu=atom, in order
to avoid running into the added assertion.

Finally, this patch restores the use of anti-dependency checking
(which was turned off temporarily for the 3.1 release) for
Intel Atom in the Post RA scheduler.

Patch by Andy Zhang!

Thanks to Jakob and Anton for their reviews.

llvm-svn: 155395

12 years agoARM: VSLI two-operand assmebly aliases are tblgen'erated.
Jim Grosbach [Mon, 23 Apr 2012 21:22:04 +0000 (21:22 +0000)]
ARM: VSLI two-operand assmebly aliases are tblgen'erated.

llvm-svn: 155393

12 years agoARM: tblgen'erate VSRA/VRSRA/VSRI assembly two-operand aliases.
Jim Grosbach [Mon, 23 Apr 2012 21:00:49 +0000 (21:00 +0000)]
ARM: tblgen'erate VSRA/VRSRA/VSRI assembly two-operand aliases.

llvm-svn: 155392

12 years agoARM: Add testcases for two-operand variants of VSRA/VRSRA/VSRI.
Jim Grosbach [Mon, 23 Apr 2012 21:00:47 +0000 (21:00 +0000)]
ARM: Add testcases for two-operand variants of VSRA/VRSRA/VSRI.

llvm-svn: 155391

12 years agoAdd ARM mode tests for the NEON vector shift-accumulate tests.
Jim Grosbach [Mon, 23 Apr 2012 21:00:44 +0000 (21:00 +0000)]
Add ARM mode tests for the NEON vector shift-accumulate tests.

llvm-svn: 155390

12 years agoTidy up. Reformat for ease of reading.
Jim Grosbach [Mon, 23 Apr 2012 21:00:42 +0000 (21:00 +0000)]
Tidy up. Reformat for ease of reading.

llvm-svn: 155389

12 years agoThread safety analysis: refactor test cases so that the style is
DeLesley Hutchins [Mon, 23 Apr 2012 20:41:57 +0000 (20:41 +0000)]
Thread safety analysis: refactor test cases so that the style is
consistent.

llvm-svn: 155388

12 years agoARM: vqdmulh two-operand aliases are tblgen'erated now.
Jim Grosbach [Mon, 23 Apr 2012 20:37:20 +0000 (20:37 +0000)]
ARM: vqdmulh two-operand aliases are tblgen'erated now.

llvm-svn: 155387

12 years agowith -Wdeprecated, include a note to its deprecated declaration
Fariborz Jahanian [Mon, 23 Apr 2012 20:30:52 +0000 (20:30 +0000)]
with -Wdeprecated, include a note to its deprecated declaration
location. // rdar://10893232

llvm-svn: 155385

12 years agoAdded the ability to specify the symbol file for a module when adding it to a target.
Greg Clayton [Mon, 23 Apr 2012 20:23:39 +0000 (20:23 +0000)]
Added the ability to specify the symbol file for a module when adding it to a target.

llvm-svn: 155384

12 years ago[Support/Unix] Unconditionally include time.h.
Michael J. Spencer [Mon, 23 Apr 2012 19:00:27 +0000 (19:00 +0000)]
[Support/Unix] Unconditionally include time.h.

When building LLVM on Linux with libc++ with CMake TIME_WITH_SYS_TIME is
undefined, and HAVE_SYS_TIME_H is defined. This ends up including
sys/time.h but not time.h. Unix/TimeValue.inc requires time.h for asctime_r
and localtime. libstdc++ seems to include time.h anyway, but libc++ does
not.

Fix this by always including time.h

llvm-svn: 155382