David Given [Wed, 22 May 2013 08:47:22 +0000 (09:47 +0100)]
Build the Raspberry Pi code.
--HG--
branch : dtrg-videocore
David Given [Tue, 21 May 2013 23:52:58 +0000 (00:52 +0100)]
More typo fixes.
--HG--
branch : dtrg-videocore
David Given [Tue, 21 May 2013 23:44:04 +0000 (00:44 +0100)]
Typo fixes.
--HG--
branch : dtrg-videocore
David Given [Tue, 21 May 2013 23:16:59 +0000 (00:16 +0100)]
Adjust bootstrap code to build kernels that work with the mailbox test app.
--HG--
branch : dtrg-videocore
David Given [Tue, 21 May 2013 23:16:16 +0000 (00:16 +0100)]
Fix signedness problem that was showing up on ARM.
--HG--
branch : dtrg-videocore
David Given [Tue, 21 May 2013 22:17:30 +0000 (23:17 +0100)]
Reworked VC4 relocations and some of the instruction encoding to be actually correct. Now generating what could be real code!
--HG--
branch : dtrg-videocore
David Given [Tue, 21 May 2013 19:05:26 +0000 (20:05 +0100)]
Now compiles (incorrectly) the entire libc, libpc, libm2 and libbasic!
--HG--
branch : dtrg-videocore
David Given [Tue, 21 May 2013 18:18:11 +0000 (19:18 +0100)]
Allow platforms to specify size of long double; seperate alignment from size.
--HG--
branch : dtrg-videocore
David Given [Tue, 21 May 2013 17:16:30 +0000 (18:16 +0100)]
Lots more opcodes including float support. Define float and double to be the
same thing (as the VC4 seems not to have double-precision float support).
--HG--
branch : dtrg-videocore
David Given [Mon, 20 May 2013 22:27:45 +0000 (23:27 +0100)]
Add a lot more opcodes.
--HG--
branch : dtrg-videocore
David Given [Mon, 20 May 2013 22:27:31 +0000 (23:27 +0100)]
Fix typo.
--HG--
branch : dtrg-videocore
David Given [Mon, 20 May 2013 21:41:27 +0000 (22:41 +0100)]
Remember to clear ackflags on reset.
--HG--
branch : dtrg-videocore
David Given [Mon, 20 May 2013 21:35:12 +0000 (22:35 +0100)]
Major revamp to simplify and use 2op instructions. Better code. Now looks like it may work one day.
--HG--
branch : dtrg-videocore
David Given [Mon, 20 May 2013 18:56:33 +0000 (19:56 +0100)]
Add lea instruction. Fix dependency issues.
--HG--
branch : dtrg-videocore
David Given [Sun, 19 May 2013 22:34:42 +0000 (23:34 +0100)]
Push/pop are the right way round. Don't corrup short-form ALU instructions. Correct encoding of push/pop register ranges.
--HG--
branch : dtrg-videocore
David Given [Sun, 19 May 2013 22:33:42 +0000 (23:33 +0100)]
First steps towards a code generator.
--HG--
branch : dtrg-videocore
David Given [Sun, 19 May 2013 22:33:29 +0000 (23:33 +0100)]
Added skeleton bootstrap code.
--HG--
branch : dtrg-videocore
rename : plat/pc86/boot.s => plat/rpi/boot.s
David Given [Sun, 19 May 2013 22:19:10 +0000 (23:19 +0100)]
Correctly emit constants in some ALU instructions.
--HG--
branch : dtrg-videocore
David Given [Sun, 19 May 2013 22:18:36 +0000 (23:18 +0100)]
Fix warning.
--HG--
branch : dtrg-videocore
David Given [Sun, 19 May 2013 17:40:19 +0000 (18:40 +0100)]
Add compare-and-branch instructions.
--HG--
branch : dtrg-videocore
David Given [Sun, 19 May 2013 12:03:53 +0000 (13:03 +0100)]
Added memory operations that work on fixed up addresses.
--HG--
branch : dtrg-videocore
David Given [Sun, 19 May 2013 11:39:35 +0000 (12:39 +0100)]
Add register offset and postincrement memory operations.
--HG--
branch : dtrg-videocore
David Given [Sat, 18 May 2013 23:56:56 +0000 (00:56 +0100)]
Add most vanilla memory load/store instructions.
--HG--
branch : dtrg-videocore
David Given [Fri, 17 May 2013 22:30:49 +0000 (23:30 +0100)]
Add a whole bunch of VC4 opcodes.
--HG--
branch : dtrg-videocore
David Given [Fri, 17 May 2013 21:40:50 +0000 (22:40 +0100)]
Add special relocation type for VC4 jump instructions.
--HG--
branch : dtrg-videocore
David Given [Fri, 17 May 2013 14:28:04 +0000 (15:28 +0100)]
Merge fixes from trunk.
--HG--
branch : dtrg-videocore
David Given [Thu, 16 May 2013 23:04:54 +0000 (00:04 +0100)]
Fix warning.
David Given [Thu, 16 May 2013 23:04:37 +0000 (00:04 +0100)]
Dependency fixes.
David Given [Thu, 16 May 2013 23:03:38 +0000 (00:03 +0100)]
Skeleton of VideoCore IV support for the Raspberry Pi.
--HG--
branch : dtrg-videocore
rename : mach/powerpc/as/.distr => mach/vc4/as/.distr
rename : mach/powerpc/as/mach0.c => mach/vc4/as/mach0.c
rename : mach/powerpc/as/mach1.c => mach/vc4/as/mach1.c
rename : mach/powerpc/as/mach2.c => mach/vc4/as/mach2.c
rename : mach/powerpc/as/mach3.c => mach/vc4/as/mach3.c
rename : mach/powerpc/as/mach4.c => mach/vc4/as/mach4.c
rename : mach/powerpc/as/mach5.c => mach/vc4/as/mach5.c
rename : mach/i86/build.mk => mach/vc4/build.mk
rename : mach/powerpc/libem/powerpc.h => mach/vc4/libem/videocore.h
rename : mach/i86/libend/.distr => mach/vc4/libend/.distr
rename : mach/i86/libend/edata.s => mach/vc4/libend/edata.s
rename : mach/i86/libend/em_end.s => mach/vc4/libend/em_end.s
rename : mach/i86/libend/end.s => mach/vc4/libend/end.s
rename : mach/i86/libend/etext.s => mach/vc4/libend/etext.s
rename : mach/powerpc/ncg/.distr => mach/vc4/ncg/.distr
rename : mach/powerpc/ncg/mach.c => mach/vc4/ncg/mach.c
rename : mach/powerpc/ncg/mach.h => mach/vc4/ncg/mach.h
rename : mach/powerpc/ncg/table => mach/vc4/ncg/table
rename : plat/pc86/descr => plat/rpi/descr
David Given [Thu, 16 May 2013 21:02:59 +0000 (22:02 +0100)]
Fix buffer overrun looking up type information for op_lab pseudoops (as
they're not EM opcodes, we shouldn't look them up in em_flags!).
David Given [Thu, 16 May 2013 21:02:00 +0000 (22:02 +0100)]
Correctly generate dependency information.
David Given [Thu, 16 May 2013 13:33:19 +0000 (14:33 +0100)]
Merge in build system changes.
David Given [Thu, 16 May 2013 13:20:58 +0000 (14:20 +0100)]
A few last build tweaks.
--HG--
branch : dtrg-buildsystem
David Given [Wed, 15 May 2013 22:46:15 +0000 (23:46 +0100)]
Update distribution files.
--HG--
branch : dtrg-buildsystem
David Given [Wed, 15 May 2013 22:12:05 +0000 (23:12 +0100)]
Now describe the make-based build system in the README.
--HG--
branch : dtrg-buildsystem
David Given [Wed, 15 May 2013 21:09:28 +0000 (22:09 +0100)]
Fix build error in opt which was causing all code, everywhere, to be broken.
Remember to build opt2 too.
--HG--
branch : dtrg-buildsystem
David Given [Wed, 15 May 2013 20:14:06 +0000 (21:14 +0100)]
Build ego.
--HG--
branch : dtrg-buildsystem
rename : util/arch/build.mk => util/ego/build.mk
David Given [Tue, 14 May 2013 21:24:38 +0000 (22:24 +0100)]
Modula-2 now works.
--HG--
branch : dtrg-buildsystem
rename : lang/pc/build.mk => lang/m2/build.mk
rename : lang/pc/libpc/build.mk => lang/m2/comp/build.mk
rename : lang/pc/libpc/build.mk => lang/m2/libm2/build.mk
David Given [Tue, 14 May 2013 19:47:04 +0000 (20:47 +0100)]
Pascal compiler now runs.
--HG--
branch : dtrg-buildsystem
rename : lang/basic/build.mk => lang/pc/build.mk
rename : lang/cem/cemcom.ansi/build.mk => lang/pc/comp/build.mk
rename : lang/basic/lib/build.mk => lang/pc/libpc/build.mk
David Given [Tue, 14 May 2013 17:01:38 +0000 (18:01 +0100)]
Basic compiler now runs.
--HG--
branch : dtrg-buildsystem
David Given [Tue, 14 May 2013 15:11:29 +0000 (16:11 +0100)]
Build the Basic run-time library (after some modernisation).
--HG--
branch : dtrg-buildsystem
David Given [Tue, 14 May 2013 13:55:29 +0000 (14:55 +0100)]
Add missing dependency.
--HG--
branch : dtrg-buildsystem
David Given [Mon, 13 May 2013 22:26:15 +0000 (23:26 +0100)]
Top, topgen, aelflod. Moved the libraries back into the platform-specific
directories --- wrangling descr files was too hard. C programs can be built
for cpm, pc86, linux386, linux68k!
--HG--
branch : dtrg-buildsystem
rename : util/ack/build.mk => util/led/build.mk
rename : util/LLgen/build.mk => util/topgen/build.mk
David Given [Mon, 13 May 2013 21:12:46 +0000 (22:12 +0100)]
Split off some of the platform-independent stuff (such as as and ncg).
--HG--
branch : dtrg-buildsystem
rename : plat/pc86/build.mk => mach/i386/build.mk
rename : plat/pc86/build.mk => mach/i80/build.mk
rename : plat/pc86/build.mk => mach/i86/build.mk
rename : plat/pc86/build.mk => mach/m68020/build.mk
rename : plat/pc86/build.mk => mach/powerpc/build.mk
David Given [Mon, 13 May 2013 11:37:27 +0000 (12:37 +0100)]
Merge updates from trunk.
--HG--
branch : dtrg-buildsystem
David Given [Mon, 13 May 2013 10:14:10 +0000 (11:14 +0100)]
Fix typo.
--HG--
branch : dtrg-buildsystem
David Given [Sun, 12 May 2013 22:51:55 +0000 (23:51 +0100)]
Made a start on building the runtimes for each platform and language; the
Linuxes all build.
--HG--
branch : dtrg-buildsystem
rename : modules/src/em_mes/build.mk => modules/src/read_em/build.mk
rename : plat/pc86/build.mk => plat/linux386/build.mk
rename : plat/pc86/build.mk => plat/linux68k/build.mk
rename : plat/pc86/build.mk => plat/linuxppc/build.mk
rename : util/ack/build.mk => util/misc/build.mk
David Given [Sun, 12 May 2013 19:45:55 +0000 (20:45 +0100)]
First milestone of replacing the build system.
--HG--
branch : dtrg-buildsystem
rename : lang/cem/cpp.ansi/Parameters => lang/cem/cpp.ansi/parameters.h
David Given [Fri, 10 May 2013 11:04:21 +0000 (12:04 +0100)]
Change fatal() and error() to use varargs.
David Given [Thu, 9 May 2013 17:14:16 +0000 (18:14 +0100)]
Merge changes from branch: linux68k platform, linuxppc platform (partially
working), and miscellaneous changes to support these.
David Given [Thu, 9 May 2013 14:54:23 +0000 (15:54 +0100)]
Apply George Koehler's aelflod fix for generating non-EM_386 binaries.
Adjust platforms to use it. Fix some bugs in the linux386 platform.
--HG--
branch : dtrg-experimental-powerpc
David Given [Thu, 9 May 2013 10:20:36 +0000 (11:20 +0100)]
Properly error out if something goes wrong rather than ploughing ahead
anyway.
--HG--
branch : dtrg-experimental-powerpc
David Given [Wed, 8 May 2013 23:58:35 +0000 (00:58 +0100)]
Add pmfile for m68020 libend.
--HG--
branch : dtrg-experimental-powerpc
David Given [Wed, 8 May 2013 23:57:47 +0000 (00:57 +0100)]
Add pmfile for m68020 libem.
--HG--
branch : dtrg-experimental-powerpc
David Given [Wed, 8 May 2013 23:56:10 +0000 (00:56 +0100)]
Add missing linux68k platform and liblinux support library.
--HG--
branch : dtrg-experimental-powerpc
David Given [Tue, 7 May 2013 23:48:48 +0000 (00:48 +0100)]
Check in incomplete Linux PowerPC and M68K work.
--HG--
branch : dtrg-experimental-powerpc
George Koehler [Wed, 24 Apr 2013 23:57:23 +0000 (19:57 -0400)]
Some fixes for aelflod and aslod.
Copy rhead() and rsect() from aslod to aelflod, so aelflod can work
for machine with 64-bit long.
In aelflod, fix ELF header so file(1) no longer reports "corrupted
section header size".
David Given [Fri, 14 Dec 2012 11:56:21 +0000 (11:56 +0000)]
Back out erroneous change.
George Koehler [Wed, 24 Oct 2012 17:44:50 +0000 (13:44 -0400)]
Prevent segfault when trying to print an error message.
Use <stdarg.h> to pass arguments correctly, as ack/util/util.c
already uses <stdarg.h> the same way.
David Given [Thu, 27 Sep 2012 10:32:40 +0000 (11:32 +0100)]
Change from using platform-specific types to stdint platform-independent types
when reading the structure header.
David Given [Thu, 27 Sep 2012 09:54:41 +0000 (10:54 +0100)]
Change to use stdint's implementation independent types rather than short and
long (which vary depending on whether you're on a 64-bit system or not).
George Koehler [Sun, 23 Sep 2012 19:31:16 +0000 (15:31 -0400)]
Merge deletion of many undead files.
George Koehler [Sun, 23 Sep 2012 18:43:22 +0000 (14:43 -0400)]
Allow pc86 bootloader to boot from more floppy drives.
When the bootloader probes the drive geometry, the BIOS can clobber the
es register. If this happens, the bootloader loads the program to the
wrong address, and jumps off the code. This happens with an emulated
floppy drive in Bochs or QEMU, but not with an emulated hard disk.
George Koehler [Sat, 22 Sep 2012 02:51:12 +0000 (22:51 -0400)]
Prevent division by zero in aslod.
rhead() and rsect() had assumed sizeof(long) == 4, but OpenBSD/amd64
has sizeof(long) == 8. The problem revealed itself when sect->os_lign
became zero, and align() divided by zero.
George Koehler [Fri, 21 Sep 2012 02:26:32 +0000 (22:26 -0400)]
Delete 689 undead files.
These files "magically reappeared" after the conversion from CVS to
Mercurial. The old CVS repository deleted these files but did not
record *when* it deleted these files. The conversion resurrected these
files because they have no history of deletion. These files were
probably deleted before year 1995. The CVS repository begins to record
deletions around 1995.
These files may still appear in older revisions of this Mercurial
repository, when they should already be deleted. There is no way to fix
this, because the CVS repository provides no dates of deletion.
See http://sourceforge.net/mailarchive/message.php?msg_id=
29823032
George Koehler [Thu, 20 Sep 2012 03:39:51 +0000 (23:39 -0400)]
*Again* fix fit16i() for systems with 64-bit long.
I already did this in
abebf1586c06, but I edited the wrong file. Then
in
edddc6b7cd17, I deleted that file.
By fixing fit16i(), I can now compile ACK for OpenBSD/amd64.
George Koehler [Mon, 17 Sep 2012 20:04:55 +0000 (16:04 -0400)]
Delete old and unused files from modules/src/em_code
George Koehler [Sun, 16 Sep 2012 23:57:07 +0000 (19:57 -0400)]
Fix fit16i() for systems with 64-bit long.
(long)0xFFFF8000 had expanded to 0x00000000FFFF8000.
With (long)(-0x8000), the compiler now extends the negative sign.
George Koehler [Fri, 7 Sep 2012 20:28:10 +0000 (16:28 -0400)]
Fix more functions in util/ack for 64-bit hosts.
This continues the fix from changeset
aabde0589450. We must use
va_list to forward the arguments, because some of the arguments might
be 64-bit pointers. A pointer does not fit in an int.
George Koehler [Fri, 7 Sep 2012 19:53:13 +0000 (15:53 -0400)]
Fix cemcom.ansi for 64-bit hosts.
Hosts with sizeof(arith) == sizeof(long) == 8 need to set full_mask[1]
through full_mask[8]. Because MAXSIZE == 8, we only had full_mask[0]
through full_mask[7]. This fix declares arith full_mask[MAXSIZE + 1]
and prevents a fatal error: "array full_mask too small for this machine"
David Given [Mon, 27 Feb 2012 22:36:36 +0000 (22:36 +0000)]
Fix a 64-bitness issue (removed some untyped K&R C code that assumed ints
and pointers were the same size).
Ceriel Jacobs [Wed, 15 Jun 2011 09:13:48 +0000 (11:13 +0200)]
Added atol() that ignores overflow, so that unsigned long constants are dealt with properly
Ceriel Jacobs [Wed, 15 Jun 2011 08:56:58 +0000 (10:56 +0200)]
Fixed CFU
cjhjacobs [Wed, 18 May 2011 17:19:19 +0000 (19:19 +0200)]
Fixed bug reported on tack-devel mailing list on 20-3-2011
David Given [Sun, 20 Mar 2011 20:47:10 +0000 (20:47 +0000)]
Removed file that the CVS conversion procedure left in (when it shouldn't have).
cvs2hg [Fri, 11 Feb 2011 00:51:45 +0000 (00:51 +0000)]
convert CVS tags
dtrg [Sat, 2 Oct 2010 21:52:29 +0000 (21:52 +0000)]
Replaced dis and new with modern implementations donated by erik@backerud.se.
dtrg [Sat, 2 Oct 2010 21:51:40 +0000 (21:51 +0000)]
Call the correct kill() and getpid() syscalls rather than _kill() and _getpid().
dtrg [Mon, 27 Sep 2010 20:47:32 +0000 (20:47 +0000)]
Now call creat() and open() instead of _creat() and _open().
dtrg [Mon, 27 Sep 2010 20:44:49 +0000 (20:44 +0000)]
Added support for remove() and unlink().
dtrg [Wed, 1 Sep 2010 19:55:15 +0000 (19:55 +0000)]
Fixed very old bug where Streams.GetStreamPosition would return the wrong position --- thanks to Jan Verhoeven for finding this.
dtrg [Fri, 20 Aug 2010 19:27:09 +0000 (19:27 +0000)]
Fixed definitions of O_* flags.
dtrg [Mon, 9 Aug 2010 22:47:33 +0000 (22:47 +0000)]
Remove references to using-machine-name-for-compiler, as we don't do that any more.
dtrg [Fri, 6 Aug 2010 17:06:31 +0000 (17:06 +0000)]
Changed to actually work. (On modern Linux systems the old version just
crashes. On old Linux systems it apparently only worked by accident.)
dtrg [Fri, 6 Aug 2010 17:02:16 +0000 (17:02 +0000)]
Flush stdout before prompting the user for input.
dtrg [Thu, 5 Aug 2010 22:23:34 +0000 (22:23 +0000)]
Flush output stream before waiting for user input.
cvs2hg [Wed, 4 Aug 2010 18:04:08 +0000 (18:04 +0000)]
fixup commit for tag 'release-6-0-pre-4'
dtrg [Wed, 4 Aug 2010 18:04:07 +0000 (18:04 +0000)]
Forgot to update version number.
dtrg [Wed, 4 Aug 2010 18:01:12 +0000 (18:01 +0000)]
Updated for 6.0pre4.
dtrg [Wed, 4 Aug 2010 17:59:40 +0000 (17:59 +0000)]
Fixed typo.
dtrg [Sun, 1 Aug 2010 10:36:01 +0000 (10:36 +0000)]
Prevent build failure on modern Bisons (which are more picky than the old yacc this was written for).
dtrg [Sun, 1 Aug 2010 10:35:33 +0000 (10:35 +0000)]
Invoke genfiles explicitly with sh --- CVS doesn't store executable bits.
dtrg [Sun, 1 Aug 2010 10:35:04 +0000 (10:35 +0000)]
Renamed 'switch' variable to avoid conflict with a keyword in modern awks.
dtrg [Sun, 1 Aug 2010 10:34:27 +0000 (10:34 +0000)]
Renamed getline() to getln() to avoid conflict with glibc's version.
dtrg [Thu, 20 Mar 2008 23:20:08 +0000 (23:20 +0000)]
Added a very-nearly-noop peephole optimiser for Z80.
dtrg [Thu, 20 Mar 2008 22:50:50 +0000 (22:50 +0000)]
Properly handles files ending in a partial line.
dtrg [Fri, 2 Nov 2007 18:56:58 +0000 (18:56 +0000)]
Archival checkin (semi-working code).
cvs2hg [Sun, 29 Apr 2007 23:09:25 +0000 (23:09 +0000)]
fixup commit for tag 'release-6-0-pre-3'
dtrg [Sun, 29 Apr 2007 23:09:24 +0000 (23:09 +0000)]
Configured distr system for the 6.0pre3 release.
dtrg [Sun, 29 Apr 2007 23:03:24 +0000 (23:03 +0000)]
Cleaned up a bit and made work with the new platform architecture.