函数逻辑报告 |
Source Code:arch\x86\lib\insn-eval.c |
Create Date:2022-07-27 08:24:33 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:get_reg_offset
函数原型:static int get_reg_offset(struct insn *insn, struct pt_regs *regs, enum reg_type type)
返回类型:int
参数:
类型 | 参数 | 名称 |
---|---|---|
struct insn * | insn | |
struct pt_regs * | regs | |
enum reg_type | type |
399 | regno等于0 |
401 | static const int regoff[] = {offsetof(structpt_regs, ax), offsetof(structpt_regs, cx), offsetof(structpt_regs, dx), offsetof(structpt_regs, bx), offsetof(structpt_regs, sp), offsetof(structpt_regs, bp), offsetof(structpt_regs, si), offsetof(structpt_regs, di), offsetof(structpt_regs, r8), offsetof(structpt_regs, r9), offsetof(structpt_regs, r10), offsetof(structpt_regs, r11), offsetof(structpt_regs, r12), offsetof(structpt_regs, r13), offsetof(structpt_regs, r14), offsetof(structpt_regs, r15), } |
421 | nr_registers等于ARRAY_SIZE - get the number of elements in array @arr*@arr: array to be sized(regoff) |
426 | 如果IS_ENABLED(CONFIG_FOO) evaluates to 1 if CONFIG_FOO is set to 'y' or 'm',* 0 otherwise.(CONFIG_X86_64)且非x86_64则nr_registers减等于8 |
430 | 当:type恒等于REG_TYPE_RM |
444 | 当:type恒等于REG_TYPE_INDEX |
459 | 当:type恒等于REG_TYPE_BASE |
473 | 默认 |
474 | pr_err_ratelimited("invalid register type: %d\n", type) |
475 | 返回:负EINVAL |
478 | 如果regno大于等于nr_registers则 |
名称 | 描述 |
---|---|
insn_get_modrm_rm_off | sn_get_modrm_rm_off() - Obtain register in r/m part of the ModRM byte*@insn: Instruction containing the ModRM byte*@regs: Register values as seen when entering kernel mode* Returns:* The register indicated by the r/m part of the ModRM byte. The |
get_eff_addr_reg | get_eff_addr_reg() - Obtain effective address from register operand*@insn: Instruction |
get_eff_addr_modrm | get_eff_addr_modrm() - Obtain referenced effective address via ModRM*@insn: Instruction |
get_eff_addr_sib | get_eff_addr_sib() - Obtain referenced effective address via SIB*@insn: Instruction |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |