-
Notifications
You must be signed in to change notification settings - Fork 65
/
openmp-examples.tex
115 lines (97 loc) · 3.65 KB
/
openmp-examples.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
% Welcome to openmp-examples.tex.
% This is the main LaTex file for the OpenMP Examples document.
%
% The files in this set include:
%
% openmp-examples.tex - this file, the main file
% Makefile - makes the document
% openmp.sty - the main style file
% Title_Page.tex - the title page
% openmplogo.png - the logo
% Forward_Chapt.tex - unnumbered introductory chapter
% Chap_*.tex - example chapters
% */sources/*.c, *.f - C/C++/Fortran example source files
%
% When editing this file:
%
% 1. To change formatting, appearance, or style, please edit openmp.sty.
%
% 2. Custom commands and macros are defined in openmp.sty.
%
% 3. Be kind to other editors -- keep a consistent style by copying-and-pasting to
% create new content.
%
% 4. We use semantic markup, e.g. (see openmp.sty for a full list):
% \code{} % for bold monospace keywords, code, operators, etc.
% \plc{} % for italic placeholder names, grammar, etc.
%
% 5. Other recommendations:
% Use the convenience macros defined in openmp.sty for the minor headers
% such as Comments, Syntax, etc.
%
% To keep items together on the same page, prefer the use of
% \begin{samepage}.... Avoid \parbox for text blocks as it interrupts line numbering.
% When possible, avoid \filbreak, \pagebreak, \newpage, \clearpage unless that's
% what you mean. Use \needspace{} cautiously for troublesome paragraphs.
%
% Avoid absolute lengths and measures in this file; use relative units when possible.
% Vertical space can be relative to \baselineskip or ex units. Horizontal space
% can be relative to \linewidth or em units.
%
% Prefer \emph{} to italicize terminology, e.g.:
% This is a \emph{definition}, not a placeholder.
% This is a \plc{var-name}.
%
% The following says letter size, but the style sheet may change the size
\documentclass[10pt,letterpaper,twoside,makeidx,hidelinks]{scrreprt}
% input a generated file with additional definitions
\input{generated-include}
% Text to appear in the footer on even-numbered pages:
\newcommand{\footerText}{OpenMP \langselect Examples Version \VER{} -- \VERDATE}
% Unified style sheet for OpenMP documents:
\input{openmp.sty}
\makeindex
\begin{document}
\pagenumbering{roman}
\input{Title_Page}
\input{Foreword_Chapt}
\thispagestyle{empty}
\newpage
\setcounter{page}{1}
\setcounter{tocdepth}{2}
\begin{spacing}{1.3}
\tableofcontents
\clearpage
\listoffigures
\vspace*{5ex}
\listoftables
\end{spacing}
% Uncomment the next line to enable line numbering on the main body text:
\linenumbers\pagewiselinenumbers
\cleardoublepage
\pagenumbering{arabic}
\setcounter{chapter}{0} % start chapter numbering here
\input{Chap_introduction}
\input{Chap_directives}
\input{Chap_parallel_execution}
\input{Chap_affinity}
\input{Chap_tasking}
\input{Chap_devices}
\input{Chap_SIMD}
\input{Chap_loop_transformations}
\input{Chap_synchronization}
\input{Chap_data_environment}
\input{Chap_memory_model}
\input{Chap_program_control}
\input{Chap_ompt_interface}
\setcounter{chapter}{0} % restart chapter numbering with "letter A"
\renewcommand{\thechapter}{\Alph{chapter}}%
\appendix
\input{Deprecated_Features}
\input{History}
\nolinenumbers
\clearpage
\phantomsection
\addcontentsline{toc}{chapter}{Index}
\printindex
\end{document}