[all-commits] [llvm/llvm-project] 08ab4f: [BOLT][NFC] Const-ify analyzeJumpTable

Amir Ayupov via All-commits all-commits at lists.llvm.org
Mon Feb 27 15:22:57 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 08ab4faf1aa338802ce7f482622dc020a2a26e08
      https://github.com/llvm/llvm-project/commit/08ab4faf1aa338802ce7f482622dc020a2a26e08
  Author: Amir Ayupov <aaupov at fb.com>
  Date:   2023-02-27 (Mon, 27 Feb 2023)

  Changed paths:
    M bolt/include/bolt/Core/BinaryContext.h
    M bolt/include/bolt/Core/JumpTable.h
    M bolt/lib/Core/BinaryContext.cpp

  Log Message:
  -----------
  [BOLT][NFC] Const-ify analyzeJumpTable

Avoid modifying `BF`, instead set extra output parameter and modify BF in caller
scope.

Reviewed By: #bolt, rafauler

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


  Commit: 1c286acfb81813951b7cb0651db648226d327d9a
      https://github.com/llvm/llvm-project/commit/1c286acfb81813951b7cb0651db648226d327d9a
  Author: Amir Ayupov <aaupov at fb.com>
  Date:   2023-02-27 (Mon, 27 Feb 2023)

  Changed paths:
    M bolt/lib/Core/BinaryFunction.cpp
    A bolt/test/X86/split-func-jump-table-unknown.s

  Log Message:
  -----------
  [BOLT] Prevent unsetting unknown control flow for split jump table

In case of a function with unknown control flow but with a single jump
table and a single jump table site, we attempt to match the jump table
and a site and update block successors using jump table targets.
Restrict this behavior for split jump tables which have targets in a
fragment function.

Fixes https://github.com/llvm/llvm-project/issues/60795.

Reviewed By: #bolt, rafauler

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


Compare: https://github.com/llvm/llvm-project/compare/03e94f66087e...1c286acfb818


More information about the All-commits mailing list