LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::operator>>(node*&)
void LinkedList::operator>> (node*& lastNode){ 
  if (size > 0) {
    lastNode->data = tail->data;
    lastNode->next = tail->next;

    removeLast();
  } else {
    lastNode = nullptr;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %rbx
cmpq $0x0, 0x10(%rdi)
je 0x1691
movq %rdi, %r14
movq 0x8(%rdi), %rsi
movq (%rbx), %rdi
callq 0x20e6
movq 0x8(%r14), %rax
movq 0x40(%rax), %rax
movq (%rbx), %rcx
movq %rax, 0x40(%rcx)
movq %r14, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x169a
andq $0x0, (%rbx)
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::removeLast()
void LinkedList::removeLast() {
  node* pre = nullptr;
  node* cur = nullptr;

  cur = head;

  while (cur->next != nullptr) {
    pre = cur;
    cur = cur->next;
  }

  tail = pre;
  pre->next = nullptr;

  --size;
  delete cur;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq (%rdi), %rax
xorl %ecx, %ecx
movq %rax, %rbx
movq %rcx, %rdx
movq 0x40(%rax), %rax
movq %rbx, %rcx
testq %rax, %rax
jne 0x16a5
movq %rdx, 0x8(%rdi)
andq $0x0, 0x40(%rdx)
decq 0x10(%rdi)
movq %rbx, %rdi
callq 0x5830
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x1100
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::operator<<(node*&)
void LinkedList::operator<< (node*& newNode) {
  if (newNode == nullptr) {
    return;
  } else {
    insertEnd(newNode->data);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x40, %rsp
movq (%rsi), %rsi
testq %rsi, %rsi
je 0x1710
movq %rdi, %rbx
leaq -0x50(%rbp), %r14
movq %r14, %rdi
callq 0x20ac
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1470
leaq -0x50(%rbp), %rdi
callq 0x5830
addq $0x40, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %rbx
leaq -0x50(%rbp), %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1180
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::insertStart(Song)
void LinkedList::insertStart(Song value) {
  // Evita a adição de músicas repetidas
  if (search(value) != nullptr) {
    cout << "A música já existe no sistema." << endl;
  } else {
    node* temp = new node;

    temp->data = value;
    temp->next = head;
    head = temp;

    ++size;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq -0x58(%rbp), %r15
movq %r15, %rdi
callq 0x20ac
movq %rbx, %rdi
movq %r15, %rsi
callq 0x17fc
movq %rax, %r15
leaq -0x58(%rbp), %rdi
callq 0x5830
testq %r15, %r15
je 0x17a4
movq 0x8842(%rip), %rdi      # 0x9fd0
leaq 0x486f(%rip), %rsi      # 0x6004
callq 0x1110
movq %rax, %rdi
callq 0x1070
jmp 0x17d0
pushq $0x48
popq %rdi
callq 0x1120
movq %rax, %r15
movq %rax, %rdi
callq 0x5808
movq %r15, %rdi
movq %r14, %rsi
callq 0x20e6
movq (%rbx), %rax
movq %rax, 0x40(%r15)
movq %r15, (%rbx)
incq 0x10(%rbx)
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq %r15, %rdi
callq 0x1100
jmp 0x17f4
movq %rax, %rbx
leaq -0x58(%rbp), %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::search(Song)
node* LinkedList::search(Song searchSong) {
  node* temp = head;

  while (temp != nullptr) {
    Song s = temp->data;

    // Compara os títulos e artistas desconsiderando maiúsculas
    if ( toLowercase(s.getTitle()) == toLowercase(searchSong.getTitle()) && 
        toLowercase(s.getArtist()) == toLowercase(searchSong.getArtist()) ) {
      // Retorna o ponteiro para o nó correspondente
      return temp; 
    }

    temp = temp->next;
  }
  // Caso não encontre, retorna nullptr
  return nullptr;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x158, %rsp            # imm = 0x158
movq %rsi, -0x40(%rbp)
movq (%rdi), %rsi
leaq -0x60(%rbp), %r13
leaq -0x120(%rbp), %r12
testq %rsi, %rsi
je 0x1975
leaq -0x160(%rbp), %r15
movq %r15, %rdi
movq %rsi, -0x30(%rbp)
callq 0x20ac
movq %r13, %rdi
movq %r15, %rsi
callq 0x5850
leaq -0x80(%rbp), %rdi
movq %r13, %rsi
callq 0x589c
leaq -0xe0(%rbp), %r13
movq %r13, %rdi
movq -0x40(%rbp), %rsi
callq 0x5850
movq %r12, %rdi
movq %r13, %rsi
callq 0x589c
leaq -0x80(%rbp), %rdi
movq %r12, %rsi
callq 0x2110
testb %al, %al
je 0x1912
leaq -0xa0(%rbp), %r13
movq %r13, %rdi
leaq -0x160(%rbp), %rsi
callq 0x5868
leaq -0x100(%rbp), %r14
leaq -0xc0(%rbp), %rdi
movq %r13, %rsi
callq 0x589c
movq %r14, %rdi
movq -0x40(%rbp), %rsi
callq 0x5868
movq %r12, %r15
leaq -0x180(%rbp), %rbx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x589c
leaq -0xc0(%rbp), %r12
movq %r12, %rdi
movq %rbx, %rsi
callq 0x2110
movl %eax, %r13d
movq %rbx, %rdi
callq 0x1060
movq %r14, %rdi
callq 0x1060
movq %r12, %rdi
callq 0x1060
leaq -0xa0(%rbp), %rdi
callq 0x1060
movq %r15, %r12
jmp 0x1915
xorl %r13d, %r13d
movq %r12, %rdi
callq 0x1060
leaq -0xe0(%rbp), %rdi
callq 0x1060
leaq -0x80(%rbp), %rdi
callq 0x1060
leaq -0x60(%rbp), %rdi
callq 0x1060
testb %r13b, %r13b
je 0x194a
movq -0x30(%rbp), %rax
movq %rax, -0x38(%rbp)
jmp 0x1956
movq -0x30(%rbp), %rax
movq 0x40(%rax), %rax
movq %rax, -0x30(%rbp)
leaq -0x160(%rbp), %rdi
callq 0x5830
testb %r13b, %r13b
leaq -0x60(%rbp), %r13
movq -0x30(%rbp), %rsi
je 0x1822
jmp 0x197d
movq $0x0, -0x38(%rbp)
movq -0x38(%rbp), %rax
addq $0x158, %rsp            # imm = 0x158
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
jmp 0x19c9
movq %rax, %rbx
leaq -0x100(%rbp), %rdi
callq 0x1060
jmp 0x19ac
movq %rax, %rbx
leaq -0xc0(%rbp), %rdi
callq 0x1060
jmp 0x19bd
movq %rax, %rbx
leaq -0xa0(%rbp), %rdi
callq 0x1060
leaq -0x120(%rbp), %rdi
callq 0x1060
jmp 0x19e9
movq %rax, %rbx
jmp 0x1a07
movq %rax, %rbx
jmp 0x19f5
movq %rax, %rbx
jmp 0x19fe
movq %rax, %rbx
leaq -0xe0(%rbp), %rdi
callq 0x1060
leaq -0x80(%rbp), %rdi
callq 0x1060
leaq -0x60(%rbp), %rdi
callq 0x1060
leaq -0x160(%rbp), %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1180
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::insertEnd(LinkedList&)
void LinkedList::insertEnd(LinkedList& toInsert) {
  // Tratamento para garantir que a nova lista não está vazia
  if (toInsert.getSize() < 1) {
    return;
  } else {
    node* temp = toInsert.getHead();

    while (temp != nullptr) {
      // Insere cada elemento no fim da lista atual
      insertEnd(temp->data);
      
      temp = temp->next;
    }
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x48, %rsp
cmpq $0x0, 0x10(%rsi)
je 0x1a66
movq %rsi, %rbx
movq %rdi, %r14
leaq -0x58(%rbp), %r15
movq (%rbx), %rbx
testq %rbx, %rbx
je 0x1a66
movq %r15, %rdi
movq %rbx, %rsi
callq 0x20ac
movq %r14, %rdi
movq %r15, %rsi
callq 0x1470
movq %r15, %rdi
callq 0x5830
addq $0x40, %rbx
jmp 0x1a3a
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x58(%rbp), %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1180
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::insertPosition(unsigned long, Song)
void LinkedList::insertPosition(size_t pos, Song value) {
  node* pre = nullptr;
  node* cur = nullptr;

  if (pos == 1) {
    if (size == 0) {
      insertEnd(value);
    } else {
      insertStart(value);
    } 
  } else if (pos <= size) {
    // Evita a adição de músicas repetidas
    if (search(value) != nullptr) {
      cout << "A música já existe no sistema." << endl;
    } else {

      node* temp = new node;
      
      cur = head;
    
      for (size_t i = 1; i < pos; ++i) {
        pre = cur;
        cur = cur->next;
      }

      temp->data = value;
      pre->next = temp;
      temp->next = cur;

      ++size;
    }
  } else {
    insertEnd(value);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x108, %rsp            # imm = 0x108
movq %rdx, %r14
movq %rdi, %rbx
movq 0x10(%rdi), %rax
cmpq $0x1, %rsi
jne 0x1adc
testq %rax, %rax
je 0x1b52
leaq -0xf0(%rbp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x20ac
movq %rbx, %rdi
movq %r15, %rsi
callq 0x174c
leaq -0xf0(%rbp), %rdi
jmp 0x1b76
movq %rsi, %r15
cmpq %rsi, %rax
jae 0x1b04
leaq -0x70(%rbp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x20ac
movq %rbx, %rdi
movq %r15, %rsi
callq 0x1470
leaq -0x70(%rbp), %rdi
jmp 0x1b76
leaq -0xb0(%rbp), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x20ac
movq %rbx, %rdi
movq %r12, %rsi
callq 0x17fc
movq %rax, %r12
leaq -0xb0(%rbp), %rdi
callq 0x5830
testq %r12, %r12
je 0x1b8d
movq 0x8494(%rip), %rdi      # 0x9fd0
leaq 0x44c1(%rip), %rsi      # 0x6004
callq 0x1110
movq %rax, %rdi
callq 0x1070
jmp 0x1b7b
leaq -0x130(%rbp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x20ac
movq %rbx, %rdi
movq %r15, %rsi
callq 0x1470
leaq -0x130(%rbp), %rdi
callq 0x5830
addq $0x108, %rsp            # imm = 0x108
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
pushq $0x48
popq %rdi
callq 0x1120
movq %rax, -0x30(%rbp)
movq %rax, %rdi
callq 0x5808
pushq $0x1
popq %rax
xorl %r12d, %r12d
movq %rbx, %rcx
movq (%rcx), %r13
cmpq %r15, %rax
jae 0x1bbe
leaq 0x40(%r13), %rcx
incq %rax
movq %r13, %r12
jmp 0x1baa
movq -0x30(%rbp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x20e6
movq %r15, 0x40(%r12)
movq %r13, 0x40(%r15)
incq 0x10(%rbx)
jmp 0x1b7b
movq %rax, %rbx
movq -0x30(%rbp), %rdi
callq 0x1100
jmp 0x1c1a
movq %rax, %rbx
leaq -0x130(%rbp), %rdi
jmp 0x1c15
movq %rax, %rbx
leaq -0xb0(%rbp), %rdi
jmp 0x1c15
movq %rax, %rbx
leaq -0x70(%rbp), %rdi
jmp 0x1c15
movq %rax, %rbx
leaq -0xf0(%rbp), %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::removeFirst()
void LinkedList::removeFirst() {
  node* temp = head;

  head = head->next;

  --size;
  delete temp;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq (%rdi), %rbx
movq 0x40(%rbx), %rax
movq %rax, (%rdi)
decq 0x10(%rdi)
movq %rbx, %rdi
callq 0x5830
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x1100
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::removePosition(unsigned long)
void LinkedList::removePosition(size_t pos) {
  node* pre = nullptr;
  node* cur = nullptr;

  if (pos == 1) {
    removeFirst();
  } else if (pos < size) {
    cur = head;

    for (size_t i = 1; i < pos; ++i) {
      pre = cur;
      cur = cur->next;
    }
    
    pre->next = cur->next;

    --size;
    delete cur;
  } else if (pos < 1) {
    return;
  } else {
    removeLast();
  }
}

// Assembly:
cmpq $0x1, %rsi
je 0x1c22
movq 0x10(%rdi), %rax
cmpq %rsi, %rax
jbe 0x1ca6
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
pushq $0x1
popq %rcx
xorl %edx, %edx
movq %rdi, %r8
movq (%r8), %rbx
cmpq %rsi, %rcx
jae 0x1c81
leaq 0x40(%rbx), %r8
incq %rcx
movq %rbx, %rdx
jmp 0x1c6d
movq 0x40(%rbx), %rcx
movq %rcx, 0x40(%rdx)
decq %rax
movq %rax, 0x10(%rdi)
movq %rbx, %rdi
callq 0x5830
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x1100
testq %rsi, %rsi
jne 0x169a
retq
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::removePosition(LinkedList&)
void LinkedList::removePosition(LinkedList& toRemove) {
  // Tratamento para garantir que a nova lista não está vazia
  if (toRemove.getSize() < 1) {
    return;
  } else {
    node* temp = toRemove.getHead();

    while (temp != nullptr) {
      // Obtém a posição da música na lista atual
      size_t pos = getPosition(temp->data);
  
      // Remove da lista atual
      if (pos > 0) {
        removePosition(pos);
      }                      
      
      temp = temp->next;
    }    
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
cmpq $0x0, 0x10(%rsi)
je 0x1d0f
movq %rsi, %rbx
movq %rdi, %r14
leaq -0x60(%rbp), %r15
movq (%rbx), %rbx
testq %rbx, %rbx
je 0x1d0f
movq %r15, %rdi
movq %rbx, %rsi
callq 0x20ac
movq %r14, %rdi
movq %r15, %rsi
callq 0x1d30
movq %rax, %r12
movq %r15, %rdi
callq 0x5830
testq %r12, %r12
je 0x1d09
movq %r14, %rdi
movq %r12, %rsi
callq 0x1c4c
addq $0x40, %rbx
jmp 0x1cd0
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x60(%rbp), %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::getPosition(Song)
size_t LinkedList::getPosition(Song searchSong) {
  node* temp = head;
  size_t pos = 1;

  while (temp != nullptr) {
    Song s = temp->data;

    // Compara os títulos e artistas desconsiderando maiúsculas
    if ( toLowercase(s.getTitle()) == toLowercase(searchSong.getTitle()) && 
        toLowercase(s.getArtist()) == toLowercase(searchSong.getArtist()) ) {
      // Retorna a posição correspondente
      return pos; 
    }

    temp = temp->next;
    ++pos;
  }
  // Caso não encontre, retorna 0
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x168, %rsp            # imm = 0x168
movq %rsi, -0x48(%rbp)
movq (%rdi), %rsi
pushq $0x1
popq %rax
movq %rax, -0x40(%rbp)
leaq -0x68(%rbp), %r13
leaq -0x128(%rbp), %r12
testq %rsi, %rsi
je 0x1ebd
leaq -0x168(%rbp), %r15
movq %r15, %rdi
movq %rsi, -0x30(%rbp)
callq 0x20ac
movq %r13, %rdi
movq %r15, %rsi
callq 0x5850
leaq -0x88(%rbp), %rdi
movq %r13, %rsi
callq 0x589c
leaq -0xe8(%rbp), %r13
movq %r13, %rdi
movq -0x48(%rbp), %rsi
callq 0x5850
movq %r12, %rdi
movq %r13, %rsi
callq 0x589c
leaq -0x88(%rbp), %rdi
movq %r12, %rsi
callq 0x2110
testb %al, %al
je 0x1e53
leaq -0xa8(%rbp), %r13
movq %r13, %rdi
leaq -0x168(%rbp), %rsi
callq 0x5868
leaq -0x108(%rbp), %r14
leaq -0xc8(%rbp), %rdi
movq %r13, %rsi
callq 0x589c
movq %r14, %rdi
movq -0x48(%rbp), %rsi
callq 0x5868
movq %r12, %r15
leaq -0x188(%rbp), %rbx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x589c
leaq -0xc8(%rbp), %r12
movq %r12, %rdi
movq %rbx, %rsi
callq 0x2110
movl %eax, %r13d
movq %rbx, %rdi
callq 0x1060
movq %r14, %rdi
callq 0x1060
movq %r12, %rdi
callq 0x1060
leaq -0xa8(%rbp), %rdi
callq 0x1060
movq %r15, %r12
jmp 0x1e56
xorl %r13d, %r13d
movq %r12, %rdi
callq 0x1060
leaq -0xe8(%rbp), %rdi
callq 0x1060
leaq -0x88(%rbp), %rdi
callq 0x1060
leaq -0x68(%rbp), %rdi
callq 0x1060
testb %r13b, %r13b
je 0x1e8e
movq -0x40(%rbp), %rax
movq %rax, -0x38(%rbp)
jmp 0x1e9e
movq -0x30(%rbp), %rax
movq 0x40(%rax), %rax
movq %rax, -0x30(%rbp)
incq -0x40(%rbp)
leaq -0x168(%rbp), %rdi
callq 0x5830
testb %r13b, %r13b
leaq -0x68(%rbp), %r13
movq -0x30(%rbp), %rsi
je 0x1d5d
jmp 0x1ec5
movq $0x0, -0x38(%rbp)
movq -0x38(%rbp), %rax
addq $0x168, %rsp            # imm = 0x168
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
jmp 0x1f11
movq %rax, %rbx
leaq -0x108(%rbp), %rdi
callq 0x1060
jmp 0x1ef4
movq %rax, %rbx
leaq -0xc8(%rbp), %rdi
callq 0x1060
jmp 0x1f05
movq %rax, %rbx
leaq -0xa8(%rbp), %rdi
callq 0x1060
leaq -0x128(%rbp), %rdi
callq 0x1060
jmp 0x1f31
movq %rax, %rbx
jmp 0x1f52
movq %rax, %rbx
jmp 0x1f3d
movq %rax, %rbx
jmp 0x1f49
movq %rax, %rbx
leaq -0xe8(%rbp), %rdi
callq 0x1060
leaq -0x88(%rbp), %rdi
callq 0x1060
leaq -0x68(%rbp), %rdi
callq 0x1060
leaq -0x168(%rbp), %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::getNode(unsigned long)
node* LinkedList::getNode(size_t pos) {
  // Caso a posição seja inválida, retorna nullptr
  if (pos < 1 || pos > size) {
    return nullptr;
  } else {
    node* temp = head;

    for (size_t i = 1; i < pos; ++i) {
      temp = temp->next;
    }
    // Retorna o ponteiro para o nó correspondente
    return temp;
  }
}

// Assembly:
leaq -0x1(%rsi), %rcx
cmpq 0x10(%rdi), %rcx
jae 0x1f94
pushq %rbp
movq %rsp, %rbp
movq %rdi, %rax
movabsq $0x1, %rcx
movq (%rax), %rax
cmpq %rsi, %rcx
jae 0x1f92
addq $0x40, %rax
incq %rcx
jmp 0x1f81
popq %rbp
retq
xorl %eax, %eax
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/linkedList.cpp
// Function: LinkedList::display()
void LinkedList::display() {
  node* temp = head;
  size_t index = 1;

  while (temp != nullptr) {
    Song s = temp->data;
    cout << index << " - " << s.getTitle() << " - " << s.getArtist() << endl;
    temp = temp->next;
    ++index;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movq (%rdi), %rbx
pushq $0x1
popq %r14
leaq -0xa8(%rbp), %r15
testq %rbx, %rbx
je 0x2063
movq %r15, %rdi
movq %rbx, %rsi
callq 0x20ac
movq 0x7ffb(%rip), %rdi      # 0x9fd0
movq %r14, %rsi
callq 0x10b0
movq %rax, %rdi
leaq 0x403e(%rip), %rsi      # 0x6025
callq 0x1110
movq %rax, %r12
leaq -0x68(%rbp), %r13
movq %r13, %rdi
movq %r15, %rsi
callq 0x5850
movq %r12, %rdi
movq %r13, %rsi
callq 0x10f0
movq %rax, %rdi
leaq 0x4012(%rip), %rsi      # 0x6025
callq 0x1110
movq %rax, %r12
leaq -0x48(%rbp), %r13
movq %r13, %rdi
movq %r15, %rsi
callq 0x5868
movq %r12, %rdi
movq %r13, %rsi
callq 0x10f0
movq %rax, %rdi
callq 0x1070
leaq -0x48(%rbp), %rdi
callq 0x1060
leaq -0x68(%rbp), %rdi
callq 0x1060
movq 0x40(%rbx), %rbx
incq %r14
movq %r15, %rdi
callq 0x5830
jmp 0x1fba
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x2087
jmp 0x2095
movq %rax, %rbx
leaq -0x48(%rbp), %rdi
callq 0x1060
jmp 0x208a
movq %rax, %rbx
leaq -0x68(%rbp), %rdi
callq 0x1060
jmp 0x2098
movq %rax, %rbx
leaq -0xa8(%rbp), %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/listOfPlaylists.cpp
// Function: ListOfPlaylists::~ListOfPlaylists()
ListOfPlaylists::~ListOfPlaylists() {
  if (size != 0) {
    node_* temp = nullptr;
    node_* cur = nullptr;

    cur = head;

    while (cur != nullptr) {
      temp = cur->next;
      delete cur->data;
      delete cur;
      cur = temp;
    }
  }
}

// Assembly:
cmpq $0x0, 0x10(%rdi)
je 0x21a6
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq (%rdi), %rbx
testq %rbx, %rbx
je 0x219c
movq (%rbx), %r14
movq 0x8(%rbx), %r15
testq %r14, %r14
je 0x2187
movq %r14, %rdi
callq 0x50c0
movq %r14, %rdi
callq 0x1100
movq %rbx, %rdi
callq 0x1100
movq %r15, %rbx
jmp 0x216e
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/listOfPlaylists.cpp
// Function: ListOfPlaylists::getPlaylist(unsigned long)
Playlist* ListOfPlaylists::getPlaylist(size_t pos) {
  // Caso a posição seja inválida, retorna nullptr
  if (pos < 1 || pos > size) {
    return nullptr;
  } else {
    node_* temp = head;

    for (size_t i = 1; i < pos; ++i) {
      temp = temp->next;
    }
    // Retorna o ponteiro para a playlist correspondente
    return temp->data;
  }
}

// Assembly:
leaq -0x1(%rsi), %rax
cmpq 0x10(%rdi), %rax
jae 0x21e0
pushq %rbp
movq %rsp, %rbp
movabsq $0x1, %rax
movq (%rdi), %rdi
cmpq %rsi, %rax
jae 0x21db
addq $0x8, %rdi
incq %rax
jmp 0x21ca
movq (%rdi), %rax
popq %rbp
retq
xorl %eax, %eax
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/listOfPlaylists.cpp
// Function: ListOfPlaylists::searchPlaylist(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
Playlist* ListOfPlaylists::searchPlaylist(string searchName) {
  node_* temp = head;

  while (temp != nullptr) {
    // Compara os nomes desconsiderando maiúsculas
    if ( toLowercase(temp->data->getName()) == toLowercase(searchName) ) {
      // Retorna o ponteiro para o nó correspondente
      return temp->data; 
    }

    temp = temp->next;
  }
  // Caso não encontre, retorna nullptr
  return nullptr;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movq %rsi, -0x30(%rbp)
movq %rdi, %r14
leaq -0x90(%rbp), %r13
leaq -0x70(%rbp), %rbx
leaq -0xb0(%rbp), %r15
movq (%r14), %r14
testq %r14, %r14
je 0x2284
movq (%r14), %rsi
leaq -0x50(%rbp), %r12
movq %r12, %rdi
callq 0x54dc
movq %r13, %rdi
movq %r12, %rsi
callq 0x589c
movq %rbx, %rdi
movq -0x30(%rbp), %rsi
callq 0x1140
movq %r15, %rdi
movq %rbx, %rsi
callq 0x589c
movq %r13, %rdi
movq %r15, %rsi
callq 0x2110
movl %eax, %r12d
movq %r15, %rdi
callq 0x1060
movq %rbx, %rdi
callq 0x1060
movq %r13, %rdi
callq 0x1060
leaq -0x50(%rbp), %rdi
callq 0x1060
testb %r12b, %r12b
jne 0x2288
addq $0x8, %r14
jmp 0x2211
xorl %eax, %eax
jmp 0x228b
movq (%r14), %rax
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
jmp 0x22bf
movq %rax, %rbx
leaq -0x70(%rbp), %rdi
callq 0x1060
jmp 0x22b3
movq %rax, %rbx
leaq -0x90(%rbp), %rdi
callq 0x1060
leaq -0x50(%rbp), %rdi
callq 0x1060
movq %rbx, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/listOfPlaylists.cpp
// Function: ListOfPlaylists::insertPlaylist(Playlist*)
void ListOfPlaylists::insertPlaylist(Playlist* value) {
  if (searchPlaylist(value->getName()) != nullptr) {
    cout << "Já existe uma playlist com esse nome no sistema." << endl;
  } else {
    node_* temp = new node_;

    temp->data = value;
    temp->next = nullptr;

    if (head == nullptr) {
      head =  temp;
      tail = temp;
      temp = nullptr;
    } else {
      tail->next = temp;
      tail = temp;
    }

    ++size;
    cout << "Playlist criada! Adicione algumas músicas." << endl;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq -0x38(%rbp), %r15
movq %r15, %rdi
callq 0x54dc
movq %rbx, %rdi
movq %r15, %rsi
callq 0x21e4
movq %rax, %r15
leaq -0x38(%rbp), %rdi
callq 0x1060
testq %r15, %r15
je 0x2314
leaq 0x3d17(%rip), %rsi      # 0x6029
jmp 0x2346
pushq $0x10
popq %rdi
callq 0x1120
movq %r14, (%rax)
andq $0x0, 0x8(%rax)
cmpq $0x0, (%rbx)
je 0x2334
movq 0x8(%rbx), %rcx
movq %rax, 0x8(%rcx)
jmp 0x2337
movq %rax, (%rbx)
movq %rax, 0x8(%rbx)
incq 0x10(%rbx)
leaq 0x3d15(%rip), %rsi      # 0x605b
movq 0x7c83(%rip), %rdi      # 0x9fd0
callq 0x1110
movq %rax, %rdi
callq 0x1070
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x38(%rbp), %rdi
callq 0x1060
movq %rbx, %rdi
callq 0x1180
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/listOfPlaylists.cpp
// Function: ListOfPlaylists::removePlaylist(unsigned long)
void ListOfPlaylists::removePlaylist(size_t pos) {
  node_* pre = nullptr;
  node_* cur = nullptr;

  cur = head;

  if (pos == 1) {
    head = head->next;
  } else if (pos < size) {
    for (size_t i = 1; i < pos; ++i) {
      pre = cur;
      cur = cur->next;
    }
    
    pre->next = cur->next;
  } else {
    while (cur->next != nullptr) {
      pre = cur;
      cur = cur->next;
    }

    tail = pre;
    pre->next = nullptr;
  }

  --size;
  delete cur->data;
  delete cur;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq (%rdi), %rbx
cmpq $0x1, %rsi
jne 0x2397
movq 0x8(%rbx), %rax
movq %rax, (%rdi)
movq 0x10(%rdi), %rax
jmp 0x23df
movq 0x10(%rdi), %rax
cmpq %rsi, %rax
jbe 0x23bf
pushq $0x1
popq %rcx
xorl %edx, %edx
movq 0x8(%rbx), %r8
cmpq %rsi, %rcx
jae 0x23b9
incq %rcx
movq %rbx, %rdx
movq %r8, %rbx
jmp 0x23a5
movq %r8, 0x8(%rdx)
jmp 0x23df
xorl %edx, %edx
movq %rbx, %rcx
movq %rdx, %rsi
movq 0x8(%rbx), %rbx
movq %rcx, %rdx
testq %rbx, %rbx
jne 0x23c1
movq %rsi, 0x8(%rdi)
andq $0x0, 0x8(%rsi)
movq %rcx, %rbx
decq %rax
movq %rax, 0x10(%rdi)
movq (%rbx), %r14
testq %r14, %r14
je 0x23f6
movq %r14, %rdi
callq 0x50c0
movq %r14, %rdi
callq 0x1100
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x1100
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/listOfPlaylists.cpp
// Function: ListOfPlaylists::removeFromAll(Song)
void ListOfPlaylists::removeFromAll(Song target) {
  node_* temp = head;

  // Percorre as playlists do sistema
  while (temp != nullptr) {
    // Guarda a lista de músicas atual
    LinkedList* songs = temp->data->getSongs();

    // Verifica se o alvo está na lista 
    if (songs->search(target) != nullptr) {
      // Obtém a posição numérica da música
      size_t pos = songs->getPosition(target);
      // Remove a música da lista
      songs->removePosition(pos);
    }

    temp = temp->next;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %rsi, -0x38(%rbp)
movq %rdi, %r12
leaq -0x78(%rbp), %rbx
leaq -0xb8(%rbp), %r15
movq %rbx, -0x30(%rbp)
movq (%r12), %r12
testq %r12, %r12
je 0x24aa
movq (%r12), %rdi
callq 0x535a
movq %rax, %r13
movq %rbx, %rdi
movq -0x38(%rbp), %rsi
callq 0x20ac
movq %r13, %rdi
movq %rbx, %rsi
callq 0x17fc
movq %rax, %r14
movq %rbx, %rdi
callq 0x5830
testq %r14, %r14
je 0x24a4
movq %r15, %rbx
movq %r15, %rdi
movq -0x38(%rbp), %rsi
callq 0x20ac
movq %r13, %rdi
movq %r15, %rsi
callq 0x1d30
movq %rax, %r14
movq %rbx, %rdi
callq 0x5830
movq %r13, %rdi
movq %r14, %rsi
callq 0x1c4c
leaq -0x78(%rbp), %rbx
addq $0x8, %r12
jmp 0x2434
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq %rbx, -0x30(%rbp)
jmp 0x24c8
movq %rax, %r14
movq -0x30(%rbp), %rdi
callq 0x5830
movq %r14, %rdi
callq 0x1180
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/listOfPlaylists.cpp
// Function: ListOfPlaylists::display()
void ListOfPlaylists::display() {
  node_* temp = head;
  size_t index = 1;
  string name = "";

  while (temp != nullptr) {
    name = temp->data->getName();
    cout << index << " - " << name << endl;
    temp = temp->next;
    ++index;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq (%rdi), %r12
leaq 0x3b33(%rip), %rsi      # 0x6028
leaq -0x48(%rbp), %rbx
leaq -0x68(%rbp), %r14
movq %rbx, %rdi
movq %r14, %rdx
callq 0x1040
pushq $0x1
popq %r15
leaq 0x3b12(%rip), %r13      # 0x6025
testq %r12, %r12
je 0x256e
movq (%r12), %rsi
movq %r14, %rdi
callq 0x54dc
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1130
movq %r14, %rdi
callq 0x1060
movq 0x7a92(%rip), %rdi      # 0x9fd0
movq %r15, %rsi
callq 0x10b0
movq %rax, %rdi
movq %r13, %rsi
callq 0x1110
movq %rax, %rdi
movq %rbx, %rsi
callq 0x10f0
movq %rax, %rdi
callq 0x1070
movq 0x8(%r12), %r12
incq %r15
jmp 0x2513
leaq -0x48(%rbp), %rdi
callq 0x1060
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x2588
movq %rax, %rbx
leaq -0x48(%rbp), %rdi
callq 0x1060
movq %rbx, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/playlist.cpp
// Function: Playlist::Playlist(Playlist const&)
Playlist::Playlist(const Playlist& old) {
  songs = new LinkedList;
  playing = nullptr;
  count = 1;
  name = old.name;

  node* temp = old.songs->getHead();

  while (temp != nullptr) {
    songs->insertEnd(temp->data);

    temp = temp->next;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
movq %rax, (%rdi)
andq $0x0, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
pushq $0x18
popq %rdi
callq 0x1120
movq %rax, %r15
movq %rax, %rdi
callq 0x13bc
movq %r15, 0x20(%rbx)
andq $0x0, 0x28(%rbx)
movq $0x1, 0x30(%rbx)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1080
movq 0x20(%r14), %rdi
callq 0x172e
movq %rax, %r14
leaq -0x60(%rbp), %r15
testq %r14, %r14
je 0x5181
movq 0x20(%rbx), %r12
movq %r15, %rdi
movq %r14, %rsi
callq 0x20ac
movq %r12, %rdi
movq %r15, %rsi
callq 0x1470
movq %r15, %rdi
callq 0x5830
movq 0x40(%r14), %r14
jmp 0x5154
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0x519f
movq %rax, %r14
movq %r15, %rdi
callq 0x1100
jmp 0x51b0
jmp 0x519f
movq %rax, %r14
jmp 0x51b0
movq %rax, %r14
leaq -0x60(%rbp), %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1060
movq %r14, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/playlist.cpp
// Function: Playlist::operator+(Playlist&)
Playlist Playlist::operator+ (Playlist& secondPlaylist) {
  Playlist result;
  
  // Insere as músicas da playlist atual na playlist final
  result.insertSong(*this); 

  // Insere as músicas da segunda playlist na playlist final
  result.insertSong(secondPlaylist);

  return result;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
callq 0x5054
movq %rbx, %rdi
movq %r15, %rsi
callq 0x5210
movq %rbx, %rdi
movq %r14, %rsi
callq 0x5210
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x50c0
movq %r14, %rdi
callq 0x1180
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/playlist.cpp
// Function: Playlist::insertSong(Playlist&)
void Playlist::insertSong(Playlist& toInsert) {
  // Tratamento para garantir que a nova lista não está vazia
  if (toInsert.getSongs()->getSize() < 1) {
    return;
  } else {
    // Insere as músicas na playlist atual por meio de sobrecarga
    songs->insertEnd(*toInsert.getSongs());
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq 0x20(%rsi), %rdi
callq 0x1742
testq %rax, %rax
je 0x523c
movq 0x20(%r14), %rdi
movq 0x20(%rbx), %rsi
popq %rbx
popq %r14
popq %rbp
jmp 0x1a1c
popq %rbx
popq %r14
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/playlist.cpp
// Function: Playlist::operator+(Song&)
Playlist Playlist::operator+ (Song& toAdd) {
  Playlist result;

  // Insere as músicas da playlist atual na playlist final
  result.insertSong(*this); 

  // Insere a música do parâmetro no final
  result.songs->insertEnd(toAdd);

  return result;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
callq 0x5054
movq %rbx, %rdi
movq %r15, %rsi
callq 0x5210
movq 0x20(%rbx), %r15
leaq -0x58(%rbp), %rdi
movq %r14, %rsi
callq 0x20ac
leaq -0x58(%rbp), %rsi
movq %r15, %rdi
callq 0x1470
leaq -0x58(%rbp), %rdi
callq 0x5830
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
leaq -0x58(%rbp), %rdi
callq 0x5830
jmp 0x52ac
movq %rax, %r14
movq %rbx, %rdi
callq 0x50c0
movq %r14, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/playlist.cpp
// Function: Playlist::operator-(Playlist&)
Playlist Playlist::operator- (Playlist& secondPlaylist) {
  // Cria a playlist final a partir da playlist atual
  Playlist result(*this);

  node* temp = secondPlaylist.getSongs()->getHead();
  // Percorre a segunda playlist
  while (temp != nullptr) {
    // Procura a posição da música na playlist final
    size_t pos = result.getSongs()->getPosition(temp->data);

    
    if (pos > 0) {
      result.removeSong(pos);
    }

    temp = temp->next;
  }
  
  return result;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %rdx, %r14
movq %rdi, %rbx
callq 0x50f0
movq 0x20(%r14), %rdi
callq 0x172e
movq %rax, %r14
leaq -0x60(%rbp), %r15
testq %r14, %r14
je 0x5326
movq 0x20(%rbx), %r12
movq %r15, %rdi
movq %r14, %rsi
callq 0x20ac
movq %r12, %rdi
movq %r15, %rsi
callq 0x1d30
movq %rax, %r12
movq %r15, %rdi
callq 0x5830
testq %r12, %r12
je 0x5320
movq %rbx, %rdi
movq %r12, %rsi
callq 0x5364
movq 0x40(%r14), %r14
jmp 0x52e6
movq %rbx, %rax
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0x5346
movq %rax, %r14
leaq -0x60(%rbp), %rdi
callq 0x5830
jmp 0x5349
movq %rax, %r14
movq %rbx, %rdi
callq 0x50c0
movq %r14, %rdi
callq 0x1180
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/playlist.cpp
// Function: Playlist::operator-(Song&)
Playlist Playlist::operator- (Song& toRemove) {
  // Cria a playlist final a partir da playlist atual
  Playlist result(*this);

  // Obtém a posição da música na playlist final
  size_t pos = result.getSongs()->getPosition(toRemove);

  // Se existir, remove
  if (pos > 0) {
    result.removeSong(pos);
  }

  return result;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rdx, %r15
movq %rdi, %rbx
callq 0x50f0
movq 0x20(%rbx), %r14
leaq -0x58(%rbp), %rdi
movq %r15, %rsi
callq 0x20ac
leaq -0x58(%rbp), %rsi
movq %r14, %rdi
callq 0x1d30
movq %rax, %r14
leaq -0x58(%rbp), %rdi
callq 0x5830
testq %r14, %r14
je 0x53c2
movq %rbx, %rdi
movq %r14, %rsi
callq 0x5364
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
leaq -0x58(%rbp), %rdi
callq 0x5830
jmp 0x53e1
movq %rax, %r14
movq %rbx, %rdi
callq 0x50c0
movq %r14, %rdi
callq 0x1180
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/playlist.cpp
// Function: Playlist::operator>>(Song*&)
void Playlist::operator>> (Song*& lastSong) {
  if (songs->getSize() > 0) {
    node* temp = new node;
    // Extrai o ultimo nó da lista de músicas
    *songs >> temp;
    // Guarda a música desse nó
    *lastSong = temp->data;

    delete temp;
  } else {
    lastSong = nullptr;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movq 0x20(%rdi), %rdi
callq 0x1742
testq %rax, %rax
je 0x5463
pushq $0x48
popq %rdi
callq 0x1120
movq %rax, %r15
movq %rax, %rdi
callq 0x5808
leaq -0x28(%rbp), %r12
movq %r15, (%r12)
movq 0x20(%r14), %rdi
movq %r12, %rsi
callq 0x1656
movq (%r12), %rsi
movq (%rbx), %rdi
callq 0x20e6
movq (%r12), %rbx
testq %rbx, %rbx
je 0x5459
movq %rbx, %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1100
jmp 0x5467
andq $0x0, (%rbx)
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq %r15, %rdi
callq 0x1100
movq %rbx, %rdi
callq 0x1180
nop
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/playlist.cpp
// Function: Playlist::operator<<(Song*&)
void Playlist::operator<< (Song*& newSong) {
  if (newSong == nullptr) {
    return;
  } else {
    songs->insertEnd(*newSong);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x40, %rsp
movq (%rsi), %rsi
testq %rsi, %rsi
je 0x54bf
movq 0x20(%rdi), %rbx
leaq -0x50(%rbp), %r14
movq %r14, %rdi
callq 0x20ac
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1470
leaq -0x50(%rbp), %rdi
callq 0x5830
addq $0x40, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, %rbx
leaq -0x50(%rbp), %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/playlist.cpp
// Function: Playlist::moveSong(unsigned long, unsigned long)
void Playlist::moveSong(size_t start, size_t end) {
  if (start != end) {
    // Acessa o valor da música a ser movida
    node* target = songs->getNode(start);
    Song value = target->data;

    // Remove ela da posição atual
    songs->removePosition(start);

    // Insere ela na nova posição
    if (end < start) {
      songs->insertPosition(end, value);
    } else {
      songs->insertPosition(end + 1, value);
    } 

    // Cada vez que uma música for movida, playing recebe head
    playing = songs->getHead();
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0xc0, %rsp
cmpq %rdx, %rsi
je 0x561f
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq 0x20(%rdi), %rdi
callq 0x1f66
leaq -0x60(%rbp), %rdi
movq %rax, %rsi
callq 0x20ac
movq 0x20(%rbx), %rdi
movq %r15, %rsi
callq 0x1c4c
movq 0x20(%rbx), %r12
cmpq %r15, %r14
jae 0x55dd
leaq -0xe0(%rbp), %r15
leaq -0x60(%rbp), %rsi
movq %r15, %rdi
callq 0x20ac
movq %r12, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x1a86
jmp 0x5601
leaq -0xa0(%rbp), %r15
leaq -0x60(%rbp), %rsi
movq %r15, %rdi
callq 0x20ac
incq %r14
movq %r12, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x1a86
movq %r15, %rdi
callq 0x5830
movq 0x20(%rbx), %rdi
callq 0x172e
movq %rax, 0x28(%rbx)
leaq -0x60(%rbp), %rdi
callq 0x5830
addq $0xc0, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0xa0(%rbp), %rdi
jmp 0x5645
movq %rax, %rbx
leaq -0xe0(%rbp), %rdi
callq 0x5830
jmp 0x564f
movq %rax, %rbx
leaq -0x60(%rbp), %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/playlist.cpp
// Function: Playlist::removeSong(Playlist&)
size_t Playlist::removeSong(Playlist& toRemove) {
  // Tratamento para garantir que a nova playlist não está vazia
  if (toRemove.getSongs()->getSize() < 1) {
    return 0;
  } else {
    size_t removed = 0;

    node* temp = toRemove.getSongs()->getHead();

    while (temp != nullptr) {
      // Obtém a posição da música na playlist atual
      size_t pos = getSongs()->getPosition(temp->data);

      // Remove da playlist atual
      if (pos > 0) {
        removeSong(pos);
        ++removed;
      }

      temp = temp->next;
    }
    
    return removed;
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq 0x20(%rsi), %rdi
callq 0x1742
testq %rax, %rax
je 0x56db
movq 0x20(%r14), %rdi
callq 0x172e
movq %rax, %r15
xorl %r14d, %r14d
leaq -0x68(%rbp), %r12
testq %r15, %r15
je 0x56de
movq 0x20(%rbx), %r13
movq %r12, %rdi
movq %r15, %rsi
callq 0x20ac
movq %r13, %rdi
movq %r12, %rsi
callq 0x1d30
movq %rax, %r13
movq %r12, %rdi
callq 0x5830
testq %r13, %r13
je 0x56d5
movq %rbx, %rdi
movq %r13, %rsi
callq 0x5364
incq %r14
movq 0x40(%r15), %r15
jmp 0x5698
xorl %r14d, %r14d
movq %r14, %rax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq -0x68(%rbp), %rdi
callq 0x5830
movq %rbx, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/playlist.cpp
// Function: Playlist::displayAllSongs(node*)
void Playlist::displayAllSongs(node* current) {
  // Condição de parada
  if (current == nullptr) {
    count = 1;
    return;
  }
  // Imprime a música atual
  cout << count << " - " << current->data.getTitle() << " - " << current->data.getArtist() << endl;
  ++count;
  // Chamada recursiva
  displayAllSongs(current->next);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %rdi, %rbx
testq %rsi, %rsi
je 0x57cc
movq %rsi, %r14
movq 0x30(%rbx), %rsi
movq 0x488b(%rip), %rdi      # 0x9fd0
callq 0x10b0
leaq 0x8d4(%rip), %rsi       # 0x6025
movq %rax, %rdi
callq 0x1110
movq %rax, %r15
leaq -0x60(%rbp), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x5850
movq %r15, %rdi
movq %r12, %rsi
callq 0x10f0
leaq 0x8a8(%rip), %rsi       # 0x6025
movq %rax, %rdi
callq 0x1110
movq %rax, %r15
leaq -0x40(%rbp), %rdi
movq %r14, %rsi
callq 0x5868
leaq -0x40(%rbp), %rsi
movq %r15, %rdi
callq 0x10f0
movq %rax, %rdi
callq 0x1070
leaq -0x40(%rbp), %rdi
callq 0x1060
leaq -0x60(%rbp), %rdi
callq 0x1060
incq 0x30(%rbx)
movq 0x40(%r14), %rsi
movq %rbx, %rdi
callq 0x571c
jmp 0x57d4
movq $0x1, 0x30(%rbx)
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0x57f1
movq %rax, %rbx
leaq -0x40(%rbp), %rdi
callq 0x1060
jmp 0x57f4
movq %rax, %rbx
leaq -0x60(%rbp), %rdi
callq 0x1060
movq %rbx, %rdi
callq 0x1180
nopl (%rax)
// File: /workspace/github_cpp_makefile_star2_O2/lorenatoscano[P]musify/src/utils.cpp
// Function: toLowercase(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
string toLowercase(string s) {
  string result = "";

  for (size_t i = 0; i < s.size(); i++) {
    result += tolower(s[i]);
  }
  
  return result;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x775(%rip), %rsi       # 0x6028
leaq -0x19(%rbp), %rdx
callq 0x1040
xorl %r15d, %r15d
cmpq 0x8(%r14), %r15
jae 0x58e2
movq (%r14), %rax
movsbl (%rax,%r15), %edi
callq 0x1160
movsbl %al, %esi
movq %rbx, %rdi
callq 0x10d0
incq %r15
jmp 0x58bf
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x1060
movq %r14, %rdi
callq 0x1180
// File: /workspace/github_cpp_makefile_star2_O2/utkukaratas[P]xkeylayers/./config.hpp
// Function: key_add_key(TKey*, unsigned char)
TKey *key_add_key(TKey *keys, KeyCode key)
{
    TKey *rval = keys;

    if (keys == NULL)
    {
        keys = new TKey;
        rval = keys;
    }
    else
    {
        while (keys->next != NULL) keys = keys->next;
        keys = (keys->next = new TKey);
    }

    keys->key = key;
    keys->next = NULL;

    return rval;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %esi, %ebx
testq %rdi, %rdi
je 0x255c
movq %rdi, %r14
movq %rdi, %rax
movq %rax, %r15
movq 0x8(%rax), %rax
testq %rax, %rax
jne 0x2542
pushq $0x10
popq %rdi
callq 0x2160
movq %rax, 0x8(%r15)
jmp 0x2567
pushq $0x10
popq %rdi
callq 0x2160
movq %rax, %r14
movb %bl, (%rax)
andq $0x0, 0x8(%rax)
movq %r14, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O2/utkukaratas[P]xkeylayers/xkeylayers.cpp
// Function: debug(char const*, ...)
void debug(const char *fmt, ...) {
    if (app.debug) {
        va_list args;
        va_start(args, fmt);
        vfprintf(stdout, fmt, args);
        va_end(args);
    }
}

// Assembly:
subq $0xd8, %rsp
testb %al, %al
je 0x25b9
movaps %xmm0, 0x50(%rsp)
movaps %xmm1, 0x60(%rsp)
movaps %xmm2, 0x70(%rsp)
movaps %xmm3, 0x80(%rsp)
movaps %xmm4, 0x90(%rsp)
movaps %xmm5, 0xa0(%rsp)
movaps %xmm6, 0xb0(%rsp)
movaps %xmm7, 0xc0(%rsp)
movq %rsi, 0x28(%rsp)
movq %rdx, 0x30(%rsp)
movq %rcx, 0x38(%rsp)
movq %r8, 0x40(%rsp)
movq %r9, 0x48(%rsp)
cmpb $0x1, 0x3c77(%rip)      # 0x6250
jne 0x2615
movq %rdi, %r10
leaq 0x20(%rsp), %rax
movq %rsp, %rdx
movq %rax, 0x10(%rdx)
leaq 0xe0(%rsp), %rax
movq %rax, 0x8(%rdx)
movabsq $0x3000000008, %rax     # imm = 0x3000000008
movq %rax, (%rdx)
movq 0x39a6(%rip), %rax      # 0x5fb0
movq (%rax), %rdi
movq %r10, %rsi
callq 0x21d0
addq $0xd8, %rsp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/utkukaratas[P]xkeylayers/xkeylayers.cpp
// Function: TApplication::trigger_key(TModifierKey*)
void TApplication::trigger_key(TModifierKey* mod)
{
    for (auto keycode : mod->fake_keys)
    {
        ::debug("Generating %s!\n", XKeysymToString(sym_from_code(keycode)));

        XTestFakeKeyEvent(_ctrl_conn, keycode, True, 0);
        generated = key_add_key(generated, keycode);
    }
    for (auto keycode : mod->fake_keys)
    {
        XTestFakeKeyEvent(_ctrl_conn, keycode, False, 0);
        generated = key_add_key(generated, keycode);
    }
    XFlush(_ctrl_conn);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x10(%rsi), %r13
movq %rsi, (%rsp)
movq 0x18(%rsi), %r14
leaq 0x19f1(%rip), %r15      # 0x4030
pushq $0x1
popq %rbp
cmpq %r14, %r13
je 0x2694
movzbl (%r13), %r12d
movl %r12d, %edi
callq 0x2eca
movq %rax, %rdi
callq 0x22c0
movq %r15, %rdi
movq %rax, %rsi
xorl %eax, %eax
callq 0x2577
movq 0x8(%rbx), %rdi
movl %r12d, %esi
movl %ebp, %edx
xorl %ecx, %ecx
callq 0x21b0
movq 0xd8(%rbx), %rdi
movl %r12d, %esi
callq 0x2530
movq %rax, 0xd8(%rbx)
incq %r13
jmp 0x2642
movq (%rsp), %rax
movq 0x10(%rax), %r14
movq 0x18(%rax), %r15
cmpq %r15, %r14
je 0x26d2
movzbl (%r14), %ebp
movq 0x8(%rbx), %rdi
movl %ebp, %esi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0x21b0
movq 0xd8(%rbx), %rdi
movl %ebp, %esi
callq 0x2530
movq %rax, 0xd8(%rbx)
incq %r14
jmp 0x26a0
movq 0x8(%rbx), %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x2210
nop
// File: /workspace/github_cpp_makefile_star2_O2/utkukaratas[P]xkeylayers/xkeylayers.cpp
// Function: TApplication::connect_x11()
void TApplication::connect_x11() {
    int dummy;
    _data_conn = XOpenDisplay(NULL);
    _ctrl_conn = XOpenDisplay(NULL);

    if (!_data_conn || !_ctrl_conn)
    {
        cerr << "Unable to connect to X11 display. Is $DISPLAY set?\n";
        exit(EXIT_FAILURE);
    }
    if (!XQueryExtension(_ctrl_conn,
                "XTEST", &dummy, &dummy, &dummy))
    {
        cerr << "Xtst extension missing\n";
        exit(EXIT_FAILURE);
    }
    if (!XRecordQueryVersion(_ctrl_conn, &dummy, &dummy))
    {
        cerr << "Failed to obtain xrecord version\n";
        exit(EXIT_FAILURE);
    }
    if (!XkbQueryExtension(_ctrl_conn, &dummy, &dummy,
            &dummy, &dummy, &dummy))
    {
        cerr << "Failed to obtain xkb version\n";
        exit(EXIT_FAILURE);
    }
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
xorl %edi, %edi
callq 0x21e0
movq %rax, (%rbx)
xorl %edi, %edi
callq 0x21e0
movq %rax, 0x8(%rbx)
cmpq $0x0, (%rbx)
je 0x2769
testq %rax, %rax
je 0x2769
leaq 0x195b(%rip), %rsi      # 0x4074
leaq 0xc(%rsp), %rcx
movq %rax, %rdi
movq %rcx, %rdx
movq %rcx, %r8
callq 0x2070
testl %eax, %eax
je 0x2779
movq 0x8(%rbx), %rdi
leaq 0xc(%rsp), %rdx
movq %rdx, %rsi
callq 0x2290
testl %eax, %eax
je 0x2789
movq 0x8(%rbx), %rdi
leaq 0xc(%rsp), %rcx
movq %rcx, %rsi
movq %rcx, %rdx
movq %rcx, %r8
movq %rcx, %r9
callq 0x2130
testl %eax, %eax
je 0x2799
addq $0x10, %rsp
popq %rbx
retq
movq 0x3880(%rip), %rdi      # 0x5ff0
leaq 0x18c9(%rip), %rsi      # 0x4040
jmp 0x27a7
movq 0x3870(%rip), %rdi      # 0x5ff0
leaq 0x18f3(%rip), %rsi      # 0x407a
jmp 0x27a7
movq 0x3860(%rip), %rdi      # 0x5ff0
leaq 0x18fb(%rip), %rsi      # 0x4092
jmp 0x27a7
movq 0x3850(%rip), %rdi      # 0x5ff0
leaq 0x190d(%rip), %rsi      # 0x40b4
callq 0x2150
pushq $0x1
popq %rdi
callq 0x21a0
// File: /workspace/github_cpp_makefile_star2_O2/utkukaratas[P]xkeylayers/xkeylayers.cpp
// Function: TApplication::hook_x11()
void TApplication::hook_x11() {
    XRecordRange *rec_range = XRecordAllocRange();
    rec_range->device_events.first = KeyPress;
    rec_range->device_events.last = ButtonRelease;
    XRecordClientSpec client_spec = XRecordAllClients;

    _record_ctx = XRecordCreateContext(_ctrl_conn,
            0, &client_spec, 1, &rec_range, 1);

    if (_record_ctx == 0)
    {
        cerr << "Failed to create xrecord context\n";
        exit(EXIT_FAILURE);
    }

    XSync(_ctrl_conn, False);

    if (!XRecordEnableContext(_data_conn,
                _record_ctx, intercept, (XPointer)&app))
    {
        cerr << "Failed to enable xrecord context\n";
        exit(EXIT_FAILURE);
    }

    if (!XRecordFreeContext(_ctrl_conn, _record_ctx))
    {
        cerr << "Failed to free xrecord context\n";
    }
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
callq 0x2300
leaq 0x8(%rsp), %r8
movq %rax, (%r8)
movw $0x502, 0x12(%rax)      # imm = 0x502
movq %rsp, %rdx
movq $0x3, (%rdx)
movq 0x8(%rbx), %rdi
pushq $0x1
popq %rcx
xorl %esi, %esi
movl %ecx, %r9d
callq 0x2260
movq %rax, 0x10(%rbx)
testq %rax, %rax
je 0x2846
movq 0x8(%rbx), %rdi
xorl %esi, %esi
callq 0x22e0
movq (%rbx), %rdi
movq 0x10(%rbx), %rsi
leaq 0x65(%rip), %rdx        # 0x2871
leaq 0x399d(%rip), %rcx      # 0x61b0
callq 0x2230
testl %eax, %eax
je 0x2856
movq 0x8(%rbx), %rdi
movq 0x10(%rbx), %rsi
callq 0x20f0
testl %eax, %eax
jne 0x2840
movq 0x37bc(%rip), %rdi      # 0x5ff0
leaq 0x18db(%rip), %rsi      # 0x4116
callq 0x2150
addq $0x10, %rsp
popq %rbx
retq
movq 0x37a3(%rip), %rdi      # 0x5ff0
leaq 0x187e(%rip), %rsi      # 0x40d2
jmp 0x2864
movq 0x3793(%rip), %rdi      # 0x5ff0
leaq 0x1890(%rip), %rsi      # 0x40f4
callq 0x2150
pushq $0x1
popq %rdi
callq 0x21a0