Owen Anderson
1245bd420e
Add a method to generate a string representation from a TargetData.
...
This continues the work on PR 761.
llvm-svn: 28239
2006-05-12 07:01:44 +00:00
Owen Anderson
29e4d70aed
Refactor a bunch of includes so that TargetMachine.h doesn't have to include
...
TargetData.h. This should make recompiles a bit faster with my current
TargetData tinkering.
llvm-svn: 28238
2006-05-12 06:33:49 +00:00
Evan Cheng
f3d7bb7a9e
Backing out fix for PR770. Need to re-apply it after live range splitting is possible
...
llvm-svn: 28236
2006-05-12 06:06:34 +00:00
Owen Anderson
30ffff31f2
Add a new constructor to TargetData that builds a TargetData from its
...
string representation.
This is part of PR 761.
llvm-svn: 28234
2006-05-12 05:49:47 +00:00
Evan Cheng
0b8e4bca80
Add capability to scheduler to commute nodes for profit.
...
If a two-address code whose first operand has uses below, it should be commuted
when possible.
llvm-svn: 28230
2006-05-12 01:58:24 +00:00
Evan Cheng
cb2a0f392c
Refactor scheduler code. Move register-reduction list scheduler to a
...
separate file. Added an initial implementation of top-down register pressure
reduction list scheduler.
llvm-svn: 28226
2006-05-11 23:55:42 +00:00
Evan Cheng
e2cebf972d
Also add super- register class info.
...
llvm-svn: 28222
2006-05-11 07:31:44 +00:00
Chris Lattner
39290ea978
Add alloca/malloc ctors that don't take array sizes.
...
llvm-svn: 28211
2006-05-10 04:38:35 +00:00
Chris Lattner
adef4bbf27
This method doesn't need to be virtual, thanks to Reid for pointing this out.
...
llvm-svn: 28206
2006-05-09 17:29:17 +00:00
Evan Cheng
aad3fe008e
PR 770 - permit coallescing of registers in subset register classes.
...
llvm-svn: 28197
2006-05-09 06:37:48 +00:00
Evan Cheng
e989b1534a
Added sub- register classes information.
...
llvm-svn: 28196
2006-05-09 06:35:30 +00:00
Chris Lattner
9669e5ece6
Implement MASM sections correctly, without a "has masm sections flag" and a
...
bunch of special case code.
llvm-svn: 28193
2006-05-09 05:33:28 +00:00
Chris Lattner
a5f13d3120
Split SwitchSection into the SwitchTo{Text|Data}Section functions, to better
...
support assemblers that distinguish the two.
llvm-svn: 28183
2006-05-09 04:59:30 +00:00
Chris Lattner
2a1973c8c2
Move methods out of line so that MutexGuard.h isn't required in the header.
...
llvm-svn: 28178
2006-05-08 22:00:26 +00:00
Chris Lattner
c1736fdce0
Move the definition of value_use_iterator::getOperandNo to User.h where the
...
definition of the User class is available, this fixes the build with some
compiler versions.
llvm-svn: 28163
2006-05-08 05:59:36 +00:00
Nate Begeman
c5a92246bc
Remove unncessary include
...
llvm-svn: 28160
2006-05-08 01:33:11 +00:00
Chris Lattner
06d617846d
Add some new methods for computing sign bit information.
...
llvm-svn: 28144
2006-05-06 09:26:22 +00:00
Nate Begeman
60c4e49b4e
Somehow, I missed this part of the checkin a couple days ago
...
llvm-svn: 28116
2006-05-05 01:13:11 +00:00
Chris Lattner
56ae04a191
Add a helper method.
...
llvm-svn: 28114
2006-05-05 00:51:42 +00:00
Chris Lattner
9f535ef329
Fix this to be a proper copy ctor
...
llvm-svn: 28111
2006-05-04 21:17:35 +00:00
Chris Lattner
db888e7880
Final pass of minor cleanups for MachineInstr
...
llvm-svn: 28110
2006-05-04 19:36:09 +00:00
Chris Lattner
32adc4592f
Remove redundancy and a level of indirection when creating machine operands
...
llvm-svn: 28107
2006-05-04 19:14:44 +00:00
Chris Lattner
27d69eb53d
Move register numbers out of "extra" into "contents". Other minor cleanup.
...
llvm-svn: 28106
2006-05-04 18:25:20 +00:00
Chris Lattner
075404adaa
Remove and simplify some more machineinstr/machineoperand stuff.
...
llvm-svn: 28105
2006-05-04 18:16:01 +00:00
Chris Lattner
eb41c99161
Rename MO_VirtualRegister -> MO_Register. Clean up immediate handling.
...
llvm-svn: 28104
2006-05-04 18:05:43 +00:00
Chris Lattner
57eca0ab4f
remove hasAllocatedReg
...
llvm-svn: 28103
2006-05-04 17:56:20 +00:00
Chris Lattner
685568510a
Move some methods out of MachineInstr into MachineOperand
...
llvm-svn: 28102
2006-05-04 17:52:23 +00:00
Chris Lattner
97f1af2f14
There shalt be only one "immediate" operand type!
...
llvm-svn: 28099
2006-05-04 17:21:20 +00:00
Chris Lattner
51b0cac238
Change "value" in MachineOperand to be a GlobalValue, as that is the only
...
thing that can be in it. Remove a dead method.
llvm-svn: 28098
2006-05-04 17:02:51 +00:00
Chris Lattner
a39a7f900f
Remove a bunch more dead V9 specific stuff
...
llvm-svn: 28094
2006-05-04 01:26:39 +00:00
Chris Lattner
c779fca289
Remove a bunch more SparcV9 specific stuff
...
llvm-svn: 28093
2006-05-04 01:15:02 +00:00
Chris Lattner
ed58ec2a57
Remove some more V9-specific stuff.
...
llvm-svn: 28092
2006-05-04 00:49:59 +00:00
Chris Lattner
0f89e6b11d
Remove some more unused stuff from MachineInstr that was leftover from V9.
...
llvm-svn: 28091
2006-05-04 00:44:25 +00:00
Chris Lattner
f89e1162ad
Change from using MachineRelocation ctors to using static methods
...
in MachineRelocation to create Relocations.
llvm-svn: 28088
2006-05-03 20:30:20 +00:00
Chris Lattner
662f66bfcd
Cleanup the internal implementation of MachineRelocation. No interface or
...
functionality changes.
llvm-svn: 28086
2006-05-03 18:52:31 +00:00
Chris Lattner
d36b66d6dc
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.
llvm-svn: 28082
2006-05-03 17:10:41 +00:00
Owen Anderson
71bc529dfa
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.
llvm-svn: 28074
2006-05-03 01:29:57 +00:00
Chris Lattner
1bfcd5b981
Add a new emitAlignment method
...
llvm-svn: 28072
2006-05-03 01:01:51 +00:00
Chris Lattner
06ccac43d7
Change the BasicBlockAddrs map to be a vector, indexed by MBB number.
...
llvm-svn: 28069
2006-05-03 00:32:55 +00:00
Chris Lattner
2bf37af52d
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.
llvm-svn: 28065
2006-05-02 23:22:24 +00:00
Chris Lattner
95cce111f4
Add a method for allocating space from the code buffer.
...
llvm-svn: 28064
2006-05-02 22:51:03 +00:00
Chris Lattner
8054cd3830
Do not make the JIT memory manager manage the memory for globals. Instead
...
just have the JIT malloc them.
llvm-svn: 28062
2006-05-02 21:57:51 +00:00
Chris Lattner
d100478886
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.
llvm-svn: 28060
2006-05-02 19:14:47 +00:00
Chris Lattner
055baf5c7b
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.
llvm-svn: 28059
2006-05-02 18:27:26 +00:00
Chris Lattner
436a2304db
Remove a now-dead method
...
llvm-svn: 28054
2006-05-02 17:17:13 +00:00
Chris Lattner
aff0e22c2a
Remove the debug machine code emitter. The "FilePrinterEmitter" is moreuseful for debugging.
...
llvm-svn: 28052
2006-05-02 16:59:49 +00:00
Nate Begeman
05174045df
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.
llvm-svn: 28050
2006-05-02 05:37:32 +00:00
Chris Lattner
1275941193
Add pass ID's for various passes, so they can be AddRequiredID. Patch by
...
Domagoj Babic!
llvm-svn: 28048
2006-05-02 04:24:36 +00:00
Jeff Cohen
a35a8a5f9c
De-virtualize SwitchSection.
...
llvm-svn: 28047
2006-05-02 03:58:45 +00:00
Jeff Cohen
b257253098
De-virtualize EmitZeroes.
...
llvm-svn: 28046
2006-05-02 03:46:13 +00:00
Jeff Cohen
5c2e201a63
Finish support for Microsoft ML/MASM. May still be a few rough edges.
...
llvm-svn: 28045
2006-05-02 03:11:50 +00:00
Jeff Cohen
ec0f5808a1
Make Intel syntax mode friendlier to Microsoft ML assembler (still needs more work).
...
llvm-svn: 28044
2006-05-02 01:16:28 +00:00
Evan Cheng
9f21c2daf4
Remove the temporary option: -no-isel-fold-inflight
...
llvm-svn: 28012
2006-04-28 18:54:11 +00:00
Evan Cheng
ff5a88b62e
Added a temporary option -no-isel-fold-inflight to control whether a "inflight"
...
node can be folded.
llvm-svn: 28003
2006-04-28 02:09:19 +00:00
Evan Cheng
e521de4e60
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).
llvm-svn: 27964
2006-04-24 23:34:56 +00:00
Evan Cheng
679d1dd5cf
Added addJumpTableIndex
...
llvm-svn: 27956
2006-04-24 06:42:15 +00:00
Nate Begeman
7bb910dbe7
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
llvm-svn: 27952
2006-04-23 06:26:20 +00:00
Nate Begeman
f86709e9e2
Code cleanup associated with jump tables, thanks to Chris for noticing
...
these.
llvm-svn: 27950
2006-04-22 23:52:35 +00:00
Nate Begeman
7ed816f900
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.
llvm-svn: 27947
2006-04-22 18:53:45 +00:00
Chris Lattner
6a2ec2cd3b
Remove a bunch of dead stuff, shrinkifying TargetInstrDescriptor significantly.
...
llvm-svn: 27897
2006-04-20 18:32:02 +00:00
Chris Lattner
1fcd927af4
Remove some obsolete interfaces
...
llvm-svn: 27896
2006-04-20 18:17:21 +00:00
Chris Lattner
7649e06c23
Remove some of the obvious v9-specific cruft
...
llvm-svn: 27894
2006-04-20 18:09:13 +00:00
Chris Lattner
0b321ad43f
remove a dead prototype
...
llvm-svn: 27882
2006-04-20 15:45:54 +00:00
Evan Cheng
ec4d1668ef
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.
llvm-svn: 27873
2006-04-20 08:54:13 +00:00
Reid Spencer
b569daf7a6
Add in missing #defines for _OpenBSD_ systems.
...
llvm-svn: 27850
2006-04-20 00:18:39 +00:00
Nate Begeman
7821901005
Fix a copy & paste error from long ago.
...
llvm-svn: 27800
2006-04-18 16:03:18 +00:00
Chris Lattner
bcd61bbadb
Add some convenience methods.
...
llvm-svn: 27774
2006-04-17 21:35:08 +00:00
Chris Lattner
5324c4f9aa
These instructions always return a packed vector. Improve the class definitions to expose this fact.
...
llvm-svn: 27712
2006-04-14 22:20:07 +00:00
Evan Cheng
32c4470374
Last few SSE3 intrinsics.
...
llvm-svn: 27711
2006-04-14 21:59:03 +00:00
Evan Cheng
184264997e
Misc. SSE2 intrinsics: clflush, lfench, mfence
...
llvm-svn: 27699
2006-04-14 07:43:12 +00:00
Evan Cheng
360a73046f
pcmpeq* and pcmpgt* intrinsics.
...
llvm-svn: 27685
2006-04-14 01:39:53 +00:00
Evan Cheng
18a1a0e199
psll*, psrl*, and psra* intrinsics.
...
llvm-svn: 27684
2006-04-14 00:14:05 +00:00
Chris Lattner
4bebf6718d
Fix an incorrect prototype for this intrinsic, fixing
...
CFrontend/2003-08-18-SigSetJmp.c with llvm-gcc3. This is part of PR733.
llvm-svn: 27670
2006-04-13 18:23:48 +00:00
Evan Cheng
a27ec55558
pmin, pmax, and psad intrinsics.
...
llvm-svn: 27646
2006-04-13 06:09:41 +00:00
Evan Cheng
d5bd292d89
pmul*, pmadd*, and pavg* intrinsics.
...
llvm-svn: 27642
2006-04-13 05:09:06 +00:00
Evan Cheng
2f634fac6d
padds{b|w}, paddus{b|w}, psubs{b|w}, psubus{b|w} intrinsics.
...
llvm-svn: 27639
2006-04-13 00:43:35 +00:00
Evan Cheng
537bdb370c
Naming inconsistency.
...
llvm-svn: 27638
2006-04-13 00:00:23 +00:00
Evan Cheng
8768f25c80
SSE / SSE2 conversion intrinsics.
...
llvm-svn: 27637
2006-04-12 23:42:44 +00:00
Reid Spencer
553050adcb
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
llvm-svn: 27607
2006-04-12 16:44:15 +00:00
Chris Lattner
048bc55352
Provide a default impl of LowerArguments
...
llvm-svn: 27605
2006-04-12 16:21:12 +00:00
Evan Cheng
fbdf6ece4a
Various SSE2 conversion intrinsics
...
llvm-svn: 27603
2006-04-12 05:20:24 +00:00
Evan Cheng
68b885f50c
Added __builtin_ia32_storelv4si, __builtin_ia32_movqv4si,
...
__builtin_ia32_loadlv4si, __builtin_ia32_loaddqu, __builtin_ia32_storedqu.
llvm-svn: 27599
2006-04-11 22:28:25 +00:00
Chris Lattner
bf69078515
new dag node
...
llvm-svn: 27596
2006-04-11 21:30:42 +00:00
Evan Cheng
c0848b1eaf
gcc lower SSE prefetch into generic prefetch intrinsic. Need to add support
...
later.
llvm-svn: 27591
2006-04-11 18:04:57 +00:00
Evan Cheng
7a9fca11b5
Misc. intrinsics.
...
llvm-svn: 27590
2006-04-11 17:35:57 +00:00
Evan Cheng
798acd4094
movnt* and maskmovdqu intrinsics
...
llvm-svn: 27587
2006-04-11 06:57:30 +00:00
Chris Lattner
eda5a7014a
Add helper methods.
...
llvm-svn: 27576
2006-04-11 01:09:25 +00:00
Jim Laskey
54dc261ef6
Use existing information.
...
llvm-svn: 27574
2006-04-10 23:09:19 +00:00
Chris Lattner
1659f983ff
Fix a typo: Instr* -> Intr*
...
llvm-svn: 27568
2006-04-10 22:02:59 +00:00
Evan Cheng
0a8da94ae5
__builtin_ia32_loadup{s|d}, __builtin_ia32_storeup{s|d}
...
llvm-svn: 27561
2006-04-10 21:09:59 +00:00
Andrew Lenharth
b3f434b83d
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.
llvm-svn: 27560
2006-04-10 19:26:09 +00:00
Chris Lattner
a4a7e59c52
Add a new VSELECT node.
...
llvm-svn: 27541
2006-04-08 22:16:01 +00:00
Chris Lattner
80450dd773
Add methods to check insert/extract element instructions for validity
...
llvm-svn: 27522
2006-04-08 04:04:54 +00:00
Chris Lattner
e2d0c1084a
Add a new shufflevector instruction
...
llvm-svn: 27507
2006-04-08 01:15:18 +00:00
Evan Cheng
e55651f4d7
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.
llvm-svn: 27505
2006-04-08 00:47:01 +00:00
Evan Cheng
36de346008
Remove int_x86_sse_storeh_ps and int_x86_sse_storel_ps. These are now lowered
...
by the frontend.
llvm-svn: 27495
2006-04-07 21:18:40 +00:00
Jim Laskey
fabb0ba736
Make sure that debug labels are defined within the same section and after the
...
entry point of a function.
llvm-svn: 27494
2006-04-07 20:44:42 +00:00
Jim Laskey
b93bc75add
Foundation for call frame information.
...
llvm-svn: 27491
2006-04-07 16:34:46 +00:00
Evan Cheng
f49979cf28
Remove int_x86_sse_loadh_ps and int_x86_sse_loadl_ps. These are now lowered
...
by the frontend to shuffles.
llvm-svn: 27475
2006-04-06 23:25:41 +00:00
Chris Lattner
b19cdc8fc1
These intrinsics are now lowered by the FE.
...
llvm-svn: 27458
2006-04-06 21:12:48 +00:00
Chris Lattner
09b9548243
this is no longer an intrinsic.
...
llvm-svn: 27451
2006-04-06 18:29:17 +00:00
Evan Cheng
f1a2e421c3
Added comi and ucomi SSE intrinsics.
...
llvm-svn: 27443
2006-04-05 23:37:18 +00:00
Chris Lattner
86763bafa7
add altivec ds* intrinsics
...
llvm-svn: 27441
2006-04-05 22:18:01 +00:00
Chris Lattner
986d42c2e9
Get the types right, third time is the charm. Add vsl.
...
llvm-svn: 27424
2006-04-05 01:15:54 +00:00
Chris Lattner
f41b7d5a80
correct the type of two intrinsics, add int_ppc_altivec_vmladduhm
...
llvm-svn: 27422
2006-04-05 00:49:14 +00:00
Chris Lattner
0afabdfdaf
Add m[tf]vscr intrinsics.
...
llvm-svn: 27420
2006-04-05 00:03:03 +00:00
Chris Lattner
e7a52b473f
Add missing byte merges.
...
llvm-svn: 27418
2006-04-04 23:43:56 +00:00
Chris Lattner
ab137b431f
Add FP -> Int Conversions
...
llvm-svn: 27417
2006-04-04 23:25:02 +00:00
Chris Lattner
39a966beec
add average intrinsics.
...
llvm-svn: 27415
2006-04-04 23:13:21 +00:00
Evan Cheng
a4d3c6df75
Added intrinsics to match __builtin_ia32_pslldqi128 and
...
__builtin_ia32_psrldqi128.
llvm-svn: 27411
2006-04-04 21:48:31 +00:00
Chris Lattner
657e2d1d80
How could this ever have worked?
...
llvm-svn: 27409
2006-04-04 19:05:42 +00:00
Chris Lattner
6ce700fbae
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
llvm-svn: 27403
2006-04-04 17:39:56 +00:00
Chris Lattner
1dc3c03ee7
Move isShuffleLegal from TLI to Legalize.
...
llvm-svn: 27398
2006-04-04 17:21:22 +00:00
Chris Lattner
a1fc0eb694
Fix the types for these intrinsics.
...
llvm-svn: 27392
2006-04-04 01:40:06 +00:00
Chris Lattner
9925c6018f
Allow targets to have fine grained control over which types various ops get
...
promoted to, if they desire.
llvm-svn: 27389
2006-04-04 00:25:10 +00:00
Chris Lattner
b46d7d9fc4
Keep track of max stack alignment as objects are added. Remove an obsolete method.
...
llvm-svn: 27378
2006-04-03 21:38:39 +00:00
Chris Lattner
29156e5094
shrinkify intrinsics more by using some local classes
...
llvm-svn: 27373
2006-04-03 17:20:06 +00:00
Chris Lattner
c0cba5e03f
Add some classes to make it easier to define intrinsics. Add min/max intrinsics.
...
llvm-svn: 27371
2006-04-03 15:43:07 +00:00
Chris Lattner
99a3213376
simplify this method
...
llvm-svn: 27338
2006-04-02 02:28:52 +00:00
Chris Lattner
a76347d917
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.
llvm-svn: 27326
2006-04-01 04:48:52 +00:00
Evan Cheng
aeb1560ea5
Added haddp{s|d} and hsubp{s|d} intrinsics.
...
llvm-svn: 27309
2006-03-31 21:28:46 +00:00
Chris Lattner
8e0dfe133c
Modify the TargetLowering::getPackedTypeBreakdown method to also return the
...
unpromoted element type.
llvm-svn: 27273
2006-03-31 00:46:36 +00:00
Chris Lattner
557951b354
Add a method useful for decimating vectors.
...
llvm-svn: 27269
2006-03-31 00:28:23 +00:00
Chris Lattner
e35e1db8c2
fix incorrect prototypes
...
llvm-svn: 27267
2006-03-30 23:32:58 +00:00
Chris Lattner
69148453d0
Add vector multiply, multiply sum, pack, unpack, and lvsl/lvsr intrinsics.
...
llvm-svn: 27258
2006-03-30 18:52:02 +00:00
Evan Cheng
57d481a78a
Add support for _mm_cmp{cc}_ss and _mm_cmp{cc}_ps intrinsics
...
llvm-svn: 27256
2006-03-30 06:21:22 +00:00
Evan Cheng
82d2a6910f
Add 128-bit pmovmskb intrinsic support.
...
llvm-svn: 27255
2006-03-30 00:33:26 +00:00
Evan Cheng
9ebe75e915
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.
llvm-svn: 27254
2006-03-29 23:53:14 +00:00
Evan Cheng
1b19ed24d6
Add SSE2 integer pack with saturation intrinsics.
...
llvm-svn: 27253
2006-03-29 23:09:19 +00:00
Evan Cheng
84c8b5bcd9
Add more SSE intrinsics
...
llvm-svn: 27247
2006-03-29 06:07:16 +00:00
Chris Lattner
83ec289ebf
Add a new node
...
llvm-svn: 27230
2006-03-28 19:54:11 +00:00
Jim Laskey
4c2d4d1912
Refactor address attributes. Add base register to frame info.
...
llvm-svn: 27226
2006-03-28 14:58:32 +00:00
Jim Laskey
eb38a3e83a
Expose base register for DwarfWriter. Refactor code accordingly.
...
llvm-svn: 27225
2006-03-28 13:48:33 +00:00
Nate Begeman
5a82c8ccbd
Add a few more altivec intrinsics
...
llvm-svn: 27215
2006-03-28 04:15:58 +00:00
Chris Lattner
1a5116bd0c
These don't directly map to gcc intrinsics any more.
...
llvm-svn: 27213
2006-03-28 03:52:36 +00:00
Chris Lattner
176d16aec7
Add some more intrinsics: rotates, fp rounds, and random other fp instructions.
...
llvm-svn: 27208
2006-03-28 02:28:48 +00:00
Evan Cheng
d10153ba72
getVectorTyppe(MVT::i64, 2) ==> MVT::v2i64.
...
llvm-svn: 27207
2006-03-28 01:59:17 +00:00
Chris Lattner
76ce849af5
Add lvxl
...
llvm-svn: 27206
2006-03-28 01:49:27 +00:00
Chris Lattner
a0f80c3c3f
Tblgen doesn't like multiple SDNode<> definitions that map to the same
...
enum value. Split them into separate enums.
llvm-svn: 27199
2006-03-28 00:39:06 +00:00
Chris Lattner
b53e0ddbd3
Reenable pointer intrinsics.
...
llvm-svn: 27198
2006-03-28 00:15:44 +00:00
Chris Lattner
1e517cbb0c
revert this, it breaks things
...
llvm-svn: 27195
2006-03-28 00:02:52 +00:00
Jim Laskey
1585be504a
Should not remove casts from variable's alloca.
...
llvm-svn: 27191
2006-03-27 23:30:18 +00:00
Chris Lattner
720a11dd3e
Add support for intrinsics with pointer arguments in target .td files.
...
llvm-svn: 27190
2006-03-27 22:49:46 +00:00
Chris Lattner
a6ae3e278a
Add some missing template specializations for autodereferencing User.
...
llvm-svn: 27189
2006-03-27 22:49:07 +00:00
Chris Lattner
fd3aa5f890
add a new iPTR ValueType for tblgen use
...
llvm-svn: 27187
2006-03-27 22:48:00 +00:00
Chris Lattner
6917dae72b
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.
llvm-svn: 27186
2006-03-27 22:38:39 +00:00
Chris Lattner
735fa11e56
fix spelling :(
...
llvm-svn: 27184
2006-03-27 22:07:12 +00:00
Chris Lattner
37cd00ed2a
add some more intrinsics.
...
llvm-svn: 27183
2006-03-27 22:05:34 +00:00
Evan Cheng
aba79c636f
Intrinsics naming convention change.
...
llvm-svn: 27172
2006-03-27 08:23:12 +00:00
Evan Cheng
4667bd17cb
Change isBuildVectorAllOnesInteger to isBuildVectorAllOnes. Also check for
...
floating point cases.
llvm-svn: 27165
2006-03-27 06:58:47 +00:00
Nate Begeman
3d518334b9
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.
llvm-svn: 27156
2006-03-27 01:32:24 +00:00
Jim Laskey
278ca1e735
How to be dumb on $5/day. Need a tri-state to track valid debug descriptors.
...
llvm-svn: 27154
2006-03-26 22:45:20 +00:00
Evan Cheng
ef3b33b847
Add ISD::isBuildVectorAllZeros predicate
...
llvm-svn: 27147
2006-03-26 09:50:58 +00:00
Chris Lattner
0069646b1d
Add predicate comparison intrinsics.
...
llvm-svn: 27145
2006-03-26 07:50:25 +00:00
Chris Lattner
d8f528f04f
Split the PPC and X86 intrinsics out to their own files.
...
llvm-svn: 27141
2006-03-26 02:37:19 +00:00
Chris Lattner
83cad7bff6
Add saturating subtracts, non-predicate compares, and some other random
...
intrinsics.
llvm-svn: 27140
2006-03-26 02:34:07 +00:00
Chris Lattner
9ecf506a2f
add int_ppc_altivec_vsldoi intrinsic
...
llvm-svn: 27138
2006-03-26 00:25:43 +00:00
Chris Lattner
91fe1d4b55
Add a predicate
...
llvm-svn: 27129
2006-03-25 22:56:35 +00:00
Jim Laskey
576323f04f
Unused function - easier to throw away than fix.
...
llvm-svn: 27123
2006-03-25 18:42:45 +00:00
Chris Lattner
06a3ec70c9
remove extraneous lets
...
llvm-svn: 27114
2006-03-25 07:30:34 +00:00
Chris Lattner
e767292e67
Add a bunch of simple altivec intrinsics
...
llvm-svn: 27113
2006-03-25 07:27:18 +00:00
Chris Lattner
33f07e82dc
Add support for __builtin_altivec_vnmsubfp
...
llvm-svn: 27111
2006-03-25 07:05:35 +00:00
Chris Lattner
2ed67c5d0f
Add a programatic interface to intrinsic names.
...
llvm-svn: 27107
2006-03-25 06:32:07 +00:00
Evan Cheng
ff65ba0857
X86 SSE1 cacheability support ops intrinsics
...
llvm-svn: 27104
2006-03-25 06:05:45 +00:00
Evan Cheng
ad4f96ae46
X86 SSE1 SIMD store intrinsics.
...
llvm-svn: 27099
2006-03-25 02:02:51 +00:00
Evan Cheng
35a181d293
X86 SSE1 SIMD load intrinsics (movhps, movlps, and movups).
...
llvm-svn: 27098
2006-03-25 01:58:54 +00:00
Evan Cheng
b58801303a
X86 SSE1 conversion operations intrinsics.
...
llvm-svn: 27097
2006-03-25 01:35:17 +00:00
Evan Cheng
35bbc93d35
X86 SSE1 comparison intrinsics.
...
llvm-svn: 27093
2006-03-25 00:32:32 +00:00
Evan Cheng
e3f4eecb44
X86 SSE1 arithmetic and logical operation intrinsics.
...
llvm-svn: 27092
2006-03-25 00:18:20 +00:00
Evan Cheng
83c1f2e316
ldmxcsr is a SSE instruction.
...
llvm-svn: 27086
2006-03-24 22:13:47 +00:00
Evan Cheng
b98a5e8507
Added ldmxcsr intrinsic.
...
llvm-svn: 27085
2006-03-24 22:10:59 +00:00
Chris Lattner
3be0858857
Specify the value type for each llvm type. This needs work for pointers.
...
llvm-svn: 27074
2006-03-24 19:41:10 +00:00
Chris Lattner
9c8fb73936
Pull in valuetypes.td here, we will use it shortly.
...
llvm-svn: 27072
2006-03-24 18:51:56 +00:00
Jim Laskey
b4ff5c3e78
Tweak a comment.
...
llvm-svn: 27066
2006-03-24 16:18:42 +00:00
Jim Laskey
06c78bb995
Clean up some commentary.
...
llvm-svn: 27064
2006-03-24 10:00:56 +00:00
Jim Laskey
0d63725a26
Rename for truth in advertising.
...
llvm-svn: 27063
2006-03-24 09:50:27 +00:00
Jeff Cohen
3fb8f32540
Fix headers
...
llvm-svn: 27043
2006-03-24 06:07:16 +00:00
Jeff Cohen
1dcffcaf83
Minor corrections.
...
llvm-svn: 27041
2006-03-24 02:58:54 +00:00
Jeff Cohen
dab30f45d8
Get JIT/Interpreter working on Windows again.
...
llvm-svn: 27037
2006-03-24 02:53:49 +00:00
Chris Lattner
7c4160da23
add a new intrinsic node
...
llvm-svn: 27019
2006-03-24 01:03:55 +00:00
Chris Lattner
41352d6892
Add a couple simple intrinsics for intel. Fix the v2f64 definition.
...
llvm-svn: 27018
2006-03-24 00:04:52 +00:00
Reid Spencer
c9240dc0e5
Ignore generated file Intrinsics.gen
...
llvm-svn: 27014
2006-03-23 23:49:59 +00:00
Jim Laskey
4ab13dc9be
Make sure types are allocated in the scope of their use.
...
llvm-svn: 27002
2006-03-23 23:02:34 +00:00
Jim Laskey
cec9c18c62
Add support to locate local variables in frames (early version.)
...
llvm-svn: 26994
2006-03-23 18:12:57 +00:00
Jim Laskey
867301543c
Generate local variable and scope information and equivalent dwarf forms.
...
llvm-svn: 26989
2006-03-23 18:07:55 +00:00
Jim Laskey
47de3793e3
Simplify handling of llvm.dbg intrinsic operands to one spot.
...
llvm-svn: 26987
2006-03-23 18:05:12 +00:00
Jim Laskey
b29f9a22e7
Modify usage of llvm.dbg intrinsics.
...
llvm-svn: 26986
2006-03-23 18:04:18 +00:00
Jim Laskey
36afd7b19d
Support for locating of debug items in frames.
...
llvm-svn: 26984
2006-03-23 18:01:12 +00:00
Chris Lattner
b26a7c8735
Eliminate IntrinsicLowering from TargetMachine.
...
llvm-svn: 26973
2006-03-23 05:41:41 +00:00
Chris Lattner
3d5ca510c9
remove always-null IntrinsicLowering argument.
...
llvm-svn: 26971
2006-03-23 05:28:02 +00:00
Chris Lattner
2aa3f9a6b5
remove the intrinsiclowering hook
...
llvm-svn: 26970
2006-03-23 05:22:51 +00:00
Evan Cheng
54215cd1ea
Added a ValueType operand to isShuffleMaskLegal(). For now, x86 will not do
...
64-bit vector shuffle.
llvm-svn: 26964
2006-03-22 22:07:06 +00:00
Chris Lattner
d4f04c4b6a
Fix comments
...
llvm-svn: 26960
2006-03-22 20:09:04 +00:00
Chris Lattner
b1bc1f88c0
add a new node
...
llvm-svn: 26958
2006-03-22 19:56:46 +00:00
Chris Lattner
05c3c52edf
wrap lines to 80 columns.
...
Add static JITCtor/InterpCtor fields
llvm-svn: 26945
2006-03-22 06:06:37 +00:00
Chris Lattner
9f8cfe5ab4
add some nodes for extractelement
...
llvm-svn: 26927
2006-03-21 20:43:08 +00:00
Nate Begeman
31da564faa
Move some common data structures between dom and pdom into the base class
...
llvm-svn: 26905
2006-03-20 19:32:48 +00:00
Chris Lattner
a3663c3dbb
Add some helper methods
...
llvm-svn: 26882
2006-03-20 00:55:52 +00:00
Chris Lattner
c0f029cf63
Add another helper
...
llvm-svn: 26881
2006-03-20 00:20:30 +00:00
Chris Lattner
0b7ec34646
add a node
...
llvm-svn: 26879
2006-03-19 23:42:51 +00:00
Chris Lattner
8e89272e96
Add a helper method
...
llvm-svn: 26878
2006-03-19 23:41:32 +00:00
Chris Lattner
bbbf21b37b
improve comments, add a new MVT::getVectorBaseType method.
...
llvm-svn: 26855
2006-03-19 05:26:45 +00:00
Chris Lattner
868679006d
Rename ConstantVec -> BUILD_VECTOR and VConstant -> VBUILD_VECTOR. Allow
...
*BUILD_VECTOR to take variable inputs.
llvm-svn: 26846
2006-03-19 00:52:25 +00:00
Chris Lattner
25feee0be9
Update comments.
...
llvm-svn: 26839
2006-03-18 01:43:28 +00:00
Chris Lattner
da6506a1f2
add a couple of enum values
...
llvm-svn: 26829
2006-03-17 19:53:41 +00:00
Nate Begeman
42736d46b2
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.
llvm-svn: 26814
2006-03-17 01:40:33 +00:00
Evan Cheng
db35180b27
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.
llvm-svn: 26803
2006-03-16 21:53:05 +00:00
Evan Cheng
cad75d9f0c
Added a way for TargetLowering to specify what values can be used as the
...
scale component of the target addressing mode.
llvm-svn: 26802
2006-03-16 21:47:42 +00:00
Chris Lattner
c7aaa3cc89
Add markers for the first and last vector value type.
...
llvm-svn: 26796
2006-03-16 19:42:44 +00:00
Jim Laskey
940c39aa65
Typo.
...
llvm-svn: 26792
2006-03-16 18:15:12 +00:00
Chris Lattner
4fbdb99abb
minor changes so that GCC builtin can be specified before the Intrinsic info,
...
add some more PPC intrinsics.
llvm-svn: 26786
2006-03-15 19:23:40 +00:00
Jim Laskey
f6494d753a
Expand subprogram and added block descriptor.
...
llvm-svn: 26782
2006-03-15 19:09:58 +00:00
Chris Lattner
c13249a1d3
Set TargetPrefix on target-specific intrinsics. That way, in theory, different
...
targets could have different implemenations of a __builtin_foo gcc intrinsic.
llvm-svn: 26769
2006-03-15 01:32:36 +00:00
Chris Lattner
163ea2cc68
Fix the gcread/gcwrite intrinsic specifications, fixing
...
CodeGen/Generic/GC/alloc_loop.ll
llvm-svn: 26765
2006-03-14 20:00:20 +00:00
Evan Cheng
ed013bd937
Add LSR hooks.
...
llvm-svn: 26740
2006-03-13 23:18:16 +00:00
Evan Cheng
72d4882732
Added getTargetLowering() - returns DAG lowering info.
...
llvm-svn: 26739
2006-03-13 23:17:42 +00:00
Evan Cheng
692235499c
Added target lowering hooks which LSR consults to make more intelligent
...
transformation decisions.
llvm-svn: 26738
2006-03-13 23:14:23 +00:00
Chris Lattner
e3422808f6
Add a first ppc altivec intrinsic. Add packed type support.
...
llvm-svn: 26734
2006-03-13 22:38:32 +00:00
Jim Laskey
c741139c24
Handle the removal of the debug chain.
...
llvm-svn: 26729
2006-03-13 13:07:37 +00:00
Chris Lattner
2594ddf452
Mark llvm.stacksave as only reading memory, this fixes
...
Regression/Transforms/InstCombine/stacksaverestore.ll
llvm-svn: 26715
2006-03-12 00:04:28 +00:00
Nate Begeman
7c2afcfc02
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.
llvm-svn: 26707
2006-03-11 02:20:46 +00:00
Evan Cheng
57c206232d
Added a parameter to control whether Constant::getStringValue() would chop
...
off the result string at the first null terminator.
llvm-svn: 26704
2006-03-10 23:52:03 +00:00
Chris Lattner
f80c0a7188
remove ShouldEmitDebugFunctions, a hack to support llvm-db via the jit
...
llvm-svn: 26702
2006-03-10 22:49:05 +00:00
Chris Lattner
d6bc58d086
Fix another broken intrinsic.
...
llvm-svn: 26696
2006-03-10 18:01:03 +00:00
Chris Lattner
228fa5bd76
Fix incorrect definitions of these intrinsics, which broke a bunch of
...
stuff last night.
llvm-svn: 26694
2006-03-10 17:48:34 +00:00
Chris Lattner
0a64d261e0
Move simple-selector-specific types to the simple selector.
...
llvm-svn: 26693
2006-03-10 07:51:18 +00:00
Chris Lattner
40b1b16c56
Simplify the interface to the schedulers, to not pass the selected heuristic
...
in.
llvm-svn: 26691
2006-03-10 07:48:52 +00:00
Chris Lattner
da5f77e3cf
Move some simple-sched-specific instance vars to the simple scheduler.
...
llvm-svn: 26690
2006-03-10 07:42:02 +00:00
Chris Lattner
808cc02983
move some simple scheduler methods into the simple scheduler
...
llvm-svn: 26688
2006-03-10 07:35:21 +00:00
Chris Lattner
89a5a946f5
Make EmitNode take a SDNode instead of a NodeInfo*
...
llvm-svn: 26687
2006-03-10 07:28:36 +00:00
Chris Lattner
f1be1182f0
Store VRBase in a map, not in NodeInfo.
...
llvm-svn: 26685
2006-03-10 07:24:45 +00:00
Chris Lattner
6ef56b998f
make some methods protected instead of private
...
llvm-svn: 26681
2006-03-10 06:30:11 +00:00
Chris Lattner
0f3034a5b6
Fix an incorrect intrinsic description
...
llvm-svn: 26677
2006-03-10 04:17:06 +00:00
Chris Lattner
e6230f10c3
use the enum list autogen'd from Intrinsics.td
...
llvm-svn: 26660
2006-03-09 20:03:31 +00:00
Chris Lattner
dc7268f6a3
remove dbg_declare, it's not used yet.
...
llvm-svn: 26659
2006-03-09 20:02:42 +00:00
Jim Laskey
9249c06683
Forgot this on last check in.
...
llvm-svn: 26645
2006-03-09 17:30:53 +00:00
Chris Lattner
0b736a0d1e
Add a helper method for running static ctors/dtors in the module.
...
llvm-svn: 26619
2006-03-08 18:42:46 +00:00
Chris Lattner
ad498794f8
add a new helper method
...
llvm-svn: 26617
2006-03-08 18:38:51 +00:00
Jim Laskey
a1ad999bba
Get rid of the multiple copies of getStringValue. Now a Constant:: method.
...
llvm-svn: 26616
2006-03-08 18:11:07 +00:00
Chris Lattner
3f23d22d3f
Change the interface for getting a target HazardRecognizer to be more clean.
...
llvm-svn: 26608
2006-03-08 04:25:59 +00:00
Jim Laskey
eec3faecde
Switch to using a numeric id for anchors.
...
llvm-svn: 26598
2006-03-07 20:53:47 +00:00
Chris Lattner
a0769e790e
Hoist the HazardRecognizer out of the ScheduleDAGList.cpp file to where
...
targets can implement them. Make the top-down scheduler non-g5-specific.
llvm-svn: 26568
2006-03-06 00:20:29 +00:00
Chris Lattner
4dae9a978e
add an emitnoop method
...
llvm-svn: 26563
2006-03-05 23:50:42 +00:00
Chris Lattner
c656f75535
custom lowered nodes are legal too
...
llvm-svn: 26561
2006-03-05 23:49:19 +00:00
Chris Lattner
5fd145d9c4
add a hook to insert a noop
...
llvm-svn: 26560
2006-03-05 23:48:51 +00:00
Jim Laskey
45dfae3a50
Breathe some life into a comment.
...
llvm-svn: 26553
2006-03-05 21:20:20 +00:00
Chris Lattner
a171bcca08
Add a new scheduling type. This is, of course, a hack. Proper factoring
...
will come later.
llvm-svn: 26551
2006-03-05 21:08:06 +00:00
Chris Lattner
9f589d65a1
Add a copysign node
...
llvm-svn: 26540
2006-03-05 05:06:40 +00:00
Jim Laskey
f915b6b08b
Adding basic structure support.
...
llvm-svn: 26505
2006-03-03 15:06:57 +00:00
Evan Cheng
4afe769361
Add more vector NodeTypes: VSDIV, VUDIV, VAND, VOR, and VXOR.
...
llvm-svn: 26504
2006-03-03 07:01:07 +00:00