DAVlifer
June 7th, 2008, 02:26 PM
I am looking for a compiler/assembler that takes z80 to tms9900. I suspect it is out there as some old programs like a chess game and astrology program were originally in z80/CP/M and then came out in Texas Instruments machines. Any help would be appreciated.
carlsson
June 8th, 2008, 01:03 AM
The Z80 and TMS9900 both are CPUs, so what you're looking for is one of the following:
1. A Z80 simulator/emulator that creates a virtual machine on a TI-99 and lets you execute more or less generic Z80 machine code. I don't know if a such thing exists, or at what speed it would run.
2. A static recompiler that can take the binary Z80 machine code and output a similar program in TMS9900 machine code. It would be about as complex as (1) but possibly more feasible.
3. A skilled human programmer who knows both Z80 and TMS9900 machine code, and can adopt a program mostly by hand. Depending on how different the two CPUs are when it comes to instruction set, registers and so on, the best approach may be to analyze the algorithms and flow of the first program and then write a new program from scratch that will implement in the same algorithms in the best way possible.
Alternatively, your chess and astrology games may have been written in a higher level language such as Basic, Pascal and so on which makes it a bit simpler to port to another computer which has suitable compilers for those languages. However that is only doable if you have the source code; once it is compiled you can't decompile it back to source code.
By the way, the question reminds me about one of the most frequently asked questions in the COMPUTE! magazine: which program were they using to port a listing between VIC, 64, Atari, Apple, IBM and so on? The truthful answer was that they didn't have a ready-made software, but a number of editors and assistant programmers who would convert the games by hand, often trying to stay as close to the original as possible but sometimes improve it if the target machine had better graphics etc.
vBulletin® v3.7.3, Copyright ©2000-2008, Jelsoft Enterprises Ltd.