You are on page 1of 19

Faculty of Science

Course Guide

COMP 2131
Introduction to Computer Systems
Copyright and Credits
Copyright © 2017 Thompson Rivers University. All rights reserved.
The content of this course material is the property of Thompson Rivers University
(TRU) and is protected by copyright law worldwide. This material may be used by
students enrolled at TRU for personal study purposes only. No part of this work may be
forwarded or reproduced in any form by any means without permission in writing
from the Intellectual Property Office, Thompson Rivers University, copyright@tru.ca.
TRU seeks to ensure that any course content that is owned by others has been
appropriately cleared for use in this course. Anyone wishing to make additional use
of such third party material must obtain clearance from the copyright holder.

Course Development Team


Course writer: Mridula Sharma
Course reviewer: Amos Omondi Academic Director:
Instructional designer: Ken Monroe, MA.
Course Editor: Mona Hall

Thompson Rivers University


805 TRU Way
Kamloops, BC, Canada
V2C 0C8
Table of Contents
Course Guide ..........................................................................................................................1
Introduction .........................................................................................................................1
Course Description..........................................................................................................1
Prerequisites: ....................................................................................................................1
Exclusion...........................................................................................................................1
Learning Outcomes .........................................................................................................2
Course Materials .................................................................................................................2
Required Hardware, Software, Computer Skills, and Other Resources .................2
Course Topics ......................................................................................................................2
Learning Activities ..............................................................................................................3
Student Café .....................................................................................................................3
Assessments .........................................................................................................................3
Assignments .....................................................................................................................4
Final Exam ........................................................................................................................5
Grading Scale ...................................................................................................................6
Academic Integrity ..........................................................................................................6
Suggested Schedule ............................................................................................................7
Strategies for Success ..........................................................................................................8
Help Available .....................................................................................................................9
TRU Open Learning Faculty Member Support ..........................................................9
Library Services and Resources.....................................................................................9
Technical Support..........................................................................................................10
Course Development Team .............................................................................................10
Curriculum Developer..................................................................................................10
Course Summary..................................................................................................................11
Module 1: A Tour of Computer Systems .......................................................................11
Overview ........................................................................................................................11
Learning Objectives.......................................................................................................11
Module 2: Data Representation & Boolean Logic.........................................................11
Overview ........................................................................................................................11
Learning Objectives.......................................................................................................11
Module 3: Introduction to Programming Language ‘C’..............................................12
Overview ........................................................................................................................12
Learning Objectives.......................................................................................................12
Module 4: The memory hierarchy ..................................................................................13
Overview ........................................................................................................................13
Learning Objectives.......................................................................................................13
Module 5: Compiling and Linking .................................................................................13
Overview ........................................................................................................................13
Learning Objectives.......................................................................................................13
Module 6: Machine level representation of ‘C’ programs using Assembly .............14
Overview ........................................................................................................................14
Learning Objectives.......................................................................................................14
Module 7: Optimizing Program Performance ..............................................................14
Overview ........................................................................................................................14
Learning Objectives.......................................................................................................15
COMP 2131: Introduction to Computer Systems 1

Course Guide
Introduction
Welcome to COMP 2131: Introduction to Computer Systems, a three-credit course that
can be applied toward a Thompson Rivers University (TRU) credential.
The Course Guide contains important information about the course structure,
learning materials, and expectations for completing the course requirements. It also
provides information about how and when to contact your Open Learning Faculty
Member, an expert in the course content, who will guide you through the course.
Take some time to read through the Course Guide to familiarize yourself with what
you need to do to successfully complete your course.
Before you begin your coursework, it also is a good idea to read the Student
Handbook, available at http://www.tru.ca/assets/ol/ebooks/ol_st_handbook/. The
Handbook provides information about key policies and procedures, such as course
withdrawals and cancellations, and how to schedule final exams. It also includes
information about the various student services available to you, and telephone,
email, and website contact details.
If you have any questions, please feel free to contact your Open Learning Faculty
Member. We hope you enjoy the course.

Course Description
Students learn the basic concepts of computer systems. Students are introduced to
the concepts of computer architecture, the ‘C’ and assembly programming languages
as well as the use of Linux operating system. Students learn about memory
organization, data representation, and addressing. Students are introduced to the
concepts of machine language, memory, caches, virtual memory, linkage and
assembler construction as well as exceptions and processes.

Prerequisites:
Recommended COMP 1231 with a score of C or better or
Recommended COMP 1230 with a score of C or better or
Recommended COMP 2120 with a score of C or better

