oota-llvm.git
13 years agoAdd another missing cast for Neon vcombine results.
Bob Wilson [Thu, 2 Dec 2010 01:18:18 +0000 (01:18 +0000)]
Add another missing cast for Neon vcombine results.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120639 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd casts in arm_neon.h for result values in inline functions as well as macros.
Bob Wilson [Thu, 2 Dec 2010 01:18:15 +0000 (01:18 +0000)]
Add casts in arm_neon.h for result values in inline functions as well as macros.
We should not rely on lax-vector-conversions for these intrinsics to work.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120638 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoIf tehre are not any line entry then do not try to emit .debug_line section.
Devang Patel [Thu, 2 Dec 2010 01:17:51 +0000 (01:17 +0000)]
If tehre are not any line entry then do not try to emit .debug_line section.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120637 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoImplement the first half of LiveDebugVariables.
Jakob Stoklund Olesen [Thu, 2 Dec 2010 00:37:37 +0000 (00:37 +0000)]
Implement the first half of LiveDebugVariables.

Scan the MachineFunction for DBG_VALUE instructions, and replace them with a
data structure similar to LiveIntervals. The live range of a DBG_VALUE is
determined by propagating it down the dominator tree until a new DBG_VALUE is
found. When a DBG_VALUE lives in a register, its live range is confined to the
live range of the register's value.

LiveDebugVariables runs before coalescing, so DBG_VALUEs are not artificially
extended when registers are joined.

The missing half will recreate DBG_VALUE instructions from the intervals when
register allocation is complete.

The pass is disabled by default. It can be enabled with the temporary command
line option -live-debug-variables.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120636 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd support for binary encoding of ARM 'adr' instructions referencing constant
Jim Grosbach [Thu, 2 Dec 2010 00:28:45 +0000 (00:28 +0000)]
Add support for binary encoding of ARM 'adr' instructions referencing constant
pool entries (LEApcrel pseudo). Ongoing saga of rdar://8542291.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120635 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAvoid "char" for Neon vector elements; make it explicitly signed (or unsigned).
Bob Wilson [Thu, 2 Dec 2010 00:24:59 +0000 (00:24 +0000)]
Avoid "char" for Neon vector elements; make it explicitly signed (or unsigned).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120632 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoCast scalar results of Neon macros to the correct type.
Bob Wilson [Thu, 2 Dec 2010 00:24:56 +0000 (00:24 +0000)]
Cast scalar results of Neon macros to the correct type.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120631 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRevert r120580.
Devang Patel [Thu, 2 Dec 2010 00:22:29 +0000 (00:22 +0000)]
Revert r120580.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120630 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix and re-enable tail call optimization of expanded libcalls.
Evan Cheng [Wed, 1 Dec 2010 22:59:46 +0000 (22:59 +0000)]
Fix and re-enable tail call optimization of expanded libcalls.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120622 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove unused argument.
Rafael Espindola [Wed, 1 Dec 2010 22:48:11 +0000 (22:48 +0000)]
Remove unused argument.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120621 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agofixing style nit: move class static to global static
Jason W Kim [Wed, 1 Dec 2010 22:46:50 +0000 (22:46 +0000)]
fixing style nit: move class static to global static

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120619 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMake valgrind happy.
Michael J. Spencer [Wed, 1 Dec 2010 22:28:42 +0000 (22:28 +0000)]
Make valgrind happy.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120616 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd a post encoder method to the VFP instructions to convert them to the Thumb2
Bill Wendling [Wed, 1 Dec 2010 21:54:50 +0000 (21:54 +0000)]
Add a post encoder method to the VFP instructions to convert them to the Thumb2
encoding if we're in that mode.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120608 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoUse the correct fixup type for ARM VLDR*
Jim Grosbach [Wed, 1 Dec 2010 21:09:40 +0000 (21:09 +0000)]
Use the correct fixup type for ARM VLDR*

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120604 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRename temporary symbols if they conflict with artificial symbols created
Rafael Espindola [Wed, 1 Dec 2010 20:46:11 +0000 (20:46 +0000)]
Rename temporary symbols if they conflict with artificial symbols created
by the assembler. This was blocking parsing any large .s produced by clang for
example.

