Joel Dice
622b3d1c4e
replace compare and branch instructions with combined versions
...
This allows the assembler to see the operand types of the comparison
and the condition for jumping in the same operation, which is
essential for generating efficient code in cases such as
multiple-precision compare-and-branch.
2009-10-10 15:03:23 -06:00
Joel Dice
609a1a9633
snapshot
2009-10-07 00:50:32 +00:00
Joel Dice
23197da679
fix handling of subroutines in methods of return type long on 32-bit systems
2009-10-06 03:17:12 +00:00
Joel Dice
4f78783ef1
various bugfixes for SSE-based floating-point support
2009-10-05 14:25:12 +00:00
Joel Dice
d25da6116a
snapshot
2009-10-04 22:10:36 +00:00
Joel Dice
5dad9bddd6
snapshot
2009-10-04 19:56:48 +00:00
Joel Dice
6cef085d7e
snapshot
2009-09-26 19:43:44 +00:00
Joel Dice
325f93b4d1
Merge branch 'master' into wip
...
Conflicts:
src/compile.cpp
src/compiler.cpp
src/machine.h
src/x86.cpp
2009-09-20 15:43:32 -06:00
Joel Dice
953cb69e5e
move proxy and annotation code from C++ to Java
...
This allows code shrinkers to remove it if it's not used by the application.
2009-09-19 16:21:15 -06:00
Joel Dice
1a0eef7e2d
add support for building with MSVC on Windows
2009-08-26 18:26:44 -06:00
Josh warner
78ea4d20e3
added loneMatch to improve register allocation
2009-08-11 13:46:51 -06:00
Josh warner
cd59222f53
fixed propegation of result sizes
2009-08-11 13:27:25 -06:00
Josh warner
9910e310cb
fixed register reserve logic in pickTarget
2009-08-10 13:42:37 -06:00
Josh warner
1d3ef1fc43
Merge branch 'master' of git://oss.readytalk.com/avian, fixed problems that occured in broader testing
...
Conflicts:
src/compile.cpp
src/compiler.cpp
src/powerpc.cpp
src/x86.S
src/x86.cpp
2009-08-10 13:20:23 -06:00
Joel Dice
54bb64cfb2
freeze sites for dead values in resolveOriginalSites
...
Previously, we simply removed the element from the sites array, but
this led to problems when the junction sites are shared among multiple
junctions such that the value at a given index is live at one junction
and dead at another.
2009-08-10 07:51:19 -06:00
Josh warner
53c0656ee7
added floating point support, split plan method
2009-08-06 10:14:31 -06:00
Joel Dice
63fa0668ff
avoid poor performance due to deeply-nested branches in MultiRead::intersect
2009-08-04 18:28:34 -06:00
Joel Dice
d12b441aa1
restore state from subroutine after jsr to avoid later confusion determining basic block boundaries
2009-07-20 08:26:01 -06:00
Joel Dice
e72ff8db0b
Merge branch 'master' into gnu
...
Conflicts:
src/compile.cpp
2009-07-11 12:11:59 -06:00
Joel Dice
c22b4b4e79
various subroutine handling bugfixes
2009-07-08 08:18:40 -06:00
Joel Dice
562e1e10a8
fix regression in MyCompiler::startLogicalIp
2009-06-30 17:33:54 -06:00
Joel Dice
b308354a3a
handle subroutines properly when generating frame maps (initial sketch)
2009-06-26 15:36:04 -06:00
Joel Dice
a21f951e29
consider an instruction reachable if it has no predecessors (i.e. it's the first instruction
2009-06-12 09:45:29 -06:00
Joel Dice
b4dea1f71c
fix printf warnings in compiler.cpp
2009-05-28 19:12:26 -06:00
Joel Dice
2608a2ee43
progress towards powerpc continuation and tail call support
2009-05-26 19:02:39 -06:00
Joel Dice
31eb75a736
support tail calls and continuations as build options
2009-05-25 23:27:10 -06:00
Joel Dice
18ec68c7b7
fix word order when pushing 64-bit values as arguments to helper thunks in appendCombine
2009-05-24 00:31:53 -06:00
Joel Dice
57cec2d068
various bugfixes
2009-05-14 20:08:01 -06:00
Joel Dice
eb3bd25aa1
code cleanup and build fixes
2009-05-04 19:04:17 -06:00
Joel Dice
0cd4eb2655
early sketch of continuation support
2009-05-03 14:57:11 -06:00
Joel Dice
fd99691b00
fix CallEvent::popIndex calculation
2009-04-26 21:59:22 -06:00
Joel Dice
50529969f9
fix code to visit GC roots on stack to be compatible with tail calls; avoid generating unreachable jumps
2009-04-26 19:53:42 -06:00
Joel Dice
f80fb9b536
refine code for picking target sites to avoid unecessary moves
2009-04-26 12:19:16 -06:00
Joel Dice
64b529c915
avoid generating unreachable code after tail calls
2009-04-25 20:54:36 -06:00
Joel Dice
630fde86f7
freeze registers in CallEvent::compile to ensure they are not used as temporaries by the assmebler
2009-04-25 20:07:47 -06:00
Joel Dice
0245a94ab8
generate code in ReturnEvent if and only if the event is preceded by at least one non-tail-call
2009-04-25 19:51:33 -06:00
Joel Dice
de84afe2fe
adjust stack if necessary after non-tail-call in case where callee pops arguments
2009-04-25 11:47:41 -06:00
Joel Dice
3113ae74eb
various bugfixes
2009-04-22 01:39:25 +00:00
Joel Dice
717f359666
implement "callee pops arguments" calling convention and refactor tail call code accordingly
2009-04-19 16:36:11 -06:00
Joel Dice
dba72409aa
move use of SingleRead::successor; fix build errors
...
We now use SingleRead::successor in pickTarget, where we use it to
determine the prefered target site for the successor without requiring
the target to conform to that preference. The previous code made the
preference a hard requirement, which is not desirable or even possible
in general.
2009-04-07 18:55:43 -06:00
Joel Dice
35d1c6e068
add SingleRead::successor; fix build errors
...
The SingleRead::successor field is used (when non-null) to further
constrain the SiteMask in SingleRead::intersect based on reads of
successor values (as in the cases of moves and condensed-addressing
combine and translate instructions).
2009-04-06 18:34:12 -06:00
Joel Dice
fea92ed995
more work on tail recursion
...
We now create a unique thunk for each vtable position so as to avoid
relying on using the return address to determine what method is to be
compiled and invoked, since we will not have the correct return address
in the case of a tail call. This required refactoring how executable
memory is allocated in order to keep AOT compilation working. Also, we
must always use the same register to hold the class pointer when
compiling virtual calls, and ensure that the pointer stays there until
the call instruction is executed so we know where to find it in the
thunk.
2009-04-05 15:42:10 -06:00
Joel Dice
5e740170f2
initial sketch of tail call optimization (non-virtual calls only, so far)
2009-03-31 14:15:08 -06:00
Joel Dice
c9400316fd
try harder to find a suitable stack frame site in pickTarget when there are no free registers left
2009-03-16 20:03:59 -06:00
Joel Dice
f5c79355f2
set StealRegisterReserveCount to 2 to avoid running out of registers in when shuffling values around on the stack
2009-03-16 18:00:51 -06:00
Joel Dice
d1018bf078
update copyright years
2009-03-15 12:02:36 -06:00
Joel Dice
073b829c79
avoid running out of eligable source registers for writing a single byte to memory on x86
2009-03-14 16:47:26 -06:00
Joel Dice
8d9409112c
reuse source site as destination site if appropriate in getTarget
2009-03-14 14:17:32 -06:00
Joel Dice
ee2d105f6c
freeze move operand sites prior to calling the assembler so the assembler won't steal them
2009-03-13 20:55:41 -06:00
Joel Dice
4c27755a53
fix endianness issue storing and loading longs
2009-03-11 21:07:30 -06:00