Exclusion
COMP 2130

TRU Open Learning


2 Course Guide

Learning Outcomes
Upon completion of this course, students will be able to:
1. describe the fundamentals of computer architecture
2. write programs with the powerful C programming language
3. demonstrate programming through assembly language
4. explain the critical relationship between programming and computer architecture
5. demonstrate efficient programming through code optimization

Course Materials
Bryant and O’Hallaron, Computer Systems: A Programmer’s Perspective, 3/E,
Prentice Hall, 2016. ISBN 10: 0-13-409266-X
Kernighan and Ritchie, The C Programming Language 2nd edition, Prentice Hall,
1988, ISBN 10: 0-13-110362-8

Note
If you have any questions about course textbooks or other materials, please
contact Enrolment Services at student@tru.ca or 1.800.663.9711 (toll-free in
Canada), 250.852.7000 (Kamloops, BC), and 1.250.852.7000 (International).

Required Hardware, Software, Computer Skills, and Other


Resources
For details about the generic computer equipment and resources you will need for
this course, see “Course Delivery Formats,” “Equipment,” and “Web-based Courses
Delivered by TRU-OL” at http://www.tru.ca/distance/services/online_courses.html.

Course Topics
• Basic concepts of digital systems
• Computer Abstraction and Technology
• Introduction to Linux OS and C Language
• Memory Organization, Data representation, and Addressing
• Basics of Architecture, Machine Code
• Machine Level Programming
• Memory and Caches
• Linking
• Exceptions and Processes
• Virtual Memory

TRU Open Learning


COMP 2131: Introduction to Computer Systems 3

Learning Activities
COMP 2131 is a course that provides engaging activities and opportunities to apply
your learning in relevant real-world contexts. Each of the twelve topics will guide
you to complete practice and review exercises, made up of questions and key terms.
While these learning activities are optional and ungraded, working through them
will help you to meet the course learning outcomes and successfully complete your
assessments and prepare for the final exam. These are the main learning activities
you will engage in:
1. Readings from textbook:
2. Viewing Recorded Lectures:
Multiple lectures on related topics
3. Reviewing PowerPoint slides
Module 1 to Module 7
4. Completing Practice Assignments:
Programs to practice and review the concepts studied

Student Café
An informal discussion space called the ”Student Café“ has been set up for you to
easily communicate with other learners in the course about matters of mutual
interest regarding your studies and professional development. This is an informal
gathering area to help build a learning community, and you will not be graded on
these postings. For more information about online discussions and netiquette see
http://www.tru.ca/distance/services/learner/netiquette.html.

Assessments
In order to complete this course successfully, you must obtain at least 50 per cent on
the final examination and 50 per cent overall. The following chart shows how the
final grade is determined for this course.

See the Assignments Overview tab for details on the assignments (you will
also find information posted within course material), as well as instructions
on how to submit assignments to your Open Learning Faculty Member.

TRU Open Learning


4 Course Guide

COMP 2131 Weight

Quiz 1 6%

Written Assignment 1 7%

Programming Assignment 1 8%

Programming Assignment 2 10%

Quiz 2 6%

Written Assignment 2 8%

Programming Assignment 3 10%

Final Exam 45%

Total 100%

Assignments
There are three categories of assessments:
Programming Assignments: 1, 2, and 3 – 8%, 10% and 10% Since this is a
programming course, the assignments provide you with an opportunity to
demonstrate that you have learned to course material. After every module, you are
provided with incomplete code and instructions on how to complete them. In
addition you will be required to solve problems by creating appropriate programs.
Programming Assignment 1 is due at the end of Module 3 Programming
Assignment 2 is due at the end of Module 4 Programming Assignment 3 is
due at the end of Module 7
Quizzes – There are two online quizzes that have multiple choice or true of false
questions. The first online quiz must be attempted before you move on Module-4
and will cover the concepts from Module 1 and Module 2. Quiz 2 is assigned
after Module 5 and covers the concepts of Module-4 and Module-5 of the course.
Quiz-1 - 6% of final grade Quiz-2 – 6% of final grade
Written Assignments: 1 & 2 – 7% and 8% - these are two theoretical assignments
that will cover the concepts covered in modules 1, 2, 4 and 5. These are to be
answered and submitted directly to the Open Learning Faculty Member.
Written Assignment 1 is due at the end of Module 4 Written Assignment 2 is
due after the end of Module 5

TRU Open Learning


COMP 2131: Introduction to Computer Systems 5

Final Exam
At the completion of the course you will be required to sit for a mandatory Final
Examination.
The exam will be up to 3 hours and will test you on all the topics covered. The main
points to be reviewed before sitting for the exam are:
• Major hardware and software components.
• Distinguish and explain different categories of software’s
• Explain different hardware components like SRAM, DRAM, FPGA, CHIPS,
USB etc.
• Representing the information through different number systems
• Understand the need of Octal and Hexadecimal numbers
• Floating point number representation
• Logic gates, Binary Expressions, truth tables
• Introduction to the programming language ‘C’ on Unix platform using GCC
• Operators, conditions, loops in ‘C’
• Array Handling with 1-D and 2-D arrays
• functions & Recursion
• Pointers Manipulation
• data file handling - Text files and binary files
• The memory hierarchy
• Role of Cache memory
• Compiler Drivers
• Static and Dynamic Linking
• Relocatable Object files
• Symbols and Symbol tables
• Structure and working of Assembly code
• Optimizing program performance
• Explain the concept of locality and parallelism
You must apply to write the final examination, and it is your responsibility to do so.
The deadline to apply for an examination is typically three to four weeks prior to the
writing date.
For details on how to register for your final exam refer to the following website.
http://www.tru.ca/distance/services/resources/exams.html#TRU-OLexams

TRU Open Learning


6 Course Guide

Grading Scale
The official grading scale for all Open Learning courses is the official TRU
Academic/Career/Developmental Programs scale as noted in TRU’s “Grading
Systems and Procedures.” For detailed information, go to
http://www.tru.ca/distance/services/policies/newgrading.html.

Academic Integrity
Appropriate academic conduct requires that you complete your assignments
independently, honestly, and without misrepresentation or plagiarism. Typically,
plagiarism occurs in three forms: when a person uses someone else’s exact words or
ideas as if they were his or her own, paraphrases someone else’s ideas without
acknowledgment or identifying the source, or simply fails to include proper citations.
Be sure to cite all sources of both direct quotations and borrowed ideas. If you do
not, you could fail your assignments and, possibly, the course. Also, do not attempt
to submit an assignment or any project work that has been prepared by or with the
assistance of someone else. Remember, plagiarism is a serious academic offence.

Note
Citing facts, statistics, or other illustrative materials deemed to be common
knowledge is not considered to be plagiarism.

For more resources on plagiarism and citing sources, see the following:
• TRU Library style guide, available at
http://www.tru.ca/library/guides/citation_styles.html#apa.
• TRU-OL Social Sciences Style Guide, available at
http://www.tru.ca/library/pdf/socscistyle_ol_2005.pdf
• In addition, the TRU Library website provides the “Plagiarism – what is it?”
resource at http://libguides.tru.ca/content.php?pid=83248.
• TRU’s “Academic Integrity” policy, available at
http://www.tru.ca/__shared/assets/ed05-05657.pdf. Note that it is your
responsibility to ensure that you are fully familiar with the “Forms of
Academic Dishonesty” section of this policy.
All of these resources are also available in the Links section in the left-hand
navigation bar on your course Home Page.

TRU Open Learning


COMP 2131: Introduction to Computer Systems 7

Exam Application
You are responsible for ensuring that TRU-Open Learning receives your
exam application by the deadline.
For information about TRU –OL Examinations click here

Suggested Schedule
Most students attempt to complete this course in sixteen weeks. However, you may
complete the course more quickly, or you can take up to thirty weeks to finish.
Regardless of how long you choose to take, it is a good idea to set a schedule;
otherwise, you may find yourself nearing the maximum completion deadline and
still have outstanding assignments.
The following is a suggested timetable based on the average completion rate. You can
print this schedule out and revise to your own timetable.

Week Actual
Activity Percentage Date Due
Assigned in date

Quiz 1 End of
6 Module 1 & 2
(Covers module 1&2) Week 3

Written Assignment 1 End of


7 Module 1 & 2
(Covers module 1 & 2) week 4

Programming Assignment 1
End of
(Covers Module 3 – some 8 Module 3
Week 6
topics)

Programming Assignment 2
(Covers Module 3 – rest of 10 Module 3 In week 9
the topic)

Quiz 2 End of
6 Module 4 & 5
(covers module 6) Week 10

Written Assignment 2 End of


8 Module 5
(Covers Module 4 & 5) Week 11

TRU Open Learning


