From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,3ccb707f4c91a5f2 X-Google-Attributes: gid103376,public From: Hannes Haug Subject: Re: Java vs Ada 95 (Was Re: Once again, Ada absent from DoD SBIR solicitation) Date: 1996/11/03 Message-ID: #1/1 X-Deja-AN: 194311182 sender: haugha@chaq.informatik.uni-tuebingen.de references: <325BC3B3.41C6@hso.link.com> organization: Uni Tuebingen newsgroups: comp.lang.ada Date: 1996-11-03T00:00:00+00:00 List-Id: dewar@merv.cs.nyu.edu (Robert Dewar) writes: > > Robert Eachus said > > " Yes, an implementation of Unbounded_String which uses reference > counts and lazy copying would work much better in this case." > > Be careful about casually suggesting reference counts. They are potentially > VERY expensive in a tasking context where taking a lock for incrementing > a reference count requires a system call. I hope it will be possible to use a test-and-set-lock instruction in an inlined while loop in gnat-3.08. This would be faster. Sometimes you can't even trust the "system calls" (e.g. solaris semaphores). -hannes