Fixes PR8596.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120603 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/FileSystem: Fix copy_file implementation to use toNullTerminatedStringRef
Michael J. Spencer [Wed, 1 Dec 2010 20:37:42 +0000 (20:37 +0000)]
Support/FileSystem: Fix copy_file implementation to use toNullTerminatedStringRef
instead of toStringRef. The file system APIs need c strings.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120601 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/ADT/Twine: Add toNullTerminatedStringRef.
Michael J. Spencer [Wed, 1 Dec 2010 20:37:30 +0000 (20:37 +0000)]
Support/ADT/Twine: Add toNullTerminatedStringRef.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120600 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd explicit casts for vector arguments to Neon builtins.
Bob Wilson [Wed, 1 Dec 2010 19:49:58 +0000 (19:49 +0000)]
Add explicit casts for vector arguments to Neon builtins.
This avoids warnings with -Wvector-conversions.  Radar 8228022.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120597 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd some comments for TableGen's NeonEmitter.
Bob Wilson [Wed, 1 Dec 2010 19:49:56 +0000 (19:49 +0000)]
Add some comments for TableGen's NeonEmitter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120596 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoCleanup: simplify checks for integers between 2 and 4.
Bob Wilson [Wed, 1 Dec 2010 19:49:51 +0000 (19:49 +0000)]
Cleanup: simplify checks for integers between 2 and 4.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120595 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRefactor LEApcrelJT as a pseudo-instructionlowered to a cannonical ADR
Jim Grosbach [Wed, 1 Dec 2010 19:47:31 +0000 (19:47 +0000)]
Refactor LEApcrelJT as a pseudo-instructionlowered to a cannonical ADR
instruction at MC lowering. Add binary encoding information for the ADR,
including fixup data for the label operand.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120594 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/FileSystem: Add copy_file implementation. Not tests yet because the
Michael J. Spencer [Wed, 1 Dec 2010 19:32:01 +0000 (19:32 +0000)]
Support/FileSystem: Add copy_file implementation. Not tests yet because the
file creation APIs aren't implemented.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120593 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/PathV2: Split PathV2.h into PathV2.h and FileSystem.h.
Michael J. Spencer [Wed, 1 Dec 2010 19:31:48 +0000 (19:31 +0000)]
Support/PathV2: Split PathV2.h into PathV2.h and FileSystem.h.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120592 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agounittests/Support/PathV2: Fix -pedantic warning.
Michael J. Spencer [Wed, 1 Dec 2010 19:23:49 +0000 (19:23 +0000)]
unittests/Support/PathV2: Fix -pedantic warning.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120590 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd correct encodings for STRD and LDRD, including fixup support. Additionally,...
Owen Anderson [Wed, 1 Dec 2010 19:18:46 +0000 (19:18 +0000)]
Add correct encodings for STRD and LDRD, including fixup support.  Additionally, update these to unified syntax.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120589 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agokill trailing space
Jason W Kim [Wed, 1 Dec 2010 19:07:22 +0000 (19:07 +0000)]
kill trailing space

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120586 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix a mised reloc rename spot.
Jim Grosbach [Wed, 1 Dec 2010 19:02:26 +0000 (19:02 +0000)]
Fix a mised reloc rename spot.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120585 91177308-0d34-0410-b5e6-96231b3b80d8