8 Course Guide

Week Actual
Activity Percentage Date Due
Assigned in date

Programming Assignment 3 End of


10 Module 6
(Covers Module 6) Week 13

After Week
Final Exam 45 After module 6
14

100

Strategies for Success


Taking a course through distance education is a unique experience. The following
strategies are some suggestions that should assist you to complete your course
successfully:
Familiarize yourself with the course materials
After you have read this Course Guide, look through all the course materials—
especially the assignments—so you know what coursework is expected from you
and you can be thinking about upcoming assignments.
Work through the course modules in sequence
The instructional modules lead you through the coursework, including the reading
assignments in your textbook and selected readings. Each module provides a list of
learning outcomes, instructions for reading assignments, slides that support the
learning material and practice exercises.
Complete the module activities as if they were being graded
Completing the learning activities in the modules will provide you with
opportunities to consolidate your learning and prepare for the assignments.
Although you will not receive a grade for your work in completing these exercises,
they are a key part of your learning, and often form the foundation for the work you
will do in the assignments or final exam. Work through them as if you are being
graded on your performance.
Complete the assignments carefully and submit them promptly
Assignments cover what you have learned from your readings and further research.
As soon as you have completed an assignment, submit it to your Open Learning
Faculty Member for marking.

TRU Open Learning


COMP 2131: Introduction to Computer Systems 9

Review the learning outcomes as you complete each module


As you complete each module, review the learning outcomes to be sure you have
achieved them. If you feel unsure that you are able to meet any outcome, review the
pertinent study material and/or consult your Open Learning Faculty Member.
Write the final exam
This course concludes with a final exam.
Leave enough time after completing your last assignment to review the course
material in preparation for the final exam. Review the course learning outcomes, the
unit learning outcomes, your notes, the review questions, all the assignment
questions, and your assignments with any feedback or comments on them.
The Student Handbook contains a list of permitted examination sessions and locations
and an exam application form. You will receive written confirmation in the mail of
the date, time, and place where you will write your exam.

Help Available
The following sections describe the support that is available to you throughout this course.

TRU Open Learning Faculty Member Support


Your Open Learning Faculty Member will guide your learning in this course, mark
and comment on your assignments, and provide you with whatever assistance you
need with your coursework. You are encouraged to contact your Open Learning
Faculty Member early and often; for example, when:
• You wish to discuss any aspect of the course content.
• You do not understand some aspect of the course instructions or assessments.
• You have difficulty with any of the course readings or activities.
• You have a question or a problem arising from your Open Learning Faculty
Member’s comments or grading of your assessments.

Library Services and Resources


The TRU library website has a wealth of resources to assist students, like you, who
are accessing this material from a distance. The website is available at
http://www.tru.ca/library/distance.html. A link to the Library is also provided in the
right-hand side in Web Links block. For information about how to access an article
or database, and how to locate specific articles from a citation, take a look at the
“Library Research 101: Research at a Distance” guide available at
http://libguides.tru.ca/content.php?pid=91028.

TRU Open Learning


10 Course Guide

Remember, if you are prompted to log on or sign in to access library resources, you
need your student number and your library PIN number. Your library PIN is your
six digit birth date in the YYMMDD format.
If you have any problems locating a journal or would like some guidance on how to
locate research materials more effectively, please contact the TRU Library’s Distance,
Regional and Open Learning (DROL) Library Services department
http://www.tru.ca/library/distance/distance_services_contacts.html. You can ask for
help via online chat (AskAway), email, Facebook, or phone.
For more information about TRU Library policies and services for TRU-OL students,
refer to your Student Handbook.

Technical Support
If you are having problems using the tools or features of the course website, check if
you are using the correct hardware and software required for your course at
http://www.tru.ca/distance/about/learner/techsoftware.html.
If you still are experiencing problems, go to the IT Service Desk at
http://www.tru.ca/distance/services/resources/helpdesk.html.
If you are having problems accessing the course website or have other related questions,
you can phone the IT Service Desk at 1.888.852.8533 (toll-free in Canada), 250.852.6800
(Kamloops, BC), and 1.250.852.6800 (International); or email ITServiceDesk@tru.ca.

Course Development Team


Curriculum Developer
Mridula Sharma, is a Computer Instructor involved in teaching students for more than
15 years. She has completed Master in Computer Applications and Master of Science
(Information Technology) from India and is a Ph. D. candidate at University of Victoria.

TRU Open Learning


