3. Focus of this paper
Teaching Computer Architecture Labs to Undergraduate Students in
Computer Science
4. Focus of this paper
Teaching Computer Architecture Labs to Undergraduate Students in
Computer Science
Organization?
5. Focus of this paper
Teaching Computer Architecture Labs to Undergraduate Students in
Computer Science
Organization?
6. Focus of this paper
Teaching Computer Architecture Labs to Undergraduate Students in
Computer Science
Computer Organization and Architecture
(CPSC 231 at UNBC)
Organization?
7. Teaching Computer Architecture Labs to Undergraduate Students in
Computer Science
Focus of this paper
• Instruction Set Architecture
• Addressing modes
• Interrupts
• Pipelining
Computer Organization and Architecture
(CPSC 231 at UNBC)
8. Focus of this paper
Teaching Computer Architecture Labs to Undergraduate Students in
Computer Science
• Instruction Set Architecture
• Addressing modes
• Interrupts
• Pipelining
Computer Organization and Architecture
(CPSC 231 at UNBC)
Lecture
(Conceptual Explanation and Internals)
9. Focus of this paper
Teaching Computer Architecture Labs to Undergraduate Students in
Computer Science
(Concepts Demonstrated with Assembly Exercises)
• Instruction Set Architecture
• Addressing modes
• Interrupts
• Pipelining
Computer Organization and Architecture
(CPSC 231 at UNBC)
Lecture + Labs
(Conceptual Explanation and Internals)
10. Focus of this paper
Teaching Computer Architecture Labs to Undergraduate Students in
Computer Science
(Concepts Demonstrated with Assembly Exercises)
Computer Organization and Architecture
(CPSC 231 at UNBC)
Lecture + Labs
(Conceptual Explanation and Internals)
• Instruction Set Architecture
• Addressing modes
• Interrupts
• Pipelining
15. The problem
Architecture Complexity (simulators)
Low Student Engagement (a “fun” factor)
“Courses in computer architecture and organization […] involve intricate details
of the implementation and operation of the computer. […] This paper proposes a
simulator called EASE.
--Skillen et al
16. The problem
Architecture Complexity (simulators)
Low Student Engagement (a “fun” factor)
“The description [...] of internal computer operation is not an easy task. The
processes involved are sophisticated. […] visualization is one tool to deal with
the emerging complexity“
-- Yehezkel et al
(They propose EasyCPU)
17. The problem
Architecture Complexity (simulators)
Low Student Engagement (a “fun” factor)
“motivating students in an undergraduate assembly language course is a tremendous
challenge […] Our findings […] indicate that the […] Raspberry Pi […] contributed
positively to their learning outcomes
-- Kawash et al
“The description [...] of internal computer operation is not an easy task. The
processes involved are sophisticated. […] visualization is one tool to deal with
the emerging complexity“
-- Yehezkel et al
18. The problem
Architecture Complexity (simulators)
Low Student Engagement (a “fun” factor)
“SPIMbot [ a virtual robot simulator ] was written to provide an engaging environment
to motivate students to learn assembly language concepts”
--Zilles et al
“The description [...] of internal computer operation is not an easy task. The
processes involved are sophisticated. […] visualization is one tool to deal with
the emerging complexity“
-- Yehezkel et al
19. The problem
“motivating students in an undergraduate assembly language course is a tremendous challenge […] Our
findings […] indicate that the […] Raspberry Pi […] contributed positively to their learning outcomes
-- Kawash et al
“SPIMbot [ a virtual robot simulator ] was written to provide an engaging environment to motivate
students to learn assembly language concepts”
--Zilles et al
“The description [...] of internal computer operation is not an easy task. The processes involved
are sophisticated. […] visualization is one tool to deal with the emerging complexity“
-- Yehezkel et al
“Courses in computer architecture and organization […] involve intricate details of the
implementation and operation of the computer. […] This paper proposes a simulator called EASE.
--Skillen
20. The problem
“motivating students in an undergraduate assembly language course is a tremendous challenge […] Our
findings […] indicate that the […] Raspberry Pi […] contributed positively to their learning outcomes
-- Kawash et al
“SPIMbot [ a virtual robot simulator ] was written to provide an engaging environment to motivate
students to learn assembly language concepts”
--Zilles et al
“The description [...] of internal computer operation is not an easy task. The processes involved
are sophisticated. […] visualization is one tool to deal with the emerging complexity“
-- Yehezkel et al
“Courses in computer architecture and organization […] involve intricate details of the
implementation and operation of the computer. […] This paper proposes a simulator called EASE.
--Skillen
28. Simulators
Positive:
• Students find it interesting
• It’s a real architecture
• Students get to say that they’ve had some experience with x86
Negative:
• .
29. Simulators
Positive:
• Students find it interesting
• It’s a real architecture
• Students get to say that they’ve had some experience with x86
Negative:
• x86 bare-metal is hard!
• .
30. Simulators
Positive:
• Students find it interesting
• It’s a real architecture
• Students get to say that they’ve had some experience with x86
Negative:
• x86 bare-metal is hard!
• No debugger (too difficult to set up)
• .
31. Simulators
Positive:
• Students find it interesting
• It’s a real architecture
• Students get to say that they’ve had some experience with x86
Negative:
• x86 bare-metal is hard!
• No debugger (too difficult to set up)
• Almost a blackbox
.
32. Simulators
Positive:
• Students find it interesting
• It’s a real architecture
• Students get to say that they’ve had some experience with x86
Negative:
• x86 bare-metal is hard!
• No debugger (too difficult to set up)
• Almost a blackbox
• Only means of visualization was a rudimentary print function
.
33. Simulators
Positive:
• Students find it interesting
• It’s a real architecture
• Students get to say that they’ve had some experience with x86
Negative:
• x86 bare-metal is hard!
• No debugger (too difficult to set up)
• Almost a blackbox
• Only means of visualization was a rudimentary print function
• Only means of visualization was a buggy print function
34. Simulators
Positive:
• Students find it interesting
• It’s a real architecture
• Students get to say that they’ve had some experience with x86
Negative:
• x86 bare-metal is hard!
• No debugger (too difficult to set up)
• Almost a blackbox
• Only means of visualization was a rudimentary print function
• Only means of visualization was a buggy print function
Simulators makes sense.
(It’s easy to see why they’re so widely accepted as “the way”
of teaching architecture)
35. Simulators
“Hardware simulators are used to eliminate the burden of working on
a bare machine […] can provide sophisticated development, user
interface, testing, and debugging environments unavailable when
working on bare machine”
---Goldweber et al
36. Simulators
“Hardware simulators are used to eliminate the burden of working on
a bare machine […] can provide sophisticated development, user
interface, testing, and debugging environments unavailable when
working on bare machine”
---Goldweber et al
37. Simulators
“Hardware simulators are used to eliminate the burden of working on
a bare machine […] can provide sophisticated development, user
interface, testing, and debugging environments unavailable when
working on bare machine”
---Goldweber et al
Simulators make sense!
40. Solution
The reign of the simulator is over
All hail the MCU platform!
SAM4S MCU (32-bit ARM
Cortex-M4 core):
41. Solution
The reign of the simulator is over
All hail the MCU platform!
SAM4S MCU (32-bit ARM
Cortex-M4 core):
• Memory Protection
• Cache
• Atomic Loads/Restore
• Software Ints
• User mode and Kernel
mode
• Privileged/Unprivileged
Execution
45. MCU Advantages
Pros:
• Off-the-shelf debugging!
• The debugger is visual and interactive (like a simulator)
• Pause and Resume the CPU
• Inspect and modify: memory, registers, IO interfaces.
46. MCU Advantages
Pros:
• Off-the-shelf debugging!
• The debugger is visual and interactive (like a simulator)
• Pause and Resume the CPU
• Inspect and modify: memory, registers, IO interfaces.
• Simpler architecture
47. MCU Advantages
Pros:
• Off-the-shelf debugging!
• The debugger is visual and interactive (like a simulator)
• Pause and Resume the CPU
• Inspect and modify: memory, registers, IO interfaces.
• Simpler architecture
• e.g. Switching to user mode in x86 vs in ARM Cortex-M4
48. MCU Advantages
Pros:
• Off-the-shelf debugging!
• The debugger is visual and interactive (like a simulator)
• Pause and Resume the CPU
• Inspect and modify: memory, registers, IO interfaces.
• Simpler architecture
• e.g. Switching to user mode in x86 vs in ARM Cortex-M4
• Reduces effort and time to, say, switch to user mode, or set up the MPU
49. MCU Advantages
Pros:
• Off-the-shelf debugging!
• The debugger is visual and interactive (like a simulator)
• Pause and Resume the CPU
• Inspect and modify: memory, registers, IO interfaces.
• Simpler architecture
• e.g. Switching to user mode in x86 vs in ARM Cortex-M4
• Reduces effort and time to, say, switch to user mode, or set up the MPU
• Goes well with undergrad introductory courses (exposure, not expertise)
51. MCU Advantages
Pros:
• It’s good for student engagement
• Students get to play with sensors and actuators
• Their code gets to execute on real hardware
“fun” factor
53. Solution Part two
Guzdial argues that the amount of instruction matters when teaching
computer science to beginners:
54. Solution Part two
Guzdial argues that the amount of instruction matters when teaching
computer science to beginners:
“putting introductory students in the position of discovering
information for themselves is a bad idea”
55. Solution Part two
Guzdial argues that the amount of instruction matters when teaching
computer science to beginners:
“putting introductory students in the position of discovering
information for themselves is a bad idea”
“insofar as there is any evidence from controlled studies, it almost
uniformly supports direct, strong instructional guidance”
57. Solution Part two
An in-detail tutorial book
• Demonstrate Architecture
concepts
58. Solution Part two
An in-detail tutorial book
• Demonstrate Architecture
concepts
• Cover all technical details
necessary for lab
completion
59. Solution Part two
An in-detail tutorial book
• Demonstrate Architecture
concepts
• Cover all technical details
necessary for lab
completion
1. Introduction
2. ISA
3. Memory
4. IO
5. Stack
6. Interrupts
70. Solution Part two
An in-detail tutorial book
If the guide offers too many
details or too many steps, what
is left for the student to do?
More advanced things.
71. Solution Part two
An in-detail tutorial book
If the guide offers too many
details or too many steps, what
is left for the student to do?
More advanced things.
E.g.: Loader in Lab 3
(in previous years it was difficult enough to be a final project)
79. Evaluation
2017 Winter Semester CPSC 231
16 students total
14 participate in the survey,
1 student dropped the class.
Lacks any statistical significance. We use it to get
an idea of how students perceived the labs
80. Evaluation
2017 Winter Semester CPSC 231
16 students total
14 participate in the survey,
1 student dropped the class.
1=‘Strongly disagree’, 2=‘Disagree’, 3=‘Neutral’, 4=‘Agree’, and 5=‘Strongly agree’.
16 students total
14 participate in the survey,
1 student dropped the class.
81. Evaluation
2017 Winter Semester CPSC 231
16 students total
14 participate in the survey,
1 student dropped the class.
1=‘Strongly disagree’, 2=‘Disagree’, 3=‘Neutral’, 4=‘Agree’, and 5=‘Strongly agree’.
82. Evaluation
2017 Winter Semester CPSC 231
16 students total
14 participate in the survey,
1 student dropped the class.
1=‘Strongly disagree’, 2=‘Disagree’, 3=‘Neutral’, 4=‘Agree’, and 5=‘Strongly agree’.
85. Disadvantages
• Students will not be using MCUs in their workplace. They’ll be using
desktop architectures.
• MCUs have no MMU
86. Disadvantages
• Students will not be using MCUs in their workplace. They’ll be using
desktop architectures.
• MCUs have no MMU
• MCUs are still complex!
87. Disadvantages
• Students will not be using MCUs in their workplace. They’ll be using
desktop architectures
• MCUs have no MMU
• MCUs are still complex!
• MCUs have a Harvard architecture. We need to teach Von
Neumman! (Someone please think of the children!!)