What is the Course About?

Motivation Behind The Course

Collectively, the programming-related courses offered by various programs
in the Faculty of Engineering tend to go for breadth of coverage of
programming languages rather than depth. That is, students are typically
exposed to several programming languages at a relatively basic level,
with no one language being covered in great depth. While there is
certainly considerable value in breadth of knowledge, not knowing at
least one programming language commonly used in industry in depth places
the student at a significant disadvantage when seeking employment and
can also limit the scope of projects that the student can reasonably
undertake as part of their studies. The course SENG 475 (which is
crosslisted as the graduate-level course ECE 569A) is intended to address
this problem.

The Course (SENG 475 and ECE 569A)

The course
SENG 475
(which is crosslisted as the graduate-level course
ECE 569A)
studies advanced programming techniques for robust efficient computing
in the context of the C++ programming language.
The course affords students the opportunity to apply, in depth, the concepts
learned over a number of courses in the context of a single programming language
commonly used in industry (namely, C++). For a variety of programming
concepts, the student will learn in detail how each of these concepts
maps into particular features of the C++ programming language and how to use
these features in an effective manner.
Although SENG 475 carries the
"SENG" designation, the course is open to any students in the Faculty
with the necessary prerequisites.

In order to accommodate graduate students, SENG 475 is crosslisted
as the graduate-level course
ECE 569A (Selected Topics in Computer Engineering).

When is the Course Offered?

SENG 475 (which is crosslisted as the graduate-level course ECE 569A)
is scheduled to be offered for the first time in the Summer 2018 term.
It is expected that this course will probably be offered in subsequent
Summer terms as well.
Please check this section periodically for updates
in case this schedule might possibly change.
Incidentally, if this course is not offered in a time frame
that is feasible for you to take it, you might find the course
ECE 486/586 to be of interest.

Prerequisite Knowledge and Requirements of the Course

Prerequisite Knowledge of C++

The course SENG 475 is taught using the programming language C++.
It is important to understand, however, that this course
does not attempt to teach rudimentary C++.
It is assumed that the student already has a basic working knowledge of C++.
In particular, it is assumed that the student is familiar with the
following aspects of C++:

standard library:
containers, iterators, and algorithms;
a few of the commonly-used types, such as std::vector and std::string

If you are lacking such knowledge,
please read the section below titled
"What To Do If You Are Lacking the
Prerequisite Knowledge of C++".
(I have been led to believe that CSC 116 uses C++ and recent offerings
of that course cover much of this material, but I cannot make any
guarantees about this as I did not teach that course myself.)
If SENG 475 were to devote a significant amount of time to teaching
rudimentary C++, no time would be left to cover advanced programming
techniques, which is the true purpose of the course.
This said, however, some limited time in the lectures and/or tutorials
will be devoted to discussing some common problems/misunderstandings
about the basics of the language
(e.g., const correctness and temporary objects).
These discussions will be done under the assumption that students already
have basic familiarity with C++, however.

What To Do If You Are Lacking the Prerequisite Knowledge of C++

In order to accommodate students with strong programming skills but
no prior knowledge of C++, detailed video lectures are available that
cover the necessary prerequisite material.
In particular, numerous video lectures related to C++ can be found at:

The material that is assumed as prior knowledge in the course is
covered by the lectures in the following video-lecture categories:

Basics

Classes

Templates

Standard Library

The material in the following video-lecture categories would also
be helpful to know, since students are required to learn this material in
the first week of classes for SENG 475 (by watching these video lectures):

Software Tools

Version Control Systems (Git)

Build Tools (excluding the video lecture on Make,
since CMake is used in the course, not Make)

As long as the student is able to attain a basic understanding of the
C++ material in the above video lectures by (approximately) lecture 4
of the course, this should be adequate.
The first (approximately) 3 or 4 lectures of the course are structured in a
way that any dependency on knowledge of C++ is minimized.
After this time, however, the course will plunge deeply into C++, and
any students not yet up to speed with the language will have great
difficulty (and possibly suffer permanent emotional scarring as a result).
In order to avoid unnecessary stress,
it is strongly recommended that the student learn this material
in advance of the term in which they plan to take the course
instead of cramming in the first week of the term
(which may not be possible to do).

Since it is impossible to learn C++ without writing code, it is worthwhile
to note that most Linux systems in the ECE Department (and likely the
CS Department as well) tend to have the GCC C++ compiler installed
(which is accessible via the g++ command).
Also, the software development environment (SDE) for the course is available
on the machines in the computer lab used for the course.
The SDE has all of the software needed for the course.
For more details on how to access the SDE, refer to the section
Accessing the Software Development Environment (SDE) for the Course

Registering for the Course

Since the proposal for SENG 475 as a new course had very strong student
support, the course is expected to be popular and have high enrollment.
Since the instructor runs the (computer-based) tutorial himself
in addition to his regular teaching load, it is only feasible for
the course to have a single instance of the tutorial (i.e., the tutorial
must be scheduled at the same time and location for all students in
the course).
This limits the enrollment of the course to the capacity of the lab in which
the tutorial is held (which is about 45).
For this reason, it is recommended that students register as soon
as possible for the course in order to avoid the possibility
of being placed on a long waitlist.
If a student is waitlisted for the course, there is always some chance
that the student will able to register.
Of course, the chances are much better if the student is near the start
of the waitlist, rather than the end.
Students who are waitlisted often ask if they will be able to register later.
Unfortunately, it is impossible to answer such a question.
Due to the fast pace of the course, however, it is probably not advisable
to register too much after the start of the term, even if possible to do so.

