Skip to content

Commit

Permalink
add some comments on the availability of some APIs relying on detail …
Browse files Browse the repository at this point in the history
…= ON
  • Loading branch information
aquynh committed Jan 15, 2014
1 parent 0941042 commit 2f05ab2
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions include/capstone.h
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,8 @@ const char *cs_insn_name(csh handle, unsigned int insn_id);
Find the group id from header file of corresponding architecture (arm.h for ARM, x86.h for X86, ...)
Internally, this simply verifies if @group_id matches any member of insn->groups array.
NOTE: this API is only valid when detail option is ON (which is OFF by default)
@handle: handle returned by cs_open()
@insn: disassembled instruction structure received from cs_disasm() or cs_disasm_ex()
@group_id: group that you want to check if this instruction belong to.
Expand All @@ -330,6 +332,8 @@ bool cs_insn_group(csh handle, cs_insn *insn, unsigned int group_id);
Find the register id from header file of corresponding architecture (arm.h for ARM, x86.h for X86, ...)
Internally, this simply verifies if @reg_id matches any member of insn->regs_read array.
NOTE: this API is only valid when detail option is ON (which is OFF by default)
@insn: disassembled instruction structure received from cs_disasm() or cs_disasm_ex()
@reg_id: register that you want to check if this instruction used it.
Expand All @@ -342,6 +346,8 @@ bool cs_reg_read(csh handle, cs_insn *insn, unsigned int reg_id);
Find the register id from header file of corresponding architecture (arm.h for ARM, x86.h for X86, ...)
Internally, this simply verifies if @reg_id matches any member of insn->regs_write array.
NOTE: this API is only valid when detail option is ON (which is OFF by default)
@insn: disassembled instruction structure received from cs_disasm() or cs_disasm_ex()
@reg_id: register that you want to check if this instruction modified it.
Expand All @@ -353,6 +359,8 @@ bool cs_reg_write(csh handle, cs_insn *insn, unsigned int reg_id);
Count the number of operands of a given type.
Find the operand type in header file of corresponding architecture (arm.h for ARM, x86.h for X86, ...)
NOTE: this API is only valid when detail option is ON (which is OFF by default)
@handle: handle returned by cs_open()
@insn: disassembled instruction structure received from cs_disasm() or cs_disasm_ex()
@op_type: Operand type to be found.
Expand All @@ -367,6 +375,8 @@ int cs_op_count(csh handle, cs_insn *insn, unsigned int op_type);
Later, the operand can be accessed using the returned position.
Find the operand type in header file of corresponding architecture (arm.h for ARM, x86.h for X86, ...)
NOTE: this API is only valid when detail option is ON (which is OFF by default)
@handle: handle returned by cs_open()
@insn: disassembled instruction structure received from cs_disasm() or cs_disasm_ex()
@op_type: Operand type to be found.
Expand Down

0 comments on commit 2f05ab2

Please sign in to comment.