-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Triton language #5531
base: main
Are you sure you want to change the base?
Add Triton language #5531
Conversation
Adding Triton properly requires conda env support on CE infra. Matt mentioned he'd been meaning to add it, but this PR will probably be blocked until then. If anyone wants to try this locally:
|
defaultCompiler=tritonHEAD | ||
|
||
compiler.tritonHEAD.name=Triton (HEAD) | ||
compiler.tritonHEAD.exe=/home/simon/mambaforge/envs/tritonNightly/bin/python |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should be /home/ce
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Defaults are whatever make sense as a default. I'm not any /home/
is a sensible default, but I'm also not sure what else to suggest here. Typically we refer in the defaults to things like /usr/bin/gcc
etc, where compilers are (probably) installed. It's expected users will override in their *.local.properties
, and the triton.amazon.properties
will be completely different (referring to something in /opt/compiler-explorer/...
somewhere)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I picked this default since I was hoping it makes it very obvious what it should be set to in the *.local.properties
. I don't think it's common to have a package like Triton be installed globally using the system Python, but happy to take suggestions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd go with just triton
or leave it unset entirely to make it error. But not a big deal really.
Ok I dug a bit deeper into the Triton codebase, and the "jit-ness" is really ingrained, in the sense that turning Triton into a cross-compiler is a fairly big refactoring, because it issues calls like Running CE locally will still be pretty useful to many (like me) for figuring out what Triton is doing. I don't know how others feel about having compilers in the CE main repo that only run locally. The other option would be to make sure Triton only ever runs on the GPU CE instances, and somehow make it clear to users that it cannot cross-compile and hence always targets the native GPU, and that they have to run a local instance themselves to fix that. |
From Discord, worth looking in to https://github.com/conda/conda-pack (noted by @siboehm as a potential help for installation) |
I think we can merge this PR as is, as long as it doesn't break anything. It won't add the language to the website, but people will still be able to try it out. |
This closes #5530.
From my POV, this is what's still TODO (would be happy about any input on these):
compile.py
script. It's hardcoded to work on my local machine right now.-n kernel --signature "*fp32:16, *fp16:16, *fp16:16, i32, 1024" -w 1 -g "M/16, 1, 1"
. That's not mandatory I guess and users would figure it out eventually from the error messages, but it'd make the experience a little nicer.Lmk if you want me to move the doc stuff into a separate PR.