Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.forth > #27159

Re: Reclaiming Allocated Memory

From Paul Rubin <no.email@nospam.invalid>
Newsgroups comp.lang.forth
Subject Re: Reclaiming Allocated Memory
Date 2013-12-05 07:21 -0800
Organization Nightsong/Fort GNOX
Message-ID <7xbo0vfhng.fsf@ruckus.brouhaha.com> (permalink)
References <5293458b$0$296$14726298@news.sunsite.dk> <2013Dec4.174638@mips.complang.tuwien.ac.at> <52a066dc$0$302$14726298@news.sunsite.dk> <7xr49rpdz0.fsf@ruckus.brouhaha.com> <52a08fae$0$4637$e4fe514c@dreader34.news.xs4all.nl>

Show all headers | View raw


albert@spenarnc.xs4all.nl (Albert van der Horst) writes:
> In a special context of Forth garbage, we need a special collector,
> probably order of magnitude simpler than Java's.

Anton's implementation is probably the only practical approach for
Forth: the Boehm algorithm basically scans all reachable objects for
anything that might be a pointer to a GC'd object, and treats those
locations as non-garbage.  This is called an imprecise or conservative
collector, because it can mistake data for pointers and therefore
occasionally fail to free something that is actually garbage.  While
that may sound scary, it is indeed relatively simple, and it works
pretty well in practice.  It was originally written for C and is not
unique to Forth:

   http://www.hpl.hp.com/personal/Hans_Boehm/gc/

Java's GC (Oracle version) is very complicated and highly optimized,
works with parallel processes, etc.  Java could use a simpler GC,
including the Boehm GC, at a cost in performance.  GCJ in fact uses the
Boehm GC.

Back to comp.lang.forth | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Reclaiming Allocated Memory Doug Hoffman <glidedog@gmail.com> - 2013-11-25 07:41 -0500
  Re: Reclaiming Allocated Memory Paul Rubin <no.email@nospam.invalid> - 2013-11-25 07:04 -0800
    Re: Reclaiming Allocated Memory albert@spenarnc.xs4all.nl (Albert van der Horst) - 2013-11-25 16:16 +0000
      Re: Reclaiming Allocated Memory Paul Rubin <no.email@nospam.invalid> - 2013-11-25 09:03 -0800
        Re: Reclaiming Allocated Memory Doug Hoffman <glidedog@gmail.com> - 2013-11-26 06:30 -0500
          Re: Reclaiming Allocated Memory AKK <akk@nospam.org> - 2013-11-26 13:07 +0100
    Re: Reclaiming Allocated Memory Doug Hoffman <glidedog@gmail.com> - 2013-11-26 05:11 -0500
  Re: Reclaiming Allocated Memory anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-12-04 16:46 +0000
    Re: Reclaiming Allocated Memory Doug Hoffman <glidedog@gmail.com> - 2013-12-05 06:43 -0500
      Re: Reclaiming Allocated Memory Paul Rubin <no.email@nospam.invalid> - 2013-12-05 06:30 -0800
        Re: Reclaiming Allocated Memory albert@spenarnc.xs4all.nl (Albert van der Horst) - 2013-12-05 14:37 +0000
          Re: Reclaiming Allocated Memory Paul Rubin <no.email@nospam.invalid> - 2013-12-05 07:21 -0800
        Re: Reclaiming Allocated Memory Doug Hoffman <glidedog@gmail.com> - 2013-12-06 04:57 -0500
          Re: Reclaiming Allocated Memory Paul Rubin <no.email@nospam.invalid> - 2013-12-06 07:38 -0800
            Re: Reclaiming Allocated Memory Doug Hoffman <glidedog@gmail.com> - 2013-12-07 06:14 -0500
      Re: Reclaiming Allocated Memory anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-12-05 18:14 +0000
        Re: Reclaiming Allocated Memory Doug Hoffman <glidedog@gmail.com> - 2013-12-06 04:58 -0500
          Re: Reclaiming Allocated Memory Bernd Paysan <bernd.paysan@gmx.de> - 2013-12-06 17:30 +0100
            Re: Reclaiming Allocated Memory Doug Hoffman <glidedog@gmail.com> - 2013-12-07 05:59 -0500
              Re: Reclaiming Allocated Memory anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-12-07 11:57 +0000
                Re: Reclaiming Allocated Memory albert@spenarnc.xs4all.nl (Albert van der Horst) - 2013-12-07 17:48 +0000
                Re: Reclaiming Allocated Memory Bernd Paysan <bernd.paysan@gmx.de> - 2013-12-07 19:15 +0100
                Re: Reclaiming Allocated Memory anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-12-09 13:45 +0000
          Re: Reclaiming Allocated Memory anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2013-12-06 17:42 +0000

csiph-web