Commit Graph

17096 Commits

Author SHA1 Message Date
Evan Cheng a974031ebd Select add FI, c correctly.
llvm-svn: 33960
2007-02-06 09:11:20 +00:00
Evan Cheng ea3308aef0 foldMemoryOperand() cannot fold tMOVrr sp into load / store in thumb mode. tLDRspi / tSTRspi cannot target / store high registers.
llvm-svn: 33958
2007-02-06 06:13:29 +00:00
Chris Lattner 1b4b054cba Fix PR1181 and CodeGen/CBackend/2007-02-05-memset.ll
llvm-svn: 33957
2007-02-06 06:07:51 +00:00
Zhou Sheng 94b623aad4 As Reid suggested, fixed some problems.
llvm-svn: 33955
2007-02-06 06:04:53 +00:00
Chris Lattner 28cbd1d624 Disable this for now.
llvm-svn: 33953
2007-02-06 05:38:37 +00:00
Zhou Sheng dac63788ab Add a class APInt to represent arbitrary precision constant integral values.
It is a functional replacement for common case integer type like "unsigned",
"uint64_t", but also allows non-byte-width integer type and large integer
value types such as 3-bits, 15-bits, or more than 64-bits of precision. For
more details, see pr1043.

llvm-svn: 33951
2007-02-06 03:00:16 +00:00
Chris Lattner e62c89a9f5 Fix Transforms/ConstProp/2007-02-05-BitCast.ll
llvm-svn: 33948
2007-02-06 02:22:56 +00:00
Chris Lattner 89e66e0c26 Oops, swap this. This fixes a regression I introduced in the ARM backend.
llvm-svn: 33946
2007-02-06 01:56:31 +00:00
Evan Cheng 2fc792f86b eliminateFrameIndex() bug when frame pointer is used as base register.
llvm-svn: 33945
2007-02-06 00:23:31 +00:00
Evan Cheng 650d0672f7 - Store val, [sp, c] must be selected to tSTRsp.
- If c does not fit in the offset field, materialize sp + c into a register
  using tADDhirr.

llvm-svn: 33944
2007-02-06 00:22:06 +00:00
Reid Spencer 92b50800f6 Although targets are not required to support integers > 64bits, TargetData
must in order for backends that do want to support large integer types to be
able to function. Consequently, don't assert if the bitwidth > 64 bits
when computing the size and alignment. Instead, compute the size by rounding
up to the next even number of bytes for the size. Compute the alignment
as the same as the LongABIAlignment. These provide reasonable defaults
that the target can override.

llvm-svn: 33943
2007-02-05 23:51:43 +00:00
Reid Spencer d7a00d7414 A value of 64 or fewer bits is valid if the ConstantInt has more then 64 bits.
llvm-svn: 33942
2007-02-05 23:47:56 +00:00
Reid Spencer f75727ab14 Make classes in anonymous namespaces use VISIBILITY_HIDDEN to help reduce
LLVM's footprint and speed up linking.

llvm-svn: 33941
2007-02-05 23:42:17 +00:00
Chris Lattner c85e79f3e0 With the last change, we no longer need both directions of mapping from
BBNumbers.  Instead of using a bi-directional mapping, just use a single
densemap.  This speeds up mem2reg on 176.gcc by 8%, from  1.3489 to
1.2485s.

llvm-svn: 33940
2007-02-05 23:37:20 +00:00
Reid Spencer 557ab15e71 Apply the VISIBILITY_HIDDEN field to the remaining anonymous classes in
the Transforms library. This reduces debug library size by 132 KB, debug
binary size by 376 KB, and reduces link time for llvm tools slightly.

llvm-svn: 33939
2007-02-05 23:32:05 +00:00
Chris Lattner 52da61fb5c Simplify use of DFBlocks, this makes no noticable performance difference,
but paves the way to eliminate BBNumbers.

llvm-svn: 33938
2007-02-05 23:31:26 +00:00
Reid Spencer 193abd95c9 This file should have been removed when -raise was removed. It isn't
used any more.

llvm-svn: 33937
2007-02-05 23:27:02 +00:00
Chris Lattner bf67b1229b Switch InsertedPHINodes back to SmallPtrSet now that the SmallPtrSet::erase
bug is fixed.

llvm-svn: 33932
2007-02-05 23:11:37 +00:00
Chris Lattner 92c5d1185f Fix a bug in smallptrset::erase: in the small case, return true if the
element was in the set.

llvm-svn: 33931
2007-02-05 23:10:31 +00:00
Chris Lattner 606dde0093 switch a SmallPtrSet back to an std::set for now, this caused problems.
llvm-svn: 33930
2007-02-05 22:28:52 +00:00
Chris Lattner 1ed84bbd2d switch an std::set over to a SmallPtrSet, speeding up mem2reg 6% on 176.gcc.
llvm-svn: 33929
2007-02-05 22:15:21 +00:00
Chris Lattner 70fbb9de4c switch an std::set over to SmallPtrSet, speeding up mem2reg 3.4% on 176.gcc.
llvm-svn: 33928
2007-02-05 22:13:11 +00:00
Chris Lattner 8fbc888d91 eliminate some malloc traffic, this speeds up mem2reg by 3.4%.
llvm-svn: 33927
2007-02-05 21:58:48 +00:00
Reid Spencer ca3bf1ad85 Add missing and needed #include.
llvm-svn: 33926
2007-02-05 21:47:39 +00:00
Reid Spencer 35a0718d82 Make the class VISIBILITY_HIDDEN.
Reduce lexical size of the anonymous namespace.

llvm-svn: 33925
2007-02-05 21:45:12 +00:00
Chris Lattner a9428c4f9d Fix PR1178
llvm-svn: 33924
2007-02-05 21:23:52 +00:00
Reid Spencer 1241d6d5ab For PR411:
Adjust to changes in Module interface:
getMainFunction() -> getFunction("main")
getNamedFunction(X) -> getFunction(X)

llvm-svn: 33922
2007-02-05 21:19:13 +00:00
Reid Spencer 3aaaa0b2bd For PR411:
This patch replaces the SymbolTable class with ValueSymbolTable which does
not support types planes. This means that all symbol names in LLVM must now
be unique. The patch addresses the necessary changes to deal with this and
removes code no longer needed as a result. This completes the bulk of the
changes for this PR. Some cleanup patches will follow.

llvm-svn: 33918
2007-02-05 20:47:22 +00:00
Reid Spencer e84cf92141 For PR411:
This pass is no longer needed.

llvm-svn: 33917
2007-02-05 20:41:05 +00:00
Reid Spencer ba09a3e5f0 Create a pass to strip dead function declarations (prototypes). This is
for use by llvm-extract and bugpoint.

llvm-svn: 33916
2007-02-05 20:24:25 +00:00
Devang Patel 3f806969ed Fix PR1158
Do not insert Analysis pass, if it is already available.

llvm-svn: 33915
2007-02-05 19:34:17 +00:00
Reid Spencer ac6bfc5221 Regenerate.
llvm-svn: 33912
2007-02-05 17:04:00 +00:00
Reid Spencer 9894d6cba5 ! removal was a little over zealous. Put the ! back in asserts.
llvm-svn: 33911
2007-02-05 17:01:20 +00:00
Reid Spencer a7bb3e9673 Regenerate.
llvm-svn: 33909
2007-02-05 10:18:06 +00:00
Reid Spencer de1d05f0f1 There is nothing exclamatory about an error message. No other compiler
or assembler uses ! at the end of every message. We shouldn't either.

llvm-svn: 33907
2007-02-05 10:16:10 +00:00
Chris Lattner 83ac5ae9f3 Fix miscompilations of consumer-typeset, telecomm-gsm, and 176.gcc.
llvm-svn: 33902
2007-02-05 05:57:49 +00:00
Reid Spencer a1d35926b7 For PR1177:
Revert last patch which caused iteration invalidation.

llvm-svn: 33901
2007-02-05 05:23:32 +00:00
Chris Lattner 0a28e90f2c fix a miscompilation of 176.gcc
llvm-svn: 33900
2007-02-05 04:09:35 +00:00
Owen Anderson f6fa108993 Use DenseMap for pointer->pointer maps.
llvm-svn: 33897
2007-02-05 02:39:47 +00:00
Chris Lattner 3e009e8b8f rewrite shift/shift folding, now that types are not signed.
llvm-svn: 33892
2007-02-05 00:57:54 +00:00
Nick Lewycky 15245953a5 Fix indenting, remove tabs.
Learn from sext and zext. The destination value falls within the range of the
source type.

Generalize properties regarding constant ints.

Get smarter about marking blocks as unreachable. If 1 >= 2 in order for this
block to execute, then it isn't reachable.

llvm-svn: 33889
2007-02-04 23:43:05 +00:00
Anton Korobeynikov 465c0253c3 Fixing silly "not-implemented" bug in AsmPrinter. This fixes PR1169.
llvm-svn: 33888
2007-02-04 23:27:42 +00:00
Chris Lattner fe8c530d79 Fix a miscompilation in the addr mode code trying to implement X | C and
X + C to promote LEA formation.  We would incorrectly apply it in some cases
(test) and miss it in others.

This fixes CodeGen/X86/2007-02-04-OrAddrMode.ll

llvm-svn: 33884
2007-02-04 20:18:17 +00:00
Chris Lattner 19083a4671 switch the VRBaseMap in the scheduler from an std::map to a DenseMap. This
speeds up the isel pass from 2.5570s to 2.4722s on kc++ (3.4%).

llvm-svn: 33879
2007-02-04 08:47:20 +00:00
Chris Lattner 9af2c86bc8 Introduce new UnarySDNode/BinarySDNode/TernarySDNode nodes, which coallocate
their operands with the node itself.  This reduces malloc traffic for operand
lists.  This reduces isel time on kc++ from 2.6164 to 2.5570s, about 2.3%.

llvm-svn: 33878
2007-02-04 08:35:21 +00:00
Chris Lattner 22639f3d90 eliminate the SDNode::setValueTypes method.
llvm-svn: 33876
2007-02-04 07:37:24 +00:00
Chris Lattner f17b4222e2 eliminate a bunch of duplicate ctors and helper functions.
llvm-svn: 33875
2007-02-04 07:28:00 +00:00
Reid Spencer d3ba7d9b42 Fix some comments and other minor sundry things.
llvm-svn: 33873
2007-02-04 04:43:17 +00:00
Reid Spencer 2dc3653531 Ensure that visibility and section are properly propagated.
llvm-svn: 33872
2007-02-04 04:30:33 +00:00
Reid Spencer 90246aa71e Back out last revision which was committed by accident.
llvm-svn: 33871
2007-02-04 04:29:21 +00:00