Comments (5)
Yep, Triton will compile LLVM 11.0 from scratch and link against it. I've been meaning to embed pre-compiled static libraries instead, but ran into some issues. I've compiled Triton successfully on all my linux machines, with GCC 7.5+.
Alternatively, you can also just install the latest wheel. pip install -U --pre triton
from triton.
I appreciate the reply. I am having a bit trouble to compile 11.0 from scratch, but I do have binary distribution of 11.0 available. Is there a way I can bypass the download and recompile, and use the existing compiler distribution? Thanks
from triton.
Replacing llvm-src by pre-compiled static libraries is actually something I've been meaning to do for a while. My current plan is to do it in ~2 weeks. The only solution I can think of would be to hack the CMakeLists.txt so that it links against LLVM without compiling it. As long as the the include_dir is there and the proper libraries are linked against triton, then it should be good
from triton.
I made some progress: I was able to compile successfully C++ interface with python module ON
, with downloaded llvm 11, the last few snippet is:
[ 96%] Built target LLVMLibDriver
[ 97%] Built target LLVMXRay
[100%] Built target triton
[100%] Built target LLVMHello_exports
[100%] Built target LLVMHello
and I have libtriton.so
in triton/build
directory. Then, I went to triton/python
directory, and hope to build out the python module: python setup.py build
, but I ran into bunch of errors, see below:
...
-- Targeting NVPTX
-- Adding Python module
--
-- Configuring done
-- Generating done
...
71%] Linking CXX static library ../../libLLVMInstrumentation.a
[ 71%] Built target LLVMInstrumentation
c++: internal compiler error: Killed (program cc1plus)
Please submit a full bug report,
with preprocessed source if appropriate.
See <https://gcc.gnu.org/bugs/> for instructions.
gmake[2]: *** [/tmp/llvm-release/llvm-build/lib/Transforms/Scalar/CMakeFiles/LLVMScalarOpts.dir/RewriteStatepointsForGC.cpp.o] Error 4
gmake[2]: *** Waiting for unfinished jobs....
c++: internal compiler error: Killed (program cc1plus)
Please submit a full bug report,
with preprocessed source if appropriate.
See <https://gcc.gnu.org/bugs/> for instructions.
gmake[2]: *** [/tmp/llvm-release/llvm-build/lib/Transforms/Scalar/CMakeFiles/LLVMScalarOpts.dir/StructurizeCFG.cpp.o] Error 4
c++: internal compiler error: Killed (program cc1plus)
Please submit a full bug report,
with preprocessed source if appropriate.
See <https://gcc.gnu.org/bugs/> for instructions.
gmake[2]: *** [/tmp/llvm-release/llvm-build/lib/Transforms/Scalar/CMakeFiles/LLVMScalarOpts.dir/SROA.cpp.o] Error 4
c++: internal compiler error: Killed (program cc1plus)
It seems this step (appearing to be building llvm again?) failed at various places, I am not sure how the build process works - if I have C++ interface with python enabled, I imagine it should be relatively straightforward process to get a python extension built, any suggestions? thanks!
Oliver
from triton.
Actually, I think I got the errors due to high cpu count and setup.py
is trying to use them all, causing severe resource contentions. Once I dial down the count, I am able to have a python build. Thanks again for your help.
from triton.
Related Issues (20)
- bfloat16 of fused attention seems have bug HOT 2
- Possible to use WMMA `.b1` instructions? HOT 1
- AttributeError("'AnnAssign' object has no attribute 'targets'") HOT 1
- [Bug] Compiler error in 06-fused-attention.py
- Fused Attention FP8 correctness on L20(Ada GPU) HOT 1
- What impact does changing the kernel shape's divisibility value have?
- Does Triton have a roadmap plan? HOT 1
- FP8 Casting Tensor Size Alignment Error on AMD MI210 HOT 1
- Output dtype of 09-persistent-matmul.py
- Worse performance on `H100` than `RTX3090`
- [Bug] Assertion `idx < size()' failed. HOT 7
- Seems like these slides are missing, if possible, would you mind update the links or re-upload the files?
- Should @core.extern be part of the libdevice interface? HOT 1
- Cannot find 2.0.0.dev20221202 version HOT 1
- make error
- FlexAttention Segmentation Fault HOT 2
- What is the use of divisibility in coalesce pass
- triton build failing to access https://tritonlang.blob.core.windows.net/llvm-builds/ with HTTP Error 409 HOT 15
- Confusion about memory of pointers
- [Tutorial] Fused-attention `bwd` tutorial incorrect for `causal=True`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from triton.