An Introduction to the SIC architecture

SIC/XE Assembly Programs Explained

This chapter describes a few example SIC/XE assembly programs in detail.

Each example has three sections, which should be viewed in order. The first section is the assembly code with minimal comments, like you would see in pre-written programs or would write yourself. The second section is the same assembly code, but commented line by line with what each instruction does and possibly some extra information. The last section explains what the program does and describes any additional specifics that might be relevant.

The recommended approach to reading this chapter is to read the first section of each example and try to understand what the code does by yourself. With practice you can remember what each instruction does, but you can always look at the Instruction Set or Cheatsheet side-by-side with the example.

If you think you understand what the program does, you can immediately skip to the explanation to see if you were correct, otherwise see the second section for a few hints.

Example 1

Assembly

TODO

Assembly with comments

TODO

Explanation

TODO