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.

I think that's okay but -mptx only supports the values 3.1, 6.3, and 7.0.

As the default is ptx = 6.3, 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...)

(Which points to the question of supporting multilib configurations – as
discussed before:
https://gcc.gnu.org/pipermail/gcc/2022-February/238224.html )

Tobias

-----------------
Siemens Electronic Design Automation GmbH; Anschrift: Arnulfstraße 201, 80634 
München; Gesellschaft mit beschränkter Haftung; Geschäftsführer: Thomas 
Heurung, Frank Thürauf; Sitz der Gesellschaft: München; Registergericht 
München, HRB 106955

Reply via email to