Eugene Zelenko | d3a6c89 | 2017-02-11 00:27:28 +0000 | [diff] [blame] | 1 | //===- MCInstrAnalysis.cpp - InstrDesc target hooks -----------------------===// |
Benjamin Kramer | c22d50e | 2011-08-08 18:56:44 +0000 | [diff] [blame] | 2 | // |
Chandler Carruth | 2946cd7 | 2019-01-19 08:50:56 +0000 | [diff] [blame] | 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 |
Benjamin Kramer | c22d50e | 2011-08-08 18:56:44 +0000 | [diff] [blame] | 6 | // |
| 7 | //===----------------------------------------------------------------------===// |
| 8 | |
| 9 | #include "llvm/MC/MCInstrAnalysis.h" |
Reid Kleckner | 5565d36 | 2019-11-13 16:36:21 -0800 | [diff] [blame] | 10 | |
Andrea Di Biagio | 2145b13 | 2018-06-20 10:08:11 +0000 | [diff] [blame] | 11 | #include "llvm/ADT/APInt.h" |
Chandler Carruth | 6bda14b | 2017-06-06 11:49:48 +0000 | [diff] [blame] | 12 | #include "llvm/MC/MCInst.h" |
Eugene Zelenko | d3a6c89 | 2017-02-11 00:27:28 +0000 | [diff] [blame] | 13 | #include "llvm/MC/MCInstrDesc.h" |
| 14 | #include "llvm/MC/MCInstrInfo.h" |
| 15 | #include <cstdint> |
| 16 | |
Benjamin Kramer | c22d50e | 2011-08-08 18:56:44 +0000 | [diff] [blame] | 17 | using namespace llvm; |
| 18 | |
Andrea Di Biagio | 2145b13 | 2018-06-20 10:08:11 +0000 | [diff] [blame] | 19 | bool MCInstrAnalysis::clearsSuperRegisters(const MCRegisterInfo &MRI, |
| 20 | const MCInst &Inst, |
| 21 | APInt &Writes) const { |
| 22 | Writes.clearAllBits(); |
| 23 | return false; |
| 24 | } |
| 25 | |
Fangrui Song | 52eb2f6 | 2020-04-29 23:17:14 -0700 | [diff] [blame] | 26 | bool MCInstrAnalysis::evaluateBranch(const MCInst & /*Inst*/, uint64_t /*Addr*/, |
| 27 | uint64_t /*Size*/, |
| 28 | uint64_t & /*Target*/) const { |
| 29 | return false; |
Benjamin Kramer | c22d50e | 2011-08-08 18:56:44 +0000 | [diff] [blame] | 30 | } |
Seiya Nuta | 21277e3 | 2019-07-25 06:57:09 +0000 | [diff] [blame] | 31 | |
| 32 | Optional<uint64_t> |
| 33 | MCInstrAnalysis::evaluateMemoryOperandAddress(const MCInst &Inst, uint64_t Addr, |
| 34 | uint64_t Size) const { |
| 35 | return None; |
| 36 | } |