================ @@ -1284,6 +1285,54 @@ ObjectFileELF::RefineModuleDetailsFromNote(lldb_private::DataExtractor &data, return error; } +void ObjectFileELF::ParseRISCVAttributes(DataExtractor &data, uint64_t length, + ArchSpec &arch_spec) { + lldb::offset_t offset = 0; + + uint8_t format_version = data.GetU8(&offset); + if (format_version != llvm::ELFAttrs::Format_Version) + return; + + offset = offset + sizeof(uint32_t); // Section Length + llvm::StringRef vendor_name = data.GetCStr(&offset); + + if (vendor_name != "riscv") + return; ---------------- DavidSpickett wrote:
Previously you do: ``` read thing if thing is not whatever return ``` With no blank line before the if. I like that style, do that here. https://github.com/llvm/llvm-project/pull/147990 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits