; assembly | /* r2dec pseudo code output */ | /* baljsn_encoder.t/none @ 0x47c700 */ | #include | ; (fcn) method.int_BloombergLP::baljsn::Encoder_EncodeImplUtil::encodeMember_BloombergLP::s_baltst::Choice1__BloombergLP::bdlat_TypeCategory.Choice__bool__BloombergLP::baljsn::Formatter__std::__1::basic_ostream_char__std::__1::char_traits_char_____std::__1::b () | uint64_t method_int_BloombergLP::baljsn::Encoder_EncodeImplUtil::encodeMember_BloombergLP::s_baltst::Choice1_BloombergLP::bdlat_TypeCategory_Choice_bool_BloombergLP::baljsn::Formatter_std::_1::basic_ostream_char_std::_1::char_traits_char_std::_1::b (int64_t arg_70h, int64_t arg_78h, int64_t arg6, int64_t arg5, int64_t arg4, int64_t arg3, int64_t arg2, int64_t arg1) { | int64_t var_8h; | int64_t var_10h; | int64_t var_18h; | int64_t var_20h; | int64_t var_28h; | int64_t var_30h; | r9 = arg6; | r8 = arg5; | rcx = arg4; | rdx = arg3; | rsi = arg2; | rdi = arg1; | /* int BloombergLP::baljsn::Encoder_EncodeImplUtil::encodeMember(bool*, BloombergLP::baljsn::Formatter*, std::__1::basic_ostream >*, std::__1::basic_string_view > const&, BloombergLP::s_baltst::Choice1 const&, int, BloombergLP::baljsn::EncoderOptions const&, bool, BloombergLP::bdlat_TypeCategory::Choice) */ 0x0047c700 push rbp | 0x0047c701 push r15 | 0x0047c703 push r14 | 0x0047c705 push r13 | 0x0047c707 push r12 | 0x0047c709 push rbx | 0x0047c70a sub rsp, 0x38 | 0x0047c70e mov ebp, r9d | 0x0047c711 mov r15, r8 | r15 = r8; 0x0047c714 mov r14, rcx | r14 = rcx; 0x0047c717 mov r12, rdx | r12 = rdx; 0x0047c71a mov r13, rsi | r13 = rsi; 0x0047c71d mov qword [rsp + 8], rdi | *((rsp + 8)) = rdi; 0x0047c722 mov rdi, rdx | 0x0047c725 mov rsi, r8 | rsi = r8; 0x0047c728 call 0x478aa0 | eax = intBloombergLP::baljsn::Encoder_EncodeImplUtil::validateChoice(std::_1::basic_ostream>*,BloombergLP::s_baltst::Choice1const&) (rdx); 0x0047c72d mov ebx, eax | ebx = eax; 0x0047c72f test eax, eax | | if (eax != 0) { 0x0047c731 jne 0x47c866 | goto label_0; | } 0x0047c737 test ebp, 0x10000 | | if ((ebp & 0x10000) == 0) { 0x0047c73d jne 0x47c779 | 0x0047c73f movzx ecx, byte [rsp + 0x78] | ecx = *((rsp + 0x78)); 0x0047c744 mov rdi, r13 | 0x0047c747 mov rsi, r12 | 0x0047c74a mov rdx, r14 | 0x0047c74d call 0x464340 | eax = BloombergLP::baljsn::Encoder_EncodeImplUtil::encodeMemberPrefix(BloombergLP::baljsn::Formatter*,std::_1::basic_ostream>*,std::_1::basic_string_view>const&,bool) (r13, r12, r14, rcx); 0x0047c752 mov ebx, eax | ebx = eax; 0x0047c754 test eax, eax | | if (eax != 0) { 0x0047c756 jne 0x47c866 | goto label_0; | } 0x0047c75c mov rdi, r12 | 0x0047c75f mov rsi, r15 | rsi = r15; 0x0047c762 call 0x478aa0 | eax = intBloombergLP::baljsn::Encoder_EncodeImplUtil::validateChoice(std::_1::basic_ostream>*,BloombergLP::s_baltst::Choice1const&) (r12); 0x0047c767 mov ebx, eax | ebx = eax; 0x0047c769 test eax, eax | | if (eax != 0) { 0x0047c76b jne 0x47c7cb | goto label_1; | } 0x0047c76d mov rdi, r13 | 0x0047c770 call 0x48c6b0 | BloombergLP::baljsn::Formatter::openObject() (r13); 0x0047c775 mov al, 1 | al = 1; 0x0047c777 jmp 0x47c797 | | } else { 0x0047c779 mov rdi, r12 | 0x0047c77c mov rsi, r15 | rsi = r15; 0x0047c77f call 0x478aa0 | eax = intBloombergLP::baljsn::Encoder_EncodeImplUtil::validateChoice(std::_1::basic_ostream>*,BloombergLP::s_baltst::Choice1const&) (r12); 0x0047c784 mov ebx, eax | ebx = eax; 0x0047c786 test eax, eax | | if (eax != 0) { 0x0047c788 jne 0x47c7cb | goto label_1; | } 0x0047c78a test ebp, 0x10000 | 0x0047c790 sete al | al = ((ebp & 0x10000) == 0) ? 1 : 0; 0x0047c793 or al, byte [rsp + 0x78] | al |= *((rsp + 0x78)); | } 0x0047c797 mov rcx, qword [rsp + 0x70] | rcx = *((rsp + 0x70)); 0x0047c79c mov byte [rsp + 0x10], 0 | *((rsp + 0x10)) = 0; 0x0047c7a1 mov qword [rsp + 0x18], r13 | *((rsp + 0x18)) = r13; 0x0047c7a6 mov qword [rsp + 0x20], r12 | *((rsp + 0x20)) = r12; 0x0047c7ab mov qword [rsp + 0x28], rcx | *((rsp + 0x28)) = rcx; 0x0047c7b0 mov byte [rsp + 0x30], al | *((rsp + 0x30)) = al; 0x0047c7b4 lea rsi, [rsp + 0x10] | 0x0047c7b9 mov rdi, r15 | 0x0047c7bc call 0x478b30 | eax = intBloombergLP::s_baltst::Choice1::accessSelection(BloombergLP::baljsn::Encoder_SelectionVisitor&)const (r15, rsp + 0x10); 0x0047c7c1 test eax, eax | | if (eax == 0) { 0x0047c7c3 je 0x47c877 | goto label_2; | } 0x0047c7c9 mov ebx, eax | ebx = eax; | label_1: 0x0047c7cb mov esi, 0x5441fb | 0x0047c7d0 mov edx, 0x22 | 0x0047c7d5 mov rdi, r12 | 0x0047c7d8 call 0x428ba0 | rax = std::_1::basic_ostream>&std::_1::_put_character_sequence>(std::_1::basic_ostream>&,char const*,unsigned long) (r12, "Unable to encode value of element ", 0x22); 0x0047c7dd mov esi, 0x54421e | 0x0047c7e2 mov edx, 8 | 0x0047c7e7 mov rdi, rax | 0x0047c7ea call 0x428ba0 | rax = std::_1::basic_ostream>&std::_1::_put_character_sequence>(std::_1::basic_ostream>&,char const*,unsigned long) (rax, "named: ', 8); 0x0047c7ef mov rsi, qword [r14] | 0x0047c7f2 mov rdx, qword [r14 + 8] | 0x0047c7f6 mov rdi, rax | 0x0047c7f9 call 0x428ba0 | rax = std::_1::basic_ostream>&std::_1::_put_character_sequence>(std::_1::basic_ostream>&,char const*,unsigned long) (rax, *(r14), *((r14 + 8))); 0x0047c7fe mov esi, 0x6675eb | 0x0047c803 mov edx, 2 | 0x0047c808 mov rdi, rax | 0x0047c80b call 0x428ba0 | rax = std::_1::basic_ostream>&std::_1::_put_character_sequence>(std::_1::basic_ostream>&,char const*,unsigned long) (rax, 0x6675eb, 2); 0x0047c810 mov rbp, rax | 0x0047c813 mov rax, qword [rax] | rax = *(rax); 0x0047c816 mov rsi, qword [rax - 0x18] | rsi = *((rax - 0x18)); 0x0047c81a add rsi, rbp | rsi += rbp; 0x0047c81d lea r14, [rsp + 0x10] | r14 = rsp + 0x10; 0x0047c822 mov rdi, r14 | rdi = r14; 0x0047c825 call 0x405930 | std::_1::ios_base::getloc()const (); 0x0047c82a mov esi, 0x8cce50 | esi = std::__1::ctype::id; 0x0047c82f mov rdi, r14 | rdi = r14; 0x0047c832 call 0x405a20 | rax = std::_1::locale::use_facet(std::_1::locale::id&)const (); 0x0047c837 mov rcx, qword [rax] | rcx = *(rax); 0x0047c83a mov rdi, rax | rdi = rax; 0x0047c83d mov esi, 0xa | esi = 0xa; 0x0047c842 call qword [rcx + 0x38] | eax = uint64_t (*rcx + 0x38)() (); 0x0047c845 mov r14d, eax | r14d = eax; 0x0047c848 lea rdi, [rsp + 0x10] | rdi = rsp + 0x10; 0x0047c84d call 0x405ac0 | std::_1::locale::~locale() (); 0x0047c852 movsx esi, r14b | esi = (int32_t) r14b; 0x0047c856 mov rdi, rbp | rdi = rbp; 0x0047c859 call 0x4056b0 | std::_1::basic_ostream>::put(char) (); 0x0047c85e mov rdi, rbp | rdi = rbp; 0x0047c861 call 0x4058f0 | std::_1::basic_ostream>::flush() (); | do { | label_0: 0x0047c866 mov eax, ebx | eax = ebx; 0x0047c868 add rsp, 0x38 | 0x0047c86c pop rbx | 0x0047c86d pop r12 | 0x0047c86f pop r13 | 0x0047c871 pop r14 | 0x0047c873 pop r15 | 0x0047c875 pop rbp | 0x0047c876 ret | return rax; | label_2: 0x0047c877 test ebp, 0x10000 | | if ((ebp & 0x10000) == 0) { 0x0047c87d jne 0x47c88b | 0x0047c87f mov rdi, r13 | 0x0047c882 call 0x48c760 | eax = BloombergLP::baljsn::Formatter::closeObject() (r13); 0x0047c887 xor eax, eax | eax = 0; 0x0047c889 jmp 0x47c88f | | } else { 0x0047c88b mov al, byte [rsp + 0x10] | al = *((rsp + 0x10)); | } 0x0047c88f mov rcx, qword [rsp + 8] | rcx = *((rsp + 8)); 0x0047c894 mov byte [rcx], al | *(rcx) = al; 0x0047c896 xor ebx, ebx | ebx = 0; 0x0047c898 jmp 0x47c866 | | } while (1); | }