[Lldb-commits] [PATCH] Adding SoftwareBreakpointTrapOpcode and RelocationJumpSlotType for MIPS

Bhushan Attarde bhushan.attarde at imgtec.com
Wed Jan 7 02:44:04 PST 2015


Hi clayborg,

To avoid assertion failures.

REPOSITORY
  rL LLVM

http://reviews.llvm.org/D6861

Files:
  source/Plugins/ObjectFile/ELF/ELFHeader.cpp
  source/Plugins/Platform/Linux/PlatformLinux.cpp

Index: source/Plugins/Platform/Linux/PlatformLinux.cpp
===================================================================
--- source/Plugins/Platform/Linux/PlatformLinux.cpp
+++ source/Plugins/Platform/Linux/PlatformLinux.cpp
@@ -583,6 +583,13 @@
             }
         }
         break;
+    case llvm::Triple::mips64:
+        {
+            static const uint8_t g_hex_opcode[] = { 0x00, 0x00, 0x00, 0x0d };
+            trap_opcode = g_hex_opcode;
+            trap_opcode_size = sizeof(g_hex_opcode);
+        }
+        break;
     }
 
     if (bp_site->SetTrapOpcode(trap_opcode, trap_opcode_size))
Index: source/Plugins/ObjectFile/ELF/ELFHeader.cpp
===================================================================
--- source/Plugins/ObjectFile/ELF/ELFHeader.cpp
+++ source/Plugins/ObjectFile/ELF/ELFHeader.cpp
@@ -195,6 +195,9 @@
     case EM_AARCH64:
         slot = R_AARCH64_JUMP_SLOT;
         break;
+    case EM_MIPS:
+        slot = R_MIPS_JUMP_SLOT;
+        break;
     }
 
     return slot;

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D6861.17848.patch
Type: text/x-patch
Size: 1013 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20150107/ecc4f1fe/attachment.bin>


More information about the lldb-commits mailing list