CS计算机代考程序代写 compiler cache algorithm 5/2/2021 Exam 01 Multiple Choice: CMPSC 450 Spring 2021

5/2/2021 Exam 01 Multiple Choice: CMPSC 450 Spring 2021
Exam 01 Multiple Choice
Due Feb 12 at 8:50am Points 9 Questions 9
Available Feb 12 at 8am – Feb 12 at 8:50am about 1 hour Time Limit None
This quiz was locked Feb 12 at 8:50am.
Attempt History
Attempt Time Score
LATEST Attempt 1 18 minutes 6 out of 9
Score for this quiz: 6 out of 9 Submitted Feb 12 at 8:18am This attempt took 18 minutes.
Question 1
1 / 1 pts
What is the correct order from fastest to slowest of the following operations?
Bitwise integer math, Floating point add, Floating point divide, sin() Floating point add, Floating point divide, sin(), Bitwise integer math Floating point add, Bitwise math, sin(), Floating point divide
sin(), Bitwise math, Floating point divide, Floating point add
Correct!
Question 2
1 / 1 pts
https://psu.instructure.com/courses/2109084/quizzes/4153100
1/5

5/2/2021 Exam 01 Multiple Choice: CMPSC 450 Spring 2021
Using gcc on a modern Intel platform, how many bytes is an int?
Correct! orrect Answers
4
4 (with margin: 0)
Question 3
0 / 1 pts
ou Answered
orrect Answer Correct!
ou Answered orrect Answer
Which sections of the CPU utilizes pipelining? You may select more than one answer.
ALU
SIMD Instructions
Instruction Processing Unit Registers
Branch Prediction
L1 Cache
Question 4
0 / 1 pts
2 dimensional dense matrix-matrix multiplication is an example of what order algorithm?
https://psu.instructure.com/courses/2109084/quizzes/4153100
2/5

5/2/2021 Exam 01 Multiple Choice: CMPSC 450 Spring 2021
O(N)
ou Answered orrect Answer
O(N^3) O(N^4)
O(N^2)
Question 5
1 / 1 pts
This term is when the compiler replaces a function call with the source code in the function:
inlining
out of order execution loop unrolling
look-up table
Correct!
Question 6
1 / 1 pts
One problem with multi-dimensional data/math is that:
Multi-dimensional math requires a Superscalar architecture, i.e. a new floating point multiply unit for each new dimension.
https://psu.instructure.com/courses/2109084/quizzes/4153100
3/5

5/2/2021 Exam 01 Multiple Choice: CMPSC 450 Spring 2021
Correct!
Question 7
1 / 1 pts
A serial algorithm takes T = O(N^2) time to complete. What is the work?
O(1) O(N) O(N^2) O(N^3)
Correct!
Correct!
Standard computer cache line based memory is one-dimensional. Keeping track of the dimensions is difficult for modern CPU’s. Multi-dimensional matrices are bigger on the inside.
Question 8
1 / 1 pts
What is a particular danger that must be avoided with shared memory programming?
Deadlock
Data race cases Pipeline bubbles Branch prediction fails
https://psu.instructure.com/courses/2109084/quizzes/4153100
4/5

5/2/2021 Exam 01 Multiple Choice: CMPSC 450 Spring 2021
A serial algorithm takes O(N^3) time to complete. What is the best case execution time given P processors?
orrect Answer ou Answered
O(log N) O(N) O(N^3) / P
Question 9
0 / 1 pts
O(N^3) / P + O(N^3)
Quiz Score: 6 out of 9
https://psu.instructure.com/courses/2109084/quizzes/4153100
5/5