Presentation is loading. Please wait.

Presentation is loading. Please wait.

OpenMP Quiz.

Similar presentations


Presentation on theme: "OpenMP Quiz."— Presentation transcript:

1 OpenMP Quiz

2 Because Dr. Ferner said so.
Why is OpenMP designed such that it necessary to place the opening braces on a new line after an OpenMP directive rather than on the same line? For example: #pragma omp parallel { ... } Because Dr. Ferner said so. You do not need to place the braces on the next line. It can be on the same line. So that compilers that do no recognize the directive can still continue with the next line without a syntax error and interpret the code as sequential code. None of the other answers

3 Which directive must precede the directive:
#pragma omp sections (not necessarily immediately)? #pragma omp section (b) #pragma omp parallel (c) None (d) #pragma omp master (e) None of the other answers

4 When compiling an OpenMP program with gcc, what flag must be included?
-fopenmp #pragma omp parallel (c) –o hello (d) ./openmp (e) None of the other answers

5 Within a parallel region, declared variables are by default ________ .
Private Local (c) Loco (d) Shared (e) None of the other answers

6


Download ppt "OpenMP Quiz."

Similar presentations


Ads by Google