Accessing Course Materials

Some of the downloadable course materials associated with this web page
may be stored in a private (i.e., secure/protected) area.
Two levels of security are imposed on this area:

First, this area is password protected.

Second, this area is only accessible from machines on the
university campus network.

Typically, links to password protected parts of the web site are
marked by a padlock.

In order to access the private area, you will need to know the
appropriate username and password to use (for the web server). If you
are taking this course, you should know the correct username and
password (which were announced during the first lecture).
Note that this username and password are not the ones for your
Netlink account.
If you would like to access the private area from outside
the university campus network, this can be accomplished by using the
UVic VPN.

The Software Development Environment (SDE) for the Course

A highly-customized software development environment (SDE) has been
setup for this course by the instructor.
The SDE includes very recent (usually the most recent) versions
of software such as:

GCC

Clang

CMake

GDB

YouCompleteMe (YCM)

Boost

Catch2

TeX Live

Vim

It is critically important that all students use the SDE and not the
system-installed versions of various software, as the non-SDE versions
are too outdated (or have other compatibility issues) and will not
function correctly for the purposes of the course.
The SDE will be used for the grading all programming assignments in
the course. So, it is absolutely critical that student code works
correctly in this environment.

Accessing the SDE

Lab and Lab Machines.
The SDE is only available on the machines in the computer lab used for
the course, namely, the ECE Undergraduate Linux Lab in ELW B238.
Since it is possible to remotely login to the machines in the lab via SSH,
it is still possible to use the SDE without physically being present in
the lab. The machines in the lab can be accessed by remotely logging in
(via SSH) to the generic hostname ugls.ece.uvic.ca.
Specific lab machines can also be accessed via the hostnames ugls1.ece.uvic.ca,
ugls2.ece.uvic.ca, and so on (up to something like ugls46.ece.uvic.ca).
Is it recommended, however, that the
generic hostname ugls.ece.uvic.ca be used in order to take advantage of
potential load balancing (i.e., ugls.ece.uvic.ca will get mapped to the
specific machine that is currently least loaded).

Initializing the SDE.
To access the SDE (on one of the lab machines),
you should run the following command in your shell:

/home/frodo/public/ugls_lab/bin/sde_shell

This command will start a new subshell that is correctly configured to
use the SDE.
Only this new subshell will be configured in this way, however.

Do not try to use the SDE on machines in the ECE Department other than
the machines in the lab for the course, as this will not work properly.
Although you will be able to access the sde_shell script on most ECE Department
machines since the directory /home/frodo/public/ugls_lab is accessible
on most ECE Department machines, the software installed under
/home/frodo/public/ugls_lab will only work on the machines in the lab.
Extremely bizarre failure modes are very likely to be encountered if the
SDE is used on machines outside the lab for the course.
Such failure modes include, amongst many others:

CMake complains that it was installed incorrectly.

CMake reports that the C++ compiler does not work.

The GCC and Clang compilers do not work properly.

The linker (i.e., the ld program) complains that it cannot find
certain
objects files (e.g., crt1.o) or libraries (e.g., the math library as in "-lm").

In order to use the SDE on a machine outside the lab, you would need
to install the SDE yourself (from scratch) on that machine.
Since installing the SDE is a very time-consuming and tedious process,
it is not recommended that students attempt to do this.

Common Problems With the SDE

The most common problems with the SDE are as follows:

Attempting to use the SDE on a machine with a
configuration different from the ones for which the SDE was built
(i.e., attempting to use the SDE on machines outside the lab
for the course).
The SDE was built on the lab machines and therefore can only be
guaranteed to work correctly on the lab machines.
It is almost guaranteed that the SDE will not work if used on machines
outside the lab for the course.
For information about the lab and the hostnames of the machines in
this lab,
refer to the section titled Accessing the SDE.

Failing to initialize the SDE.
The SDE is not enabled by default.
If you do not initialize it, you will not be using it.
For instructions on how to properly initialize the SDE,
refer to the section titled Accessing the SDE.

Installing the SDE (Not Officially Supported)

Although the SDE is only officially supported on the lab machines,
a student can certainly try (if they would like) to install the SDE
on their own computer.
If a student would like to install the SDE on their own computer, the
SDE is available from its official Git repository, hosted by GitHub.
The home page for the SDE on GitHub can be found at:

Installation instructions for the SDE can be found in the file
README.md in the top-level directory of the repository.

The instructor only officially supports the SDE on the lab machines.
So, if a student encounters problems when attempting to install (or use)
the SDE on their own machine, the instructor cannot provide assistance.
The SDE will only work on Unix-based systems.
It should have a reasonable chance of working with Linux distributions
that are fairly complete and stay current with recent software versions.
For example, it is known to work with recent versions of Fedora and CentOS.
It will probably not work for Mac OS X (due to Apple using older versions
of some software in OS X and not including other software at all).
Note that installing the SDE will likely take several
hours, since building software like GCC and Clang (and downloading TeX Live)
is very time consuming.

