Version française
Home     About     Download     Resources     Contact us    
Browse thread
AW: [Caml-list] The tag bit
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Jacques Garrigue <garrigue@k...>
Subject: Re: AW: [Caml-list] The tag bit
From: "Bauer, Christoph" <Christoph.Bauer@lms-gmbh.de>
> But who needs the tag bit? Only the garbage collector. Maybe it's
> an advantage to see 32 tag bits as a whole, e.g. the question
> "does the block contains any pointer" can be calculated bit-parallel.
> Anyway the garbage collector could works on blocks and needs 
> just one additional memory access per block.

But who works in your program?
The garbage collector!
Do some profiling, and you will be surprised at how much time is used
collecting garbage in a perfectly sane program.
No surprise here: in symbolic programming, you are generating garbage
all the time. In the old lisp days, people talked of the mutator (your
program) and the collector, emphasizing that they are almost equal.
And you wouldn't give 1 bit for your brother, doing all the dirty
work? :-)

More seriously, it may be that your idea of blocks could be made to
work, but it's not going to be easy. For instance, what do you do when
manipulating data between registers? Looks like it would mean updating
some special register every time you do a move operation. This could
generate heaps of code.
GC is such an old field that I suppose all weird approaches have
already been studied in the litterature.

Jacques Garrigue

-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners