CSCI 250 Assembly Language

(the only low-level language course offered by the CS division)
MASM MASM Help Using MASM Tutorial MIPS Card MIPS Guide
MIPS Instruction Set I MIPS Instruction Set II MIPS Quick Reference MIPS Supplement MIPS Tutorial
ARM ARM help Using ARM
General Information Discord EE/CS Wiki EITS Textbook Stack Overflow


Syllabus: Fall 2026   Credit hours: 3
Class times: 10:10am – 11:00pm, MoWeFr Classroom: Harrington 108
Class # (on-campus: 250-01): 36013 Class # (on-line: 250-02): 36014


Instructor: Wen-Chen Hu   (my teaching philosophy) Office: Upson II 366K
: https://und.zoom.us/j/2489867333 Email: wenchen@cs.und.edu
Office hours: 02:30pm – 04:00pm, MoWeFr

Prerequisites: CSCI 160 with a grade of C or better

Synchronous class delivery: The class lectures will be delivered synchronously via https://und.zoom.us/j/2489867333, and the Zoom video will be posted on the Blackboard afterwards. Students can watch the video clips anytime they want.

Textbook: Assembly Language for x86 Processors, 7th ed., Kip Irvine, Pearson, ISBN: 0133769402

There is no specific textbook adopted for the assembly language discussed in this course because the lecture notes and the above links provide enough information for us to use.)

Lecture notes: Other than the textbook, award-winning, interactive, complementary, and abridged lecture notes (based on the textbook and other online documents and user manuals) and detailed and precise class instructions will be provided. Collectively, the lecture notes and instructions are more like a small book, which supplies much more information than regular notes do and makes the subject studies much easier. Students will not have problem learning the subjects or taking the exams after studying them and doing the homeworks and programming exercises.



Grading:

Announcements:



Tentative Schedule:


Week

Class Topic Reading Due Where
0      
  0.1 A computer career      
  0.2 Data research      
  0.3 Data technologies      
1 01/13
01/14
01/15
1. Introduction to CSCI 250 Chapter 1    
  1.1 Course outline      
  1.2 Historical perspective 1.12  
  1.3 Programming language generations      
  1.4 A language processing system      
2 01/20
01/21
01/22
2. Computer Abstractions and Technology Chapter 1    
  2.1 Below your program 1.1-1.3    
  2.2 Under the covers 1.4    
  2.3 Memory technologies 1.5    
  2.4 Processor technologies 1.5    
01/22  Last day to add a course or drop without record
 Last day to add audit or change to/from audit
 Last day to receive a refund on a dropped class
 Drops after the last day to add will appear on a transcript.
     
01/19
Holiday, Martin Luther King Jr. Day (Monday) — no classes
     
3 01/26
01/27
01/28
01/29
3. Computer Abstractions and Technology (Cont.) Chapter 1    
  3.1 Performance 1.6    
  3.2 The power wall 1.7    
  3.3 The sea change 1.8    
  3.4 Real stuff 1.9    
4 02/02
02/03
02/04
02/05
4. MIPS Assembly Programming App. A & Ch. 2    
  4.1 Programming Exercise I      
  4.2 MARS simulator A.2-A.4    
  4.3 MIPS CPU A.9    
  4.4 MIPS assembly language A.10    
5 02/09
02/10
02/11
02/12
5. MIPS Assembly Programming (Cont.) App. A & Ch. 2    
  5.1 Operations and operands 2.1-2.3    
  5.2 Data representations 2.4    
  5.3 Signed and unsigned numbers 2.4    
  5.4 Representing instructions in the computer 2.5    
6 02/17
02/18
02/19
6. MIPS Assembly Programming (Cont.) App. A & Ch. 2    
  6.1 Memory usage A.5    
  6.2 Logical operations 2.6    
  6.3 Instructions for making decisions 2.7    
  6.4 Supporting procedures in computer hardware 2.8 EX I  
02/16
Holiday, Presidents’ Day (Monday) — no classes
     
7 02/23
02/25
02/26
7. MIPS Assembly Programming (Cont.) App. A & Ch. 2    
  7.1 Procedure call convention A.6
  7.2 Communicating with people 2.9    
  7.3 MIPS addressing for 32-bit immediates and addresses 2.10    
  7.4 Translating and starting a program 2.12    
02/24
(no class)
Exam I (for both on-campus and on-line students; 6:30pm – 8:30pm, Tuesday)
     
8 03/02
03/03
03/04
03/05
8. Arithmetic for Computers Chapter 3    
  8.1 Introduction 3.1    
  8.2 Addition and subtraction 3.2    
  8.3 Multiplication 3.3    
  8.4 Division 3.4    
9
03/09

03/13
  Spring Break — no classes
     
10 03/16
03/19
10. Arithmetic for Computers (Cont.) Chapter 3    
  10.1 Floating point representation 3.5    
  10.2 Floating-point addition and subtraction 3.5    
  10.3 Floating-point multiplication 3.5    
  10.4 The guard, round, and sticky bits 3.5    
03/17
03/18
(no classes)
Scheduled eye surgery (Tuesday & Wednesday) — no classes
     
11 03/23
03/24
03/25
03/26
11. The Processor Chapter 4    
  11.1 Introduction 4.1    
  11.2 Logic design conventions 4.2    
  11.3 Building a datapath 4.3    
  11.4 Creating a single datapath 4.3
12 03/30
03/31
04/01
04/02
12. The Processor (Cont.) Chapter 4    
  12.1 A simple implementation scheme 4.4    
  12.2 Operation of the datapath 4.4 EX II  
  12.3 The ALU control 4.4    
  12.4 Designing the main control unit 4.4    
13 04/07
04/08
04/09
13. The Processor (Cont.) Chapter 4    
  13.1 Pipelining overview 4.6
  13.2 Pipeline hazards 4.6    
  13.3 Pipelined datapath 4.7    
  13.4 Pipelined control 4.7    
04/10  Last day to change to or from S/U grading
 Last day to change to or from audit grading
 Last day to drop a full-term course or withdraw from school
     
04/06
Holiday, Easter (Monday) — no classes
     
14 04/13
04/15
04/16
14. The Processor (Cont.) Chapter 4    
  14.1 Data hazards 4.8    
  14.2 Forwarding versus stalling 4.8    
  14.3 Control hazards 4.9    
  14.4 Dynamic branch prediction 4.9    
04/14
(no class)
Exam II (for both on-campus and on-line students; 6:30pm – 8:30pm, Tuesday)
     
15 04/20
04/21
04/22
04/23
15. Exploiting Memory Hierarchy Chapter 5    
  15.1 Introduction 5.1    
  15.2 Memory technologies 5.2    
  15.3 The basics of caches 5.3    
  15.4 Accessing a cache 5.3
16 04/27
04/28
04/29
04/30
16. Exploiting Memory Hierarchy (Cont.) Chapter 5    
  16.1 Measuring cache performance 5.4    
  16.2 Improving cache performance 5.4
  16.3 Multi-level cache 5.4    
  16.4 Review questions 5.4 HW V  
17 05/04
05/05
05/06
05/07
17. Exploiting Memory Hierarchy (Cont.) Chapter 5    
  17.1 Virtual memory 5.7    
  17.2 TLB 5.7  
  17.3 A common framework 5.8    
  17.4 Wrapping up    
18 05/12
Final exam (for both on-campus and on-line students; 06:30pm – 08:30pm, Tuesday)
     
19 05/19 Grades posted before noon, Tuesday      

Though most likely you will not be asked to design computers during your career, a computer scientist or an IT worker must be familiar with the following four foundations of computer science:
  • Programming languages,
  • Computer architecture,
  • Operating systems, and
  • Computer algorithms and theories.

Instructor’s qualification: The instructor has been teaching computer architecture for more than 15 years, so he is well familiar with the topics. In addition, he taught an assembly-language course for 7 years and designed and implemented a POPLOG virtual machine for which both LISP and PROLOG compilers generate code.

University of North Dakota Course Description (
CSCI 250) —
Introduction to machine language and assembly language programming. Concepts of assembly language and the machine representation of instructions and data of a modern digital computer are presented. Requires students to practice assembly language programming techniques on ARM and Intel x86 architectures.

