// File: jstaursky[P]hutch/src/Sleigh/semantics.cc
// Function: ConstTpl::restoreXml(Element const*, AddrSpaceManager const*)
void ConstTpl::restoreXml(const Element *el,const AddrSpaceManager *manage)

{
  const string &typestring(el->getAttributeValue("type"));
  if (typestring == "real") {
    type = real;
    istringstream s(el->getAttributeValue("val"));
    s.unsetf(ios::dec | ios::hex | ios::oct);
    s >> value_real;
  }
  else if (typestring=="handle") {
    type = handle;
    istringstream s(el->getAttributeValue("val"));
    s.unsetf(ios::dec | ios::hex | ios::oct);
    s >> value.handle_index;
    select = readHandleSelector(el->getAttributeValue("s"));
    if (select == v_offset_plus) {
      istringstream s2(el->getAttributeValue("plus"));
      s2.unsetf(ios::dec | ios::hex | ios::oct);
      s2 >> value_real;
    }
  }
  else if (typestring=="start") {
    type = j_start;
  }
  else if (typestring=="next") {
    type = j_next;
  }
  else if (typestring=="curspace") {
    type = j_curspace;
  }
  else if (typestring=="curspace_size") {
    type = j_curspace_size;
  }
  else if (typestring=="spaceid") {
    type = spaceid;
    value.spaceid = manage->getSpaceByName(el->getAttributeValue("name"));
  }
  else if (typestring=="relative") {
    type = j_relative;
    istringstream s(el->getAttributeValue("val"));
    s.unsetf(ios::dec | ios::hex | ios::oct);
    s >> value_real;
  }
  else if (typestring == "flowref") {
    type = j_flowref;
  }
  else if (typestring == "flowref_size") {
    type = j_flowref_size;
  }
  else if (typestring == "flowdest") {
    type = j_flowdest;
  }
  else if (typestring == "flowdest_size") {
    type = j_flowdest_size;
  }
  else
    throw LowlevelError("Bad constant type");
}

