From: Benedikt F. <b.f...@gm...> - 2024-07-02 16:56:06
|
Am 02.07.24 um 15:53 schrieb Basil Hussain: > On 02/07/2024 14:21, Michael Hawkins wrote: >> 2) What does "unit testing" comprise of in the SDCC build environment? >> Is there some dark room somewhere with a stack of old school computers >> running different CPU's that get exercised? Or is "testing" done some >> other magical way? In other words, would I need to design a test rig >> for the 8080/85 that can be used for testing? > > Testing is primarily done against the µCsim simulator, which is > bundled with SDCC. µCsim certainly says it supports simulation of 8080 > and 8085 processors, although I don't know how accurate or complete it > is. Someone else will surely be able to comment on that. > > More information on the testing infrastructure can be found in the Wiki: > https://sourceforge.net/p/sdcc/wiki/Test/ > https://sourceforge.net/p/sdcc/wiki/Regression%20Testing/ > > One other key requirement for SDCC to support a particular processor > would be support by the assembler. If you don't know, SDCC's assembler > is a fork of the ASxxxx cross assembler. Currently, upstream ASxxxx > claims support for 8080/85, but that support almost certainly does not > exist in SDCC, and would need to be ported from upstream. > > Regards, > Basil Hussain AFAIK, a new assembler would only be necessary for the original ugly 8080 syntax. Since the Z80 is an almost perfect superset of the 8080, we could simply use the Z80 assembler and stick with its more comprehensible syntax. For the 8080 backend itself, sm83 could serve as a starting point, because its instruction set appears to be closer to (i.e. less expanded beyond) the 8080. -- Benedikt |