[PATCH] D28451: [AVR] Add support for the 'interrupt' and 'naked' attributes

Aaron Ballman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Feb 6 10:20:16 PST 2017


aaron.ballman added inline comments.


================
Comment at: lib/Sema/SemaDeclAttr.cpp:5137
+  if (!checkAttributeNumArgs(S, Attr, 0)) {
+    Attr.setInvalid();
+    return;
----------------
No need to call `Attr.setInvalid()` here or below.


================
Comment at: test/CodeGen/avr/attributes/interrupt.c:3
+
+// CHECK: define void @foo() #0
+__attribute__((interrupt)) void foo(void) { }
----------------
dylanmckay wrote:
> aaron.ballman wrote:
> > As should this.
> It seems like this sort of test _does_ sit in `CodeGen` - see `test/CodeGen/{arm-interrupt-attr.c|mips-interrupt-attr.c}`.
> 
You're correct, this test does belong here. I think I attached my comment to the wrong thing (sorry about that).


https://reviews.llvm.org/D28451





More information about the cfe-commits mailing list