Added call to functions through PLT

This commit is contained in:
Egor Sheremetov 2024-04-18 13:00:35 +03:00 committed by Roman Venediktov
parent 53d7bc42d1
commit ced766734c

View file

@ -237,7 +237,7 @@ let show instr =
| Push s -> Printf.sprintf "\tpushq\t%s" (opnd s) | Push s -> Printf.sprintf "\tpushq\t%s" (opnd s)
| Pop s -> Printf.sprintf "\tpopq\t%s" (opnd s) | Pop s -> Printf.sprintf "\tpopq\t%s" (opnd s)
| Ret -> "\tret" | Ret -> "\tret"
| Call p -> Printf.sprintf "\tcall\t%s" p | Call p -> Printf.sprintf "\tcall\t%s@plt" p
| CallI o -> Printf.sprintf "\tcall\t*(%s)" (opnd o) | CallI o -> Printf.sprintf "\tcall\t*(%s)" (opnd o)
| Label l -> Printf.sprintf "%s:\n" l | Label l -> Printf.sprintf "%s:\n" l
| Jmp l -> Printf.sprintf "\tjmp\t%s" l | Jmp l -> Printf.sprintf "\tjmp\t%s" l