Commit Graph

292 Commits

Author SHA1 Message Date
Jeremiah Orians d9504e3872
Allow M2-Planet to support larger outputs without hitting a segfault 2020-12-19 06:50:11 -05:00
Sanne Wouda 968fdfea65 AArch64 support for unsigned comparison 2020-12-17 00:01:17 +00:00
Jeremiah Orians e5befc4fee
armv7l support for unsigned comparisons 2020-12-15 21:09:26 -05:00
Jeremiah Orians f2cae3d501
AMD64 support for unsigned comparisons 2020-12-15 20:28:04 -05:00
Jeremiah Orians eaf3861954
Fix failing tests on x86 2020-12-15 19:02:32 -05:00
Jeremiah Orians 132e685f97
Fix x86 behavior on unsigned compares 2020-12-15 17:46:45 -05:00
Jeremiah Orians 9da48c5ece
match gcc behavior in regards to if(-1 > 0) 2020-12-15 07:24:07 -05:00
Jeremiah Orians 5c22aac02d
Change knight-posix HEAP behavior and leverage better relational choices for knight-posix 2020-12-15 06:02:38 -05:00
Jeremiah 196c66d19e
Merge pull request #7 from snnw/aarch64-fix
[AArch64] Use arithmetic right shift for signed
2020-12-05 10:09:50 -05:00
Sanne Wouda a63b8837c0 [AArch64] Use arithmetic right shift for signed
- as discussed with deesix, this is the proper fix
- the test1000 checksum changes as it uses the M2-Planet source as input
2020-12-05 14:59:16 +00:00
Jeremiah d34ea502cc
Merge pull request #6 from snnw/aarch64-fix
[AArch64] Fix LSEEK syscall number
2020-12-04 21:29:02 -05:00
Sanne Wouda 58b563435b [AArch64] Use arithmetic right shift
- fixes a test failure if hex2 was compiled with M2-Planet
2020-12-04 19:37:29 +00:00
Sanne Wouda 624a5ac92d [AArch64] Fix LSEEK syscall number 2020-12-04 15:45:06 +00:00
Jeremiah Orians 0615223052
Broke tests into processor specific sets and updated the M1 test 2020-12-01 22:24:36 -05:00
Jeremiah Orians 93e8b0c0a4
Removed obsolete reference to bootstrap directory 2020-11-20 05:34:11 -05:00
Jeremiah Orians e3ca15c731
Preparing for next release 2020-11-15 20:46:26 -05:00
Jeremiah Orians a5bc08b23f
Release 1.7.0 2020-11-15 20:43:58 -05:00
Jeremiah Orians 1975d88581
Fix GCC 10 compatibility issue 2020-11-15 20:28:33 -05:00
Jeremiah Orians 67dbbbdcfc
Enable support for C multi-strings 2020-11-15 18:58:25 -05:00
Jeremiah Orians 57264eb157
Catch potential segfaulting behavior in generated binaries 2020-11-08 21:13:12 -05:00
Jeremiah Orians 39915de931
harmonize integer behavior when reading strings 2020-10-17 13:50:25 -04:00
Jeremiah Orians c4a636c99d
Fix shift behavior to better match C standard 2020-10-16 22:07:06 -04:00
Jeremiah Orians e9da9c802e
make cc_* compatible 2020-10-16 19:29:38 -04:00
nimaje 52114585bf
fix malloc to accept FreeBSD's behavior and fix failing binaries 2020-10-16 17:26:39 -04:00
nimaje 028bdaf951
Update ELF headers and sha256 function to better support FreeBSD 2020-10-16 12:00:42 -04:00
Jeremiah Orians 87672ddfdb
Release 1.6.0 2020-04-30 22:35:22 -04:00
deesix 205c383c5f lib: fflush stub
Paraphrasing OriansJ's IRC message while working on kaem:

