October 20th, 2024

Computer Organization, free online textbook

The "Computer Organization" e-book by Stephen Marz provides a comprehensive guide on computer organization, covering binary numbers, CPU instructions, digital logic, and RISC-V assembly programming to support student learning.

Read original articleLink Icon
Computer Organization, free online textbook

The "Computer Organization" e-book by Stephen Marz serves as a comprehensive guide to understanding the fundamental concepts of computer organization. It begins with an introduction to the subject, outlining the key elements that will be explored throughout the text. The second chapter focuses on binary numbers and number systems, emphasizing the importance of binary in computer systems due to their Boolean nature. The third chapter delves into CPU instructions, explaining how assembly instructions are converted into machine code. Chapter four examines digital logic, detailing the components that constitute a CPU, including both combinational and sequential logic. The fifth chapter integrates the previous concepts, illustrating how digital logic components and instructions work together to execute tasks. The appendices provide practical resources, including examples of RISC-V assembly programs, advanced programming techniques, and guidance for writing custom RISC-V assembly programs. This e-book is designed to complement course lectures and serves as a valuable resource for students studying computer organization.

- The e-book covers essential topics in computer organization, including binary numbers and CPU instructions.

- It explains the relationship between digital logic components and their functions within a CPU.

- Practical appendices offer examples and guidance for RISC-V assembly programming.

- The content is structured to support course lectures and enhance student learning.

- Stephen Marz is the author and can be contacted for errors or changes.

Link Icon 3 comments
By @johndoe0815 - 6 months
This book by Stephen Marz seems to be a great addition to the Arpaci-Dousseau's "Operating Systems: Three Easy Pieces" (https://pages.cs.wisc.edu/~remzi/OSTEP/).

Stephen also wrote a great blog article series on building your own RISC-V OS in Rust (https://osblog.stephenmarz.com), so I'm really looking forward to reading his computer architecture book (and probably using it in my course).

By @snvzz - 6 months
RISC-V sure has effectively replaced MIPS and ARM in computer science education by now.
By @westurner - 6 months
emu86 emulates x86, ARM, RISC-V, and WASM instruction sets in Python and in Jupyter Notebooks (which can be graded with ottergrader, nbgrader,)

assembler/virtual_machine.py: https://github.com/gcallah/Emu86/blob/master/assembler/virtu... :

- class RISCVMachine(VirtualMachine): https://github.com/gcallah/Emu86/blob/master/assembler/virtu...

- class WASMMachine(VirtualMachine): https://github.com/gcallah/Emu86/blob/master/assembler/virtu...

assembler/RISCV/key_words.py: https://github.com/gcallah/Emu86/blob/master/assembler/RISCV...

assembler/RISCV/arithmetic.py: https://github.com/gcallah/Emu86/blob/master/assembler/RISCV...

simd, avx, X86S, x86-64-v4,

x86-64 > Microarchitecture levels: https://en.wikipedia.org/wiki/X86-64#Microarchitecture_level...

The new x86 Alliance, Intel-AMD x86 ISA overhaul org.

"Show HN: RISC-V Linux Terminal emulated via WASM" (2023) and ARM Tetris: https://news.ycombinator.com/item?id=37286019 https://westurner.github.io/hnlog/#story-37286019

From https://news.ycombinator.com/item?id=37086102 :

> [ Bindiff, Diaphora, Ghidra + GDB, ]

> Category:Instruction_set_listings has x86 but no aarch64 [or RISC-V] https://en.wikipedia.org/wiki/Category:Instruction_set_listi...

> /? jupyter asm [kernel]:

> - "Introduction to Assembly Language Tutorial.ipynb" w/ the emu86 jupyter kernel which shows register state after ops: https://github.com/gcallah/Emu86/blob/master/kernels/Introdu...

> - it looks like emu86 already also supports RISC, MIPS, and WASM but not yet ARM:

> - DeepHorizons/iarm: https://github.com/DeepHorizons/iarm/blob/master/iarm_kernel...

JupyterLite docs > adding other kernels: https://jupyterlite.readthedocs.io/en/latest/howto/configure...