Instructor

Office Hours

Final-Exam Office Hours

My final-exam office hours, as determined in the last lecture,
are as follows:

Tue Aug 14 10:00-11:00

Other Final-Exam Office Hours.
I am also available for help during my final-exam office hours for
ECE 260. I must give priority to any ECE 260 students first, but
often no students come to office hours for ECE 260, so there is
a good chance that you can obtain help during these other office
hours as well. My final-exam office hours for ECE 260 can be found
here.

Course Outline

Tutorials

General Comments About Tutorials

The tutorial is run by the instructor, not a teaching assistant.
Since the instructor runs the tutorial himself in addition to his regular
teaching workload, it is not feasible to have more than one
instance of the tutorial.
Tutorial attendance is mandatory.
An explanation of why this is so is given below.

The precise manner in which the tutorials are to be used depends on factors
that are impossible to predict in advance of the start of the course.
Such factors include the specific needs of the students taking the course
as well as the need to address any unexpected issues that arise during the
teaching of the course.
Although the precise manner in which tutorials will be used cannot
be specified in advance of the start of the course, some possible
uses can be identified.
In particular, the tutorials may be used for a number of purposes,
including (but not limited to):

presentations by the instructor to fill (unanticipated) gaps
in student knowledge relevant to the course

presentations by the instructor to further clarify more
difficult topics in the course

For some of the above uses of the tutorial, it is extremely important
that all students be in attendance.
This is why tutorial attendance is deemed mandatory.

Scheduling Conflicts with the Tutorial

If a student is considering taking the course, but has a conflict with the
tutorial, they should contact the instructor for guidance
in advance of the start of the course.
When contacting the instructor, such a student should provide the
following information:

the details of the scheduling conflict,
including what part of the tutorial overlaps with the other
conflicting course (e.g., the first 30 minutes or the last 20 minutes)

their program and year of study (e.g., 4th-year software engineering)

the level of their programming skills

the extent of their knowledge of C++

In anticipation of conflicts with the last part of the tutorial timeslot,
the instructor will try to prioritize more important content earlier
in the timeslot.
In some cases, however, the full timeslot will likely be needed, in which case
a student who leaves the tutorial early would
miss potentially important course content.

Course-Materials Bug-Bounty Program (CMBBP)

By participating in the Course-Materials Bug-Bounty Program (CMBBP), you
can earn extra marks in the course.
If you are interested in obtaining extra marks, then read
the following document on the CMBBP:

Optional Texts/Materials

It is critical to obtain the fourth edition as earlier editions do not
have coverage of C++11 features.

Video Lectures

Numerous video lectures are available on topics related to the course
materials. The video lectures focus primarily on the C++ programming
language, the C++ standard library, and a variety of software development
tools. Students may find some of these video lectures to be helpful
at various points in time. In particular, the video lectures
are expected to be extremely helpful to students who have no (or very
limited) prior experience with C++ and need to quickly get up to speed
with this language prior to the start of the course.
Note that the vast
majority of topics covered in the course are not covered by these video
lectures. So, it is critically important that students attend in-class
lectures and not attempt to rely solely on the video lectures for learning
the course materials.

Assignments

Weighting of Assignments in Assignment Component of Course Mark.
As mentioned in the course outline, the assignments are not necessarily
equally weighted in the calculation of the assignment component of the
course mark.
Each of Assignments 1, 2, 3, 4, 5, and 6 carries an equal weight,
but Assignment 0
only carries one-quarter the weight of each of the other assignments.
This difference is due to the fact that Assignment 0
is simply an exercise in using some of the
software tools for the course and does not involve any real programming
per se (i.e., no code needs to be written).

Solutions to Programming Exercises.
Since there is typically no one correct solution to the programming
exercises, solutions to such exercises are not posted.
If you would like to see the instructor's solution to any of the programming
exercises, the instructor would be more than willing
to show his solution to you (and explain how it works).
He will not provide a copy of his code, however.

Marking Issues.
If you have any concerns about the marking of an assignment,
please directly contact the TA who marked the assignment.
For a list of which TAs marked which assignments, please refer
to the following document:

Project (Graduate-Level Version of Course Only)

The project is a component of the course
only for students who are
registered in the graduate-level version of the course.
Students who are registered in the undergraduate-level version of the
course do not do a project!

C++ Book/Lecture-Slide Supplements

Some additional revisions have been made to the lecture slides for the
course since the time that they were published (e.g., to correct errors,
improve explanations, and add clarifications).
The more significant of these changes are made available through
supplements to the lecture slides, which contain collections of.
revised/new slides.
The following lecture-slide supplements are currently available:

Lecture-Slide Supplement 15 [2018-07-08].
This supplement is obsolete (and no longer available)
as it is replaced by Supplement 16.
Supplement 15 is still mentioned in this list so that
students do not wonder what happened to Supplement 15.