This is an archive of the discontinued LLVM Phabricator instance.

[ARM] Parse Tag_also_compatible_with attribute
ClosedPublic

Authored by vhscampos on Aug 1 2022, 9:08 AM.

Details

Summary

The ARM Attribute Parser used to parse the value of also_compatible_with
as it is, disregarding the way it is encoded.

This patch does a context aware parsing of the also_compatible_with
attribute. Additionally, some error handling is also done for incorrect
cases.

Diff Detail

Event Timeline

vhscampos created this revision.Aug 1 2022, 9:08 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 1 2022, 9:08 AM
vhscampos requested review of this revision.Aug 1 2022, 9:08 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 1 2022, 9:08 AM
pratlucas added inline comments.Aug 8 2022, 1:53 AM
llvm/lib/Support/ARMAttributeParser.cpp
438

Should other tags be handled here too, in a more gereric way?
The ABI specifies that the inner values can be either an ULEB128 value or an NTBS string. It would be useful to have these presented in a decoded way in adition to the raw string.

vhscampos updated this revision to Diff 451824.Aug 11 2022, 5:54 AM

More general handling of attributes inside also_compatible_with

vhscampos updated this revision to Diff 451831.Aug 11 2022, 6:20 AM

Small improvement to printStringEscapedImpl

vhscampos marked an inline comment as done.Aug 11 2022, 6:27 AM
This revision is now accepted and ready to land.Aug 12 2022, 5:40 AM
This revision was landed with ongoing or failed builds.Aug 16 2022, 3:23 AM
This revision was automatically updated to reflect the committed changes.