-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
nvcc fatal: Option '--ptx (-ptx)' is not allowed when compiling for multiple GPU architectures #289
Comments
To answer my own question: this is not really the solution. I can run it on an H100 (CC 90), which means the forward compatibility is working. But I can't run it on an A100 (CC 80), which was one of my actual targets in
(same for the I'm really not sure what this sample is supposed to do when CUDA-Samples is build for multiple SMS's. It seems like it always wants to invoke the The patch would then be:
If I build this for |
I'm building the CUDA samples for multiple architectures, since it is documented one can do this with the
SMS
option. My build command is:I've encountered the issue with both Cuda-Samples 11.3, and 12.2. The issue is present in at least two samples:
memMapIPCDrv
andptxjit
. It is in this line and this line of their respective makefiles, which both read (with some context):I believe what should be done is store the
GENCODE_FLAGS
for PTX file generation separately. I.e this line should probably read:And then the offending section modified to:
I can at least confirm that with this diff:
On top of the CUDA-Samples 12.2 sources, it builds correctly for multiple architectures. However, what I'm not 100% sure of, is if this makes sense, so I'm hoping someone else can confirm that :)
The text was updated successfully, but these errors were encountered: