For llvm-objdump, hook up existing options to work when using -macho (the Mach-O...
[opencl/llvm.git] / tools / llvm-objdump / MachODump.cpp
index 0a83843b3e0bd09ca513942a1adbdb93a59e23c0..34ad57167d07132b9f87b026ae7b8e2c59804fdf 100644 (file)
@@ -318,20 +318,16 @@ static void ProcessMachO(StringRef Filename, MachOObjectFile *MachOOF,
 
   if (Disassemble)
     DisassembleMachO(Filename, MachOOF);
-  // TODO: These should/could be printed in Darwin's otool(1) or nm(1) style
-  //       for -macho. Or just used a new option that maps to the otool(1)
-  //       option like -r, -l, etc.  Or just the normal llvm-objdump option
-  //       but now for this slice so that the -arch options can be used.
-  // if (Relocations)
-  //   PrintRelocations(MachOOF);
-  // if (SectionHeaders)
-  //   PrintSectionHeaders(MachOOF);
-  // if (SectionContents)
-  //   PrintSectionContents(MachOOF);
-  // if (SymbolTable)
-  //   PrintSymbolTable(MachOOF);
-  // if (UnwindInfo)
-  //   PrintUnwindInfo(MachOOF);
+  if (Relocations)
+    PrintRelocations(MachOOF);
+  if (SectionHeaders)
+    PrintSectionHeaders(MachOOF);
+  if (SectionContents)
+    PrintSectionContents(MachOOF);
+  if (SymbolTable)
+    PrintSymbolTable(MachOOF);
+  if (UnwindInfo)
+    printMachOUnwindInfo(MachOOF);
   if (PrivateHeaders)
     printMachOFileHeader(MachOOF);
   if (ExportsTrie)