Commit Graph

4085 Commits

Author SHA1 Message Date
Chris Lattner
02597f3b88 Move register numbers out of "extra" into "contents". Other minor cleanup.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28106 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-04 18:25:20 +00:00
Chris Lattner
8b915b4ed2 Remove and simplify some more machineinstr/machineoperand stuff.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28105 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-04 18:16:01 +00:00
Chris Lattner
2d90ac7ca6 Rename MO_VirtualRegister -> MO_Register. Clean up immediate handling.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28104 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-04 18:05:43 +00:00
Chris Lattner
68ab4c6367 remove hasAllocatedReg
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28103 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-04 17:56:20 +00:00
Chris Lattner
e53f4a055f Move some methods out of MachineInstr into MachineOperand
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28102 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-04 17:52:23 +00:00
Chris Lattner
63b3d7113d There shalt be only one "immediate" operand type!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28099 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-04 17:21:20 +00:00
Chris Lattner
ceb408f6a2 Change "value" in MachineOperand to be a GlobalValue, as that is the only
thing that can be in it.  Remove a dead method.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28098 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-04 17:02:51 +00:00
Chris Lattner
4efeab208c Remove a bunch more dead V9 specific stuff
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28094 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-04 01:26:39 +00:00
Chris Lattner
ea50fabfd4 Remove a bunch more SparcV9 specific stuff
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28093 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-04 01:15:02 +00:00
Chris Lattner
34fb2cad46 Remove some more V9-specific stuff.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28092 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-04 00:49:59 +00:00
Chris Lattner
10f3597c4e Remove some more unused stuff from MachineInstr that was leftover from V9.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28091 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-04 00:44:25 +00:00
Chris Lattner
5a032de387 Change from using MachineRelocation ctors to using static methods
in MachineRelocation to create Relocations.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28088 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-03 20:30:20 +00:00
Chris Lattner
1e3822c776 Cleanup the internal implementation of MachineRelocation. No interface or
functionality changes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28086 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-03 18:52:31 +00:00
Chris Lattner
b4432f3d47 Suck block address tracking out of targets into the JIT Emitter. This
simplifies the MachineCodeEmitter interface just a little bit and makes
BasicBlocks work like constant pools and jump tables.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28082 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-03 17:10:41 +00:00
Owen Anderson
a69571c799 Refactor TargetMachine, pushing handling of TargetData into the target-specific subclasses. This has one caller-visible change: getTargetData() now returns a pointer instead of a reference.
This fixes PR 759.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28074 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-03 01:29:57 +00:00
Chris Lattner
3db9e30c09 Add a new emitAlignment method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28072 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-03 01:01:51 +00:00
Chris Lattner
af1563fb62 Change the BasicBlockAddrs map to be a vector, indexed by MBB number.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28069 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-03 00:32:55 +00:00
Chris Lattner
f75f9be3fb Several related changes:
1. Change several methods in the MachineCodeEmitter class to be pure virtual.
2. Suck emitConstantPool/initJumpTableInfo into startFunction, removing them
   from the MachineCodeEmitter interface, and reducing the amount of target-
   specific code.
3. Change the JITEmitter so that it allocates constantpools and jump tables
   *right* next to the functions that they belong to, instead of in a separate
   pool of memory.  This makes all memory for a function be contiguous, and
   means the JITEmitter only tracks one block of memory now.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28065 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 23:22:24 +00:00
Chris Lattner
1f4549f35c Add a method for allocating space from the code buffer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28064 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 22:51:03 +00:00
Chris Lattner
f5d438c1f0 Do not make the JIT memory manager manage the memory for globals. Instead
just have the JIT malloc them.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28062 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 21:57:51 +00:00
Chris Lattner
d3f0aefc33 Fix a purely hypothetical problem (for now): emitWord emits in the host
byte format.  This doesn't work when using the code emitter in a cross target
environment.  Since the code emitter is only really used by the JIT, this
isn't a current problem, but if we ever start emitting .o files, it would be.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28060 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 19:14:47 +00:00
Chris Lattner
43b429b059 Refactor the machine code emitter interface to pull the pointers for the current
code emission location into the base class, instead of being in the derived classes.

This change means that low-level methods like emitByte/emitWord now are no longer
virtual (yaay for speed), and we now have a framework to support growable code
segments.  This implements feature request #1 of PR469.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28059 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 18:27:26 +00:00
Chris Lattner
15bddb96c3 Remove a now-dead method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28054 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 17:17:13 +00:00
Chris Lattner
14c03058be Remove the debug machine code emitter. The "FilePrinterEmitter" is moreuseful for debugging.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28052 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 16:59:49 +00:00
Nate Begeman
cdf38c4edb Extend printBasicBlockLabel a bit so that it can be used to print all
basic block labels, consolidating the code to do so in one place for each
target.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28050 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 05:37:32 +00:00
Chris Lattner
b3674e4753 Add pass ID's for various passes, so they can be AddRequiredID. Patch by
Domagoj Babic!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28048 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 04:24:36 +00:00
Jeff Cohen
51b776d259 De-virtualize SwitchSection.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28047 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 03:58:45 +00:00
Jeff Cohen
c6a057b04d De-virtualize EmitZeroes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28046 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 03:46:13 +00:00
Jeff Cohen
4f1ea1e9d9 Finish support for Microsoft ML/MASM. May still be a few rough edges.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28045 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 03:11:50 +00:00
Jeff Cohen
c884db47f1 Make Intel syntax mode friendlier to Microsoft ML assembler (still needs more work).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28044 91177308-0d34-0410-b5e6-96231b3b80d8
2006-05-02 01:16:28 +00:00
Evan Cheng
55d0fa1bfa Remove the temporary option: -no-isel-fold-inflight
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28012 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-28 18:54:11 +00:00
Evan Cheng
552c4a8494 Added a temporary option -no-isel-fold-inflight to control whether a "inflight"
node can be folded.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28003 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-28 02:09:19 +00:00
Evan Cheng
a7fc64222a Added X86 SSE2 intrinsics which can be represented as vector_shuffles. This is
a temporary workaround for the 2-wide vector_shuffle problem (i.e. its mask
would have type v2i32 which is not legal).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27964 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-24 23:34:56 +00:00
Evan Cheng
ccdcdf3e2e Added addJumpTableIndex
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27956 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-24 06:42:15 +00:00
Nate Begeman
9453eea49b Fix the updating of the machine CFG when a PHI node was in a successor of
the jump table's range check block.  This re-enables 100% dense jump tables
by default on PPC & x86


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27952 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-23 06:26:20 +00:00
Nate Begeman
3700a4d3a2 Code cleanup associated with jump tables, thanks to Chris for noticing
these.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27950 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-22 23:52:35 +00:00
Nate Begeman
37efe67645 JumpTable support! What this represents is working asm and jit support for
x86 and ppc for 100% dense switch statements when relocations are non-PIC.
This support will be extended and enhanced in the coming days to support
PIC, and less dense forms of jump tables.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27947 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-22 18:53:45 +00:00
Chris Lattner
f7fb31ea33 Remove a bunch of dead stuff, shrinkifying TargetInstrDescriptor significantly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27897 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-20 18:32:02 +00:00
Chris Lattner
3dc38d26fb Remove some obsolete interfaces
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27896 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-20 18:17:21 +00:00
Chris Lattner
05b9773300 Remove some of the obvious v9-specific cruft
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27894 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-20 18:09:13 +00:00
Chris Lattner
73173e72d6 remove a dead prototype
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27882 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-20 15:45:54 +00:00
Evan Cheng
c313c66a88 Added a virtual method isVectorClearMaskLegal to TLI. It is similar to
isShuffleMaskLegal, used to determine if it makes sense to turn a
"vector clear" (e.g. pand V, <0, -1, 0, -1> to a shuffle of the vector and
a zero vector.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27873 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-20 08:54:13 +00:00
Reid Spencer
9d3b814d53 Add in missing #defines for _OpenBSD_ systems.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27850 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-20 00:18:39 +00:00
Nate Begeman
6baa2b7220 Fix a copy & paste error from long ago.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27800 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-18 16:03:18 +00:00
Chris Lattner
6b56091842 Add some convenience methods.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27774 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-17 21:35:08 +00:00
Chris Lattner
6a56ed48b9 These instructions always return a packed vector. Improve the class definitions to expose this fact.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27712 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-14 22:20:07 +00:00
Evan Cheng
d953947d26 Last few SSE3 intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27711 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-14 21:59:03 +00:00
Evan Cheng
f3e1b1d716 Misc. SSE2 intrinsics: clflush, lfench, mfence
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27699 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-14 07:43:12 +00:00
Evan Cheng
bb5c43e73d pcmpeq* and pcmpgt* intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27685 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-14 01:39:53 +00:00
Evan Cheng
0ac8ea9a4f psll*, psrl*, and psra* intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27684 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-14 00:14:05 +00:00
Chris Lattner
463b4e5f4c Fix an incorrect prototype for this intrinsic, fixing
CFrontend/2003-08-18-SigSetJmp.c  with llvm-gcc3.  This is part of PR733.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27670 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-13 18:23:48 +00:00
Evan Cheng
82fad8ce4f pmin, pmax, and psad intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27646 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-13 06:09:41 +00:00
Evan Cheng
9df21dc0d2 pmul*, pmadd*, and pavg* intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27642 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-13 05:09:06 +00:00
Evan Cheng
49ac1bf1c4 padds{b|w}, paddus{b|w}, psubs{b|w}, psubus{b|w} intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27639 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-13 00:43:35 +00:00
Evan Cheng
a50a086341 Naming inconsistency.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27638 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-13 00:00:23 +00:00
Evan Cheng
d2a6d54f26 SSE / SSE2 conversion intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27637 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-12 23:42:44 +00:00
Reid Spencer
ace44dbbab Make sure both member variables are initialized in the default constructor
for SDOperand. This gets rid of numerous warnings in lib/CodeGen and
lib/Target when compiled with GCC 4.0.2


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27607 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-12 16:44:15 +00:00
Chris Lattner
b878151b1e Provide a default impl of LowerArguments
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27605 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-12 16:21:12 +00:00
Evan Cheng
d03db7a36c Various SSE2 conversion intrinsics
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27603 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-12 05:20:24 +00:00
Evan Cheng
397edeff50 Added __builtin_ia32_storelv4si, __builtin_ia32_movqv4si,
__builtin_ia32_loadlv4si, __builtin_ia32_loaddqu, __builtin_ia32_storedqu.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27599 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-11 22:28:25 +00:00
Chris Lattner
681ee1c1c3 new dag node
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27596 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-11 21:30:42 +00:00
Evan Cheng
df3c33c57e gcc lower SSE prefetch into generic prefetch intrinsic. Need to add support
later.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27591 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-11 18:04:57 +00:00
Evan Cheng
135c6a9d83 Misc. intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27590 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-11 17:35:57 +00:00
Evan Cheng
fcf5e21b96 movnt* and maskmovdqu intrinsics
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27587 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-11 06:57:30 +00:00
Chris Lattner
347d9d6136 Add helper methods.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27576 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-11 01:09:25 +00:00
Jim Laskey
1069fbdd2f Use existing information.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27574 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-10 23:09:19 +00:00
Chris Lattner
4b2362e247 Fix a typo: Instr* -> Intr*
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27568 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-10 22:02:59 +00:00
Evan Cheng
6ff7b605de __builtin_ia32_loadup{s|d}, __builtin_ia32_storeup{s|d}
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27561 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-10 21:09:59 +00:00
Andrew Lenharth
3433141a3e Add a simple pass to make sure that all (non-library) calls to malloc and free
are visible to analysis as intrinsics.  That is, make sure someone doesn't pass
free around by address in some struct (as happens in say 176.gcc).

This doesn't get rid of any indirect calls, just ensure calls to free and malloc
are always direct.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27560 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-10 19:26:09 +00:00
Chris Lattner
49027e639e Add a new VSELECT node.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27541 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-08 22:16:01 +00:00
Chris Lattner
fa495844a6 Add methods to check insert/extract element instructions for validity
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27522 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-08 04:04:54 +00:00
Chris Lattner
9fc18d24ae Add a new shufflevector instruction
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27507 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-08 01:15:18 +00:00
Evan Cheng
85db0df76c Fix int_x86_sse_stmxcsr and int_x86_sse_ldmxcsr. Not directly translated from
gcc builtins. They are not lowered into these intrinsics which take a ptr
argument.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27505 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-08 00:47:01 +00:00
Evan Cheng
c24b834425 Remove int_x86_sse_storeh_ps and int_x86_sse_storel_ps. These are now lowered
by the frontend.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27495 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-07 21:18:40 +00:00
Jim Laskey
6b92b8e50d Make sure that debug labels are defined within the same section and after the
entry point of a function.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27494 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-07 20:44:42 +00:00
Jim Laskey
4188699f80 Foundation for call frame information.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27491 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-07 16:34:46 +00:00
Evan Cheng
3511f4dc8d Remove int_x86_sse_loadh_ps and int_x86_sse_loadl_ps. These are now lowered
by the frontend to shuffles.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27475 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-06 23:25:41 +00:00
Chris Lattner
d21458cd32 These intrinsics are now lowered by the FE.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27458 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-06 21:12:48 +00:00
Chris Lattner
ab0bbd1ec8 this is no longer an intrinsic.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27451 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-06 18:29:17 +00:00
Evan Cheng
a43622683f Added comi and ucomi SSE intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27443 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-05 23:37:18 +00:00
Chris Lattner
20a86db26a add altivec ds* intrinsics
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27441 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-05 22:18:01 +00:00
Chris Lattner
41fe0015ee Get the types right, third time is the charm. Add vsl.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27424 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-05 01:15:54 +00:00
Chris Lattner
c6b3a92bf8 correct the type of two intrinsics, add int_ppc_altivec_vmladduhm
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27422 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-05 00:49:14 +00:00
Chris Lattner
1c89482e46 Add m[tf]vscr intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27420 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-05 00:03:03 +00:00
Chris Lattner
72e241cff7 Add missing byte merges.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27418 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-04 23:43:56 +00:00
Chris Lattner
a046d4ac11 Add FP -> Int Conversions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27417 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-04 23:25:02 +00:00
Chris Lattner
8d1aa57429 add average intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27415 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-04 23:13:21 +00:00
Evan Cheng
f01cf60ed7 Added intrinsics to match __builtin_ia32_pslldqi128 and
__builtin_ia32_psrldqi128.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27411 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-04 21:48:31 +00:00
Chris Lattner
d1adbc09a9 How could this ever have worked?
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27409 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-04 19:05:42 +00:00
Chris Lattner
5cdf4bd55c Make sure to consider alignment of variable sized objects.
This, along with the previous dag combiner fix, fixes
CodeGen/Alpha/2006-04-04-zextload.ll


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27403 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-04 17:39:56 +00:00
Chris Lattner
c45420ddd2 Move isShuffleLegal from TLI to Legalize.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27398 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-04 17:21:22 +00:00
Chris Lattner
12f859335c Fix the types for these intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27392 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-04 01:40:06 +00:00
Chris Lattner
e6bfffbae2 Allow targets to have fine grained control over which types various ops get
promoted to, if they desire.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27389 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-04 00:25:10 +00:00
Chris Lattner
208aa29feb Keep track of max stack alignment as objects are added. Remove an obsolete method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27378 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-03 21:38:39 +00:00
Chris Lattner
03017c75c7 shrinkify intrinsics more by using some local classes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27373 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-03 17:20:06 +00:00
Chris Lattner
846f7ce945 Add some classes to make it easier to define intrinsics. Add min/max intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27371 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-03 15:43:07 +00:00
Chris Lattner
885a87ef85 simplify this method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27338 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-02 02:28:52 +00:00
Chris Lattner
60a05cc118 Fix Transforms/IndVarsSimplify/2006-03-31-NegativeStride.ll and
PR726 by performing consistent signed division, not consistent unsigned
division when evaluating scev's.  Do not touch udivs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27326 91177308-0d34-0410-b5e6-96231b3b80d8
2006-04-01 04:48:52 +00:00
Evan Cheng
6159873e46 Added haddp{s|d} and hsubp{s|d} intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27309 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-31 21:28:46 +00:00
Chris Lattner
79227e2906 Modify the TargetLowering::getPackedTypeBreakdown method to also return the
unpromoted element type.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27273 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-31 00:46:36 +00:00
Chris Lattner
00cc494595 Add a method useful for decimating vectors.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27269 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-31 00:28:23 +00:00
Chris Lattner
e467829673 fix incorrect prototypes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27267 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-30 23:32:58 +00:00
Chris Lattner
99e746feba Add vector multiply, multiply sum, pack, unpack, and lvsl/lvsr intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27258 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-30 18:52:02 +00:00
Evan Cheng
0876aa5178 Add support for _mm_cmp{cc}_ss and _mm_cmp{cc}_ps intrinsics
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27256 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-30 06:21:22 +00:00
Evan Cheng
c5fb2b14ca Add 128-bit pmovmskb intrinsic support.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27255 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-30 00:33:26 +00:00
Evan Cheng
591f740a40 Change SSE pack operation definitions to fit what the intrinsics expected.
For example, packsswb actually creates a v16i8 from a pair of v8i16. But since
the intrinsic specification forces the output type to match the operands.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27254 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-29 23:53:14 +00:00
Evan Cheng
4e27b8e8f4 Add SSE2 integer pack with saturation intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27253 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-29 23:09:19 +00:00
Evan Cheng
074fd57fbd Add more SSE intrinsics
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27247 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-29 06:07:16 +00:00
Chris Lattner
eda6dfd5e4 Add a new node
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27230 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-28 19:54:11 +00:00
Jim Laskey
b3e7be25be Refactor address attributes. Add base register to frame info.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27226 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-28 14:58:32 +00:00
Jim Laskey
a99791886d Expose base register for DwarfWriter. Refactor code accordingly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27225 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-28 13:48:33 +00:00
Nate Begeman
98e70cc124 Add a few more altivec intrinsics
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27215 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-28 04:15:58 +00:00
Chris Lattner
9bade4de9d These don't directly map to gcc intrinsics any more.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27213 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-28 03:52:36 +00:00
Chris Lattner
858b35eaf7 Add some more intrinsics: rotates, fp rounds, and random other fp instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27208 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-28 02:28:48 +00:00
Evan Cheng
78b9ec3820 getVectorTyppe(MVT::i64, 2) ==> MVT::v2i64.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27207 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-28 01:59:17 +00:00
Chris Lattner
572f974939 Add lvxl
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27206 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-28 01:49:27 +00:00
Chris Lattner
ef8ef91634 Tblgen doesn't like multiple SDNode<> definitions that map to the same
enum value.  Split them into separate enums.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27199 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-28 00:39:06 +00:00
Chris Lattner
c9e0b1460b Reenable pointer intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27198 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-28 00:15:44 +00:00
Chris Lattner
0876f1c6a6 revert this, it breaks things
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27195 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-28 00:02:52 +00:00
Jim Laskey
eabef6b12e Should not remove casts from variable's alloca.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27191 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-27 23:30:18 +00:00
Chris Lattner
f211600f3d Add support for intrinsics with pointer arguments in target .td files.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27190 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-27 22:49:46 +00:00
Chris Lattner
5dc8050ca3 Add some missing template specializations for autodereferencing User.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27189 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-27 22:49:07 +00:00
Chris Lattner
e1562c82ca add a new iPTR ValueType for tblgen use
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27187 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-27 22:48:00 +00:00
Chris Lattner
c4c9506837 Divirge from the GCC specification of the load/store intrinsics: only take
one pointer operand, instead of a pointer and an offset.  The FE will lower
to this canonicalized form.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27186 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-27 22:38:39 +00:00
Chris Lattner
b92ca7d4b8 fix spelling :(
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27184 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-27 22:07:12 +00:00
Chris Lattner
28a0507042 add some more intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27183 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-27 22:05:34 +00:00
Evan Cheng
a3b7f6226f Intrinsics naming convention change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27172 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-27 08:23:12 +00:00
Evan Cheng
a8df166fbe Change isBuildVectorAllOnesInteger to isBuildVectorAllOnes. Also check for
floating point cases.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27165 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-27 06:58:47 +00:00
Nate Begeman
f15485a8d0 SelectionDAGISel can now natively handle Switch instructions, in the same
manner that the LowerSwitch LLVM to LLVM pass does: emitting a binary
search tree of basic blocks.  The new approach has several advantages:
it is faster, it generates significantly smaller code in many cases, and
it paves the way for implementing dense switch tables as a jump table by
handling switches directly in the instruction selector.

This functionality is currently only enabled on x86, but should be safe for
every target.  In anticipation of making it the default, the cfg is now
properly updated in the x86, ppc, and sparc select lowering code.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27156 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-27 01:32:24 +00:00
Jim Laskey
98e0410f07 How to be dumb on $5/day. Need a tri-state to track valid debug descriptors.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27154 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-26 22:45:20 +00:00
Evan Cheng
4a147842eb Add ISD::isBuildVectorAllZeros predicate
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27147 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-26 09:50:58 +00:00
Chris Lattner
8400ed3fc5 Add predicate comparison intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27145 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-26 07:50:25 +00:00
Chris Lattner
3f01c30be7 Split the PPC and X86 intrinsics out to their own files.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27141 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-26 02:37:19 +00:00
Chris Lattner
5617f82030 Add saturating subtracts, non-predicate compares, and some other random
intrinsics.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27140 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-26 02:34:07 +00:00
Chris Lattner
7344e1128a add int_ppc_altivec_vsldoi intrinsic
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27138 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-26 00:25:43 +00:00
Chris Lattner
322dcd379e Add a predicate
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27129 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-25 22:56:35 +00:00
Jim Laskey
0a868961d6 Unused function - easier to throw away than fix.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27123 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-25 18:42:45 +00:00
Chris Lattner
5814c20766 remove extraneous lets
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27114 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-25 07:30:34 +00:00
Chris Lattner
64caa8c5cc Add a bunch of simple altivec intrinsics
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27113 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-25 07:27:18 +00:00
Chris Lattner
ae5482618b Add support for __builtin_altivec_vnmsubfp
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27111 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-25 07:05:35 +00:00
Chris Lattner
e42dbed53a Add a programatic interface to intrinsic names.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27107 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-25 06:32:07 +00:00
Evan Cheng
2c8bb1f531 X86 SSE1 cacheability support ops intrinsics
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27104 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-25 06:05:45 +00:00
Evan Cheng
29e6ac620f X86 SSE1 SIMD store intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27099 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-25 02:02:51 +00:00
Evan Cheng
a30a316110 X86 SSE1 SIMD load intrinsics (movhps, movlps, and movups).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27098 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-25 01:58:54 +00:00
Evan Cheng
9abc80f6b3 X86 SSE1 conversion operations intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27097 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-25 01:35:17 +00:00
Evan Cheng
446848ed23 X86 SSE1 comparison intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27093 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-25 00:32:32 +00:00
Evan Cheng
af4398a281 X86 SSE1 arithmetic and logical operation intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27092 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-25 00:18:20 +00:00
Evan Cheng
11f0bd695a ldmxcsr is a SSE instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27086 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-24 22:13:47 +00:00
Evan Cheng
96bcc109d3 Added ldmxcsr intrinsic.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27085 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-24 22:10:59 +00:00
Chris Lattner
782651cffe Specify the value type for each llvm type. This needs work for pointers.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27074 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-24 19:41:10 +00:00
Chris Lattner
ad72e241c0 Pull in valuetypes.td here, we will use it shortly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27072 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-24 18:51:56 +00:00
Jim Laskey
b470caad78 Tweak a comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27066 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-24 16:18:42 +00:00
Jim Laskey
98a6979b25 Clean up some commentary.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27064 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-24 10:00:56 +00:00
Jim Laskey
0892cee81f Rename for truth in advertising.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27063 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-24 09:50:27 +00:00
Jeff Cohen
4822bd4308 Fix headers
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27043 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-24 06:07:16 +00:00
Jeff Cohen
f2dc4fd5de Minor corrections.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27041 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-24 02:58:54 +00:00
Jeff Cohen
2f51914d82 Get JIT/Interpreter working on Windows again.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27037 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-24 02:53:49 +00:00
Chris Lattner
72601cac60 add a new intrinsic node
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27019 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-24 01:03:55 +00:00
Chris Lattner
cf87e97b4f Add a couple simple intrinsics for intel. Fix the v2f64 definition.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27018 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-24 00:04:52 +00:00
Reid Spencer
a4282d9a81 Ignore generated file Intrinsics.gen
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27014 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-23 23:49:59 +00:00
Jim Laskey
90c79d73ac Make sure types are allocated in the scope of their use.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27002 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-23 23:02:34 +00:00
Jim Laskey
f1d78e8335 Add support to locate local variables in frames (early version.)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26994 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-23 18:12:57 +00:00
Jim Laskey
b8509c5752 Generate local variable and scope information and equivalent dwarf forms.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26989 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-23 18:07:55 +00:00
Jim Laskey
4556ce5d11 Simplify handling of llvm.dbg intrinsic operands to one spot.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26987 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-23 18:05:12 +00:00
Jim Laskey
c14897e673 Modify usage of llvm.dbg intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26986 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-23 18:04:18 +00:00
Jim Laskey
60f27ff879 Support for locating of debug items in frames.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26984 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-23 18:01:12 +00:00
Chris Lattner
475c010366 Eliminate IntrinsicLowering from TargetMachine.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26973 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-23 05:41:41 +00:00
Chris Lattner
ef98691ca3 remove always-null IntrinsicLowering argument.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26971 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-23 05:28:02 +00:00
Chris Lattner
726c1ef2bd remove the intrinsiclowering hook
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26970 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-23 05:22:51 +00:00
Evan Cheng
ca6e8eafd2 Added a ValueType operand to isShuffleMaskLegal(). For now, x86 will not do
64-bit vector shuffle.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26964 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-22 22:07:06 +00:00
Chris Lattner
313f13c5aa Fix comments
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26960 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-22 20:09:04 +00:00
Chris Lattner
762f2ae0c4 add a new node
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26958 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-22 19:56:46 +00:00
Chris Lattner
765c93cefd wrap lines to 80 columns.
Add static JITCtor/InterpCtor fields


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26945 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-22 06:06:37 +00:00
Chris Lattner
4b8db6c453 add some nodes for extractelement
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26927 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-21 20:43:08 +00:00
Nate Begeman
26d5d16a2c Move some common data structures between dom and pdom into the base class
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26905 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-20 19:32:48 +00:00
Chris Lattner
dc26e32ec7 Add some helper methods
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26882 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-20 00:55:52 +00:00
Chris Lattner
78fca69532 Add another helper
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26881 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-20 00:20:30 +00:00
Chris Lattner
49c6d3eba8 add a node
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26879 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-19 23:42:51 +00:00
Chris Lattner
074ad68d5a Add a helper method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26878 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-19 23:41:32 +00:00
Chris Lattner
210721aecc improve comments, add a new MVT::getVectorBaseType method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26855 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-19 05:26:45 +00:00
Chris Lattner
22232f659b Rename ConstantVec -> BUILD_VECTOR and VConstant -> VBUILD_VECTOR. Allow
*BUILD_VECTOR to take variable inputs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26846 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-19 00:52:25 +00:00
Chris Lattner
c3a60c738d Update comments.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26839 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-18 01:43:28 +00:00
Chris Lattner
fa984b61e4 add a couple of enum values
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26829 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-17 19:53:41 +00:00
Nate Begeman
81e8097377 Remove BRTWOWAY*
Make the PPC backend not dependent on BRTWOWAY_CC and make the branch
selector smarter about the code it generates, fixing a case in the
readme.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26814 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-17 01:40:33 +00:00
Evan Cheng
d1d6b5cce2 For each loop, keep track of all the IV expressions inserted indexed by
stride. For a set of uses of the IV of a stride which is a multiple
of another stride, do not insert a new IV expression. Rather, reuse the
previous IV and rewrite the uses as uses of IV expression multiplied by
the factor.

e.g.
x = 0 ...; x ++
y = 0 ...; y += 4
then use of y can be rewritten as use of 4*x for x86.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26803 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-16 21:53:05 +00:00
Evan Cheng
714554d707 Added a way for TargetLowering to specify what values can be used as the
scale component of the target addressing mode.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26802 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-16 21:47:42 +00:00
Chris Lattner
804d995f99 Add markers for the first and last vector value type.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26796 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-16 19:42:44 +00:00
Jim Laskey
41ff717e85 Typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26792 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-16 18:15:12 +00:00
Chris Lattner
8ed32f6f8e minor changes so that GCC builtin can be specified before the Intrinsic info,
add some more PPC intrinsics.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26786 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-15 19:23:40 +00:00
Jim Laskey
9d0ff8e6f9 Expand subprogram and added block descriptor.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26782 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-15 19:09:58 +00:00
Chris Lattner
dfdcd5bb95 Set TargetPrefix on target-specific intrinsics. That way, in theory, different
targets could have different implemenations of a __builtin_foo gcc intrinsic.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26769 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-15 01:32:36 +00:00
Chris Lattner
840064e605 Fix the gcread/gcwrite intrinsic specifications, fixing
CodeGen/Generic/GC/alloc_loop.ll


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26765 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-14 20:00:20 +00:00
Evan Cheng
30b37b5f29 Add LSR hooks.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26740 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-13 23:18:16 +00:00
Evan Cheng
a84b1c7c4e Added getTargetLowering() - returns DAG lowering info.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26739 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-13 23:17:42 +00:00
Evan Cheng
d277f2c669 Added target lowering hooks which LSR consults to make more intelligent
transformation decisions.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26738 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-13 23:14:23 +00:00
Chris Lattner
8ae7a3315f Add a first ppc altivec intrinsic. Add packed type support.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26734 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-13 22:38:32 +00:00
Jim Laskey
f4321a3a43 Handle the removal of the debug chain.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26729 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-13 13:07:37 +00:00
Chris Lattner
aaf1582549 Mark llvm.stacksave as only reading memory, this fixes
Regression/Transforms/InstCombine/stacksaverestore.ll


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26715 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-12 00:04:28 +00:00
Nate Begeman
442b32b5c5 Fix PR681 by using the standard Lengauer and Tarjan algorithm for dominator
set construction, rather than intersecting various std::sets.  This reduces
the memory usage for the testcase in PR681 from 496 to 26MB of ram on my
darwin system, and reduces the runtime from 32.8 to 0.8 seconds on a
2.5GHz G5.  This also enables future code sharing between Dom and PostDom
now that they share near-identical implementations.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26707 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-11 02:20:46 +00:00
Evan Cheng
0937103368 Added a parameter to control whether Constant::getStringValue() would chop
off the result string at the first null terminator.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26704 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-10 23:52:03 +00:00
Chris Lattner
682365dc80 remove ShouldEmitDebugFunctions, a hack to support llvm-db via the jit
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26702 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-10 22:49:05 +00:00
Chris Lattner
969ccf82d0 Fix another broken intrinsic.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26696 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-10 18:01:03 +00:00
Chris Lattner
5d832dc330 Fix incorrect definitions of these intrinsics, which broke a bunch of
stuff last night.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26694 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-10 17:48:34 +00:00
Chris Lattner
a34b6f8713 Move simple-selector-specific types to the simple selector.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26693 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-10 07:51:18 +00:00
Chris Lattner
37cb415eec Simplify the interface to the schedulers, to not pass the selected heuristic
in.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26691 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-10 07:48:52 +00:00
Chris Lattner
2f5806c2b3 Move some simple-sched-specific instance vars to the simple scheduler.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26690 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-10 07:42:02 +00:00
Chris Lattner
e76074ab89 move some simple scheduler methods into the simple scheduler
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26688 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-10 07:35:21 +00:00
Chris Lattner
8c7ef0599c Make EmitNode take a SDNode instead of a NodeInfo*
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26687 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-10 07:28:36 +00:00
Chris Lattner
7593639df6 Store VRBase in a map, not in NodeInfo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26685 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-10 07:24:45 +00:00
Chris Lattner
de76851d42 make some methods protected instead of private
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26681 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-10 06:30:11 +00:00
Chris Lattner
d144a24d3d Fix an incorrect intrinsic description
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26677 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-10 04:17:06 +00:00
Chris Lattner
68b67ff3db use the enum list autogen'd from Intrinsics.td
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26660 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-09 20:03:31 +00:00
Chris Lattner
59bcce5ae5 remove dbg_declare, it's not used yet.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26659 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-09 20:02:42 +00:00
Jim Laskey
62e15a3c03 Forgot this on last check in.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26645 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-09 17:30:53 +00:00
Chris Lattner
9ca6cdaee9 Add a helper method for running static ctors/dtors in the module.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26619 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-08 18:42:46 +00:00
Chris Lattner
6665b97ae9 add a new helper method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26617 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-08 18:38:51 +00:00
Jim Laskey
21b6c9d647 Get rid of the multiple copies of getStringValue. Now a Constant:: method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26616 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-08 18:11:07 +00:00
Chris Lattner
b0d21ef20c Change the interface for getting a target HazardRecognizer to be more clean.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26608 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-08 04:25:59 +00:00
Jim Laskey
e8c3e3b51c Switch to using a numeric id for anchors.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26598 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-07 20:53:47 +00:00
Chris Lattner
37e30cf736 Hoist the HazardRecognizer out of the ScheduleDAGList.cpp file to where
targets can implement them.  Make the top-down scheduler non-g5-specific.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26568 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-06 00:20:29 +00:00
Chris Lattner
202bc85a95 add an emitnoop method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26563 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-05 23:50:42 +00:00
Chris Lattner
1566d18fe2 custom lowered nodes are legal too
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26561 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-05 23:49:19 +00:00
Chris Lattner
65e9f3969b add a hook to insert a noop
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26560 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-05 23:48:51 +00:00
Jim Laskey
c0fe53383e Breathe some life into a comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26553 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-05 21:20:20 +00:00
Chris Lattner
20614b9562 Add a new scheduling type. This is, of course, a hack. Proper factoring
will come later.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26551 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-05 21:08:06 +00:00
Chris Lattner
38bf3bffe3 Add a copysign node
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26540 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-05 05:06:40 +00:00
Jim Laskey
f01e547700 Adding basic structure support.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26505 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-03 15:06:57 +00:00
Evan Cheng
3e1ce5a44d Add more vector NodeTypes: VSDIV, VUDIV, VAND, VOR, and VXOR.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26504 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-03 07:01:07 +00:00
Evan Cheng
33143dce15 Number of NodeTypes now exceeds 128.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26503 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-03 06:58:59 +00:00
Evan Cheng
bfa284f697 SDOperand::isOperand should not be a forwarding. It must check *this against N's operands.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26502 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-03 06:42:32 +00:00
Evan Cheng
80d8eaae05 Added isOperand(N): true if this is an operand of N
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26501 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-03 06:24:54 +00:00
Chris Lattner
b253400ca9 initial checkin of the intrinsic description file
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26496 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-03 02:33:15 +00:00
Chris Lattner
378fdf29b1 update comment
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26491 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-03 01:55:49 +00:00
Chris Lattner
c1323faa74 Split this out of Target.td
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26488 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-03 01:54:11 +00:00
Chris Lattner
41edaa0529 remove the read/write port/io intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26479 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-03 00:19:58 +00:00
Chris Lattner
03dd465215 Split memcpy/memset/memmove intrinsics into i32/i64 versions, resolving
PR709, and paving the way for future progress.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26476 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-03 00:00:25 +00:00
Chris Lattner
a1b2a9b7e2 Fix a compilation error with GCC 4.1. Thanks to Vladimir Merzliakov for
pointing this out.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26467 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-02 00:21:41 +00:00
Jim Laskey
6a3eb01084 Support for enumerations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26466 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-01 23:52:37 +00:00
Jim Laskey
40486cc6a0 Remove extra comma from enum list.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26457 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-01 20:49:44 +00:00
Jim Laskey
abd19e8b5b Remove comma from enum list.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26456 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-01 20:48:20 +00:00
Jim Laskey
9c4447aa2b Switch back to using actual dwarf tags. Simplifies code without loss to other
debug forms.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26455 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-01 20:39:36 +00:00
Jim Laskey
92ae740396 Use context and not compile unit.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26453 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-01 18:20:30 +00:00
Jim Laskey
f8913f19ae Basic array support.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26451 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-01 17:53:02 +00:00
Chris Lattner
00ffed0468 Add interfaces for targets to provide target-specific dag combiner optimizations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26442 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-01 04:52:55 +00:00
Evan Cheng
bf57e1f456 Missing a cast previously.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26434 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-01 00:58:54 +00:00
Evan Cheng
70695ab626 - Added v2f32, not used by any target currently. Only for testing purpose.
- Minor bug fix.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26433 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-01 00:55:26 +00:00
Evan Cheng
1ab7d859cf - Added VConstant as an abstract version of ConstantVec.
- All abstrct vector nodes must have # of elements and element type as their
first two operands.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26432 91177308-0d34-0410-b5e6-96231b3b80d8
2006-03-01 00:51:13 +00:00
Jim Laskey
45ccae5b7d Add const, volatile, restrict support.
Add array of debug descriptor support.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26428 91177308-0d34-0410-b5e6-96231b3b80d8
2006-02-28 20:15:07 +00:00
Jim Laskey
9a777a3a8e Qualify dwarf namespace inside llvm namespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26409 91177308-0d34-0410-b5e6-96231b3b80d8
2006-02-27 22:37:23 +00:00
Jim Laskey
bd76184e67 Supporting multiple compile units.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26402 91177308-0d34-0410-b5e6-96231b3b80d8
2006-02-27 17:27:12 +00:00