File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -680,13 +680,13 @@ void OpenMPIRBuilder::finalize(Function *Fn) {
680
680
Function *OutlinedFn = Extractor.extractCodeRegion (CEAC);
681
681
682
682
// Forward target-cpu, target-features attributes to the outlined function.
683
- if ( auto Attr = OuterFn->getFnAttribute (" target-cpu" );
684
- Attr .isStringAttribute ())
685
- OutlinedFn->addFnAttr (Attr );
683
+ auto TargetCpuAttr = OuterFn->getFnAttribute (" target-cpu" );
684
+ if (TargetCpuAttr .isStringAttribute ())
685
+ OutlinedFn->addFnAttr (TargetCpuAttr );
686
686
687
- if ( auto Attr = OuterFn->getFnAttribute (" target-features" );
688
- Attr .isStringAttribute ())
689
- OutlinedFn->addFnAttr (Attr );
687
+ auto TargetFeaturesAttr = OuterFn->getFnAttribute (" target-features" );
688
+ if (TargetFeaturesAttr .isStringAttribute ())
689
+ OutlinedFn->addFnAttr (TargetFeaturesAttr );
690
690
691
691
LLVM_DEBUG (dbgs () << " After outlining: " << *OuterFn << " \n " );
692
692
LLVM_DEBUG (dbgs () << " Outlined function: " << *OutlinedFn << " \n " );
You can’t perform that action at this time.
0 commit comments