[llvm-dev] warning during intrinsic defintion

Rail Shafigulin via llvm-dev
2016-05-30T21:13:32Z

Thanks! I asked for help on the irc chat, and felt pretty dumb when I got
an answer :D

On Mon, May 30, 2016 at 12:27 PM, Nemanja Ivanovic <nemanja.i.ibm at
gmail.com>
wrote:

> I don't really know exactly why you're getting this, but it seems
like you
> forgot the last line in your Builtins<Target>.def. Namely, the line:
> #undef BUILTIN
>
> On Thu, May 26, 2016 at 1:29 AM, Rail Shafigulin via llvm-dev <
> llvm-dev at lists.llvm.org> wrote:
>
>> I've introduced intrinsics for my target however when I compile
>> llvm+clang I get a a redefinition warning:
>>
>> llvm/tools/clang/lib/Basic/Targets.cpp:904:0: warning:
"BUILTIN"
>> redefined [enabled by default]
>>  #define BUILTIN(ID, TYPE, ATTRS) { #ID, TYPE, ATTRS, 0, ALL_LANGUAGES
},
>>  ^
>>
>> In file included from llvm/tools/clang/lib/Basic/Targets.cpp:26:0:
>> llvm/tools/clang/include/clang/Basic/TargetBuiltins.h:164:0: note: this
>> is the location of the previous definition
>>  #define BUILTIN(ID, TYPE, ATTRS) BI##ID,
>>
>> I pretty much copied what other targets did when they defined
intrinsics.
>> Why this happens for my target but not for the others?
>>
>> Any help is appreciated.
>>
>> --
>> Rail Shafigulin
>> Software Engineer
>> Esencia Technologies
>>
>> _______________________________________________
>> LLVM Developers mailing list
>> llvm-dev at lists.llvm.org
>> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
>>
>>
>


--
Rail Shafigulin
Software Engineer
Esencia Technologies
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.llvm.org/pipermail/llvm-dev/attachments/20160530/d8f4a944/attachment.html>