[m-rev.] for prelim review: remove hand-coded RTTI

Peter Ross pro at missioncriticalit.com
Tue Nov 18 20:56:22 AEDT 2003


On Tue, Nov 18, 2003 at 01:03:15PM +1100, Fergus Henderson wrote:
> On 17-Nov-2003, Peter Ross <pro at missioncriticalit.com> wrote:
> > With the change below I can now build the standard library in the il
> > grade and no longer require hand-coded RTTI for int.
> > 
> > So far all I have done is satisfy myself that it works for int, however
> > I would like some confirmation that there is nothing fundamentally wrong
> > with this approach, plus any suggestions on how the approach could be
> > improved.
> 
> I think the approach looks OK.
> 
> Does the compiler inline builtin_compare_int into the definition of the
> new automatically-generated comparison procedure for int?
> That's pretty important.
> 
It can't on the IL backend because builtin_compare_int is defined in C#.
However the JIT engine should do that inlining because everything is
located in the same assembly.

Regarding the C backends.  Upon further investigation the port is not so
trivial due to code in the runtime inspecting some of the
type_ctor_infos.  This would require that I move all this code into the
library, which would be to time consuming for me to contenance.  Thus I
will factor the code so that the auto-generation of the type_ctor_infos
only occurs on the non-C backends.
--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list