From: Michael H. <mha...@gm...> - 2024-07-02 13:21:36
|
Hi everyone, Years ago, I was considering jumping in to help/do SDCC support for 8080/8085. Now, I am seriously about to begin doing just that. But before I do, I would like to understand the testing that is done as part of your build processes. And, I seem to recall that there was initial discussion about the limitations of the number of registers in the 8080 that would make it unsuitable for C/SDCC. So my first questions are: 1) Is the 8080/85 considered too primitive to be a successful target for SDCC? Lack of registers? Other whys? 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? Cheers, -- Michael A Hawkins Stamford, CT 06902 USA Mobile: 203-550-5502 |
From: Philipp K. K. <pk...@sp...> - 2024-07-02 13:56:29
|
Am 02.07.24 um 15:21 schrieb Michael Hawkins: > So my first questions are: > 1) Is the 8080/85 considered too primitive to be a successful target > for SDCC? Lack of registers? Other whys? I don't think that would be a problem. After all, the 8051 and the Padauk devices aren't that powerful either. > 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? We do regression testing. The regression tests can be run locally by sdcc developers (we usually do before making a commit), and are run on the nightly snapshots in the compile farm: Each machine in the farm gets the current sdcc from svn, builds it, and runs the regression tests. The regression tests mostly consist of a few ten thousand small C code samples that are compiled for each architecture, and then run on simulators. Those programs contain assertions, and failures are reported, and can be seen on the snapshots page (https://sdcc.sourceforge.net/snap.php - red dots indicate failures). There's a bit more, in particular some testing of diagnostics (i.e. warnings and errors), where a few smaple programs are compiled and get checked that warnings and erros are emitted for the issues on the correct line numbers. See also https://sourceforge.net/p/sdcc/wiki/Test/ Philipp P.S.: https://sourceforge.net/p/sdcc/wiki/Adding%20a%20port/ might also be helpful here. |
From: Michael H. <mha...@gm...> - 2024-07-02 14:23:02
|
Hi Philip, OK, that's all good so far. I assume the "simulators" are not bare metal so what are they exactly? Because, should I expect to need to contribute to building a simulator for 8080/85? -- Michael A Hawkins Stamford, CT 06902 USA Mobile: 203-550-5502 On Tue, 2024-07-02 at 15:43 +0200, Philipp Klaus Krause wrote: > and then run on > simulators |
From: <dan...@un...> - 2024-07-03 08:19:44
|
On Tue, 2 Jul 2024, Michael Hawkins wrote: > Because, should I expect to need to contribute to building a simulator > for 8080/85? No, it is included in sdcc already and it includes 8080/8085. Daniel |
From: mhawkins.consultant <mha...@gm...> - 2024-07-03 19:30:58
|
Does uCsim rely on assembler mnemonics? Or object code?Still trying to figure out if using z80 as core makes sense.Michael A HawkinsMobile: 203-550-5502 -------- Original message --------From: dan...@un... Date: 7/3/24 3:15 PM (GMT-05:00) To: Development chatter about sdcc <sdc...@li...> Subject: Re: [sdcc-devel] 8080/8085 support On Tue, 2 Jul 2024, Michael Hawkins wrote:> Because, should I expect to need to contribute to building a simulator> for 8080/85?No, it is included in sdcc already and it includes 8080/8085.Daniel_______________________________________________sdcc-devel mailing lis...@li...https://lists.sourceforge.net/lists/listinfo/sdcc-devel |
From: Benedikt F. <b.f...@gm...> - 2024-07-03 19:40:57
|
Am 03.07.24 um 21:30 schrieb mhawkins.consultant: > Does uCsim rely on assembler mnemonics? Or object code? > > Still trying to figure out if using z80 as core makes sense. > > > > Michael A Hawkins > Mobile: 203-550-5502 > AFAIK, ucsim runs a binary. In my opinion, sm83 (Gameboy) is a bit closer to pure 8080. Creating a fork of that (or Z80) and merely making the output 8080 compatible sounds like a good proof-of-concept step to me. You can then still change the mnemonics if you want to. -- Benedikt |
From: <dan...@un...> - 2024-07-04 07:05:14
|
On Wed, 3 Jul 2024, mhawkins.consultant wrote: > Does uCsim rely on assembler mnemonics? Not at all. It reads hex (or omf) file. > Or object code? No. Although it can read cdb file to pick up symbols. Daniel |
From: Basil H. <ba...@st...> - 2024-07-02 14:27:26
|
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 |
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 |
From: Brian <bw...@va...> - 2024-07-02 15:46:07
|
Michael -- Welcome back!! 1) The original Small-C published in Dr. Dobb's was for the 8080. SDCC will work there , too. https://en.wikipedia.org/wiki/Small-C 2) If you need / want to test on hardware, use an "IMSAI 8080 replica". The IMSAI front panel is implemented by an ESP32 running z80pack. Fortunately, the power demand is less than one amp, so no need for the half-farad filter caps (j/k) in the original power supply!! If you don't have an ADM-3A terminal, you can use its USB-serial connection instead. https://thehighnibble.com/imsai8080/#overview all the best, *brianW ----- Original Message ----- From: "Michael Hawkins" <mha...@gm...> To: "Development chatter about sdcc" <sdc...@li...> Sent: Tuesday, July 2, 2024 6:21:29 AM Subject: [sdcc-devel] 8080/8085 support Hi everyone, Years ago, I was considering jumping in to help/do SDCC support for 8080/8085. Now, I am seriously about to begin doing just that. But before I do, I would like to understand the testing that is done as part of your build processes. And, I seem to recall that there was initial discussion about the limitations of the number of registers in the 8080 that would make it unsuitable for C/SDCC. So my first questions are: 1) Is the 8080/85 considered too primitive to be a successful target for SDCC? Lack of registers? Other whys? 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? Cheers, -- Michael A Hawkins Stamford, CT 06902 USA Mobile: 203-550-5502 _______________________________________________ sdcc-devel mailing list sdc...@li... https://lists.sourceforge.net/lists/listinfo/sdcc-devel |
From: Michael H. <mha...@gm...> - 2024-07-02 19:19:01
|
Is "8080" a valid name for a port? Or perhaps "int80"? Or "intel8080"? And 80C85 would be a command line option/flag to operate under port "intel8080"? Since there is already an assembler but it's not in SDCC at this time, it would seem that doing that would be the first task. I looked at the wiki: https://sourceforge.net/p/sdcc/wiki/Adding%20a%20port/ under "typical parts of a new port" and don't see instructions for doing the assembler task. Where does the assembler exist on the Internet? From where I can begin to get the 8080/85 piece and begin importing into SDCC? -- Michael A Hawkins Stamford, CT 06902 USA Mobile: 203-550-5502 On Tue, 2024-07-02 at 11:25 -0400, Brian wrote: > Michael -- > > Welcome back!! > > 1) The original Small-C published in Dr. Dobb's was for the 8080. > SDCC will work there , too. > https://en.wikipedia.org/wiki/Small-C > > 2) If you need / want to test on hardware, use an "IMSAI 8080 > replica". The IMSAI front panel is implemented by an ESP32 running > z80pack. Fortunately, the power demand is less than one amp, so no > need for the half-farad filter caps (j/k) in the original power > supply!! If you don't have an ADM-3A terminal, you can use its USB- > serial connection instead. > https://thehighnibble.com/imsai8080/#overview > > > all the best, > *brianW > > ----- Original Message ----- > From: "Michael Hawkins" <mha...@gm...> > To: "Development chatter about sdcc" > <sdc...@li...> > Sent: Tuesday, July 2, 2024 6:21:29 AM > Subject: [sdcc-devel] 8080/8085 support > > Hi everyone, > > Years ago, I was considering jumping in to help/do SDCC support for > 8080/8085. Now, I am seriously about to begin doing just that. But > before I do, I would like to understand the testing that is done as > part of your build processes. And, I seem to recall that there was > initial discussion about the limitations of the number of registers > in > the 8080 that would make it unsuitable for C/SDCC. > > So my first questions are: > 1) Is the 8080/85 considered too primitive to be a successful target > for SDCC? Lack of registers? Other whys? > > 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? > > Cheers, > |
From: Eric H. <eri...@ya...> - 2024-07-02 19:53:30
|
I would suggest i8080 as name for the port.8080 and 8085 are binary compatible. Eric Am Dienstag, 2. Juli 2024 um 21:19:32 MESZ hat Michael Hawkins <mha...@gm...> Folgendes geschrieben: Is "8080" a valid name for a port? Or perhaps "int80"? Or "intel8080"? And 80C85 would be a command line option/flag to operate under port "intel8080"? Since there is already an assembler but it's not in SDCC at this time, it would seem that doing that would be the first task. I looked at the wiki: https://sourceforge.net/p/sdcc/wiki/Adding%20a%20port/ under "typical parts of a new port" and don't see instructions for doing the assembler task. Where does the assembler exist on the Internet? From where I can begin to get the 8080/85 piece and begin importing into SDCC? -- Michael A Hawkins Stamford, CT 06902 USA Mobile: 203-550-5502 On Tue, 2024-07-02 at 11:25 -0400, Brian wrote: > Michael -- > > Welcome back!! > > 1) The original Small-C published in Dr. Dobb's was for the 8080. > SDCC will work there , too. > https://en.wikipedia.org/wiki/Small-C > > 2) If you need / want to test on hardware, use an "IMSAI 8080 > replica". The IMSAI front panel is implemented by an ESP32 running > z80pack. Fortunately, the power demand is less than one amp, so no > need for the half-farad filter caps (j/k) in the original power > supply!! If you don't have an ADM-3A terminal, you can use its USB- > serial connection instead. > https://thehighnibble.com/imsai8080/#overview > > > all the best, > *brianW > > ----- Original Message ----- > From: "Michael Hawkins" <mha...@gm...> > To: "Development chatter about sdcc" > <sdc...@li...> > Sent: Tuesday, July 2, 2024 6:21:29 AM > Subject: [sdcc-devel] 8080/8085 support > > Hi everyone, > > Years ago, I was considering jumping in to help/do SDCC support for > 8080/8085. Now, I am seriously about to begin doing just that. But > before I do, I would like to understand the testing that is done as > part of your build processes. And, I seem to recall that there was > initial discussion about the limitations of the number of registers > in > the 8080 that would make it unsuitable for C/SDCC. > > So my first questions are: > 1) Is the 8080/85 considered too primitive to be a successful target > for SDCC? Lack of registers? Other whys? > > 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? > > Cheers, > _______________________________________________ sdcc-devel mailing list sdc...@li... https://lists.sourceforge.net/lists/listinfo/sdcc-devel |
From: Benedikt F. <b.f...@gm...> - 2024-07-02 19:30:36
|
Am 02.07.24 um 21:18 schrieb Michael Hawkins: > Is "8080" a valid name for a port? Or perhaps "int80"? Or "intel8080"? > And 80C85 would be a command line option/flag to operate under port > "intel8080"? > > Since there is already an assembler but it's not in SDCC at this time, > it would seem that doing that would be the first task. > > I looked at the wiki: > https://sourceforge.net/p/sdcc/wiki/Adding%20a%20port/ under "typical > parts of a new port" and don't see instructions for doing the assembler > task. > Where does the assembler exist on the Internet? From where I can begin > to get the 8080/85 piece and begin importing into SDCC? > Intel themselves apparently called the architectures MCS-80 and MCS-85, see https://archive.org/details/Mcs80_85FamilyUsersManual Regarding the ASXXXX assembler, I believe that this is the official website: https://shop-pdp.net/ashtml/asxxxx.php But, as mentioned before, you can probably make your life easier by simply using Zilog's mnemonics and syntax. |
From: Michael H. <mha...@gm...> - 2024-07-02 20:40:52
|
"But, as mentioned before, you can probably make your life easier by simply using Zilog's mnemonics and syntax." I think it's a nice idea to just strip the z80 implementation back to 8080 or 8085 and then add the new instructions that the 80C85 had. The down side though, is that existing assembler would not be reusable. I take it that SDCC passes assembler found inside of source files back to the assembler itself. In which case, taking a large 8080/85 assembler file and inserting it into C source files isn't going to work because the mnenomics are z80 and not 8080. Right? -- Michael A Hawkins Stamford, CT 06902 USA Mobile: 203-550-5502 On Tue, 2024-07-02 at 21:30 +0200, Benedikt Freisen via sdcc-devel wrote: > But, as mentioned before, you can probably make your life easier by > simply using Zilog's mnemonics and syntax. |