diff options
author | WANG Xuerui <git@xen0n.name> | 2022-10-25 14:36:52 +0800 |
---|---|---|
committer | WANG Xuerui <git@xen0n.name> | 2022-12-04 16:14:43 +0800 |
commit | bdc16f086f1664b56d8add0691c9a80d7997efd9 (patch) | |
tree | 13bd26ccab93fe2623f161ec21712dfcc7c076e8 /src/corelib/plugin/qelfparser_p.cpp | |
parent | 6da057d811fd9494e1c173ba38d54bc3e9810f41 (diff) |
Add LoongArch detection
- detect the LoongArch architecture, define Q_PROCESSOR_LOONGARCH and
Q_PROCESSOR_LOONGARCH_{32,64} appropriately
- document the macros as being available starting from 6.5
- add LoongArch ELF support in QElfParser
Change-Id: I438146af49ec3adacacec84c27c9f4abaa542830
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/plugin/qelfparser_p.cpp')
-rw-r--r-- | src/corelib/plugin/qelfparser_p.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/corelib/plugin/qelfparser_p.cpp b/src/corelib/plugin/qelfparser_p.cpp index 4388c6babe..b7c6760864 100644 --- a/src/corelib/plugin/qelfparser_p.cpp +++ b/src/corelib/plugin/qelfparser_p.cpp @@ -122,6 +122,8 @@ struct ElfMachineCheck EM_PARISC #elif defined(Q_PROCESSOR_IA64) EM_IA_64 +#elif defined(Q_PROCESSOR_LOONGARCH) + EM_LOONGARCH #elif defined(Q_PROCESSOR_M68K) EM_68K #elif defined(Q_PROCESSOR_MIPS) @@ -387,6 +389,9 @@ Q_DECL_UNUSED Q_DECL_COLD_FUNCTION static QDebug &operator<<(QDebug &d, ElfHeade case EM_BLACKFIN: d << ", Blackfin"; break; #endif case EM_IA_64: d << ", IA-64"; break; +#ifdef EM_LOONGARCH + case EM_LOONGARCH: d << ", LoongArch"; break; +#endif case EM_MIPS: d << ", MIPS"; break; case EM_PARISC: d << ", HPPA"; break; case EM_PPC: d << ", PowerPC"; break; |