This shows you the differences between two versions of the page.
cpl:labs:08 [2016/10/04 07:51] bogdan.nitulescu |
cpl:labs:08 [2017/11/21 06:52] (current) bogdan.nitulescu [Exercițiul 3] |
||
---|---|---|---|
Line 1: | Line 1: | ||
===== 08. LLVM backend ===== | ===== 08. LLVM backend ===== | ||
- | |||
- | **TO BE UPDATED SOON** | ||
- | <note warning>Exemplele de mai jos folosesc LLVM 3.6 - codul va fi ușor diferit pentru a folosi noile facilități din 3.8</note> | ||
===== Nice to read ===== | ===== Nice to read ===== | ||
Line 305: | Line 302: | ||
După ce ați modificat toate fișierele, compilați **llc** cu suport pentru noul target: | După ce ați modificat toate fișierele, compilați **llc** cu suport pentru noul target: | ||
- | cd ~/packages/llvm-3.6.2/build | + | cd ~/packages/llvm-3.8.0/build |
cmake -DLLVM_TARGETS_TO_BUILD=Cpl path_to_llvm_src | cmake -DLLVM_TARGETS_TO_BUILD=Cpl path_to_llvm_src | ||
make -j2 llc | make -j2 llc | ||
+ | |||
+ | Codul sursa LLVM poate fi descărcat de pe [[http://llvm.org/releases/3.6.0/llvm-3.6.0.src.tar.xz|llvm.org]] | ||
+ | |||
Pentru a testa, compilați fișierul ex3.a.ll folosind opțiunea ''-filetype=null'' pentru llc. | Pentru a testa, compilați fișierul ex3.a.ll folosind opțiunea ''-filetype=null'' pentru llc. | ||
<note warning> | <note warning> |