2014-08-01 23:03:36 +00:00
|
|
|
//===- UseListOrder.cpp - Implement Use List Order ------------------------===//
|
2014-07-25 14:49:26 +00:00
|
|
|
//
|
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
//
|
|
|
|
// This file is distributed under the University of Illinois Open Source
|
|
|
|
// License. See LICENSE.TXT for details.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
//
|
2014-08-01 23:03:36 +00:00
|
|
|
// Implement structures and command-line options for preserving use-list order.
|
2014-07-25 14:49:26 +00:00
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
|
|
#include "llvm/IR/UseListOrder.h"
|
|
|
|
#include "llvm/Support/CommandLine.h"
|
|
|
|
|
|
|
|
using namespace llvm;
|
|
|
|
|
|
|
|
static cl::opt<bool> PreserveBitcodeUseListOrder(
|
|
|
|
"preserve-bc-use-list-order",
|
|
|
|
cl::desc("Experimental support to preserve bitcode use-list order."),
|
|
|
|
cl::init(false), cl::Hidden);
|
|
|
|
|
2014-07-25 15:41:49 +00:00
|
|
|
static cl::opt<bool> PreserveAssemblyUseListOrder(
|
|
|
|
"preserve-ll-use-list-order",
|
|
|
|
cl::desc("Experimental support to preserve assembly use-list order."),
|
|
|
|
cl::init(false), cl::Hidden);
|
|
|
|
|
2014-07-25 14:49:26 +00:00
|
|
|
bool llvm::shouldPreserveBitcodeUseListOrder() {
|
|
|
|
return PreserveBitcodeUseListOrder;
|
|
|
|
}
|
|
|
|
|
2014-07-25 15:41:49 +00:00
|
|
|
bool llvm::shouldPreserveAssemblyUseListOrder() {
|
|
|
|
return PreserveAssemblyUseListOrder;
|
|
|
|
}
|
2014-08-19 21:08:27 +00:00
|
|
|
|
|
|
|
void llvm::setPreserveBitcodeUseListOrder(bool ShouldPreserve) {
|
|
|
|
PreserveBitcodeUseListOrder = ShouldPreserve;
|
|
|
|
}
|
|
|
|
|
|
|
|
void llvm::setPreserveAssemblyUseListOrder(bool ShouldPreserve) {
|
|
|
|
PreserveAssemblyUseListOrder = ShouldPreserve;
|
|
|
|
}
|