[all-commits] [llvm/llvm-project] 698ae9: [RegisterScavenging] Fix assert in scavengeRegiste...

Craig Blackmore via All-commits all-commits at lists.llvm.org
Fri Dec 18 08:57:38 PST 2020


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 698ae90f306248aafbfb5c85cdd9bb81c387bb59
      https://github.com/llvm/llvm-project/commit/698ae90f306248aafbfb5c85cdd9bb81c387bb59
  Author: Craig Blackmore <craig.blackmore at embecosm.com>
  Date:   2020-12-18 (Fri, 18 Dec 2020)

  Changed paths:
    M llvm/lib/CodeGen/RegisterScavenging.cpp

  Log Message:
  -----------
  [RegisterScavenging] Fix assert in scavengeRegisterBackwards

According to the documentation, if a spill is required to make a
register available and AllowSpill is false, then NoRegister should be
returned, however, this scenario was actually triggering an assertion
failure.

This patch moves the assertion after the handling of AllowSpill.

Authored by: Lewis Revill

Reviewed By: arsenm

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




More information about the All-commits mailing list