Slava Pestov
10d25cc0ad
Revert "compiler.cfg: change linear ordering to place GC call blocks at the end"
...
This reverts commit 544a288192 .
2010-07-27 23:58:41 -04:00
Slava Pestov
544a288192
compiler.cfg: change linear ordering to place GC call blocks at the end
2010-07-27 13:00:28 -04:00
Slava Pestov
73c83333f2
compiler: remove flat machine representation and generate code directly from the CFG
2010-05-03 17:34:32 -04:00
Slava Pestov
fc7a1ad8b3
New GC checks work in progress
2010-05-03 17:34:16 -04:00
Slava Pestov
80558a93fa
Debugging untagged fixnums
2010-05-03 17:34:02 -04:00
Joe Groff
8d274e851a
fix ... in compiler.cfg.linearization
2010-03-05 14:27:58 -08:00
Slava Pestov
08b6ebc7fa
Factor source files should not be executable
2009-11-21 17:50:43 -06:00
Slava Pestov
931107397c
compiler.cfg: remove _gc instruction, it doesn't need to exist, and change GC checks to ensure that the right amount of space is available instead of blindly checking for 1Kb
2009-10-05 05:27:49 -05:00
Joe Groff
7b13fa4283
fold test-vector/branch sequences into a test-vector-branch instruction
2009-10-01 19:53:30 -05:00
Joe Groff
025a5b7b15
split unordered and ordered float comparison intrinsics in compiler; generate only unordered comparisons for now
2009-09-08 17:04:26 -05:00
Slava Pestov
12ab2b9e9d
_gc instruction doesn't need slot to hold GC root area size, since that's just tagged-values>> length
2009-08-09 03:08:13 -05:00
Slava Pestov
88d15dfbea
compiler.cfg: new system to track when results of analyses need to be recomputed (reverse post order, linear order, predecessors, dominance, loops). Passes can now call needs-predecessors, needs-dominance, needs-loops at the beginning, and cfg-changed, predecessors-changd at the end. Linearization order now takes loop nesting into account, and linear scan now uses linearization order instead of RPO.
2009-08-08 20:02:56 -05:00
Slava Pestov
4d2160799f
Split off the notion of a register representation from a register class
2009-08-07 17:44:50 -05:00
Slava Pestov
99216b8435
compiler.cfg: Get inline GC checks working again, using a dataflow analysis to compute uninitialized stack locations in compiler.cfg.stacks.uninitialized. Re-enable intrinsics which use inline allocation
2009-07-30 09:19:44 -05:00
Slava Pestov
5ecd0d91a3
compiler.cfg: remove 'regs' slot from instruction tuples now that register allocation doesn't use it anymore
2009-07-29 06:50:46 -05:00
Slava Pestov
c634f5a9a0
compiler.cfg.linearization: rotate loops. 2x speedup with empty times loop, 1.5x speedup on benchmark.dawes
2009-07-28 21:31:08 -05:00
Slava Pestov
91d2b3e805
compiler.cfg.utilities: add loop-entry? word
2009-07-28 08:47:50 -05:00
Slava Pestov
c2c3d64d6d
compiler.cfg.stacks: now performs online local DCN
2009-07-23 20:54:38 -05:00
Slava Pestov
7c488f2b25
Insert _loop-entry in linearization pass instead of in CFG builder, so that optimizations don't have to worry about it
2009-07-22 06:05:17 -05:00
Slava Pestov
5d9f7b0ed2
compiler.cfg: Major restructuring -- do not compute liveness before local optimization, and instead change local optimizations to be more permissive of undefined values. Now, liveness is only computed once, after phi elimination and before register allocation. This means liveness analysis does not need to take phi nodes into account and can now use the new compiler.cfg.dataflow-analysis framework
2009-07-22 03:08:28 -05:00
Slava Pestov
99faf3c79f
Overflowing fixnum intrinsics now expand into several CFG nodes. This speeds up the common case since only the uncommon case is now a stack syncpoint
2009-07-16 18:29:40 -05:00
Slava Pestov
1eae4286cd
compiler.cfg: split off condition codes into a comparisons sub-vocabulary
2009-07-13 14:42:52 -05:00
Slava Pestov
12cbbbd6ad
compiler.cfg: clean up GC check generation to use spill-slot data type
2009-07-03 23:11:23 -05:00
Slava Pestov
89fbc8efb4
compiler.cfg.tco: Tail call optimization moved out of compiler.cfg.builder into its own pass
2009-06-30 20:13:35 -05:00
Slava Pestov
7aca076408
GC checks now save and restore registers
2009-06-02 18:23:47 -05:00
Slava Pestov
b52bdf60e4
Fix for recent word renaming
2009-06-01 03:19:35 -05:00
Slava Pestov
57d9d9f961
Split off local-optimization combinator into compiler.cfg.local, factor out CFG -> MR into compiler.cfg.mr, split off GC check insertion into a new compiler.cfg.gc-checks pass
2009-05-31 12:20:46 -05:00
Slava Pestov
968a9bb666
Various codegen improvements:
...
- new-insn word to construct instructions
- cache RPO in the CFG
- re-organize low-level optimizer so that MR is built after register allocation
- register allocation now stores instruction numbers in the instructions themselves
- split defs-vregs into defs-vregs and temp-vregs
2009-05-29 13:11:34 -05:00
Slava Pestov
5a5afcbfaa
On second thought, linearization will be done after SSA destruction so live-in is accurate
2009-05-29 05:45:40 -05:00
Slava Pestov
fbefd02bfb
Put GC checks in the right place when linearizing, and generate _dispatch-labels
2009-05-29 05:36:04 -05:00
Slava Pestov
3954c3fdc3
Add a new ##allocation union to remove some code duplication
2009-05-27 18:55:49 -05:00
Slava Pestov
25805f9bfe
Refactoring low-level optimizer to support stack analysis pass
2009-05-26 19:31:19 -05:00
Doug Coleman
3c408342ef
renaming: contain? -> any?, deep-contains? -> deep-any?, pad-left -> pad-head, pad-right -> pad-tail, trim-left -> trim-head, trim-right -> trim-tail
2009-01-29 22:19:07 -06:00
Slava Pestov
0021cde743
Fix more compile errors
2008-12-15 22:21:56 -06:00
Slava Pestov
daf2857d7b
define-inline now takes an effect parameter
...
C: now sets the stack effect of the new word to slot names
add new basis/constants vocab; CONSTANT: foo bar is equivalent to : foo bar ; inline
(going to fold CONSTANT:, ALIAS: and qualified into core soon perhaps)
tighten the screws: inline words now need a stack declaration too
update some usages of inline words
2008-12-15 19:44:56 -06:00
Slava Pestov
b1aa3697cb
Emit branches in the same order they're written in code
2008-11-13 03:52:01 -06:00
Slava Pestov
efcb916e35
Handle a jump to a jump by cloning the block, in the same way we optimize jumps to returns
2008-11-03 21:02:34 -06:00
Slava Pestov
445e353337
Optimize away useless jumps
2008-11-02 23:09:31 -06:00
Slava Pestov
3834eaeb05
Don't generate GC checks if the allocation instruction is optimized out
2008-11-02 01:50:48 -06:00
Slava Pestov
492a15e345
Move insn class to compiler.cfg.instructions
2008-10-24 09:17:06 -05:00
Slava Pestov
1f693b50b3
Massive focused action
2008-10-22 18:39:41 -05:00
Slava Pestov
37cf7d9a9c
Add SSA comparison instructions, fix various problems
2008-10-20 05:55:20 -05:00
Slava Pestov
f092622fac
CFG IR is now pure SSA
2008-10-20 01:56:28 -05:00
Slava Pestov
f436fd0c0f
Merging in new codegen
2008-10-07 16:16:50 -05:00