Yet another fix llvm-objdump so it picks a good CPU based for Mach-O files,

in this case for CPU_SUBTYPE_ARM64_ALL.

For this cpusubtype it should default to a cyclone CPU
to give proper disassembly without a -mcpu= flag.

rdar://27767188

llvm-svn: 294771
This commit is contained in:
Kevin Enderby
2017-02-10 19:27:10 +00:00
parent 0e01170c79
commit dc412ccc41
4 changed files with 6 additions and 1 deletions

View File

@@ -2477,6 +2477,8 @@ Triple MachOObjectFile::getArchTriple(uint32_t CPUType, uint32_t CPUSubType,
case MachO::CPU_TYPE_ARM64:
switch (CPUSubType & ~MachO::CPU_SUBTYPE_MASK) {
case MachO::CPU_SUBTYPE_ARM64_ALL:
if (McpuDefault)
*McpuDefault = "cyclone";
if (ArchFlag)
*ArchFlag = "arm64";
return Triple("arm64-apple-darwin");