[all-commits] [llvm/llvm-project] 4fe4d9: [IR] Handle `expected` tag in switch branch weight...

Justin Lebar via All-commits all-commits at lists.llvm.org
Wed May 27 14:25:02 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 4fe4d9844862451b38bb3bd7329ab1b29916e3be
      https://github.com/llvm/llvm-project/commit/4fe4d9844862451b38bb3bd7329ab1b29916e3be
  Author: Justin Lebar <justin.lebar at gmail.com>
  Date:   2026-05-27 (Wed, 27 May 2026)

  Changed paths:
    M llvm/lib/IR/Instructions.cpp
    M llvm/test/Transforms/SimpleLoopUnswitch/trivial-unswitch-profmd.ll

  Log Message:
  -----------
  [IR] Handle `expected` tag in switch branch weights. (#200025)

Switch branch weight metadata has an optional `expected` tag.
SwitchInstProfUpdateWrapper::getSuccessorWeight() did not handle this
tag; if it was present, it would return nullopt, effectively ignoring
the metadata.

This bug was found by a large run of Opus 4.7 looking for bugs in LLVM.



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