blob: c768671f2ec5e4f31d7f145686fcfae5e3628577 [file] [log] [blame]
Chris Lattner51cbcbf2002-11-20 20:47:41 +00001//===- ValueMapper.h - Interface shared by lib/Transforms/Utils -*- C++ -*-===//
Misha Brukmanfd939082005-04-21 23:48:37 +00002//
John Criswell856ba762003-10-21 15:17:13 +00003// The LLVM Compiler Infrastructure
4//
5// This file was developed by the LLVM research group and is distributed under
6// the University of Illinois Open Source License. See LICENSE.TXT for details.
Misha Brukmanfd939082005-04-21 23:48:37 +00007//
John Criswell856ba762003-10-21 15:17:13 +00008//===----------------------------------------------------------------------===//
Chris Lattner51cbcbf2002-11-20 20:47:41 +00009//
10// This file defines the MapValue interface which is used by various parts of
11// the Transforms/Utils library to implement cloning and linking facilities.
12//
13//===----------------------------------------------------------------------===//
14
Brian Gaeke6129af32004-05-19 09:08:12 +000015#ifndef VALUEMAPPER_H
16#define VALUEMAPPER_H
Chris Lattner51cbcbf2002-11-20 20:47:41 +000017
18#include <map>
Brian Gaeked0fde302003-11-11 22:41:34 +000019
20namespace llvm {
Chris Lattnerf7703df2004-01-09 06:12:26 +000021 class Value;
Brian Gaeke6129af32004-05-19 09:08:12 +000022 class Instruction;
23 typedef std::map<const Value *, Value *> ValueMapTy;
24
25 Value *MapValue(const Value *V, ValueMapTy &VM);
26 void RemapInstruction(Instruction *I, ValueMapTy &VM);
Brian Gaeked0fde302003-11-11 22:41:34 +000027} // End llvm namespace
28
Chris Lattner51cbcbf2002-11-20 20:47:41 +000029#endif