Skip to content

Commit e49d7e9

Browse files
committed
[AArch64][Build Attributes] Remove assertion
When adding build attributes from assembly, an existing value should not trigger an assertion. This case is valid, and behavior should remain consistent between builds with and without assertions.
1 parent 3019e49 commit e49d7e9

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

llvm/lib/Target/AArch64/MCTargetDesc/AArch64TargetStreamer.cpp

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -222,13 +222,9 @@ void AArch64TargetStreamer::emitAttribute(StringRef VendorName, unsigned Tag,
222222
"Can not add AArch64 build attribute: An attribute with "
223223
"the same tag and a different value already exists");
224224
return;
225-
} else {
226-
// Case Item.IntValue == Value, no need to emit twice
227-
assert(0 &&
228-
"AArch64 build attribute: An attribute with the same tag "
229-
"and a same value already exists");
230-
return;
231225
}
226+
// Case Item.IntValue == Value, no need to emit twice
227+
return;
232228
}
233229
}
234230
}

0 commit comments

Comments
 (0)