[all-commits] [llvm/llvm-project] 844c8f: [CodeGen] Include MachineInstr.h
kazutakahirata via All-commits
all-commits at lists.llvm.org
Sun Dec 18 15:12:44 PST 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 844c8fc9c93fa22a05663b5d75b489c0ff9081cc
https://github.com/llvm/llvm-project/commit/844c8fc9c93fa22a05663b5d75b489c0ff9081cc
Author: Kazu Hirata <kazu at google.com>
Date: 2022-12-18 (Sun, 18 Dec 2022)
Changed paths:
M llvm/include/llvm/CodeGen/DbgEntityHistoryCalculator.h
Log Message:
-----------
[CodeGen] Include MachineInstr.h
This patch teaches DbgEntityHistoryCalculator.h to include
MachineInstr.h so that the header file is self contained.
Without this patch, a C++ source file that only includes
DbgEntityHistoryCalculator.h does not compile because:
PointerIntPair<const MachineInstr *, 1, EntryKind> Instr;
wants to know the alignment of llvm::MachineInstr:
llvm/include/llvm/Support/PointerLikeTypeTraits.h:61:28: error:
invalid application of 'alignof' to an incomplete type
'llvm::MachineInstr'
detail::ConstantLog2<alignof(T)>::value;
^~~~~~~~~~
More information about the All-commits
mailing list