1 \documentclass[hyperref={pdfpagelabels=false}]{beamer}
3 %\setbeameroption{show notes}
10 \setbeamercovered{transparent}
11 %\setbeamertemplate{footline}[frame number]
14 \usepackage[english]{babel}
15 \usepackage[latin1]{inputenc}
17 \usepackage[T1]{fontenc}
20 \usepackage{multimedia}
21 \usepackage{subfigure}
23 % Can use a tiny fontsize
27 %\usepackage{pgfpages}
28 %\pgfpagesuselayout{4 on 1}[a4paper,border shrink=5mm]
30 %For handouts, use the following two lines:
31 %\usepackage{pgfpages}
32 %\pgfpagesuselayout{2 on 1}[a4paper,border shrink=5mm]
36 {MontiumC Transforming}
38 \author {Matthijs Kooijman}
40 \institute[Recore Systems and University of Twente]
46 Faculty of Electrical Engineering, Mathematics and Computer Science\\
56 \begin{frame}{Contents}
60 \section{Introduction}
61 \begin{frame}{Montium Tile Processor}
63 \item Explicitely parallel processor
64 \item Multilevel reconfiguration
65 \item Separate memory addressing units
66 \item Data oriented, limited control flow
67 \item Redesign on the way
71 \begin{frame}{MontiumC}
74 \item Operations on data using MontiumC API
75 \item Compilable by gcc (as C++)
76 \item Under constant improvement
80 \begin{frame}{Low Level Virtual Machine (LLVM)}
82 \item Compiler framework.
86 \item Intermediate representation (LLVM IR)
87 \item Transformation passes
88 \item Native codegenerators
95 \begin{frame}{Compiling MontiumC}
96 \pgfdeclareimage[width=\textwidth]{Compiling}{images/Compiling}
97 \pgfuseimage{Compiling}
99 \item Focus: montiumccfe and transformations
105 \subsection{Original tasks}
106 \begin{frame}{Original tasks}
108 \item Select LLVM transformations
109 \item Improve and add transformations
110 \item Provide debugging information
114 \subsection{Extra tasks}
115 \begin{frame}{Extra tasks}
117 \item What is MontiumC?
118 \item What is Montium IR?
119 \item Reconfigurable binaries
123 \begin{frame}{What is MontiumC?}
124 \note{Two angles: What do we want, and what do we support.}
126 \item Status: Specification is ongoing
129 \item Clang is nontransparent
130 \note[item]{Clang --- A lot of special cases}
132 \note[item]{Complex C --- A lot of corner cases}
134 \note[item]{Limited C --- Need to use annotations, limited amount of types}
135 \item Assembly vs. High level
136 \note[item]{Tradeoffs -- Code size vs compiler complexity, clarity
137 vs control, clarity vs determinism}
142 \begin{frame}[containsverbatim]
144 \begin{column}{0.5\textwidth}
146 \begin{Verbatim}[fontsize=\tiny]
152 factor = from_int(2);
153 input = alloc_mem(P0M0);
154 output = alloc_mem(P0M1);
156 set_offset(input, 0);
157 set_base(output, -1);
158 set_offset(output, -1);
161 word in = read_mem(input);
162 word out = p0o0(imul(ra1(in), rc1(factor)))
163 add_offset(input, 1);
164 add_offset(output, 1);
167 write_mem(output, out);
168 in = read_mem(input);
169 out = p0m0(imul(ra1(in), rc1(factor)))
170 add_offset(input, 1);
171 add_offset(output, 1);
172 } while(loop_next(LC1));
174 write_mem(output, out);
177 \begin{column}{0.5\textwidth}
179 \begin{Verbatim}[fontsize=\tiny]
184 for (int i=0; i<10; ++i)
185 output[i] = input[i] * 2;
191 \note{} % Empty filler note page
193 \begin{frame}{What is Montium IR?}
195 \item Status: Initial version
198 \item Backend is a fast moving target
200 \note[item]{Corner case --- global constants}
201 \item Hardware dependencies
202 \note[item]{Hardware --- Limited number of conditionals possible}
207 \begin{frame}{Selecting LLVM transformations}
212 \item LLVM Passes assume a lot
213 \note[item]{Assumptions --- Immediates are not free}
214 \item Montium has specific constraints
215 \note[item]{Constraint --- Implicit cycle boundaries and ordering}
220 \begin{frame}{Improving / adding transformations}
222 \item Status: Ongoing
225 \item Staying generic
226 \note[item]{Generic --- LLVM maintained passes are a lot easier}
227 \item New LLVM features
228 \note[item]{Features --- Multiple return values, inlining and
229 annotation attributes}
234 \begin{frame}{Debugging information}
236 \item Status: Not started
239 \item Not much LLVM support yet
240 \note[item]{LLVM support --- New in clang/backend, no support in
241 transformations yet.}
242 \item Transformations
243 \note[item]{Transformations --- Global arguments, argument addition,
249 \begin{frame}{Reconfigurable binaries}
251 \item Status: Recently started
254 \item Tracking variables
255 \note[item]{Tracking --- Through all steps of the process}
256 \item Loss of optimizations
257 \note[item]{Optimizations --- Hard to encode constraints}
258 \item Mostly a backend problem
263 \section{Work process}
264 \begin{frame}{Working at Recore}
267 \item Fast communication
268 \note[item]{Communication --- Mixed teams, easy to "listen in".}
269 \item Constructive brainstorming
270 \note[item]{Brainstorming --- Evaluating different ideas and approaches.}
274 \begin{frame}{Working with LLVM}
276 \item Large community
277 \note[item]{Community --- Companies involved, a lot of full time
280 \note[item]{Support --- mailing list, bug reports solved within 1/2 days.}
281 \item Slightly conflicting goals
282 \note[item]{Goals --- LLVM aims mainly at "regular" architectures.}
286 \section{Conclusions}
287 \begin{frame}{Conclusions}
289 \item LLVM is very suitable
290 \item Defining the problem is harder than solving it
291 \item Three months is short!