MCInstrAnalysis.cpp 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. //===- MCInstrAnalysis.cpp - InstrDesc target hooks -----------------------===//
  2. //
  3. // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
  4. // See https://llvm.org/LICENSE.txt for license information.
  5. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  6. //
  7. //===----------------------------------------------------------------------===//
  8. #include "llvm/MC/MCInstrAnalysis.h"
  9. #include "llvm/ADT/APInt.h"
  10. #include <cstdint>
  11. namespace llvm {
  12. class MCSubtargetInfo;
  13. }
  14. using namespace llvm;
  15. bool MCInstrAnalysis::clearsSuperRegisters(const MCRegisterInfo &MRI,
  16. const MCInst &Inst,
  17. APInt &Writes) const {
  18. Writes.clearAllBits();
  19. return false;
  20. }
  21. bool MCInstrAnalysis::evaluateBranch(const MCInst & /*Inst*/, uint64_t /*Addr*/,
  22. uint64_t /*Size*/,
  23. uint64_t & /*Target*/) const {
  24. return false;
  25. }
  26. std::optional<uint64_t> MCInstrAnalysis::evaluateMemoryOperandAddress(
  27. const MCInst &Inst, const MCSubtargetInfo *STI, uint64_t Addr,
  28. uint64_t Size) const {
  29. return std::nullopt;
  30. }
  31. std::optional<uint64_t>
  32. MCInstrAnalysis::getMemoryOperandRelocationOffset(const MCInst &Inst,
  33. uint64_t Size) const {
  34. return std::nullopt;
  35. }