kernel-mode #1
@ -109,11 +109,18 @@ class ElfInstruction:
|
|||||||
return self.args[num]
|
return self.args[num]
|
||||||
|
|
||||||
def __repr__(self):
|
def __repr__(self):
|
||||||
|
if self.name in ('sw', 'sh', 'sb', 'lb', 'lh', 'lb', 'lbu', 'lhu'):
|
||||||
|
args = "{}, {}({})".format(
|
||||||
|
self.args[1], self.args[2], self.args[0]
|
||||||
|
)
|
||||||
|
else:
|
||||||
|
args = ", ".join(map(str, self.args))
|
||||||
return "{:<8} {}".format(
|
return "{:<8} {}".format(
|
||||||
self.name,
|
self.name,
|
||||||
", ".join(map(str, self.args))
|
args
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
class ElfLoadedMemorySection(LoadedMemorySection):
|
class ElfLoadedMemorySection(LoadedMemorySection):
|
||||||
def read_instruction(self, offset):
|
def read_instruction(self, offset):
|
||||||
if not self.flags.executable:
|
if not self.flags.executable:
|
||||||
|
Loading…
Reference in New Issue
Block a user