* Stage0 Release 0.4.0, M2-Planet Release 1.5.0 and mescc-tools-seed Release 1.2
@ 2020-02-03 10:38 Orians, Jeremiah (DTMB)
2020-02-04 13:14 ` Efraim Flashner
0 siblings, 1 reply; 4+ messages in thread
From: Orians, Jeremiah (DTMB) @ 2020-02-03 10:38 UTC (permalink / raw)
To: info-gnu@gnu.org
Cc: guix-devel@gnu.org, rb-general@lists.reproducible-builds.org,
bootstrappable@freelists.org
Today I am pleased to announce the following releases:
https://savannah.nongnu.org/projects/stage0/
https://github.com/oriansj/stage0
In stage0 we have gained hand written (in assembly) C compilers for:
AMD64 :: cc_amd64.s
Knight :: cc_knight-native.s and cc_knight-posix.s
ARMv7l :: cc_armv7l.s
AArch64 :: cc_aarch64.s
Along with C High level prototypes for all of them
(All of the above was completed in a 4 hour speed run)
https://github.com/oriansj/M2-Planet
In M2-Planet we gained more posix primitives and thanks to recent fuzzing have dropped a considerable number of possible segfaults.
Knight-native gained support for large binaries (2GB)
Oh and to bury the lead a bit.
Deesix single handedly ported AArch64 support into M2-Planet! (up next RISC-V [32 and 64bit])
https://github.com/oriansj/mescc-tools-seed
In mescc-tools-seed we eliminated all binaries (not that there was much anyway)
So you'll have to clone https://github.com/oriansj/bootstrap-seeds if you want a generated 357byte hex0 binary
- Jeremiah
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Stage0 Release 0.4.0, M2-Planet Release 1.5.0 and mescc-tools-seed Release 1.2
2020-02-03 10:38 Stage0 Release 0.4.0, M2-Planet Release 1.5.0 and mescc-tools-seed Release 1.2 Orians, Jeremiah (DTMB)
@ 2020-02-04 13:14 ` Efraim Flashner
2020-02-04 13:42 ` Orians, Jeremiah (DTMB)
2020-02-04 17:22 ` Jan Nieuwenhuizen
0 siblings, 2 replies; 4+ messages in thread
From: Efraim Flashner @ 2020-02-04 13:14 UTC (permalink / raw)
To: Orians, Jeremiah (DTMB)
Cc: guix-devel@gnu.org, rb-general@lists.reproducible-builds.org,
bootstrappable@freelists.org
[-- Attachment #1: Type: text/plain, Size: 1543 bytes --]
On Mon, Feb 03, 2020 at 10:38:41AM +0000, Orians, Jeremiah (DTMB) wrote:
> Today I am pleased to announce the following releases:
>
> https://savannah.nongnu.org/projects/stage0/
> https://github.com/oriansj/stage0
> In stage0 we have gained hand written (in assembly) C compilers for:
> AMD64 :: cc_amd64.s
> Knight :: cc_knight-native.s and cc_knight-posix.s
> ARMv7l :: cc_armv7l.s
> AArch64 :: cc_aarch64.s
> Along with C High level prototypes for all of them
> (All of the above was completed in a 4 hour speed run)
WOW! That is an impressive list. And in 4 hours.
Is there something I can play with on my 32-bit ppc machine to add to
the list?
>
> https://github.com/oriansj/M2-Planet
> In M2-Planet we gained more posix primitives and thanks to recent fuzzing have dropped a considerable number of possible segfaults.
> Knight-native gained support for large binaries (2GB)
> Oh and to bury the lead a bit.
> Deesix single handedly ported AArch64 support into M2-Planet! (up next RISC-V [32 and 64bit])
Congrats!
>
> https://github.com/oriansj/mescc-tools-seed
> In mescc-tools-seed we eliminated all binaries (not that there was much anyway)
> So you'll have to clone https://github.com/oriansj/bootstrap-seeds if you want a generated 357byte hex0 binary
>
> - Jeremiah
>
>
--
Efraim Flashner <efraim@flashner.co.il> אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: Stage0 Release 0.4.0, M2-Planet Release 1.5.0 and mescc-tools-seed Release 1.2
2020-02-04 13:14 ` Efraim Flashner
@ 2020-02-04 13:42 ` Orians, Jeremiah (DTMB)
2020-02-04 17:22 ` Jan Nieuwenhuizen
1 sibling, 0 replies; 4+ messages in thread
From: Orians, Jeremiah (DTMB) @ 2020-02-04 13:42 UTC (permalink / raw)
To: Efraim Flashner
Cc: guix-devel@gnu.org, rb-general@lists.reproducible-builds.org,
bootstrappable@freelists.org
> WOW! That is an impressive list. And in 4 hours.
Really ends the debate about how to bootstrap C compilers in my book
> Is there something I can play with on my 32-bit ppc machine to add to the list?
Well if you are willing to do some testing it is really trivial to get a new architecture into mescc-tools and M2-Planet (I can handle the conversion to cc_* rather quickly)
First you'll want to figure out how the architecture expresses immediates and offsets; hex2 is the place where those architecture specific details are leveraged (https://github.com/oriansj/mescc-tools/blob/master/hex2_linker.c)
(rasm2 and gdb are extremely handy here)
This will give you the answers to hex2 --architecture powerpc32 (or what ever name you want really) --{Big/Little}Endian -f elf-header.hex2 -f test.hex2 -- exec_enable -o binary
Which will generate working binaries for that architecture from hex2 sources
Next you'll want to figure out how the bits of the instructions are actually laid out and M1 definitions are a quick way to get to that quickly (https://github.com/oriansj/mescc-tools/blob/master/M1-macro.c)
This will give you the answers to M1 --architecture powerpc32 (or what ever name you want really) --{Big/Little}Endian -f defs.M1 -f test.M1 -o test.hex2
Which can be passed to hex2 (with the previously created elf-header) and generate a working binary for that architecture.
After that one needs to figure out what M1 defs would be required (This should give you a simple example of what would be required https://github.com/oriansj/stage0/blob/master/stage2/High_level_prototypes/cc_x86/cc_core.c )
Which will convert C code into M1 output which you at this point know what to do with it to get a working binary.
After all of that, one simply takes the M1 strings that are in M2-Planet which we know generate working C code and taking a copy of cc_x86.s, replace the strings, fix the local and argument offsets (change a few type sizes for 64bit targets) and you are done. With a working C compiler for powerpc32 written in assembly.
One trick is after you get the architecture into M2-Planet Is have it build itself for your target instruction set and put that into a file (I used foo1)
Then cat all of the inputs used into another file (I used foo.c)
Here is the instruction I used with knight-native:
M1 --architecture knight-native --BigEndian -f High_level_prototypes/defs -f stage2/cc_knight-native.s -o scratch/cc_knight-native.hex2 && hex2 --architecture knight-native --BigEndian -f scratch/cc_knight-native.hex2 -o scratch/cc_knight-native && ./bin/vm --rom scratch/cc_knight-native --tape_01 foo.c --memory 10M && meld foo1 tape_02
If you need further clarification, I am more than happy to help
Plus there are some wonderful people on #bootstrappable who are able to help you work through ugly details
-Jeremiah
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Stage0 Release 0.4.0, M2-Planet Release 1.5.0 and mescc-tools-seed Release 1.2
2020-02-04 13:14 ` Efraim Flashner
2020-02-04 13:42 ` Orians, Jeremiah (DTMB)
@ 2020-02-04 17:22 ` Jan Nieuwenhuizen
1 sibling, 0 replies; 4+ messages in thread
From: Jan Nieuwenhuizen @ 2020-02-04 17:22 UTC (permalink / raw)
To: Efraim Flashner
Cc: guix-devel@gnu.org, rb-general@lists.reproducible-builds.org,
Orians, Jeremiah (DTMB), bootstrappable@freelists.org
Efraim Flashner writes:
> On Mon, Feb 03, 2020 at 10:38:41AM +0000, Orians, Jeremiah (DTMB) wrote:
>> Today I am pleased to announce the following releases:
>>
>> https://savannah.nongnu.org/projects/stage0/
>> https://github.com/oriansj/stage0
>> In stage0 we have gained hand written (in assembly) C compilers for:
>> AMD64 :: cc_amd64.s
>> Knight :: cc_knight-native.s and cc_knight-posix.s
>> ARMv7l :: cc_armv7l.s
>> AArch64 :: cc_aarch64.s
>> Along with C High level prototypes for all of them
>> (All of the above was completed in a 4 hour speed run)
>
> WOW! That is an impressive list. And in 4 hours.
Congrats on the releases...amazing!
>> https://github.com/oriansj/M2-Planet
>> In M2-Planet we gained more posix primitives and thanks to recent fuzzing have dropped a considerable number of possible segfaults.
>> Knight-native gained support for large binaries (2GB)
>> Oh and to bury the lead a bit.
>> Deesix single handedly ported AArch64 support into M2-Planet! (up next RISC-V [32 and 64bit])
>
> Congrats!
Ooh, that's amazing; very good news!
janneke
--
Jan Nieuwenhuizen <janneke@gnu.org> | GNU LilyPond http://lilypond.org
Freelance IT http://JoyofSource.com | Avatar® http://AvatarAcademy.com
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2020-02-04 17:22 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-02-03 10:38 Stage0 Release 0.4.0, M2-Planet Release 1.5.0 and mescc-tools-seed Release 1.2 Orians, Jeremiah (DTMB)
2020-02-04 13:14 ` Efraim Flashner
2020-02-04 13:42 ` Orians, Jeremiah (DTMB)
2020-02-04 17:22 ` Jan Nieuwenhuizen
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).