Name: | __________________ |
Student ID: | __________________ |
Total points:
- What were some of the groundbreaking innovations in Engelbart's NLS
prototype demonstration in 1968?
mouse, windowing system, hyperlinks, chording keyboard,
collaborative work (email, IM, video conf)
- Name at least three early GUI environments of the 1980's, besides
Microsoft Windows and Apple MacOS.
Atari GEM, Amiga, NeXTstep, OS/2, Unix X11, Xerox Star/Smalltalk
- What are events and callbacks? Describe an example.
An event is an action, usually triggered by the user: e.g., clicking on a
button, selecting a menu item, pressing Enter, moving the mouse. A callback
is a procedure/function
invoked when a corresponding event happens. For example, the exit() function
might be run when the user clicks on a "Quit" button.
- What are the FLTK components needed to develop an FLTK program?
FLTK include files (e.g., FL/Fl_Window.h), FLTK shared or static libraries
(e.g., libfltk.a or libfltk_dll.a or libfltk.so). Fluid is also handy.
- The CubeView tutorial example in Lab0 had three C++ files: CubeView.cxx,
CubeMain.cxx, and CubeViewUI.cxx. Why have three files? Contrast their
purposes.
CubeMain was very small, just had the main() function and kicked off an
instance of CubeViewUI. CubeViewUI was generated by fluid, and just contained
the user interface widgets. The primary functionality was in CubeView.cxx, in
a class that was used/instantiated by CubeViewUI.
- Describe a complete human-computer interface other than our standard
keyboard, monitor, mouse/touchpad/etc. Describe an application for which this
interface might be better-suited than our traditional interface.
- Name three out of the five user interface design principles we discussed
in class.
- Know your users
- Be consistent
- Use metaphors carefully
- Allow multiple levels of complexity (let the user tradeoff safety for
control)
- Always show the current state of the program
- Attached is a printout of
A List Apart's (website design group)
frontpage. Critique their user interface design: good points and bad points.
Bear in mind that this is a static printout of a website.
- Describe at least four applications well-suited to parallel computing.
Weather modelling, computational fluid dynamics, metallurgy, modelling a
nuclear blast without actually setting one off, aircraft design, protein
folding, off-line 3D rendering, large-scale satellite image analysis, large
websites, data mining, etc.
- Describe the vonNeumann model of computing.
A computer processes input data according to input
instructions, and produces output results.
The computer's memory can store both the input data as well as the instructions.
- Describe Flynn's taxonomy of parallel computing.
- SISD: single instruction single data: serial computing
- SIMD: single instruction multiple data: multiple processors each perform
the same set of instructions, but on different data in parallel. Also called
vector processing.
- MISD: multiple instruction, single data: run the same data through
different operations in parallel. Not often used.
- MIMD: multiple instruction, multiple data: each processor independently
runs a different task on different data. Most modern supercomputers fall into
this category.
- Describe the (1) shared, (2) distributed, and (3) hybrid memory models of
parallel computing. Draw the diagrams illustrating how memory and processors
are tied together. What are the advantages/disadvantages of shared memory vs.
distributed memory models?
- Describe the three parallel programming (API) models we discussed in
class, and name an example API for each. (The fourth programming model we
talked about is hybrids of these three.)
- Threads: master thread forks worker threads; collects results when threads
complete. OpenMP, POSIX Threads.
- Message passing: threads communicate by sending messages to each other.
MPI.
- Data parallelism: each thread performs same work in parallel on a
different chunk of the data. HPF.
- Compare the pros/cons of OpenMP vs. MPI.
OpenMP uses the threading model instead of the message-passing model, is easier
to program in and easier to add-on to existing serial code. The programmer
need not know how many processors the program is actually using. It is generally
more well-suited to a shared-memory model. MPI is more complex to program in
but provides more control over synchronization and communication. MPI often
scales up better to more processors; it is more appropriate for
distributed-memory models.
- What is a semaphore? Describe an OpenMP construct that implicitly uses a
semaphore.
- Write a complete OpenMP C/C++ procedure to do the dot-product of two
float arrays of the same length:
float dotproduct(int len, float vec1[], float vec2[]);