187 Commits (338f2eae4c36b6cf6d08f7cd003704230fefcc7d)

Author SHA1 Message Date
Félix Cloutier 3973d8b11e Silencing Clang warning bys casting values 10 years ago
pancake 9c10ace558 Make pkg-config and source consistent with installation 10 years ago
Nguyen Anh Quynh 611b0c5c22 code style 10 years ago
Edward Williamson f1e497502c check malloc return value 10 years ago
Nguyen Anh Quynh ff7bba3d6d x86: print out immediate as positive number for logic arithmetic operations: AND, OR, XOR. only works for x86 Intel syntax so far. issue reported by Pancake 10 years ago
Nguyen Anh Quynh 6c0dd63fe7 fix an overflow bug in fill_insn() 10 years ago
flyingsymbols d91f964d40 * Fixed bug in Thumb2 pop caused by me incorrectly assuming that 10 years ago
Nguyen Anh Quynh 9090672e97 clean cs_disasm_iter() 10 years ago
Nguyen Anh Quynh 29ce6c3517 cs_disasm_iter: return false when handle is invalid and do not zero out detail pointer when handling skipdata mode. suggested by @hlide 10 years ago
Nguyen Anh Quynh 0a2eca7c6c modify API cs_disasm_iter() and add new API cs_malloc(). also adds sample code test_iter.c 10 years ago
hlide 993f362ad8 New API: cs_disasm_iter 10 years ago
Nguyen Anh Quynh 4d3ccf46fd simplify the way to calculate insn_cache in cs_disasm(). suggested by @hlide 10 years ago
danghvu 2fb7c8e46a Fix a bug with previous patch 10 years ago
Nguyen Anh Quynh f9d8a89c24 correct some comments in cs_disasm() 10 years ago
danghvu 0d1aad1e9f Increase cache size by golden ratio 10 years ago
Nguyen Anh Quynh 27a4a08bb2 fix a double-free bug introduced by the last change in cs_disasm() 10 years ago
Nguyen Anh Quynh ea3c089591 some simple optimizations for speed. this improves performance about 5% 10 years ago
Nguyen Anh Quynh 16f330c37a cs_disasm(): properly resize the cache when count in range [2, INSN_CACHE_SIZE] 10 years ago
Nguyen Anh Quynh 523ca99087 cs_disasm(): make sure cache_size is smaller than INSN_CACHE_SIZE to avoid integer overflow in malloc() 10 years ago
Nguyen Anh Quynh 50eeba2a86 avoid setting instruction cache size to @count when Capstone uses user-customized memory management, which might fail in resource scarce env such as kernel 10 years ago
Nguyen Anh Quynh ac98ca0129 set buffer size for instruction cache in cs_disasm() to @count if @count > 0. this avoids realloc() in cases where @count is pre-determined. thanks Dang Hoang Vu for the idea 10 years ago
Nguyen Anh Quynh 0beb0d494b api: get back the old API cs_disasm() & mark cs_disasm_ex() deprecated. cs_disasm_ex() will be removed in the future 10 years ago
Nguyen Anh Quynh 0c07cc9b06 zero-out instruction details, mnemonic & op_str so cs_insn doesnt have garbage in Diet mode 10 years ago
Nguyen Anh Quynh 4b6b15fcb1 fix more MSVC warnings 10 years ago
obs 876b6b6a33 use const when passing cs_insn pointers 10 years ago
Nguyen Anh Quynh 0b690387b3 x86: update core with upstream. this added bunch of new instructions & groups. also updated Python & Java bindings after the core change 10 years ago
flyingsymbols 298d413bbc * added a test file to suite for testing invalid and valid instruction sequences 10 years ago
Nguyen Anh Quynh 027afdc179 Change the prototype of the callback in SKIPDATA option. Suggested by Ben Nagy. 11 years ago
Nguyen Anh Quynh 0df7e93a3c Change the prototype of the callback in SKIPDATA option. Suggested by Ben Nagy. 11 years ago
Nguyen Anh Quynh 650f96ce43 add new API cs_group_name() to return group name in string, given the group id 11 years ago
Nguyen Anh Quynh 25b7f760ce simplify code copying @mnemonic in fill_insn() 11 years ago
Nguyen Anh Quynh d392f6ef89 simplify code copying @mnemonic in fill_insn() 11 years ago
Nguyen Anh Quynh 22ea683583 only verify x86_prefix[0] for x86 arch. bug reported by @pancake 11 years ago
Nguyen Anh Quynh 1d3100ad5b only verify x86_prefix[0] for x86 arch. bug reported by @pancake 11 years ago
Nguyen Anh Quynh 5a7f409dec set @insn to NULL on error in cs_disasm_ex() 11 years ago
Nguyen Anh Quynh dab17fd0b1 set @insn to NULL on error in cs_disasm_ex() 11 years ago
Nguyen Anh Quynh 6c182aedcf fix a memleaking issue in cs_disasm_ex() where memory was not freed when input code is illegit 11 years ago
Nguyen Anh Quynh cae09bf543 replace offset_of with offsetof from stddef.h 11 years ago
Nguyen Anh Quynh 64091f77e0 resize total memory allocated for @insns to just the right size for cs_disasm_ex() 11 years ago
Nguyen Anh Quynh 495295ecd4 MCInst_Init() is arch-independent 11 years ago
Nguyen Anh Quynh db3c00c0ff consider tab as delimiter char in asm bufffer in fill_insn() 11 years ago
Nguyen Anh Quynh 69582d71ae initialize cs_insn.detail by properly zero-out right members for each arch 11 years ago
Nguyen Anh Quynh c88d9929ae cs_disasm_ex(): properly calculate insn_cache when reallocating total variable 11 years ago
Nguyen Anh Quynh ee5839420d cs_disasm_ex(): avoid multiple memcpy() by allocating memory for total, then directly work on that instead of using static array insn_cache[] 11 years ago
Nguyen Anh Quynh 5329a6ffd4 directly update cs_insn from MCInst interface to avoid multiple memcpy() 11 years ago
Nguyen Anh Quynh 7566a2d9dd copy mnemonic in the same loop of searching for mnemonic/opstring delimiter 11 years ago
Nguyen Anh Quynh 07e84a2094 do not need to verify handle->insn_id in fill_insn() 11 years ago
Nguyen Anh Quynh 6ddd715fac we have to consider \t in input buffer of fill_insn() 11 years ago
Nguyen Anh Quynh f8ea346310 properly copy buffer to op_str 11 years ago
Nguyen Anh Quynh 177dd9b223 simplify fill_insn(): do not check for \t in asm buffer 11 years ago