Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!ncar!tank!eecae!cps3xx!usenet From: usenet@cps3xx.UUCP (Usenet file owner) Newsgroups: comp.sys.amiga.tech Subject: Re: Official Warnings... Summary: Expires: Message-ID: <2799@cps3xx.UUCP> Date: 2 May 89 16:03:58 GMT References: <3082@haven.umd.edu> <11394@well.UUCP> <3773@sugar.hackercorp.com> Reply-To: porkka@frith.UUCP (Joseph A Porkka) Organization: Michigan State University Lines: 17 In article <3773@sugar.hackercorp.com> karl@sugar.hackercorp.com (Karl Lehenbauer) writes: >Isn't TAS useful on a single CPU system, though, for providing fast, >uninterruptable test and set for use as a semaphore, without having >to turn off interrupts? Thats what the BSET, BCLR, BCHG, etc.. are for. Those instructions won't be interrupted by a task switch, but their memory read/write cycles could be interleaved with memory accesses from other processors, like another CPU, or the copper, or even the blitter. Generally though, the copper and blitter would not be using memory that programs are using for semaphores and the like. Perhaps the badness of TAS and alternate solutions should be included in the RKMs, since it apparently causes problems for a lot of programmers.