Re: [PATCH] nvptx: Add a __PTX_ISA__ predefined macro based on target ISA.

2021-08-24 Thread Tom de Vries via Gcc-patches
On 8/20/21 12:54 AM, Roger Sayle wrote: > > This patch adds a __PTX_ISA__ predefined macro to the nvptx backend that > allows code to check the compute model being targeted by the compiler. Hi Roger, The naming __PTX_ISA__ is consistent with the naming of -misa=sm_30/sm_35. The -misa=sm_30/sm_3

[PATCH] nvptx: Add a __PTX_ISA__ predefined macro based on target ISA.

2021-08-19 Thread Roger Sayle
This patch adds a __PTX_ISA__ predefined macro to the nvptx backend that allows code to check the compute model being targeted by the compiler. This is equivalent to the __CUDA_ARCH__ macro defined by CUDA's nvcc compiler, but to avoid causing problems for source code that checks for that compiler