A minor issue with register allocator

sig siguctua at gmail.com
Tue Jul 3 21:45:33 UTC 2007


> The answer is the instruction selector only looks at the expression
> trees, it doesn't do whole method analysis so because (-4 eax) is
> loaded into a register it doesn't recognise that it's only used in
> one place.
>
I understand. I just wanted to use this for testing, to see how is my
method inlining works.

in sample above i compiling two methods:
--
message4: arg1 with: arg2
	self pragma: #cdecl.
	^ arg1 + arg2.
--
and:

inlineMessage4: a with: b
	self pragma: #cdecl.
	^ self inlineCall: (self message4: a with:b)
--

the intent was to get same code for both methods compiled with Exupery.
I thought that any extra registers/movs/jumps produced as side effect
of inlining can be simply optimized with Exupery low-level stuff..
But instead i have different code, which, of course doing same.


More information about the Exupery mailing list