Displaying 2 results from an estimated 2 matches for "addnounwind".
Did you mean:
aanounwind
2012 Sep 19
0
[LLVMdev] [RFC] Overhauling Attributes
...comments, but nothing really substantive.
Minor API comment as that seems more immediate:
On Wed, Sep 19, 2012 at 3:25 PM, Bill Wendling <wendling at apple.com> wrote:
> An example syntax could be:
>
> // Building an Attribute
>
> Attributes A;
> A.addAlignAttr(4)
> .addNoUnwindAttr()
> .addStackProtectorAttr()
> .addUnwindTableAttr()
> .addReadNoneAttr();
>
Personally, I would prefer to make the Attributes class be immutable, and
the building happen in a helper. One possible interface would end up
looking like:
Attributes Base = ...;
Attributes A = Attri...
2012 Sep 19
8
[LLVMdev] [RFC] Overhauling Attributes
...tation to be swapped out independently of all the clients
changing. It would then expose a very simple predicate interface. Building
attributes for LLVM objects will be done with simple 'add*' methods:
An example syntax could be:
// Building an Attribute
Attributes A;
A.addAlignAttr(4)
.addNoUnwindAttr()
.addStackProtectorAttr()
.addUnwindTableAttr()
.addReadNoneAttr();
// Querying an Attribute
if (!A.hasStackProtector() || A.hasAlign(4))
...
The Attributes class will be expanded in the future to support code generation
and target-specific options. But it won't require a massive...