Risc-V Bare Metal C Hello World!

Описание к видео Risc-V Bare Metal C Hello World!

I walk through creating a bare-metal hello world C program for the Risc-V architecture and test it using QEMU.

My prior assembly language video that I referred to in this video is here:    • Risc-V Bare Metal Assembler Hello World!  

My github repo with source code: https://github.com/chuckb/riscv-hello...

Inspiration for this was derived from the excellent blog by Tyler Wilcock at: https://twilco.github.io/riscv-from-s...

If you want to know everything about linker script development, try: https://mcyoung.xyz/2021/06/01/linker...

The TI datasheet I referenced is at: https://www.ti.com/lit/ds/symlink/tl1...

One note that I did not mention in the video...some might say why I did not use the ENTRY(_start) clause in the linker. Because it would make no difference in this case. ENTRY just writes to the elf header. Because there is not boot loader, the entry point in the header does not matter. The only thing that matters is the order of the code sections. And because I placed the hello.o before start.o in the linker, unless the KEEP directive is used, listing order will govern.

Комментарии

Информация по комментариям в разработке