amusman closed this revision.
amusman added a comment.
Thanks, I've commited the changes in revision 248158 (but forgot to add link in
svn commit message).
Alexander
http://reviews.llvm.org/D12955
___
cfe-commits mailing list
cfe-commits@lists.llvm
aaron.ballman accepted this revision.
aaron.ballman added a comment.
This revision is now accepted and ready to land.
With one minor change, LGTM! Thank you for working on this.
~Aaron
Comment at: lib/Sema/SemaStmtAsm.cpp:447
@@ +446,3 @@
+// Make sure no more than one inpu
amusman updated this revision to Diff 35222.
amusman added a comment.
Added an assertion for TiedTo value.
http://reviews.llvm.org/D12955
Files:
include/clang/Basic/DiagnosticSemaKinds.td
lib/Sema/SemaStmtAsm.cpp
test/Sema/asm.c
Index: lib/Sema/SemaStmtAsm.cpp
===
amusman added inline comments.
Comment at: lib/Sema/SemaStmtAsm.cpp:447
@@ +446,3 @@
+// Make sure no more than one input constraint matches each output.
+if (InputMatchedToOutput[TiedTo] != ~0U) {
+ Diag(NS->getInputExpr(i)->getLocStart(),
aaron.ball
aaron.ballman added a comment.
Generally LGTM, with one question about guarding against overflow.
Comment at: lib/Sema/SemaStmtAsm.cpp:447
@@ +446,3 @@
+// Make sure no more than one input constraint matches each output.
+if (InputMatchedToOutput[TiedTo] != ~0U) {
+
amusman created this revision.
amusman added reviewers: rsmith, aaron.ballman, ABataev.
amusman added a subscriber: cfe-commits.
Several inputs may not refer to one output constraint in inline assembler
insertions, clang fails on assertion on such test case here:
llvm/lib/IR/InlineAsm.cpp:46: ll