<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content=text/html;charset=ISO-8859-1>
<META content="MSHTML 6.00.2800.1528" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY text=#000000 bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Ouch.&nbsp; This suggests to me that code 
generation isn't well organized in the compiler.&nbsp; Adding a field should be 
as easy as, well, adding a field to a struct or object in any other 
system.&nbsp; But I have the impression that the generated code doesn't use 
struct definitions in C it uses hard-wired pointer arithmetic.&nbsp;&nbsp;Using 
pointer arithmetic is&nbsp;very poor practice because it makes what should be 
trivial changes, hard.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Josh Scholar</FONT></DIV>
<BLOCKQUOTE 
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
  <DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
  <DIV 
  style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B> 
  <A title=joerg@deepcovelabs.com href="mailto:joerg@deepcovelabs.com">Joerg 
  Beekmann</A> </DIV>
  <DIV style="FONT: 10pt arial"><B>To:</B> <A 
  title=squeak-dev@lists.squeakfoundation.org 
  href="mailto:squeak-dev@lists.squeakfoundation.org">The general-purpose Squeak 
  developers list</A> </DIV>
  <DIV style="FONT: 10pt arial"><B>Sent:</B> Monday, January 02, 2006 8:54 
  AM</DIV>
  <DIV style="FONT: 10pt arial"><B>Subject:</B> Re: Adding a new imediate 
  type</DIV>
  <DIV><BR></DIV>Peter Crowther wrote: 
  <BLOCKQUOTE 
  cite=mid4148C9693F97D044A563A88663D9C24E0725C9@uriel.crowther.local 
  type="cite">
    <BLOCKQUOTE type="cite"><PRE wrap="">From: [...] Joerg Beekmann
Can anyone comment on how much work would be involved in
1) Adding a new 32bit field to the object header
    </PRE></BLOCKQUOTE><PRE wrap=""><!---->
Nasty.  I tried it back in the 2.2 days, and failed.  My biggest problem
was getting the garbage collector stable.

  </PRE>
    <BLOCKQUOTE type="cite"><PRE wrap="">2) Adding a new immediate type like integer, presumable by adding 
another tag bit.
    </PRE></BLOCKQUOTE><PRE wrap=""><!---->
Also nasty - there aren't any more tag bits, and tweaking with the
header format also involves the GC.  If you're going to do this, look at
the compact classes instead and see whether you can make yours compact.
Last I looked, I think there were a couple of spares.  Note that changes
to compact classes did *not* involve image format or VM changes last I
looked.
  </PRE></BLOCKQUOTE>Thanks Peter, I am not aware of compact classes so I'll 
  have a look.<BR><BR><BR><PRE class=moz-signature cols="72">-- 
Joerg Beekmann
DeepCove Labs
4th floor 595 Howe Street
Vancouver, BC, V6C 2T5
<A class=moz-txt-link-abbreviated href="mailto:joerg@deepcovelabs.com">joerg@deepcovelabs.com</A></PRE>
  <P>
  <HR>

  <P></P><BR></BLOCKQUOTE></BODY></HTML>