// File: /workspace/github_cpp_makefile_star2_O3/AshOlogn[P]ash-language-interpreter/src/bitlogicaleval.cpp
// Function: ParseData bitHelper<long, long>(long, long, ParseDataType, ParseOperatorType)
ParseData bitHelper(T1 n1, T2 n2, ParseDataType finalType, ParseOperatorType op) {

  T1 arg1 = n1;
  T2 arg2 = n2;
  
  ParseData d;
  d.type = finalType;
  
  switch(op) {
    
    case BIT_AND_OP: {
      switch(finalType) {
        case CHAR_T: d.value.integer = (unsigned char) (n1 & n2); break;
        case INT32_T: d.value.integer = (int32_t) (n1 & n2); break;
        case INT64_T: d.value.integer = (int64_t) (n1 & n2); break;
        case UINT32_T: d.value.integer = (uint32_t) (n1 & n2); break;
        case UINT64_T: d.value.integer = (uint64_t) (n1 & n2); break;
      }
      break;
    }

    case BIT_XOR_OP: {
      switch(finalType) {
        case CHAR_T: d.value.integer = (unsigned char) (n1 ^ n2); break;
        case INT32_T: d.value.integer = (int32_t) (n1 ^ n2); break;
        case INT64_T: d.value.integer = (int64_t) (n1 ^ n2); break;
        case UINT32_T: d.value.integer = (uint32_t) (n1 ^ n2); break;
        case UINT64_T: d.value.integer = (uint64_t) (n1 ^ n2); break;
      }
      break;
    }
    
    case BIT_OR_OP: {
      switch(finalType) {
        case CHAR_T: d.value.integer = (unsigned char) (n1 | n2); break;
        case INT32_T: d.value.integer = (int32_t) (n1 | n2); break;
        case INT64_T: d.value.integer = (int64_t) (n1 | n2); break;
        case UINT32_T: d.value.integer = (uint32_t) (n1 | n2); break;
        case UINT64_T: d.value.integer = (uint64_t) (n1 | n2); break;
      }
      break;
    }

		case BIT_LEFT_OP: {
			switch(finalType) {
        case CHAR_T: d.value.integer = (unsigned char) (n1 << n2); break;
        case INT32_T: d.value.integer = (int32_t) (n1 << n2); break;
        case INT64_T: d.value.integer = (int64_t) (n1 << n2); break;
        case UINT32_T: d.value.integer = (uint32_t) (n1 << n2); break;
        case UINT64_T: d.value.integer = (uint64_t) (n1 << n2); break;
      }
      break;
		}

		case BIT_RIGHT_OP: {
			switch(finalType) {
        case CHAR_T: d.value.integer = (unsigned char) (n1 >> n2); break;
        case INT32_T: d.value.integer = (int32_t) (n1 >> n2); break;
        case INT64_T: d.value.integer = (int64_t) (n1 >> n2); break;
        case UINT32_T: d.value.integer = (uint32_t) (n1 >> n2); break;
        case UINT64_T: d.value.integer = (uint64_t) (n1 >> n2); break;
      }
      break;
		}
  }

  return d;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl %edx, %eax
movq %rsi, %rdx
addl $-0x11, %ecx
cmpl $0xa, %ecx
ja 0x12b50
leaq 0xf186(%rip), %rsi      # 0x21bc4
movslq (%rsi,%rcx,4), %rcx
addq %rsi, %rcx
jmpq *%rcx
leal -0x2(%rax), %ecx
cmpl $0x6, %ecx
ja 0x12b50
leaq 0xf1b2(%rip), %rsi      # 0x21c0c
movslq (%rsi,%rcx,4), %rcx
addq %rsi, %rcx
jmpq *%rcx
movl %edx, %ecx
shlq %cl, %rdi
jmp 0x12aaf
leal -0x2(%rax), %ecx
cmpl $0x6, %ecx
ja 0x12b50
leaq 0xf1e3(%rip), %rsi      # 0x21c60
movslq (%rsi,%rcx,4), %rcx
addq %rsi, %rcx
jmpq *%rcx
andq %rdi, %rdx
jmp 0x12b50
leal -0x2(%rax), %ecx
cmpl $0x6, %ecx
ja 0x12b50
leaq 0xf14f(%rip), %rsi      # 0x21bf0
movslq (%rsi,%rcx,4), %rcx
addq %rsi, %rcx
jmpq *%rcx
movl %edx, %ecx
sarq %cl, %rdi
movq %rdi, %rdx
jmp 0x12b50
leal -0x2(%rax), %ecx
cmpl $0x6, %ecx
ja 0x12b50
leaq 0xf17a(%rip), %rsi      # 0x21c44
movslq (%rsi,%rcx,4), %rcx
addq %rsi, %rcx
jmpq *%rcx
xorq %rdi, %rdx
jmp 0x12b50
leal -0x2(%rax), %ecx
cmpl $0x6, %ecx
ja 0x12b50
leaq 0xf141(%rip), %rsi      # 0x21c28
movslq (%rsi,%rcx,4), %rcx
addq %rsi, %rcx
jmpq *%rcx
orq %rdi, %rdx
jmp 0x12b50
andl %edi, %edx
jmp 0x12b1f
movl %edx, %ecx
shlq %cl, %rdi
jmp 0x12b0d
andl %edi, %edx
jmp 0x12b50
andl %edi, %edx
jmp 0x12b4d
movl %edx, %ecx
sarq %cl, %rdi
movslq %edi, %rdx
jmp 0x12b50
movl %edx, %ecx
sarq %cl, %rdi
jmp 0x12b29
xorl %edi, %edx
jmp 0x12b1f
orl %edi, %edx
movslq %edx, %rdx
jmp 0x12b50
movl %edx, %ecx
shlq %cl, %rdi
movl %edi, %edx
jmp 0x12b50
movl %edx, %ecx
shlq %cl, %rdi
jmp 0x12b39
movl %edx, %ecx
sarq %cl, %rdi
movzbl %dil, %edx
jmp 0x12b50
xorl %edi, %edx
jmp 0x12b50
xorl %edi, %edx
jmp 0x12b4d
orl %edi, %edx
jmp 0x12b50
orl %edi, %edx
movzbl %dl, %edx
popq %rbp
retq