Commit Graph

41451 Commits

Author SHA1 Message Date
Dan Gohman
3d84a76917 Refactor the logic for testing if an instruction is dead into a
separate method.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56531 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-24 00:27:38 +00:00
Dan Gohman
035268eaf7 Set SetStore to false, to allow this pass to delete
dead loads.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56529 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-24 00:07:08 +00:00
Dan Gohman
3e4fb70c6a Add a method to MachineInstr for testing whether it makes
any volatile memory references.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56528 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-24 00:06:15 +00:00
Devang Patel
20bcaff6a7 Put FN_NOTE_AlwaysInline and others in FnAttr namespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56527 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-24 00:06:15 +00:00
Evan Cheng
da43bcf624 Properly handle 'm' inline asm constraints. If a GV is being selected for the addressing mode, it requires the same logic for PIC relative addressing, etc.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56526 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-24 00:05:32 +00:00
Devang Patel
dd4924c564 Move FN_NOTE_AlwaysInline and other out of ParamAttrs namespace.
Do not check isDeclaration() in hasNote(). It is clients' responsibility.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56524 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 23:52:03 +00:00
Devang Patel
06117b6598 80 cols
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56521 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 23:32:15 +00:00
Devang Patel
2d2255d2d9 s/ParameterAttributes/Attributes/g
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56520 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 23:25:44 +00:00
Devang Patel
b700c3f367 Remove tabs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56515 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 23:18:26 +00:00
Devang Patel
eaf42abab6 s/ParameterAttributes/Attributes/g
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56513 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 23:03:40 +00:00
Devang Patel
d9b4a5f859 Use parameter attribute store (soon to be renamed) for
Function Notes also. Function notes are stored at index ~0.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56511 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 22:35:17 +00:00
Dan Gohman
b2c3e3fdd9 Now that DeadMachineInstructionElim is basically working
correctly, it's not necessary to explicitly remove registers
from their use-def lists.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56509 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 22:04:18 +00:00
Dan Gohman
d57dd5f4e6 Arrange for FastISel code to have access to the MachineModuleInfo
object. This will be needed to support debug info.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56508 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 21:53:34 +00:00
Dan Gohman
8468d1a845 Track local physical register liveness. This is not the most
efficient implementation possible, but it's pretty simple and
good enough for the time being.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56504 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 21:40:44 +00:00
Chris Lattner
ccef6b5d76 regenerate
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56502 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 21:18:31 +00:00
Chris Lattner
013766707b allow inreg on the result of a function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56501 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 21:18:08 +00:00
Dan Gohman
086ec9976f Replace the LiveRegs SmallSet with a simple counter that keeps
track of the number of live registers, which is all the set was
being used for.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56498 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 18:50:48 +00:00
Dan Gohman
0ba2bcfcc3 Fix these enums' starting values to reflect the way that
instruction opcodes are now numbered. No functionality change.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56497 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 18:42:32 +00:00
Dan Gohman
987756308b Update the comment to reflect the new name.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56496 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 18:27:53 +00:00
Dan Gohman
fe29e770e6 Delete an unused function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56495 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 18:26:47 +00:00
Dan Gohman
8b746969ba Move the code for initializing the global base reg out of
X86ISelDAGToDAG.cpp and into X86InstrInfo.cpp. This will allow
it to be reused by FastISel.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56494 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 18:22:58 +00:00
Duncan Sands
3ee8fc9649 Rationalize the names of passes that print information:
-callgraph => print-callgraph
    -callscc   => print-callgraph-sccs
    -cfgscc    => print-cfg-sccs
    -externalfnconstants => print-externalfnconstants
    -print               => print-function
    -print-alias-sets (no change)
    -print-callgraph     => dot-callgraph
    -print-cfg           => dot-cfg
    -print-cfg-only      => dot-cfg-only
    -print-dom-info (no change)
    -printm              => print-module
    -printusedtypes      => print-used-types


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56487 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 12:47:39 +00:00
Matthijs Kooijman
1de42e8374 Fix indendation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56486 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 08:54:41 +00:00
Owen Anderson
fae86eddeb Add initial support for inserting last minute copies.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56485 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-23 04:37:10 +00:00
Evan Cheng
364091e090 Support x86 specific inline asm modifier 'J'.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56483 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 23:57:37 +00:00
Dale Johannesen
869aed7d83 Remove silly semicolon.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56481 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 23:28:18 +00:00
Dan Gohman
87a0f10dc7 Fix the alignment of loads from constant pool entries when the
load address has an offset from the base of the constant pool
entry.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56479 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 22:40:08 +00:00
Dale Johannesen
2165e1288e Remove a compiler warning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56478 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 22:33:34 +00:00
Devang Patel
f3ba70861c Add hasNote() to check note associated with a function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56477 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 22:32:29 +00:00
Evan Cheng
ef901c5756 Livestacks really does preserve everything.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56476 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 22:26:15 +00:00
Evan Cheng
8b56a90bec Instead of setPreservesAll, just mark them preseving machine loop info and machine dominators.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56475 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 22:21:38 +00:00
Evan Cheng
bc09afa80e Test case for fp logical instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56474 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 22:19:34 +00:00
Owen Anderson
e04cec0ecf Significant improvements to the logic for merging live intervals. This code can't
just use LI::MergeValueAsValue, as its behavior in the presence of overlapping ranges
isn't what StrongPHIElimination wants.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56472 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 21:58:58 +00:00
Dale Johannesen
0bb41608e9 Make log, log2, log10, exp, exp2 use Expand by
default.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56471 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 21:57:32 +00:00
Evan Cheng
bbeeb2a61e Mark several codegen passes as preserving all analysis.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56469 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 20:58:04 +00:00
Dale Johannesen
f74185b80e More refactoring. Yawn.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56468 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 20:51:30 +00:00
Mikhail Glushenkov
14ef05937f Convert llvmc2 plugins to use llvm/Support/Registry.h machinery.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56467 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 20:51:19 +00:00
Mikhail Glushenkov
4a1a77c1c9 Move llvmc2 header files under include/llvm/CompilerDriver
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56466 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 20:50:40 +00:00
Mikhail Glushenkov
c82ce4a8a7 Plugin support for llvmc2 (a-la opt).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56465 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 20:49:34 +00:00
Mikhail Glushenkov
9ecd30c4a2 Add a 'Debugging' section to the documentation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56464 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 20:48:48 +00:00
Mikhail Glushenkov
0737651452 Make comments a little bit more clear.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56463 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 20:48:22 +00:00
Mikhail Glushenkov
11a353a206 Get rid of GlobalLanguageMap. Global state is evil.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56462 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 20:47:46 +00:00
Mikhail Glushenkov
ac69f91e44 Rename our version of ccc to ccc2
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56461 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 20:47:09 +00:00
Mikhail Glushenkov
d92f2e01fc Fix some comments
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56460 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 20:46:44 +00:00
Mikhail Glushenkov
fdee954623 Add a (forward_as) option property
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56459 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 20:46:19 +00:00
Mikhail Glushenkov
5ccf28f168 Delete the file llvmc2/doc/LLVMC-Enhancements.rst + some minor language/spelling fixes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56458 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 20:45:17 +00:00
Dale Johannesen
c4342eab9b Refactor FP intrinisic setup. Per review feedback.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56456 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 19:51:58 +00:00
Oscar Fuentes
1d8e4cfdb7 CMake build system: support for parallel builds.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56453 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 18:21:51 +00:00
Evan Cheng
242ebd145d Per review feedback: Only perform
(srl x, (trunc (and y, c))) -> (srl x, (and (trunc y), c))
etc. when both "trunc" and "and" have single uses.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56452 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 18:19:24 +00:00
Arnold Schwaighofer
290ae0398e Change the calling convention used when tail call optimization is enabled from CC_X86_32_TailCall to CC_X86_32_FastCC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56436 91177308-0d34-0410-b5e6-96231b3b80d8
2008-09-22 14:50:07 +00:00