[all-commits] [llvm/llvm-project] 137d8e: [X86] Fix eliminateFrameIndex dropping existing in...

Alexey Bataev via All-commits all-commits at lists.llvm.org
Mon Sep 7 06:58:36 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 137d8e684984df207576c8f24bd8743ddb71c5c9
      https://github.com/llvm/llvm-project/commit/137d8e684984df207576c8f24bd8743ddb71c5c9
  Author: Alexey Bataev <a.bataev at outlook.com>
  Date:   2026-09-07 (Mon, 07 Sep 2026)

  Changed paths:
    M llvm/lib/Target/X86/X86RegisterInfo.cpp
    M llvm/test/CodeGen/X86/avx512f-large-stack.ll
    A llvm/test/CodeGen/X86/huge-frame-index.ll

  Log Message:
  -----------
  [X86] Fix eliminateFrameIndex dropping existing index register for huge frame offsets

When the frame offset does not fit in disp32 and the address mode already
uses an index register, the register-scavenging path overwrote the index
operand with the scratch register, silently dropping the index from the
effective address (and applying the stale scale to the frame offset).
Fold the offset into the base register with an LEA in this case instead.

Fixes #213960

Assisted-by: Cursor

Reviewers: RKSimon, qcolombet

Pull Request: https://github.com/llvm/llvm-project/pull/221016



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list