[llvm-dev] Legal names for Functions and other Identifiers
Philip Pfaffe via llvm-dev
llvm-dev at lists.llvm.org
Thu Jun 22 05:44:23 PDT 2017
since I've seen you working with GPU code generation, one additional heads
up: You must take care that your function names are also legal in the
target architecture (such as PTX).
While backends can legalize function names, NVPTX can't/doesn't (it can't,
really, because kernel invocation can be done by a name string). This means
that you mustn't have, e.g., a dot in your function name. The dot is legal
in an LLVM identifier, but not in a ptx function name. This also is
noteworthy because the slot tracker automatically inserts dots into
function names for deduplication.
2017-06-22 14:34 GMT+02:00 SANJAY SRIVALLABH SINGAPURAM via llvm-dev <
llvm-dev at lists.llvm.org>:
> Thank You Chen !
> On Thu, Jun 22, 2017 at 5:21 PM 陳韋任 <chenwj.cs97g at g2.nctu.edu.tw> wrote:
>> Perhaps you can refer to . Function name should be a global one.
>>  http://llvm.org/docs/LangRef.html#identifiers
>> 2017-06-22 16:35 GMT+08:00 SANJAY SRIVALLABH SINGAPURAM via llvm-dev <
>> llvm-dev at lists.llvm.org>:
>>> I'd like to know the format a function's name must conform to. Can I be
>>> pointed to LLVM documention that specifies the nomenclature for functions
>>> and other Identifiers as well (%registers, ModuleID etc.) ?
>>> LLVM Developers mailing list
>>> llvm-dev at lists.llvm.org
>> Wei-Ren Chen (陳韋任)
>> Homepage: https://people.cs.nctu.edu.tw/~chenwj
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the llvm-dev