Fun with using LLVM IR to implement Kaleidoscope
-
Get kaleidoscope:
git clone https://github.com/atsmtat/kaleidoscope.git
-
Get llvm:
- on macOs,
brew install llvm
will install the includes and libs in/usr/local/opt/llvm
- update path:
export PATH="/usr/local/opt/llvm/bin:$PATH"
to use llvm-config util to get build flags.
- on macOs,
-
Configure, build, and install kaleidoscope:
cd kaleidoscope
mkdir build
cd build
cmake ..
cmake --build .
make install