Everything is a Register!

bryce at kampjes.demon.co.uk bryce at kampjes.demon.co.uk
Mon May 7 12:31:52 UTC 2007


Mathieu Suen writes:
 > Why do you have this special syntaxe? Why don't you use the Smalltalk  
 > bytcode?
 > On May 7, 2007, at 12:54 PM, sig wrote:
 > 
 > > ((block 1
 > >  (mov 1 't2')
 > >  (mov 2 't3')
 > >  (add 't3' 't2')
 > >  (jge block5))
 > > (block 2
 > >  (mov 5 't1')
 > >  (sub 't3' 1)
 > >  (jnz block4))
 > > (block 3
 > >  (mov (mov 10 't1') 't5'))
 > > (block 4
 > >  (mov 't5' 't4'))
 > > (block 5
 > >  (return 't1')))

The format shown is just a written form of Exupery's low level
intermediate. It was originally created for unit testing, it can
be used to create intermediate objects, to compare outupt, and
to set up mocks.

In normal operation, Exupery will translate bytecode through several
intermediate forms to create tolerably efficient machine code.

Bryce



More information about the Squeak-dev mailing list