Replies: 8 comments
-
Most of the version 6 version is working. Formal releases basically stopped being a thing because they're annoying and not very useful --- you're recommended to just use head instead. I need to get autobuild releases working. Development does still happen, slowly, based on what people are interested in. (I've been trying to come up with a modernised code generator but keep running into register allocation problems...) For eight-bit systems, the 6800, 8080 and Z80 code generators work pretty well. There is a 6502 code generator but it's hasn't seen much love and may in fact not be ported from 5.5. What you get is a complete cross-compilation toolchain including compilers, assembler and linker. Code generation quality is adequate for CISC memory machine systems but the old ncg code generator doesn't get on well with register-centric systems. For Windows... it builds on MSYS for MINGW, so you should be able to use the resulting binaries without MSYS installed. But I haven't tried this. The 5.5 version still works fine, but it's an absolute pig to build and the set of available targets doesn't really cover anything around today. Like, there's no Linux target. I do see Minix, Xenix and some 68000-based SunOS targets, though! |
Beta Was this translation helpful? Give feedback.
-
Thanks. That sounds promising. Does the 6800 generator include the 6809 (as used in the Dragon 32/64)? Are there configuration files for specific computers? A Sinclair Spectrum 48 doesn't have a lot in common with an MSX, for example. Does TACK still include an interpreter and virtual machine in the toolchain? Are all the front end languages available again? MSYS would be a better option for me than WSL, so that's good news. My installation of WSL2 currently throws up a lot of warnings when I use it, possibly because I chose Debian instead of Ubuntu or maybe because I use UK English as the default instead of US English. Compiler support for modern targets is not a high priority for me as there are other compilers that could be used instead. |
Beta Was this translation helpful? Give feedback.
-
I beg your pardon, there's no 6800 support (other than the assemblers). I was getting the ACK confused with another compiler. The 6809 should be reasonably easy to add a code generator for as it's pretty sane. I also notice that the Z80 backend hasn't had any exercise for a while. The compiler distinguishes between architectures and platforms --- you have to build for a specific platform. Architectures are here: https://github.com/davidgiven/ack/tree/default/mach Platforms are here: https://github.com/davidgiven/ack/tree/default/plat Each platform contains the startup code, system call library, libc configuration, etc. You can also havee specialised code generators per platform. For example, the CP/M platform uses a customised 8080 code generator which uses rst helpers a lot to make the code smaller. So adding support for, e.g. the Spectrum would be easy; adding support for the ZX81 would require specialising the code generator not to use the index registers. See https://github.com/davidgiven/ack/tree/default/plat/pc86 for a minimal example which produces PC bootable floppy disk images. The emulator does still exist, along with a 16-bit platform targeting it. 32 bit is possible but nobody's asked for it yet. Regarding the warnings... that's actually normal. A lot of the code base is immensely old and is in K&R, which modern compilers will compile, but they're not happy about it. |
Beta Was this translation helpful? Give feedback.
-
The files at https://github.com/davidgiven/ack/tree/default/mach/6809 are not complete enough for the 6809? Are there any existing 8-bit home computer platforms implemented? I'll need to learn as I go along and I'm not sure a floppy disk PC is going to have much in common with a tape-based Spectrum. I'm not looking for anything 32-bit either. There are other tools for compiling C, Pascal etc. to modern machines. The WSL2 warnings I mentioned are from compiling and/or running almost anything. I haven't tried installing ACK yet as I'm still trying to discover how much time and effort it would need compared with using something like CROSS-LIB. |
Beta Was this translation helpful? Give feedback.
-
Yeah, the 6809 support is just the assembler. For existing 8-bits, I think the only one currently implemented is CP/M using the 8080 code generator (old school CP/M). AFAIK the ACK is the only current optimising compiler which supports the 8080; it's the compiler CROSS-LIB uses. I'd be interested to add support for the Spectrum, as the Z80 code generator needs some exercise. |
Beta Was this translation helpful? Give feedback.
-
If you could add at least one tape-based 8-bit system that I could use as a template, that would be very helpful. |
Beta Was this translation helpful? Give feedback.
-
I got the Z80 code generator working with a compiling but completely untested ZX Spectrum target. (It just produces binaries which load at 0x4000, and the only system call is rst 0x10, and even that may not even work.) So... turns out that the Z80 code generator is actually a generation 1 code generator (called cg), rather than a generation 2 code generator (ncg). cg is extremely simple and produces very naive code --- optimised this isn't. But it does produce code. cg isn't very well understood because ncg is better; it'd be interesting to just do a search-and-replace adaptation of the 8080 ncg generator to produce Z80 code and see if it's any better than the Z80 cg generator. See https://github.com/davidgiven/ack/blob/default/mach/i80/ncg/table If you want to try it, it's here: https://github.com/davidgiven/ack/tree/dtrg-spectrum Compile stuff with |
Beta Was this translation helpful? Give feedback.
-
Thanks. I will brush up on downloading via Git in MSYS2 and see how it compares with using z88dk to compile C files for the Speccy. |
Beta Was this translation helpful? Give feedback.
-
I've looked at The Amsterdam Compiler Kit several times, but I've never been sure how much of it is still working after the revamp.
It doesn't help that the most recent release is from almost 6 years ago.
Which parts of TACK can currently be used in a compiler toolchain? (I'm especially interested in compiling for 8-bit platforms.)
Is it still only usable on Linux or is Windows now an option? If it can be used on Windows, is that in native mode or only via MSYS, Cygwin or WSL?
Is version 5.5 still a viable option or only the 6.0 prerelease?
Beta Was this translation helpful? Give feedback.
All reactions