// Assembly:
subq $0x8a8, %rsp            # imm = 0x8A8
movq %rdi, 0x8a0(%rsp)
movq %rsi, 0x898(%rsp)
movq %rdx, 0x890(%rsp)
movq 0x8a0(%rsp), %rax
movq %rax, 0x120(%rsp)
movq 0x898(%rsp), %rax
movq %rax, 0x128(%rsp)
leaq 0x867(%rsp), %rdi
movq %rdi, 0x130(%rsp)
callq 0xe0c80
movq 0x130(%rsp), %rdx
leaq 0x71ee9(%rip), %rsi     # 0x187b9c
leaq 0x868(%rsp), %rdi
callq 0xe00a0
jmp 0x115cc2
movq 0x128(%rsp), %rdi
leaq 0x868(%rsp), %rsi
callq 0xdb6f0
movq %rax, 0x118(%rsp)
jmp 0x115ce1
leaq 0x868(%rsp), %rdi
callq 0xd4550
leaq 0x867(%rsp), %rdi
callq 0xd8ec0
movq 0x118(%rsp), %rax
movq %rax, 0x888(%rsp)
movq 0x888(%rsp), %rdi
leaq 0x725b7(%rip), %rsi     # 0x1882d1
callq 0xe30f0
testb $0x1, %al
jne 0x115d28
jmp 0x115f17
movq 0x120(%rsp), %rax
movl $0x0, (%rax)
movq 0x898(%rsp), %rax
movq %rax, 0x108(%rsp)
leaq 0x6af(%rsp), %rdi
movq %rdi, 0x110(%rsp)
callq 0xe0c80
movq 0x110(%rsp), %rdx
leaq 0x71477(%rip), %rsi     # 0x1871e1
leaq 0x6b0(%rsp), %rdi
callq 0xe00a0
jmp 0x115d79
movq 0x108(%rsp), %rdi
leaq 0x6b0(%rsp), %rsi
callq 0xdb6f0
movq %rax, 0x100(%rsp)
jmp 0x115d98
movq 0x100(%rsp), %rsi
leaq 0x6d0(%rsp), %rdi
movl $0x8, %edx
callq 0xdfcc0
jmp 0x115db4
leaq 0x6b0(%rsp), %rdi
callq 0xd4550
leaq 0x6af(%rsp), %rdi
callq 0xd8ec0
movq 0x6d0(%rsp), %rax
movq -0x18(%rax), %rax
leaq 0x6d0(%rsp,%rax), %rax
movq %rax, 0xf0(%rsp)
movl $0x2, %edi
movl $0x8, %esi
callq 0xe0e70
movl %eax, 0xfc(%rsp)
jmp 0x115e02
movl 0xfc(%rsp), %edi
movl $0x40, %esi
callq 0xe0e70
movl %eax, 0xec(%rsp)
jmp 0x115e1c
movl 0xec(%rsp), %esi
movq 0xf0(%rsp), %rdi
callq 0xda6e0
jmp 0x115e32
movq 0x120(%rsp), %rsi
addq $0x10, %rsi
leaq 0x6d0(%rsp), %rdi
callq 0xdcd70
jmp 0x115e4d
leaq 0x6d0(%rsp), %rdi
callq 0xd25a0
jmp 0x116867
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
jmp 0x115e96
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
leaq 0x868(%rsp), %rdi
callq 0xd4550
leaq 0x867(%rsp), %rdi
callq 0xd8ec0
jmp 0x11686f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
jmp 0x115edf
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
leaq 0x6b0(%rsp), %rdi
callq 0xd4550
leaq 0x6af(%rsp), %rdi
callq 0xd8ec0
jmp 0x11686f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
leaq 0x6d0(%rsp), %rdi
callq 0xd25a0
jmp 0x11686f
movq 0x888(%rsp), %rdi
leaq 0x723b0(%rip), %rsi     # 0x1882d6
callq 0xe30f0
testb $0x1, %al
jne 0x115f34
jmp 0x11635b
movq 0x120(%rsp), %rax
movl $0x1, (%rax)
movq 0x898(%rsp), %rax
movq %rax, 0xd8(%rsp)
leaq 0x507(%rsp), %rdi
movq %rdi, 0xe0(%rsp)
callq 0xe0c80
movq 0xe0(%rsp), %rdx
leaq 0x7126b(%rip), %rsi     # 0x1871e1
leaq 0x508(%rsp), %rdi
callq 0xe00a0
jmp 0x115f85
movq 0xd8(%rsp), %rdi
leaq 0x508(%rsp), %rsi
callq 0xdb6f0
movq %rax, 0xd0(%rsp)
jmp 0x115fa4
movq 0xd0(%rsp), %rsi
leaq 0x528(%rsp), %rdi
movl $0x8, %edx
callq 0xdfcc0
jmp 0x115fc0
leaq 0x508(%rsp), %rdi
callq 0xd4550
leaq 0x507(%rsp), %rdi
callq 0xd8ec0
movq 0x528(%rsp), %rax
movq -0x18(%rax), %rax
leaq 0x528(%rsp,%rax), %rax
movq %rax, 0xc0(%rsp)
movl $0x2, %edi
movl $0x8, %esi
callq 0xe0e70
movl %eax, 0xcc(%rsp)
jmp 0x11600e
movl 0xcc(%rsp), %edi
movl $0x40, %esi
callq 0xe0e70
movl %eax, 0xbc(%rsp)
jmp 0x116028
movl 0xbc(%rsp), %esi
movq 0xc0(%rsp), %rdi
callq 0xda6e0
jmp 0x11603e
movq 0x120(%rsp), %rsi
addq $0x8, %rsi
leaq 0x528(%rsp), %rdi
callq 0xd4480
jmp 0x116059
movq 0x898(%rsp), %rax
movq %rax, 0xa8(%rsp)
leaq 0x4df(%rsp), %rdi
movq %rdi, 0xb0(%rsp)
callq 0xe0c80
movq 0xb0(%rsp), %rdx
leaq 0x7113b(%rip), %rsi     # 0x1871c8
leaq 0x4e0(%rsp), %rdi
callq 0xe00a0
jmp 0x11609c
movq 0xa8(%rsp), %rdi
leaq 0x4e0(%rsp), %rsi
callq 0xdb6f0
movq %rax, 0xa0(%rsp)
jmp 0x1160bb
movq 0xa0(%rsp), %rdi
callq 0xe0d00
movl %eax, 0x9c(%rsp)
jmp 0x1160d1
movq 0x120(%rsp), %rax
movl 0x9c(%rsp), %ecx
movl %ecx, 0x18(%rax)
leaq 0x4e0(%rsp), %rdi
callq 0xd4550
leaq 0x4df(%rsp), %rdi
callq 0xd8ec0
movq 0x120(%rsp), %rax
cmpl $0x3, 0x18(%rax)
jne 0x116337
movq 0x898(%rsp), %rax
movq %rax, 0x88(%rsp)
leaq 0x337(%rsp), %rdi
movq %rdi, 0x90(%rsp)
callq 0xe0c80
movq 0x90(%rsp), %rdx
leaq 0x720b2(%rip), %rsi     # 0x1881f5
leaq 0x338(%rsp), %rdi
callq 0xe00a0
jmp 0x116152
movq 0x88(%rsp), %rdi
leaq 0x338(%rsp), %rsi
callq 0xdb6f0
movq %rax, 0x80(%rsp)
jmp 0x116171
movq 0x80(%rsp), %rsi
leaq 0x358(%rsp), %rdi
movl $0x8, %edx
callq 0xdfcc0
jmp 0x11618d
leaq 0x338(%rsp), %rdi
callq 0xd4550
leaq 0x337(%rsp), %rdi
callq 0xd8ec0
movq 0x358(%rsp), %rax
movq -0x18(%rax), %rax
leaq 0x358(%rsp,%rax), %rax
movq %rax, 0x70(%rsp)
movl $0x2, %edi
movl $0x8, %esi
callq 0xe0e70
movl %eax, 0x7c(%rsp)
jmp 0x1161d5
movl 0x7c(%rsp), %edi
movl $0x40, %esi
callq 0xe0e70
movl %eax, 0x6c(%rsp)
jmp 0x1161e9
movl 0x6c(%rsp), %esi
movq 0x70(%rsp), %rdi
callq 0xda6e0
jmp 0x1161f9
movq 0x120(%rsp), %rsi
addq $0x10, %rsi
leaq 0x358(%rsp), %rdi
callq 0xdcd70
jmp 0x116214
leaq 0x358(%rsp), %rdi
callq 0xd25a0
jmp 0x116337
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
jmp 0x11625d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
leaq 0x508(%rsp), %rdi
callq 0xd4550
leaq 0x507(%rsp), %rdi
callq 0xd8ec0
jmp 0x11686f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
jmp 0x116349
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
jmp 0x1162bf
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
leaq 0x4e0(%rsp), %rdi
callq 0xd4550
leaq 0x4df(%rsp), %rdi
callq 0xd8ec0
jmp 0x116349
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
jmp 0x116305
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
leaq 0x338(%rsp), %rdi
callq 0xd4550
leaq 0x337(%rsp), %rdi
callq 0xd8ec0
jmp 0x116349
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
leaq 0x358(%rsp), %rdi
callq 0xd25a0
jmp 0x116349
leaq 0x528(%rsp), %rdi
callq 0xd25a0
jmp 0x116865
leaq 0x528(%rsp), %rdi
callq 0xd25a0
jmp 0x11686f
movq 0x888(%rsp), %rdi
leaq 0x724d3(%rip), %rsi     # 0x18883d
callq 0xe30f0
testb $0x1, %al
jne 0x116375
jmp 0x116388
movq 0x120(%rsp), %rax
movl $0x2, (%rax)
jmp 0x116863
movq 0x888(%rsp), %rdi
leaq 0x71f46(%rip), %rsi     # 0x1882dd
callq 0xe30f0
testb $0x1, %al
jne 0x1163a2
jmp 0x1163b5
movq 0x120(%rsp), %rax
movl $0x3, (%rax)
jmp 0x116861
movq 0x888(%rsp), %rdi
leaq 0x71f1e(%rip), %rsi     # 0x1882e2
callq 0xe30f0
testb $0x1, %al
jne 0x1163cf
jmp 0x1163e2
movq 0x120(%rsp), %rax
movl $0x4, (%rax)
jmp 0x11685f
movq 0x888(%rsp), %rdi
leaq 0x71efa(%rip), %rsi     # 0x1882eb
callq 0xe30f0
testb $0x1, %al
jne 0x1163fc
jmp 0x11640f
movq 0x120(%rsp), %rax
movl $0x5, (%rax)
jmp 0x11685d
movq 0x888(%rsp), %rdi
leaq 0x718e9(%rip), %rsi     # 0x187d07
callq 0xe30f0
testb $0x1, %al
jne 0x11642c
jmp 0x116529
movq 0x120(%rsp), %rax
movl $0x6, (%rax)
movq 0x890(%rsp), %rax
movq %rax, 0x50(%rsp)
movq 0x898(%rsp), %rax
movq %rax, 0x58(%rsp)
leaq 0x30f(%rsp), %rdi
movq %rdi, 0x60(%rsp)
callq 0xe0c80
movq 0x60(%rsp), %rdx
leaq 0x70bbf(%rip), %rsi     # 0x187031
leaq 0x310(%rsp), %rdi
callq 0xe00a0
jmp 0x116481
movq 0x58(%rsp), %rdi
leaq 0x310(%rsp), %rsi
callq 0xdb6f0
movq %rax, 0x48(%rsp)
jmp 0x11649a
movq 0x48(%rsp), %rsi
movq 0x50(%rsp), %rdi
callq 0xe10d0
movq %rax, 0x40(%rsp)
jmp 0x1164b0
movq 0x120(%rsp), %rax
movq 0x40(%rsp), %rcx
movq %rcx, 0x8(%rax)
leaq 0x310(%rsp), %rdi
callq 0xd4550
leaq 0x30f(%rsp), %rdi
callq 0xd8ec0
jmp 0x11685b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
jmp 0x116517
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
leaq 0x310(%rsp), %rdi
callq 0xd4550
leaq 0x30f(%rsp), %rdi
callq 0xd8ec0
jmp 0x11686f
movq 0x888(%rsp), %rdi
leaq 0x71dc1(%rip), %rsi     # 0x1882f9
callq 0xe30f0
testb $0x1, %al
jne 0x116546
jmp 0x1166c8
movq 0x120(%rsp), %rax
movl $0x7, (%rax)
movq 0x898(%rsp), %rax
movq %rax, 0x30(%rsp)
leaq 0x167(%rsp), %rdi
movq %rdi, 0x38(%rsp)
callq 0xe0c80
movq 0x38(%rsp), %rdx
leaq 0x70c62(%rip), %rsi     # 0x1871e1
leaq 0x168(%rsp), %rdi
callq 0xe00a0
jmp 0x11658e
movq 0x30(%rsp), %rdi
leaq 0x168(%rsp), %rsi
callq 0xdb6f0
movq %rax, 0x28(%rsp)
jmp 0x1165a7
movq 0x28(%rsp), %rsi
leaq 0x188(%rsp), %rdi
movl $0x8, %edx
callq 0xdfcc0
jmp 0x1165c0
leaq 0x168(%rsp), %rdi
callq 0xd4550
leaq 0x167(%rsp), %rdi
callq 0xd8ec0
movq 0x188(%rsp), %rax
movq -0x18(%rax), %rax
leaq 0x188(%rsp,%rax), %rax
movq %rax, 0x18(%rsp)
movl $0x2, %edi
movl $0x8, %esi
callq 0xe0e70
movl %eax, 0x24(%rsp)
jmp 0x116608
movl 0x24(%rsp), %edi
movl $0x40, %esi
callq 0xe0e70
movl %eax, 0x14(%rsp)
jmp 0x11661c
movl 0x14(%rsp), %esi
movq 0x18(%rsp), %rdi
callq 0xda6e0
jmp 0x11662c
movq 0x120(%rsp), %rsi
addq $0x10, %rsi
leaq 0x188(%rsp), %rdi
callq 0xdcd70
jmp 0x116647
leaq 0x188(%rsp), %rdi
callq 0xd25a0
jmp 0x116859
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
jmp 0x116690
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
leaq 0x168(%rsp), %rdi
callq 0xd4550
leaq 0x167(%rsp), %rdi
callq 0xd8ec0
jmp 0x11686f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
leaq 0x188(%rsp), %rdi
callq 0xd25a0
jmp 0x11686f
movq 0x888(%rsp), %rdi
leaq 0x71c2b(%rip), %rsi     # 0x188302
callq 0xe30f0
testb $0x1, %al
jne 0x1166e2
jmp 0x1166f5
movq 0x120(%rsp), %rax
movl $0x8, (%rax)
jmp 0x116857
movq 0x888(%rsp), %rdi
leaq 0x71c06(%rip), %rsi     # 0x18830a
callq 0xe30f0
testb $0x1, %al
jne 0x11670f
jmp 0x116722
movq 0x120(%rsp), %rax
movl $0x9, (%rax)
jmp 0x116855
movq 0x888(%rsp), %rdi
leaq 0x71be6(%rip), %rsi     # 0x188317
callq 0xe30f0
testb $0x1, %al
jne 0x11673c
jmp 0x11674f
movq 0x120(%rsp), %rax
movl $0xa, (%rax)
jmp 0x116853
movq 0x888(%rsp), %rdi
leaq 0x71bc2(%rip), %rsi     # 0x188320
callq 0xe30f0
testb $0x1, %al
jne 0x116769
jmp 0x11677c
movq 0x120(%rsp), %rax
movl $0xb, (%rax)
jmp 0x116851
movb $0x1, 0x13e(%rsp)
movl $0x20, %edi
callq 0xd2b40
movq %rax, (%rsp)
leaq 0x13f(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0xe0c80
movq 0x8(%rsp), %rdx
leaq 0x71b7e(%rip), %rsi     # 0x18832e
leaq 0x140(%rsp), %rdi
callq 0xe00a0
jmp 0x1167bf
movq (%rsp), %rdi
leaq 0x140(%rsp), %rsi
callq 0xd1ae0
jmp 0x1167d2
movq (%rsp), %rdi
movb $0x0, 0x13e(%rsp)
movq 0xb16ab(%rip), %rsi     # 0x1c7e90
movq 0xb13e4(%rip), %rdx     # 0x1c7bd0
callq 0xe01f0
jmp 0x11687c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
jmp 0x11682d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x858(%rsp)
movl %eax, 0x854(%rsp)
leaq 0x140(%rsp), %rdi
callq 0xd4550
leaq 0x13f(%rsp), %rdi
callq 0xd8ec0
testb $0x1, 0x13e(%rsp)
jne 0x116846
jmp 0x11684f
movq (%rsp), %rdi
callq 0xd5400
jmp 0x11686f
jmp 0x116853
jmp 0x116855
jmp 0x116857
jmp 0x116859
jmp 0x11685b
jmp 0x11685d
jmp 0x11685f
jmp 0x116861
jmp 0x116863
jmp 0x116865
jmp 0x116867
addq $0x8a8, %rsp            # imm = 0x8A8
retq
movq 0x858(%rsp), %rdi
callq 0xe0be0
nopl (%rax)