Computer Architecture from Wikipedia
Computer architecture in computer engineering is the conceptual design and fundamental operational structure of a computer system. It is a blueprint and functional description of requirements and design implementations for the various parts of a computer, focusing largely on the way by which the central processing unit (CPU) performs internally and accesses addresses in memory.

Assembly Language from webopedia.com
Assembly language is once removed from a computer’s machine language. Machine languages consist entirely of numbers and are almost impossible for humans to read and write. Assembly languages have the same structure and set of commands as machine languages, but they enable programmers to use names instead of numbers. Each type of CPU has its own machine language and assembly language, so an assembly language program written for one type of CPU will not run on another. In the early days of programming, all programs were written in assembly language. Now, most programs are written in a high-level language such as FORTRAN or C. Programmers still use assembly language when speed is essential or when they need to perform an operation that isn’t possible in a high-level language.

A System Structure of Basic Computer Systems —

An Assemble-Link-Execute Cycle —







01:~/public_html/course/250> emacs index.html File Edit Options Buffers Tools HTML SGML Text Help

 80x86 Assem\ bly


 80x86 Assembly

 C/C++

 CGI

 CodeView

 DOS

 Getting Started

 HTML

 MSAM

 Textbook


CSci250 Assembly Language Programming


Syllabus: Fall 2008
Class times
  & rooms:

Class Time Classroom
Lecture 11:00am – 11:50am, MWF Streibel Hall 106
Lab 01 05:00pm – 07:00pm, Tu Streibel Hall 107
Lab 02 04:00pm – 06:00pm, M Streibel Hall 107

Instructor: Wen-Chen Hu
Lab instructor: Varun Krishna
Email: varun.krishna@hotmail.com
Office: Streibel Hall 229
Office hours: 03:00pm – 04:00pm, MF


University of North Dakota course description —
Computer structure, machine representation of numbers and characters, instruction codes and assembly systems. Includes laboratory.

webopedia.com
Assembly language is once removed from a computer's machine language. Machine languages consist entirely of numbers and are almost impossible for humans to read and write. Assembly languages have the same structure and set of commands as machine languages, but they enable a programmers to use names instead of number. Each type of CPU has its own machine language and assembly language, so an assembly language program written for one type of CPU will not run on another. In the early days of in a high-level language such as FORTRAN or C. Programmers still use assembly language when speed is essential or when they need to perform an operation that is not possible in a high-level language.

Free On-Line Dictionary of Computing
Assembly language is a symbolic representation of the machine language of a specific processor. It is converted to machine code by an assembler. Usually, each line of assembly code produces one machine instruction, though the use of macros is library. Programming in assembly language is slow and error-prone but is the only way to squeeze every last bit of performance out of the hardware.

Software

Hardware

Grading:

Housekeeping Details:

  • Wednesday, December 17: Final Exam to be held.
  • Wednesday, December 10: Final Exam Question Distribution posted.
  • Wednesday, December 10: Lab V due in class.
  • Friday, November 21: Lab V posted.
  • Wednesday, November 12: Homework IV Solutions posted.
  • Monday, November 10: Homework III Solutions posted.
  • Friday, November 14: Exam II to be held.
  • Friday, November 07: Exam II Question Distribution posted.
  • Monday, November 10 (firm): Homework IV due in class.
  • Wednesday, November 04: Homework IV posted.
  • Monday, November 24: Lab IV due in class.
  • Monday, October 27: Lab IV posted.
  • Friday, October 31: Homework III due in class.
  • Wednesday, October 22: Homework III posted.
  • Monday, October 27: Lab III due in class.
  • Monday, October 06: Lab III posted.
  • Wednesday, October 01: Homework II Solutions posted.
  • Monday, September 29: Homework I Solutions posted.
  • Friday, October 03: Exam I to be held.
  • Friday, September 26: Exam I Question Distribution posted.
  • Monday, September 29 (firm): Homework II due in class.
  • Monday, September 22: Homework II posted.
  • Monday, October 06: Lab II due in class.
  • Monday, September 22: Lab II posted.
  • Monday, September 22: Homework I due in class.
  • Friday, September 12: Homework I posted.
  • Monday, September 22: Lab I due in class.
  • Friday, September 05: Lab I posted.
  • Friday, August 29: An exercise posted.
  • Wednesday, August 27: Fill up and send the email wenchen@cs.und.edu to register this course.

Tentative Schedule:


Week

Class Topic Reading Due Where
1
08/27
08/29
1. Introduction Chapter 1    
  1.1 Course outline      
  1.2 A language processing system 1.1    
No lab the first of school      
2
09/03
09/05
2. Basic Concepts Chapter 1    
  2.1 Software and hardware 1.1    
  2.2 Virtual machines 1.2    
09/01 Labor Day holiday — no classes      
3
09/08
09/10
09/12
3. Data Representation & Laboratory Assignments Chapter 1    
  3.1 Binary and hexadecimal numbers 1.3    
  3.1 Boolean operations 1.4    
  3.2 Assembling, linking, and running programs      
09/09 Last day to add a full-term course
Last day to add audit or change to/from audit
Drops after the last day to add will appear on a transcript.
     
4
09/15
09/17
09/19
4. Assembly Language Fundamentals Chapter 3    
  4.1 Basics 3.1    
  4.2 A sample program 3.2    
  4.3 Line-by-line anatomy 3.3    
5
09/22
09/24
09/26
5. Assembly Language Fundamentals (Cont.) Chapter 3    
  5.1 Arithmetic instructions 3.4 Lab I
on 09/22
 
  5.2 Defining data 3.4 HW I
on 09/22
 
  5.3 Symbolic constants 3.5    
6
09/29
10/01
6. Data Transfers, Addressing, and Arithmetic Chapter 4    
  6.1 Data transfer instructions 4.1 HW II
on 09/29
 
  6.2 Addition and subtraction 4.2    
10/03 Exam I      
7
10/06
10/08
10/10
7. Data Transfers, Addressing, and Arithmetic (Cont.) Chapter 4    
  7.1 Data-related operators and directives 4.3 Lab II
on 10/06
 
  7.2 Indirect addressing 4.4    
  7.3 JMP and LOOP instructions 4.5    
8
10/13
10/15
10/17
8. Procedures Chapter 5    
  8.1 Introduction 5.1–2    
  8.2 A sample program      
  8.3 This book's link library 5.3    
9
10/20
10/22
10/24
9. Procedures (Cont.) Chapter 5    
  9.1 The runtime stack 5.4    
  9.2 Stack operations 5.4    
  9.3 Defining and using procedures 5.5    
10
10/27
10/29
10/31
10. Conditional Processing Chapter 6    
  10.1 A sample program 6.1 Lab III
on 10/27
 
  10.2 Boolean instructions 6.2 HW III
on 10/31
 
  10.3 Comparison instructions 6.2    
11
11/03
11/05
11/07
11. Conditional Processing (Cont.) Chapter 6    
  11.1 Conditional jumps 6.3    
  11.2 Loop instructions 6.4    
  11.3 Conditional structures 6.5    
11/07 Last day to change to or from S/U grading
Last day to change to or from audit grading
Last day to drop a full-term course or withdraw from school
     
12
11/10
11/12
12. Advanced Procedures Chapter 8    
  12.1 Local variables 8.1–2 HW IV
on 11/10
 
  12.2 .MODEL, .INVOKE, & PROTO directives 8.4–5    
11/14 Exam II      
13
11/17
11/19
11/21
13. High-Level Language Interface Chapter 12    
  13.1 Introduction 12.1    
  13.2 Inline assembly code 12.2    
  13.3 C/C++ introduction      
14
11/24
11/26
14. High-Level Language Interface (Cont.) Chapter 12    
  14.1 Linking to C/C++ 12.3 Lab IV
on 11/24
 
  14.2 Calling C/C++ functions 12.3    
11/28 Thanksgiving recess — no classes      
15
12/01
12/03
12/05
15. Integer Arithmetic Chapter 7    
  15.1 A sample program 7.1    
  15.2 Shift instructions 7.2    
  15.3 Rotate instructions 7.2    
16
12/08
12/10
16. Integer Arithmetic (Cont.) Chapter 7    
  16.1 Multiplication instructions 7.4    
  16.2 Division instructions 7.4 Lab V
on 12/10
 
17
12/17
Final exam (10:15am – 12:15pm, Wednesday)
    We're here.
18 12/23 Grades posted before noon, Tuesday