13 years ago10 bits, not 12.
Jim Grosbach [Wed, 1 Dec 2010 18:51:32 +0000 (18:51 +0000)]
10 bits, not 12.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120584 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoDisable debug info for x86-darwin9 and earlier until PR 8715 and radar 8709290 are...
Devang Patel [Wed, 1 Dec 2010 16:59:34 +0000 (16:59 +0000)]
Disable debug info for x86-darwin9 and earlier until PR 8715 and radar 8709290 are fixed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120580 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd hiddent command line option, as an debugging aid, to disable .loc use.
Devang Patel [Wed, 1 Dec 2010 15:36:49 +0000 (15:36 +0000)]
Add hiddent command line option, as an debugging aid, to disable .loc use.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120575 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoI don't think it makes any sense to assert that the target supports SSE3 here.
Duncan Sands [Wed, 1 Dec 2010 12:58:13 +0000 (12:58 +0000)]
I don't think it makes any sense to assert that the target supports SSE3 here.
The user (i.e. whoever generated a call to the intrinsic in the first place) is
essentially asking for a particular instruction to be placed in the assembler.
If that instruction won't execute on the target machine, that's their problem
not ours.  Two buildbots with processors that don't support SSE3 were barfing
on the apm.ll test in CodeGen/X86 because of this assertion.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120574 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoptx: bug fix: use after free
Che-Liang Chiou [Wed, 1 Dec 2010 11:45:53 +0000 (11:45 +0000)]
ptx: bug fix: use after free

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120571 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoPR5207: Rename overloaded APInt methods set(), clear(), flip() to
Jay Foad [Wed, 1 Dec 2010 08:53:58 +0000 (08:53 +0000)]
PR5207: Rename overloaded APInt methods set(), clear(), flip() to
setAllBits(), setBit(unsigned), etc.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120564 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/PathV2: Add is_{absolute,relative} implementation.
Michael J. Spencer [Wed, 1 Dec 2010 06:21:53 +0000 (06:21 +0000)]
Support/PathV2: Add is_{absolute,relative} implementation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120560 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/PathV2: Add has_{root_path,root_name,root_directory,parent_path,filename...
Michael J. Spencer [Wed, 1 Dec 2010 06:03:50 +0000 (06:03 +0000)]
Support/PathV2: Add has_{root_path,root_name,root_directory,parent_path,filename,stem,extension} implementation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120559 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agounittests/Support/PathV2: Make tests much shorter; although harder to understand.
Michael J. Spencer [Wed, 1 Dec 2010 06:03:33 +0000 (06:03 +0000)]
unittests/Support/PathV2: Make tests much shorter; although harder to understand.

I'm going to replace this all anyway with a proper table and separated tests
when done.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120558 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoElaborate on FIXME.
Jim Grosbach [Wed, 1 Dec 2010 04:01:17 +0000 (04:01 +0000)]
Elaborate on FIXME.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120552 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMove the ARMAsmPrinter class defintiion into a header file.
Jim Grosbach [Wed, 1 Dec 2010 03:45:07 +0000 (03:45 +0000)]
Move the ARMAsmPrinter class defintiion into a header file.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120551 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/PathV2: Add extension implementation.
Michael J. Spencer [Wed, 1 Dec 2010 03:37:41 +0000 (03:37 +0000)]
Support/PathV2: Add extension implementation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120550 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSpeculatively disable x86 portion of r120501 to appease the x86_64 buildbot.
Evan Cheng [Wed, 1 Dec 2010 03:27:20 +0000 (03:27 +0000)]
Speculatively disable x86 portion of r120501 to appease the x86_64 buildbot.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120549 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/PathV2: Add stem implementation.
Michael J. Spencer [Wed, 1 Dec 2010 03:18:33 +0000 (03:18 +0000)]
Support/PathV2: Add stem implementation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120547 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/PathV2: Add filename implementation.
Michael J. Spencer [Wed, 1 Dec 2010 03:18:17 +0000 (03:18 +0000)]
Support/PathV2: Add filename implementation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120546 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove "comparison of integers of different signs" warning by making the
Bill Wendling [Wed, 1 Dec 2010 02:49:04 +0000 (02:49 +0000)]
Remove "comparison of integers of different signs" warning by making the
variable unsigned.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120541 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/PathV2: Remove is_valid. It was only added because Path had it, but
Michael J. Spencer [Wed, 1 Dec 2010 02:48:43 +0000 (02:48 +0000)]
Support/PathV2: Remove is_valid. It was only added because Path had it, but
apparently it is unused.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120540 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/PathV2: Add native implementation.
Michael J. Spencer [Wed, 1 Dec 2010 02:48:27 +0000 (02:48 +0000)]
Support/PathV2: Add native implementation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120539 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoDelete Path::appendSuffix's return value; it wasn't used anywhere, which
Dan Gohman [Wed, 1 Dec 2010 02:46:41 +0000 (02:46 +0000)]
Delete Path::appendSuffix's return value; it wasn't used anywhere, which
is fine since isn't really necessary to check isValid there anyway.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120538 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoGeneral cleanups of comments.
Bill Wendling [Wed, 1 Dec 2010 02:42:55 +0000 (02:42 +0000)]
General cleanups of comments.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120536 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoARM/MC/ELF relocation "hello world" for movw/movt.
Jason W Kim [Wed, 1 Dec 2010 02:40:06 +0000 (02:40 +0000)]
ARM/MC/ELF relocation "hello world" for movw/movt.
Lifted adjustFixupValue() from Darwin for sharing w ELF.
Test added
TODO:
  refactor ELFObjectWriter::RecordRelocation more.
  Possibly share more code with Darwin?
  Lots more relocations...

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120534 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFormatting. It's all the rage!
Bill Wendling [Wed, 1 Dec 2010 02:36:55 +0000 (02:36 +0000)]
Formatting. It's all the rage!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120533 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMore refactoring. This time the T1pI pattern.
Bill Wendling [Wed, 1 Dec 2010 02:28:08 +0000 (02:28 +0000)]
More refactoring. This time the T1pI pattern.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120532 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRefactor load/store handling again. Simplify and make some room for
Eric Christopher [Wed, 1 Dec 2010 01:40:24 +0000 (01:40 +0000)]
Refactor load/store handling again. Simplify and make some room for
reg+reg handling.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120526 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoInitialize an ARMConstantPoolValue field.
Jan Wen Voung [Wed, 1 Dec 2010 01:38:58 +0000 (01:38 +0000)]
Initialize an ARMConstantPoolValue field.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120525 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agos/T1pIEncode/T1pILdStEncode/g
Bill Wendling [Wed, 1 Dec 2010 01:38:08 +0000 (01:38 +0000)]
s/T1pIEncode/T1pILdStEncode/g
s/T1pIEncodeImm/T1pILdStEncodeImm/g

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120524 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRenaming variables to coincide with documentation. No functionality change.
Bill Wendling [Wed, 1 Dec 2010 01:32:02 +0000 (01:32 +0000)]
Renaming variables to coincide with documentation. No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120522 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agofix a bozo bug I introduced in r119930, causing a miscompile of
Chris Lattner [Wed, 1 Dec 2010 01:24:55 +0000 (01:24 +0000)]
fix a bozo bug I introduced in r119930, causing a miscompile of
20040709-1.c from the gcc testsuite.  I was using the size of a
pointer instead of the pointee.  This fixes rdar://8713376

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120519 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRefactor T1sI and T1sIt encodings into helper classes.
Bill Wendling [Wed, 1 Dec 2010 01:20:15 +0000 (01:20 +0000)]
Refactor T1sI and T1sIt encodings into helper classes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120518 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/PathV2: Add replace_extension implementation.
Michael J. Spencer [Wed, 1 Dec 2010 00:52:55 +0000 (00:52 +0000)]
Support/PathV2: Add replace_extension implementation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120514 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/PathV2: Add remove_filename implementation.
Michael J. Spencer [Wed, 1 Dec 2010 00:52:28 +0000 (00:52 +0000)]
Support/PathV2: Add remove_filename implementation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120513 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRefactor the T1sIt encodings into a parent class to get rid of all of the "let"
Bill Wendling [Wed, 1 Dec 2010 00:48:44 +0000 (00:48 +0000)]
Refactor the T1sIt encodings into a parent class to get rid of all of the "let"
statements.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120512 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoUse by-name rather than by-order matching for NEON operands.
Owen Anderson [Wed, 1 Dec 2010 00:28:25 +0000 (00:28 +0000)]
Use by-name rather than by-order matching for NEON operands.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120507 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agotest/Archive: FileCheck-ize, and remove *.toc. These may be CRLF-tolerant.
NAKAMURA Takumi [Wed, 1 Dec 2010 00:09:25 +0000 (00:09 +0000)]
test/Archive: FileCheck-ize, and remove *.toc. These may be CRLF-tolerant.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120506 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoComment typo.
Andrew Trick [Tue, 30 Nov 2010 23:59:50 +0000 (23:59 +0000)]
Comment typo.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120504 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoEnable sibling call optimization of libcalls which are expanded during
Evan Cheng [Tue, 30 Nov 2010 23:55:39 +0000 (23:55 +0000)]
Enable sibling call optimization of libcalls which are expanded during
legalization time. Since at legalization time there is no mapping from
SDNode back to the corresponding LLVM instruction and the return
SDNode is target specific, this requires a target hook to check for
eligibility. Only x86 and ARM support this form of sibcall optimization
right now.
rdar://8707777

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120501 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRename operands to match ARM documentation. No functionality change.
Bill Wendling [Tue, 30 Nov 2010 23:54:45 +0000 (23:54 +0000)]
Rename operands to match ARM documentation. No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120500 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix typo.
Jim Grosbach [Tue, 30 Nov 2010 23:51:41 +0000 (23:51 +0000)]
Fix typo.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120499 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoEnhance DSE to handle the variable index case in PR8657.
Chris Lattner [Tue, 30 Nov 2010 23:43:23 +0000 (23:43 +0000)]
Enhance DSE to handle the variable index case in PR8657.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120498 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoTrailing whitespace.
Jim Grosbach [Tue, 30 Nov 2010 23:29:24 +0000 (23:29 +0000)]
Trailing whitespace.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120497 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/PathV2: Implement reverse iteration and parent_path.
Michael J. Spencer [Tue, 30 Nov 2010 23:28:07 +0000 (23:28 +0000)]
Support/PathV2: Implement reverse iteration and parent_path.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120496 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSupport/ADT/StringRef: Add find_last_of.
Michael J. Spencer [Tue, 30 Nov 2010 23:27:35 +0000 (23:27 +0000)]
Support/ADT/StringRef: Add find_last_of.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120495 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoThanks to JimG for catching this!
Jason W Kim [Tue, 30 Nov 2010 23:27:18 +0000 (23:27 +0000)]
Thanks to JimG for catching this!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120494 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoremove fixme comment too.
Chris Lattner [Tue, 30 Nov 2010 23:25:01 +0000 (23:25 +0000)]
remove fixme comment too.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120493 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agocheck in *all* files. This is now handled by my previous DSE commit.
Chris Lattner [Tue, 30 Nov 2010 23:23:59 +0000 (23:23 +0000)]
check in *all* files.  This is now handled by my previous DSE commit.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120492 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoCoding style. No significant functionality. Abandon linear scan style
Andrew Trick [Tue, 30 Nov 2010 23:18:47 +0000 (23:18 +0000)]
Coding style. No significant functionality. Abandon linear scan style
in favor of the widespread llvm style. Capitalize variables and add
newlines for visual parsing. Rename variables for readability.
And other cleanup.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120490 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoInline classes that were used in only one place.
Bill Wendling [Tue, 30 Nov 2010 23:16:25 +0000 (23:16 +0000)]
Inline classes that were used in only one place.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120488 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoteach DSE to use GetPointerBaseWithConstantOffset to analyze
Chris Lattner [Tue, 30 Nov 2010 23:05:20 +0000 (23:05 +0000)]
teach DSE to use GetPointerBaseWithConstantOffset to analyze
may-aliasing stores that partially overlap with different base
pointers.  This implements PR6043 and the non-variable part of
PR8657

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120485 91177308-0d34-0410-b5e6-96231b3b80d8

13 years ago* Add support for encoding t_addrmode_s2 and t_addrmode_s1. They are the same as
Bill Wendling [Tue, 30 Nov 2010 22:57:21 +0000 (22:57 +0000)]
* Add support for encoding t_addrmode_s2 and t_addrmode_s1. They are the same as
  t_addrmode_s4, but with a different scaling factor.

* Encode the Thumb1 load and store instructions. This involved a bit of
  refactoring (hi, Chris! :-). Some of the patterns became dead afterwards and
  were removed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120482 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSimplify the encoding of reg+/-imm12 values that allow PC-relative encoding. This...
Owen Anderson [Tue, 30 Nov 2010 22:45:47 +0000 (22:45 +0000)]
Simplify the encoding of reg+/-imm12 values that allow PC-relative encoding.  This allows the
Thumb2 encoding to share code with the ARM encoding, which gets use fixup support for free.
It also allows us to fold away at least one codegen-only pattern.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120481 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix handling of ARM negative pc-relative fixups for loads and stores.
Jim Grosbach [Tue, 30 Nov 2010 22:40:36 +0000 (22:40 +0000)]
Fix handling of ARM negative pc-relative fixups for loads and stores.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120480 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomove GetPointerBaseWithConstantOffset out of GVN into ValueTracking.h
Chris Lattner [Tue, 30 Nov 2010 22:25:26 +0000 (22:25 +0000)]
move GetPointerBaseWithConstantOffset out of GVN into ValueTracking.h

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120476 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoremove a fixed fixme
Chris Lattner [Tue, 30 Nov 2010 22:18:11 +0000 (22:18 +0000)]
remove a fixed fixme

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120474 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMake DeleteDeadInstruction be a static function, move some code around.
Chris Lattner [Tue, 30 Nov 2010 21:58:14 +0000 (21:58 +0000)]
Make DeleteDeadInstruction be a static function, move some code around.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120471 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMove X86InstrFPStack.td over to PseudoI as well.
Eric Christopher [Tue, 30 Nov 2010 21:57:32 +0000 (21:57 +0000)]
Move X86InstrFPStack.td over to PseudoI as well.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120470 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoswitch RemoveAccessedObjects to use AliasAnalysis::Location to simplify
Chris Lattner [Tue, 30 Nov 2010 21:47:58 +0000 (21:47 +0000)]
switch RemoveAccessedObjects to use AliasAnalysis::Location to simplify
the code.  We now get accurate sizes on Loads, though it surely doesn't
matter in practice.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120469 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agotwo improvements to RemoveAccessedObjects:
Chris Lattner [Tue, 30 Nov 2010 21:38:30 +0000 (21:38 +0000)]
two improvements to RemoveAccessedObjects:
1. if the underlying pointer passed in can be resolved
   to any argument or alloca, then we don't need to scan.
   Previously we would only avoid the scan if the alloca
   or byval was actually considered dead.
2. The dead store processing code is itself completely
   dead and didn't handle volatile stores right anyway,
   so delete it.  This allows simplifying the interface
   to RemoveAccessedObjects.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120467 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMigrate X86InstrControl.td to use PseudoI and fix a couple of 80-col violations
Eric Christopher [Tue, 30 Nov 2010 21:37:36 +0000 (21:37 +0000)]
Migrate X86InstrControl.td to use PseudoI and fix a couple of 80-col violations
while I'm in there.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120466 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoremove the "undead" terminology, which is nonstandard and never
Chris Lattner [Tue, 30 Nov 2010 21:32:12 +0000 (21:32 +0000)]
remove the "undead" terminology, which is nonstandard and never
made sense to me.  We now have a set of dead stack objects, and
they become live when loaded.  Fix a theoretical problem where
we'd pass in the wrong pointer to the alias query.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120465 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomove call handling in handleEndBlock up a bit, and simplify it.
Chris Lattner [Tue, 30 Nov 2010 21:18:46 +0000 (21:18 +0000)]
move call handling in handleEndBlock up a bit, and simplify it.
If the call might read all the allocas, stop scanning early.
Convert a vector to smallvector, shrink SmallPtrSet to 16 instead
of 64 to avoid crazy linear scans.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120463 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoPerformance optimization on ImmutableMap/ImmutableSet:
Ted Kremenek [Tue, 30 Nov 2010 20:26:45 +0000 (20:26 +0000)]
Performance optimization on ImmutableMap/ImmutableSet:

- Use a DenseSet instead of a FoldingSet to cache
canonicalized nodes.  This reduces the overhead
of double-hashing.

- Use reference counts in ImutAVLTree to much
more aggressively recover tree nodes that are
no longer usable.  We can generate many
transient nodes while using add() and remove()
on ImmutableSet/ImmutableMaps to generate a final
set/map.

For the clang static analyzer (the main client
of these data structures), this results in
a slight speedup (0.5%) when analyzing sqlite3,
but much more importantly results in a 30-60%
reduction in peak memory usage when the analyzer
is analyzing a given function in a file.  On
average that's about a ** 44% reduction ** in the
memory footprint of the static analyzer.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120459 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAvoid exponential growth of a table. It feels like
Dale Johannesen [Tue, 30 Nov 2010 20:23:21 +0000 (20:23 +0000)]
Avoid exponential growth of a table.  It feels like
there should be a better way to do this.  PR 8679.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120457 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoProvide Thumb2 encodings for a few miscellaneous instructions.
Owen Anderson [Tue, 30 Nov 2010 20:00:01 +0000 (20:00 +0000)]
Provide Thumb2 encodings for a few miscellaneous instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120455 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agovarious cleanups and code simplification
Chris Lattner [Tue, 30 Nov 2010 19:48:15 +0000 (19:48 +0000)]
various cleanups and code simplification

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120454 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agomake getPointerSize a static function. Add ivars to DSE for
Chris Lattner [Tue, 30 Nov 2010 19:34:42 +0000 (19:34 +0000)]
make getPointerSize a static function.  Add ivars to DSE for
AA and MD pass info instead of using getAnalysis<> all over.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120453 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoreduce indentation, clean up TD use a bit.
Chris Lattner [Tue, 30 Nov 2010 19:28:23 +0000 (19:28 +0000)]
reduce indentation, clean up TD use a bit.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120452 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd FIXME
Jim Grosbach [Tue, 30 Nov 2010 19:25:56 +0000 (19:25 +0000)]
Add FIXME

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120451 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoforbid rtti and exceptions
Chris Lattner [Tue, 30 Nov 2010 19:20:40 +0000 (19:20 +0000)]
forbid rtti and exceptions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120450 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd encoding support for Thumb2 PLD and PLI instructions.
Owen Anderson [Tue, 30 Nov 2010 19:19:31 +0000 (19:19 +0000)]
Add encoding support for Thumb2 PLD and PLI instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120449 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoNoticed this on inspection, fix and update some comments.
Eric Christopher [Tue, 30 Nov 2010 19:14:07 +0000 (19:14 +0000)]
Noticed this on inspection, fix and update some comments.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120447 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoenhance isRemovable to refuse to delete volatile mem transfers
Chris Lattner [Tue, 30 Nov 2010 19:12:10 +0000 (19:12 +0000)]
enhance isRemovable to refuse to delete volatile mem transfers
now that DSE hacks on them.  This fixes a regression I introduced,
by generalizing DSE to hack on transfers.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120445 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoThe VLDMQ/VSTMQ instructions are reprented as true Pseudo-insts now (i.e.,
Jim Grosbach [Tue, 30 Nov 2010 19:08:32 +0000 (19:08 +0000)]
The VLDMQ/VSTMQ instructions are reprented as true Pseudo-insts now (i.e.,
no extra encoding information), so we no longer need to special case them
here.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120444 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoTidy up.
Jim Grosbach [Tue, 30 Nov 2010 19:00:13 +0000 (19:00 +0000)]
Tidy up.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120443 91177308-0d34-0410-b5e6-96231b3b80d8