Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!magnus.acs.ohio-state.edu!cis.ohio-state.edu!ucbvax!mtxinu!taniwha!paul From: paul@taniwha.UUCP (Paul Campbell) Newsgroups: comp.sys.m68k Subject: Re: Daystar Digital Review: 030 vs. 040 Perf. (Very Long) Message-ID: <886@taniwha.UUCP> Date: 30 Jun 91 19:46:48 GMT References: <1991Jun28.230007.10651@oakhill.sps.mot.com> Reply-To: paul@taniwha.UUCP (Paul Campbell) Organization: Taniwha Systems Design, Oakland Lines: 53 In article <1991Jun28.230007.10651@oakhill.sps.mot.com> jtr@oakhill.sps.mot.com (Jim Reinhart) writes: > >>SOFTWARE COMPATIBILITY WILL BE A MAJOR PROBLEM ON 68040 >>ACCELERATORS AS WELL AS APPLE'S NEW 68040 MACHINE. APPLE >>WILL HAVE TO MAKE MAJOR PATCHES TO THE MAC OS TO HANDLE >>PROBLEMS WITH MEMORY MANAGEMENT AND EXCEPTION HANDLING. IN > >There are indeed differences between the O.S. programming for >the 68030 and 68040. However, Daystar's assertion that this >is a "MAJOR" problem is not generally supportable. First, >the differences have been documented long enough (~1.5 years >in print) for vendors to make appropriate plans. Second, the >only major differences (or 'problems' in Daystar terminology) >concern the virtual exception processing model and cache >management. This impacts only a small portion of O.S. code While I mostly agree with Mot. and disagree with Daystar on almost all these issues, I have to take exception to this response. There is a quite large body of code (mostly INITs and things that do trap patches) that runs on existing Macs and doesn't run on '040s, the main reason has to do with programmers who modify code, or load data containing code and execute it without being aware of the impacts of the caches in the '020/'030 and '040. The reason this happens is for 2 reasons: 1) People who are running '040s without writethrough data caches (ie a copyback cache) which means that data may be in the cache but that memory has an old value 2) The '040 caches are much bigger, code that happens to run today on an '030 fails on an '040 because the '030 instruction cache entries happened to be replaced because it's much smaller. So if you are a Mac programmer: if you load code in a resource, or copy it anywhere, or if you modify code (a good example is the trick of putting the address of a trap address after a jmp instruction when you are trap patching) remember to flush the caches, it's easy, you have to do both of them and it's done using the traps: _FlushInstructionCache _FlushDataCache If in doubt flush the caches! On the other hand CPUs like the '040 depend on caches for their performance - so don't flush the caches unnecessarily. Paul Campbell -- Paul Campbell UUCP: ..!mtxinu!taniwha!paul AppleLink: CAMPBELL.P Tom Metzger's White Ayrian Resistance has been enjoined to stop selling Nazi Bart Simpson t-shirts - Tom of course got it wrong, Bart is yellow, not white.