[all-commits] [llvm/llvm-project] a0b674: Fix UB in EmulateInstructionARM64.cpp

adrian-prantl via All-commits all-commits at lists.llvm.org
Mon Jun 1 18:14:25 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: a0b674fd7f06b86241cf19387313b508248a3868
      https://github.com/llvm/llvm-project/commit/a0b674fd7f06b86241cf19387313b508248a3868
  Author: Adrian Prantl <aprantl at apple.com>
  Date:   2020-06-01 (Mon, 01 Jun 2020)

  Changed paths:
    M lldb/source/Plugins/Instruction/ARM64/EmulateInstructionARM64.cpp
    M lldb/source/Plugins/Instruction/ARM64/EmulateInstructionARM64.h
    M lldb/unittests/CMakeLists.txt
    A lldb/unittests/Instruction/CMakeLists.txt
    A lldb/unittests/Instruction/TestAArch64Emulator.cpp

  Log Message:
  -----------
  Fix UB in EmulateInstructionARM64.cpp

This fixes an unhandled signed integer overflow in AddWithCarry() by
using the llvm::checkedAdd() function. Thats to Vedant Kumar for the
suggestion!

<rdar://problem/60926115>

Differential Revision: https://reviews.llvm.org/D80955




More information about the All-commits mailing list