GCC needs fflush(stdout) to get matching behavior, as M2-Planet doesn't
buffer. I guess we will need to make a fflush function (it'll do nothing
but return 0).
2020-03-01 18:55:32 +01:00
Jeremiah Orians 09783ac089
Fixed continue behavior and added a test to verify correct behavior 2020-02-28 18:48:58 -05:00
Jeremiah Orians 6343e48600
Major relocation of tests to better structure for future additions 2020-02-28 18:27:12 -05:00
deesix b2ece54864 aarch64: do not generate a wasteful stack anymore
Until now, each element on the compiled program stack was 128 bits long,
half of them unused because only one 64 bits value was stored.

Now it's 64 bits long, so we don't waste all that memory.

We workaround the architectural alignment restriction of the SP register by
using a free regular register. X18 is for platform use so it seems a good
candidate for this task.

At _start we copy the value of SP into X18. SP is not used anymore. When a
definition refers to SP it doesn't mean it literaly now, because here we
redefine (without renaming) the involved M1 macro definitions to operate
on X18 (easier transition; abstraction). INIT_SP is introduced.

The function arguments are passed via stack, so the offset from the Base
Pointer ("depth") to each of them is different now. Changes both to
compiler code (cc_core.c) and libc reflect that the arguments are 8 bytes
(instead of 16 bytes) apart now. Note that SUB_X0_32 and SUB_X0_48 are
removed, because we only need 8, 16 and 24 bytes subtraction to reach the
arguments from asm libc functions. SUB_X0_8 and SUB_X0_24 are introduced.
2020-02-08 00:16:54 +01:00
deesix b2b1e13b03 aarch64: test27 links to the usual 0x400000 base address 2020-02-05 13:20:58 +01:00
Jeremiah Orians aad1198faf
Revised tests to include dwarf stubs 2020-02-01 17:50:26 -05:00
Jeremiah Orians 1f709f3ff1
Merge branch 'master' of github.com:oriansj/M2-Planet 2020-02-01 17:23:20 -05:00
Jeremiah Orians aa96bd22fa
Preparing for next release cycle 2020-02-01 17:22:38 -05:00
Jeremiah f0b1f50c2c
Merge pull request #5 from fosslinux/chdir-tests
Add chdir family and getcwd family tests
2020-02-01 17:20:52 -05:00
fosslinux 831de6bc4a
Update kaem test to new kaem.c 2020-02-02 09:18:27 +11:00
fosslinux 510d4203ec
Add chdir family and getcwd family tests 2020-02-02 09:11:06 +11:00
Jeremiah Orians 71062011cd
Release 1.5.0 2020-02-01 16:21:10 -05:00
Jeremiah Orians 24829bee3c
Merge remote-tracking branch 'deesix/aarch64' 2020-02-01 15:40:16 -05:00
deesix 4db378437e aarch64: doc and thanks :)
Thanks to Hagfish for proofreading this documentation.

My deepest thanks to Jeremiah Orians for supporting me during the
development of this patch series. Your wisdom and patience is greatly
appreciated.

Thanks to the rest of the #bootstrappable family.

All errors left are mine.
2020-02-01 21:23:49 +01:00
deesix 7dc280a10d aarch64: tests 2020-02-01 21:23:49 +01:00
deesix fa524bdce3 aarch64: libc 2020-02-01 21:23:49 +01:00
deesix fbc2bf3333 aarch64: statement 2020-02-01 21:23:49 +01:00
deesix 803cf4ffa3 aarch64: flow control 2020-02-01 21:23:49 +01:00
deesix ebb0e4a3f9 aarch64: expression 2020-02-01 21:23:49 +01:00
deesix c32cb92daa aarch64: arithmetic, relational and bitwise expressions 2020-02-01 21:23:49 +01:00
deesix 39936d81cb aarch64: primary, postfix and unary expressions 2020-02-01 21:23:49 +01:00
deesix b581244df0 aarch64: load of function, constant, global and variable 2020-02-01 21:23:49 +01:00
deesix 02bac66940 aarch64: function, function call, arguments, locals and return 2020-02-01 21:23:49 +01:00
deesix 0737a2acf0 aarch64: common recursion 2020-02-01 21:23:49 +01:00