• Home
  • Raw
  • Download

Lines Matching +full:get +full:- +full:conclusion

2 Kaleidoscope: Conclusion and other useful LLVM tidbits
8 Tutorial Conclusion
14 being a semi-interesting (but probably still useless) toy. :)
18 interactive run-loop (with a JIT!) by-hand in under 700 lines of
19 (non-comment/non-blank) code.
32 - **global variables** - While global variables have questional value
40 - **typed variables** - Kaleidoscope currently only supports variables
47 - **arrays, structs, vectors, etc** - Once you add types, you can start
51 LLVM `getelementptr <../LangRef.html#getelementptr-instruction>`_ instruction
57 - **standard runtime** - Our current language allows the user to access
59 and "putchard". As you extend the language to add higher-level
61 lowered to calls into a language-supplied runtime. For example, if
64 - **memory management** - Currently we can only access the stack in
71 - **debugger support** - LLVM supports generation of `DWARF Debug
75 C/C++ code with "``clang -g -O0``" and taking a look at what it
77 - **exception handling support** - LLVM supports generation of `zero
83 - **object orientation, generics, database access, complex numbers,
84 geometric programming, ...** - Really, there is no end of crazy
86 - **unusual domains** - We've been talking about applying LLVM to a
95 Have fun - try doing something crazy and unusual. Building a language
97 little crazy or off the wall and seeing how it turns out. If you get
98 stuck or want to talk about it, feel free to email the `llvm-dev mailing
99 list <http://lists.llvm.org/mailman/listinfo/llvm-dev>`_: it has lots
111 We have a couple common questions about code in the LLVM IR form - lets
112 just get these out of the way right now, shall we?
115 -------------------
125 Kaleidoscope-compiled program and run it on any target that LLVM
128 compiler generates target-independent code because it never queries for
129 any target-specific information when generating code.
131 The fact that LLVM provides a compact, target-independent,
137 course, C source code is not actually portable in general either - ever
138 port a really old application from 32- to 64-bits?).
142 preprocessor often destructively removes target-independence from the
145 .. code-block:: c
159 32-bits, and long = 64-bits), don't care about ABI compatibility with
162 such as an in-kernel language.
165 -----------------
175 casts, use after free bugs, buffer over-runs, and a variety of other
177 conveniently, several groups have investigated this. Ask on the `llvm-dev
178 mailing list <http://lists.llvm.org/mailman/listinfo/llvm-dev>`_ if
181 Language-Specific Optimizations
182 -------------------------------
188 high-level language-specific optimization: LLVM "loses too much
197 SSA-value came from a C "int" or a C "long" on an ILP32 machine (other
198 than debug info). Both get compiled down to an 'i32' value and the
202 have two types in a high-level language that have the same structure
213 user-driven: people want LLVM to include some specific feature, so they
216 Third, it is *possible and easy* to add language-specific optimizations,
218 example, it is easy to add language-specific optimization passes that
226 variety of other language-specific information into the LLVM IR. If you
228 the llvm-dev list. At the very worst, you can always treat LLVM as if it
229 were a "dumb code generator" and implement the high-level optimizations
230 you desire in your front-end, on the language-specific AST.
241 -------------------------------------
250 width of a pointer is trivially target-specific. However, there is a
252 instruction <http://nondot.org/sabre/LLVMNotes/SizeOf-OffsetOf-VariableSizedStructs.txt>`_
256 ------------------------------
263 if you want. It requires your front-end to convert the code into
265 Style <http://en.wikipedia.org/wiki/Continuation-passing_style>`_ and