mips16/no mips16 attributes - please review
Bill Wendling
wendling at apple.com
Wed Mar 13 11:32:25 PDT 2013
The function should be more like this:
+ const FunctionDecl *FD = dyn_cast<FunctionDecl>(D);
+ if (!FD) return;
+ llvm::Function *Fn = cast<llvm::Function>(GV);
+ if (FD->hasAttr<Mips16Attr>()) {
+ Fn->addFnAttr("mips16");
+ }
+ else if (FD->hasAttr<NoMips16Attr>()) {
+ Fn->addFnAttr("nomips16");
+ }
With that change, LGTM.
-bw
On Mar 12, 2013, at 11:31 PM, Reed Kotler <rkotler at mips.com> wrote:
> This patch will make clang put the mips16/nomips16 attribute in function bitcode for functions
> which contain that attribute
> <mips16_attrn.txt>
More information about the cfe-commits
mailing list