[all-commits] [llvm/llvm-project] e3a45a: [ARM][Thumb2InstrInfo] Fix default `0` opcode when...

David Tellenbach via All-commits all-commits at lists.llvm.org
Mon Oct 28 12:00:07 PDT 2019


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: e3a45a24d1077e2afc917024032715afa70fb2ac
      https://github.com/llvm/llvm-project/commit/e3a45a24d1077e2afc917024032715afa70fb2ac
  Author: David Tellenbach <david.tellenbach at arm.com>
  Date:   2019-10-28 (Mon, 28 Oct 2019)

  Changed paths:
    M llvm/lib/Target/ARM/Thumb2InstrInfo.cpp

  Log Message:
  -----------
  [ARM][Thumb2InstrInfo] Fix default `0` opcode when rewriting frame indices

The static functions `positiveOffsetOpcode`, `negativeOffsetOpcode` and
`immediateOffsetOpcode` (lib/Target/ARM/Thumb2InstrInfo.cpp) currently can
return `0` as default opcode which is meaningless in this situation.

This patch replaces this default value by llvm_unreachable.

Reviewers: t.p.northover, tellenbach

Reviewed By: tellenbach

Subscribers: tellenbach, kristof.beyls, hiraditya, llvm-commits

Tags: #llvm

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

Patch By: Lorenzo Casalino <lorenzo.casalino93 at gmail.com>




More information about the All-commits mailing list