You are on page 1of 4

news

Society | DOI:10.1145/3148760 Keith Kirkpatrick

Parallel Computational
Thinking
Applications must be programmed to process instructions in
parallel to take full advantage of the new multicore processors.

W
HEN LEARNING A new
skill, it is often advanta- Amdahl’s Law
geous to start out sim- 20
ply, and then incorpo-
18
rate greater complexity
Parallel portion
as the learner gains greater experience, 50%
16
expertise, and familiarity with the sub- 75%
ject at hand. 14 90%
Indeed, most computer science edu- 95%
cation has followed that line of thinking, 12
Speedup

teaching beginning computer science


students to write programs that perform 10
one instruction at a time, and then move
on to the next instruction. This is known 8

as sequential programming, and it has


6
largely been the accepted model of com-
puter science instruction at both the 4
university and K–12 levels, in contrast
with parallel computing, a model of pro- 2
gramming where multiple instructions
are processed simultaneously. 0
“The educational system is, mostly
1

16

32

64

128

256

512

1024

2048

4096

8192

16384

32768

65536
through inertia, still focused on the
Number of processors
computing paradigm of the 20th centu-
ry, which was one processor executing A chart illustrating Amdahl’s Law, which says the speed-up of a program from parallelization
instructions one after another, so al- is limited by how much of the program can be parallelized.
gorithmic problem-solving was mainly
oriented toward a sequential model,” students to think and program in par- has run its course. We have added other
explains Charles (Chip) Weems, an as- allel will not only better prepare them forms of parallelism that do not hide the
sociate professor of computer science to code and program these devices, but issue as much for programmers.”
at the University of Massachusetts. also helps to train their minds to think Computing societies have recog-
Today, however, nearly all applica- in abstractions to solve problems, rath- nized the need to incorporate parallel-
tions running on smartphones, tab- er than simply in terms of writing code. ism as part of a core collegiate comput-
lets, and PCs, are powered by multi- “Computer architectures have been er science curriculum. The ACM and
core processors, which are necessary doing parallelism at the instruction level the IEEE jointly introduced new guide-
when working with the large datasets for decades in a way that the vast major- lines in 2013, and recommended inte-
that drive both consumer applications, ity of programmers can ignore that it’s grating parallel education throughout
such a Twitter or Facebook feed, as well there,” says Dan Grossman, a professor the curriculum. Although these are
as business and commerce-related ap- at the Paul G. Allen School of Computer only guidelines, and most universities
IMAGE BY DA NIELS22 0/W IKIMEDIA CC BY- SA 3 .0

plications, such as travel deal sites, Science & Engineering at the University still tend to teach parallel program-
weather applications, and real-time of Washington, and a member of the ming concepts only to more advanced
traffic data. To take full advantage of ACM steering committee on computing students, there is a growing push to in-
these multicore processors, program- curricula, which concluded its work in corporate parallelism in college-level
ming applications to process instruc- 2013. “If that had remained the only form programming courses from the start.
tions in parallel—which allows multi- of parallelism, there would be a much “In the last 15 years, systems have
ple instructions to be processed at the weaker argument for teaching parallel- gone almost entirely parallel,” Weems
same time—is required. ism at the undergraduate level. But that says. “Unless you’re talking about
Teaching new computer science has not remained the dominant form; it small embedded systems, everything

DEC E MB E R 2 0 1 7 | VO L. 6 0 | N O. 1 2 | C OM M U N IC AT ION S OF T HE ACM 17


news

you might encounter is a multicore in still having to choose among algo-


that’s multithreaded, and nearly every- rithmic approaches,” Weems says.
thing comes with a graphics processor, When a student learns “There are times when communicat-
which can be programmed.” parallelism, it “helps ing via shared memory is most effec-
Moreover, programming in paral- tive, while in other cases it’s better
lel—and training students to think at them develop a more to work locally and communicate via
a higher level—allows for program- flexible approach messages, or to use a combination of
ming to be more direct and concise, these approaches at different levels of
compared with sequential program- to problem solving granularity. [Parallelism] forces pro-
ming, according to Guy Blelloch, a because there are grammers to look more explicitly and
professor and Associate Dean for holistically at the interactions that
Undergraduate Programs in the com- more algorithmic take place among the data and opera-
puter science department at Carnegie models to draw upon.” tions in solving the problem, by con-
Mellon University. “It’s not so much sidering them from more perspectives
that parallel code is simpler than se- than the sequential model.”
quential code, it’s that in the abstrac- Weems, a member of the working
tion of code [it] basically makes [the group for the Center for Parallel and
problem to solved] simpler and at the of it is I just want to add five to every Distributed Computing Curriculum
same time makes it parallel.” element in the array. By doing the par- Development and Educational Re-
Blelloch, who notes that CMU teach- allelism, you’re more focusing on the sources (CDER), which is funded by
es parallelism from the start in its In- underlying ideas, as opposed to getting the U.S. National Science Foundation
tro to Data Structures and Algorithms stuck in details of loops.” (NSF), also notes that there is a de-
Course during the first semester of Another added benefit of parallel- mand for new programmers who have
sophomore year, says that by teaching ism, Weems says, is that when a stu- parallel programming skills, from gov-
beginning computer science students dent learns parallel programming, it ernment science labs as well as large
to think about problems in terms of “helps them develop a more flexible technology industry companies.
abstractions, they are able to move approach to problem solving because Some major universities, includ-
beyond a basic understanding of pro- there are more algorithmic models ing the University of Massachusetts,
gramming to get the heart of the mat- to draw upon.” While there’s also the where Weems is a faculty member,
ter of actually solving problems. added benefit of learning how to break have begun to incorporate parallel-
“There’s a lot of emphasis on intro apart larger problems into simpler ism into their curricula, with prom-
programming on a loop,” Blelloch says. ones, parallelism also requires pro- ising results. For example, a faculty-
“And that’s really not that interesting. grammers to learn to see alternate ab- authored paper from Texas State
Often you just want to be thinking, stractions of the problem. University highlights the success
‘I want to add five to every element in “There are situations where a of its new curriculum, which was
this array.’ I could start the loop at the problem can be decomposed into launched in the 2016–2017 academic
beginning, but the right way to think subtasks, but various factors result year. According to the paper, parallel

Technology

Out of Sight, Into Mind


French researchers are la Vision in Paris, France, who is computer. Once processed, the engage more than one million
developing a video technology working with Jose Alain Sahel, the visual signal will be broadcast to neurons in parallel, NESD
that will completely bypass Institut’s director, to return sight wireless devices the researchers aims to enable rich, two-way
the eyes and project an image to those who live in darkness. plan to implant inside the brain, communication with the brain at
directly into one’s brain. Both Picaud and Sahel are part which in turn will fire individual a scale that will help deepen our
Essentially, they want to enable of a larger, $21.6-million initiative neurons in the brain’s visual understanding of that organ’s
the blind to see again, without ever overseen by the U.S. Defense cortex to create sight. underlying biology, complexity,
having to rely on the human eye. Advanced Research Projects “The implanted devices and function.”
The researchers have been Agency (DARPA), which is looking containing LED arrays will “Its deeper complexities are
partially successful in their quest; to use technology to enable the deliver light stimuli on the visual going to remain a mystery for
so far, they have found a way to blind to see, the deaf to hear, and cortex,” Sahel says. some time to come,” Alvelda
model how the human retina the speech-impaired to talk. Picaud and Sachel will be adds, “but if we’re successful in
captures visual information Picaud and Sahel hope experimenting on animals before delivering rich sensory signals
using machine vision, a camera, their nascent technology will they move into the human brain. directly to the brain, NESD will
and a computer. ultimately work by using a Says Phillip Alvelda, manager lay a broad foundation for new
“We aim at extending this specially designed machine of DARPA’s Neural Engineering neurological therapies.”
modeling to the visual cortex” vision camera from Chronocam, System Design (NESD) program, —Joe Dysart is an Internet
of the brain, says Serge Picaud, which will feed imagery from “By increasing the capacity of speaker and business consultant
scientific supervisor at Institut de the outside world into a pocket advanced neural interfaces to based in Manhattan.

18 COMM UNICATIO NS O F THE ACM | D EC EM BER 201 7 | VO L . 60 | NO. 1 2


news

computing concepts are introduced what more conservative approach,” he


and reiterated via a series of short, says. “They’ve taught this course for
self-contained modules across sever- “We live in a world 20 years in a particular way and it’s not
al lower division courses. Then, most of multicore devices, very hard to add three weeks at the end
concepts are combined into a senior- which makes them think in parallel.”
level capstone course in multicore but I don’t know Perhaps the larger question for com-
programming. The evaluations con- if we should be puter science educators revolves around
ducted during the first year displayed selecting the right material to introduce
encouraging results for the early-and- teaching [parallel to beginning computer science students.
often approach in terms of learning programming] to “It’s very tempting in computer sci-
outcomes, student interest, and con- ence education to think that we do stu-
fidence gains in computer science. everyone. It may be dents a service if we introduce ‘x’ from
Still, some educators are not con- better off to start day one, for various values of ’x’, and
vinced that introducing parallelism you’re asking about ‘x’ being parallel-
during introductory or lower-division with sequential ism,” Grossman says. “I do see value in
computer science courses is necessary programming.” that, but I also see value in introducing
in order to produce well-trained com- security from day one. I see value in intro-
puter programmers of the future. ducing ethics from day one. I also see the
“We live in a world of multicore de- value of introducing performance from
vices,” says Mark Guzdial, a professor day one. But there’s only one day one.
in the School of Interactive Comput- younger kids, sequential, logical step- “Everyone who crafts a curriculum
ing at the Georgia Institute of Technol- ping is an important foundation for has to make choices about what they
ogy. “But I don’t know if we should be learning how to think logically.” introduce from the beginning as the
teaching [parallel programming] to ev- Lynn does note that some platforms default way to think about a program,
eryone. It may be better off to start with may provide some exposure to parallel compared with what they push off until
sequential programming, and then programming. “At times however, plat- later,” Grossman says. “Trade-offs are
move on to parallel.” forms such as Scratch do allow kids to trade-offs, and people can spend their
Whether to teach elements of par- get some exposure to parallel program- lives studying pedagogy.”
allelism in early coursework may also ming (such as multiple objects moving
depend on the focus of the coursework, and detecting collision simultaneous-
Further Reading
Grossman says, noting that the key to in- ly),” Lynn says. “While we may create
tegrating parallelism is to limit the com- projects with parallel programming Grossman, M., Aziz, M., Chi, H.,
Tibrewal, A., Imam, S., and Sarkar, V.
plexity of the program itself, by ensuring concepts embedded, we don’t typically
Pedagogy and tools for teaching parallel
that computations and variables are not focus on parallel thinking, as we find it computing at the sophomore undergraduate
highly dependent upon one another dilutes the focus on building their se- level, Journal of Parallel and Distributed
during parallel processing operations. quential logic thinking skills.” Computing, Volume 105 Issue C,
“The way to get parallelism to work Whether at the collegiate or second- July 2017, pp. 18-30
http://dl.acm.org/citation.cfm?id=3085740
correctly is to have as fewer shared ary level, there are challenges related to
variables as you can that can change,” revamping the curriculum to include Burtscher, M., Peng, W., Qasem, A.,
Shi, H., Tamir, D., and Thiry, H.
Grossman says, noting instead of set- parallelism. First, many professors have
Integrating Parallel Computing into the
ting up a single variable that may not had been exposed to parallelism Undergraduate Curriculum at Texas State
change its value, it may make more on a programming level, particularly if University: Experiences from the First Year
sense to simply program a second vari- they were educated before parallel pro- http://bit.ly/2tl7rpe
able that can hold the second value. cessing became mainstream, which oc- Computer Science Curricula 2013:
“There are different ways to teach curred about a decade or so ago. There Curriculum Guidelines for Undergraduate
introductory programming without are also non-technical issues, such as Degree Programs in Computer Science
getting buy-in from other faculty mem- The Joint Task Force on Computing
parallelism that make it harder or
Curricular: Association for Computing
easier to add parallelism later,” Gross- bers, as well as the challenge of updat- Machinery IEEE Computer Society
man adds. “For initial exposure to ing online tutorials and auto-graders, December 20, 2013
programming for younger, pre-college which must be revamped to deal with http://www.acm.org/education/CS2013-
students, I haven’t seen much focus on different types of code. Additionally, final-report.pdf
parallelism and I think that’s fine.” textbooks need to be augmented or Video:
Hansel Lynn owns Silicon Valley- amended, as many introductory texts
Parallel Computing Explained:
based theCoderSchool, an afterschool don’t cover parallelism. “There was one
https://www.youtube.com/
coding instruction franchise that that mentioned concurrency, but it was watch?v=q7sgzDH1cR8
works exclusively with children ages 8 in Chapter 23,” Weems quips.
to 18. Lynn believes sequential coding Blelloch says that the trend, for now, Keith Kirkpatrick is principal of 4K Research &
should be taught first. “For kids aged is to simply add a discussion about par- Consulting, LLC, based in Lynbrook, NY.
8–18, we always teach sequential cod- allelism to existing coursework. “I think
ing first,” Lynn says. “Especially for most departments are taking a some- © 2017 ACM 0001-0782/17/12 $15.00

DEC E MB E R 2 0 1 7 | VO L. 6 0 | N O. 1 2 | C OM M U N IC AT ION S OF T HE ACM 19


Copyright of Communications of the ACM is the property of Association for Computing
Machinery and its content may not be copied or emailed to multiple sites or posted to a
listserv without the copyright holder's express written permission. However, users may print,
download, or email articles for individual use.

You might also like