From: badumbatish Date: Wed, 24 Jul 2024 05:17:12 +0000 (-0700) Subject: gccrs: Added counting to check for asm_construct_outputs X-Git-Tag: basepoints/gcc-16~1207 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=8a33d0f222d5f6e234f5c9c5ae5a1f5e7f0cd084;p=thirdparty%2Fgcc.git gccrs: Added counting to check for asm_construct_outputs gcc/rust/ChangeLog: * backend/rust-compile-asm.cc (CompileAsm::asm_construct_outputs): Set up counting to check --- diff --git a/gcc/rust/backend/rust-compile-asm.cc b/gcc/rust/backend/rust-compile-asm.cc index 0dd4f672008..9305a9088bb 100644 --- a/gcc/rust/backend/rust-compile-asm.cc +++ b/gcc/rust/backend/rust-compile-asm.cc @@ -96,6 +96,13 @@ tree CompileAsm::asm_construct_outputs (HIR::InlineAsm &expr) { // TODO: Do i need to do this? + int count = 0; + + for (auto &output : expr.get_operands ()) + { + if (output.register_type == AST::InlineAsmOperand::RegisterType::Out) + count++; + } return NULL_TREE; }