Lines Matching refs:buffer
155 ZydisFormatterBuffer* buffer, ZydisFormatterContext* context) in ZydisFormatterBaseFormatOperandREG() argument
158 ZYAN_ASSERT(buffer); in ZydisFormatterBaseFormatOperandREG()
161 return formatter->func_print_register(formatter, buffer, context, context->operand->reg.value); in ZydisFormatterBaseFormatOperandREG()
165 ZydisFormatterBuffer* buffer, ZydisFormatterContext* context) in ZydisFormatterBaseFormatOperandPTR() argument
168 ZYAN_ASSERT(buffer); in ZydisFormatterBaseFormatOperandPTR()
171 ZYDIS_BUFFER_APPEND_TOKEN(buffer, ZYDIS_TOKEN_IMMEDIATE); in ZydisFormatterBaseFormatOperandPTR()
172 ZYDIS_STRING_APPEND_NUM_U(formatter, formatter->addr_base, &buffer->string, in ZydisFormatterBaseFormatOperandPTR()
174 ZYDIS_BUFFER_APPEND(buffer, DELIM_SEGMENT); in ZydisFormatterBaseFormatOperandPTR()
189 ZYDIS_BUFFER_APPEND_TOKEN(buffer, ZYDIS_TOKEN_IMMEDIATE); in ZydisFormatterBaseFormatOperandPTR()
190 ZYDIS_STRING_APPEND_NUM_U(formatter, formatter->addr_base, &buffer->string, in ZydisFormatterBaseFormatOperandPTR()
197 ZydisFormatterBuffer* buffer, ZydisFormatterContext* context) in ZydisFormatterBaseFormatOperandIMM() argument
200 ZYAN_ASSERT(buffer); in ZydisFormatterBaseFormatOperandIMM()
210 return formatter->func_print_address_abs(formatter, buffer, context); in ZydisFormatterBaseFormatOperandIMM()
212 return formatter->func_print_address_rel(formatter, buffer, context); in ZydisFormatterBaseFormatOperandIMM()
216 return formatter->func_print_imm(formatter, buffer, context); in ZydisFormatterBaseFormatOperandIMM()
224 ZydisFormatterBuffer* buffer, ZydisFormatterContext* context) in ZydisFormatterBasePrintAddressABS() argument
227 ZYAN_ASSERT(buffer); in ZydisFormatterBasePrintAddressABS()
256 ZYDIS_BUFFER_APPEND_TOKEN(buffer, ZYDIS_TOKEN_ADDRESS_ABS); in ZydisFormatterBasePrintAddressABS()
257 ZYDIS_STRING_APPEND_NUM_U(formatter, formatter->addr_base, &buffer->string, address, padding, in ZydisFormatterBasePrintAddressABS()
264 ZydisFormatterBuffer* buffer, ZydisFormatterContext* context) in ZydisFormatterBasePrintAddressREL() argument
267 ZYAN_ASSERT(buffer); in ZydisFormatterBasePrintAddressREL()
296 ZYDIS_BUFFER_APPEND_TOKEN(buffer, ZYDIS_TOKEN_ADDRESS_REL); in ZydisFormatterBasePrintAddressREL()
301 ZYDIS_STRING_APPEND_NUM_S(formatter, formatter->addr_base, &buffer->string, address, in ZydisFormatterBasePrintAddressREL()
305 ZYAN_CHECK(ZydisStringAppendShort(&buffer->string, &STR_ADD)); in ZydisFormatterBasePrintAddressREL()
306 ZYDIS_STRING_APPEND_NUM_U(formatter, formatter->addr_base, &buffer->string, address, in ZydisFormatterBasePrintAddressREL()
317 ZydisFormatterBuffer* buffer, ZydisFormatterContext* context) in ZydisFormatterBasePrintIMM() argument
320 ZYAN_ASSERT(buffer); in ZydisFormatterBasePrintIMM()
323 ZYDIS_BUFFER_APPEND_TOKEN(buffer, ZYDIS_TOKEN_IMMEDIATE); in ZydisFormatterBasePrintIMM()
330 ZYDIS_STRING_APPEND_NUM_S(formatter, formatter->imm_base, &buffer->string, in ZydisFormatterBasePrintIMM()
371 ZYDIS_STRING_APPEND_NUM_U(formatter, formatter->imm_base, &buffer->string, value, padding, in ZydisFormatterBasePrintIMM()
382 ZydisFormatterBuffer* buffer, ZydisFormatterContext* context) in ZydisFormatterBasePrintSegment() argument
385 ZYAN_ASSERT(buffer); in ZydisFormatterBasePrintSegment()
395 ZYAN_CHECK(formatter->func_print_register(formatter, buffer, context, in ZydisFormatterBasePrintSegment()
403 ZYAN_CHECK(formatter->func_print_register(formatter, buffer, context, in ZydisFormatterBasePrintSegment()
412 ZYAN_CHECK(formatter->func_print_register(formatter, buffer, context, in ZydisFormatterBasePrintSegment()
422 ZYDIS_BUFFER_APPEND(buffer, DELIM_SEGMENT); in ZydisFormatterBasePrintSegment()
429 ZydisFormatterBuffer* buffer, ZydisFormatterContext* context) in ZydisFormatterBasePrintPrefixes() argument
432 ZYAN_ASSERT(buffer); in ZydisFormatterBasePrintPrefixes()
447 if (buffer->is_token_list) in ZydisFormatterBasePrintPrefixes()
450 ZYAN_CHECK(ZydisFormatterBufferAppendPredefined(buffer, in ZydisFormatterBasePrintPrefixes()
454 ZYAN_CHECK(ZydisStringAppendShortCase(&buffer->string, in ZydisFormatterBasePrintPrefixes()
462 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_LOCK, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
465 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_SEG_CS, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
468 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_SEG_SS, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
471 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_SEG_DS, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
474 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_SEG_ES, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
477 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_SEG_FS, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
480 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_SEG_GS, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
483 ZYDIS_BUFFER_APPEND_TOKEN(buffer, ZYDIS_TOKEN_PREFIX); in ZydisFormatterBasePrintPrefixes()
484 ZYAN_CHECK(ZydisStringAppendHexU(&buffer->string, value, 0, in ZydisFormatterBasePrintPrefixes()
487 ZYDIS_BUFFER_APPEND_TOKEN(buffer, ZYDIS_TOKEN_WHITESPACE); in ZydisFormatterBasePrintPrefixes()
488 ZYAN_CHECK(ZydisStringAppendShort(&buffer->string, &STR_WHITESPACE)); in ZydisFormatterBasePrintPrefixes()
498 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_LOCK, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
503 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_XACQUIRE, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
507 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_REPNE, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
512 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_BND, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
518 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_XRELEASE, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
522 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_REP, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
526 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_REPE, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
542 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_XACQUIRE, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
546 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_XRELEASE, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
551 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_LOCK, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
556 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_BND, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
561 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_NOTRACK, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
566 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_REP, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
571 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_REPE, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
576 ZYDIS_BUFFER_APPEND_CASE(buffer, PREF_REPNE, formatter->case_prefixes); in ZydisFormatterBasePrintPrefixes()
584 ZydisFormatterBuffer* buffer, ZydisFormatterContext* context, ZydisDecorator decorator) in ZydisFormatterBasePrintDecorator() argument
587 ZYAN_ASSERT(buffer); in ZydisFormatterBasePrintDecorator()
592 ZYAN_UNUSED(buffer); in ZydisFormatterBasePrintDecorator()
603 if (buffer->is_token_list) in ZydisFormatterBasePrintDecorator()
605 ZYDIS_BUFFER_APPEND(buffer, DECO_BEGIN); in ZydisFormatterBasePrintDecorator()
606 ZYAN_CHECK(formatter->func_print_register(formatter, buffer, context, in ZydisFormatterBasePrintDecorator()
608 ZYDIS_BUFFER_APPEND(buffer, DECO_END); in ZydisFormatterBasePrintDecorator()
611 ZYAN_CHECK(ZydisStringAppendShort(&buffer->string, &STR_DECO_BEGIN)); in ZydisFormatterBasePrintDecorator()
612 ZYAN_CHECK(formatter->func_print_register(formatter, buffer, context, in ZydisFormatterBasePrintDecorator()
614 ZYAN_CHECK(ZydisStringAppendShort(&buffer->string, &STR_DECO_END)); in ZydisFormatterBasePrintDecorator()
623 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_ZERO, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
638 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_1TO2, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
641 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_1TO4, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
644 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_1TO8, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
647 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_1TO16, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
650 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_1TO32, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
653 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_1TO64, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
656 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_4TO8, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
659 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_4TO16, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
662 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_8TO16, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
679 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_RN_SAE, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
682 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_RD_SAE, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
685 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_RU_SAE, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
688 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_RZ_SAE, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
700 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_RN, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
703 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_RD, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
706 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_RU, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
709 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_RZ, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
721 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_SAE, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
734 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_CDAB, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
737 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_BADC, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
740 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_DACB, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
743 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_AAAA, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
746 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_BBBB, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
749 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_CCCC, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
752 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_DDDD, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
766 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_FLOAT16, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
769 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_SINT8, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
772 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_UINT8, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
775 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_SINT16, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
778 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_UINT16, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()
789 ZYDIS_BUFFER_APPEND_CASE(buffer, DECO_EH, formatter->case_decorators); in ZydisFormatterBasePrintDecorator()