COMP 2131: Introduction to Computer Systems 11

Course Summary
Module 1: A Tour of Computer Systems
Overview
In this module student will start with the general introduction to computers and
commonly used terminology related to computers.

Learning Objectives
Upon completion of this module, students will be able to:
• Describe the concepts of Hardware/Software and networking basics.
• Explain the steps in execution of a program
• List hierarchy of storage devices
• Identify the use and need of field-programmable gate array (FPGA)

Module 2: Data Representation & Boolean Logic


Overview
Divided into two parts, this module covers the concept of data representation in the
first session and Boolean logic in the second session.

Learning Objectives
Upon completion of this module, students will be able to:
• Representing the information through different number systems
• Understand the need of Octal and Hexadecimal numbers
• Perform inter-conversions
• Perform Binary Arithmetic
• Understand the IEEE Floating point number representation
• Perform Binary logic
• Understand Logic gates, Binary Expressions and truth tables
• Draw simple Combinational Logic diagram

TRU Open Learning


12 Course Guide

Module 3: Introduction to Programming Language ‘C’


Overview
Divided into three parts, this module covers the programing language ‘C’. Starting
with simple operators and constructs, this module covers the detailed concepts of
pointers, File handing and command line arguments.

Learning Objectives
Upon completion of first part of this module, students will be able to:
• Understand the need and use of programming language ‘C’
• Working with UNIX/LINUX operating environment to use GNU-C compiler
• Review of basic data types and operators
• Performing iterations using loops
The second part of the module covers:
• Defining and using functions
• Concept of numeric arrays
• Working with character arrays to make strings
• Understanding and using 2-D arrays
The last part of the module covers:
• Using pointers to manipulate data on specified memory locations
• Managing data into the files
• Providing data to a ‘C’ program through command line arguments
• Structures and dynamic memory allocation

TRU Open Learning


COMP 2131: Introduction to Computer Systems 13

Module 4: The memory hierarchy


Overview
This modules covers the concept of storing data in the Computer for the purpose of
processing and maintaining it for the longer duration. Measuring the overall
capacity of the storage devices will also be covered.

Learning Objectives
Upon completion of this module, students will be able to:
• Identify the need and use of storage devices
• Classify the memory hierarchy
• Calculate the total storage capacity of primary memory and secondary
memory
• Explain the need and use of cache memory
• Explain the concept of Locality and use it for the optimized performance of
the program

Module 5: Compiling and Linking


Overview
This modules covers the concept of building and executing the application
programs. Here we will discuss the interaction between the program and the
operating system. We will see how the different parts of the programs are combined
and loaded into the memory and executed by the browser.

Learning Objectives
Upon completion of this module, students will be able to:
• Identify the need and use of Compiler Drivers
• Classify the different linking mechanisms
• Explain the common concepts related to linking and executing a program
• Explain the need and use of executable object files

TRU Open Learning


14 Course Guide

Module 6: Machine level representation of ‘C’ programs


using Assembly
Overview
This module covers the concept of Assembly language programming. we will learn the
details of a particular assembly language and see how C programs get compiled into
this form of machine code. For writing programs in assembly code, a programmer must
specify exactly how the program manages memory and the low-level instructions the
program uses to carry out the computation. This helps them understand the overall
functioning of the computers and help them becoming better programmers.
This module has two sessions. Session 1 introduces Assembly language and session
2 describes stacks and covers book examples.

Learning Objectives
Upon completion of this module, students will be able to:
• Identify the need and use of Assembly language
• Classify the different registers
• Explain the common concepts of writing an assembly program
• Explain the use of stack for parameter passing

Module 7: Optimizing Program Performance


Overview
This module covers the concept of code optimization. A programmer needs to write
source code that the compiler can effectively optimize to turn into efficient executable
code. For this part, it is important to understand the capabilities and limitations of
optimizing compilers. Moreover, minor changes in a program can make large
differences in how well a program can execute. This concept is useful for programmer
of any language. Many such issues are discussed in this module with examples.

TRU Open Learning


COMP 2131: Introduction to Computer Systems 15

Learning Objectives
Upon completion of this module, students will be able to:
• Understand generally Useful Optimizations
o Code motion/pre-computation
o Strength reduction
o Sharing of common sub-expressions
o Removing unnecessary procedure calls
• Explain the Optimization Blockers
o Procedure calls
o Memory aliasing
• Exploit Instruction-Level Parallelism
• Work with Conditionals

TRU Open Learning

You might also like