On 2/8/22 14:24, Tobias Burnus wrote:
Hi Tom,
if I understand the patch correctly, -misa=sm_53 -mptx=3.1 will ...
On 08.02.22 13:57, Tom de Vries via Gcc-patches wrote:
Furthermore, using the -mptx option is a bit user-unfriendly.
Say we want to compile for sm_80. We can use -misa=sm_80 to specify
that, but
then run into errors because the default ptx version is 6.3, which
doesn't
support sm_80 yet.
...
Also add an error in case of incompatible options like
"-misa=sm_80 -mptx=6.3":
...
cc1: error: PTX version (-mptx) needs to be at least 7.0 to support \
selected -misa (sm_80)
... output that -mptx needs to be at least 4.1.
Um, you mean 4.2 I suppose:
...
$ ./gcc.sh ~/hello.c -misa=sm_53 -mptx=3.1
cc1: error: PTX version (-mptx) needs to be at least 4.2 to support
selected -misa (sm_53)
...
?
I think that's okay but -mptx only supports the values 3.1, 6.3, and 7.0.
I know. I'm sort of hoping that the new default setting will make using
-mptx unnecessary.
As the default is ptx = 6.3,
Well, that's no longer the case, that's one of the things that this
patch changes. It's by default the maximum of:
- 6.0, and
- the minimal ptx isa required by the sm version
it only occurs when both are specified in
the way shown above. Thus, we can live with that. (Misleading message
for odd corner case, only. In particular, I am not sure we really want
to add another PTX version...)
Agreed, it's misleading, but I'm hoping people will just specify the sm
version.
Thanks,
- Tom