Remove trailing whitespace
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21422 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Support/Annotation.cpp b/lib/Support/Annotation.cpp
index d35904e..b46e218 100644
--- a/lib/Support/Annotation.cpp
+++ b/lib/Support/Annotation.cpp
@@ -1,10 +1,10 @@
//===-- Annotation.cpp - Implement the Annotation Classes -----------------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
//
// This file implements the AnnotationManager class.
@@ -67,7 +67,7 @@
void *Data) {
AnnotationID Result(getID(Name));
registerAnnotationFactory(Result, Fact, Data);
- return Result;
+ return Result;
}
// getName - This function is especially slow, but that's okay because it should
@@ -82,7 +82,7 @@
}
// registerAnnotationFactory - This method is used to register a callback
-// function used to create an annotation on demand if it is needed by the
+// function used to create an annotation on demand if it is needed by the
// Annotable::findOrCreateAnnotation method.
//
void AnnotationManager::registerAnnotationFactory(AnnotationID ID, AnnFactory F,
@@ -96,7 +96,7 @@
// createAnnotation - Create an annotation of the specified ID for the
// specified object, using a register annotation creation function.
//
-Annotation *AnnotationManager::createAnnotation(AnnotationID ID,
+Annotation *AnnotationManager::createAnnotation(AnnotationID ID,
const Annotable *Obj) {
FactMapType::iterator I = getFactMap().find(ID.ID);
if (I == getFactMap().end()) return 0;
diff --git a/lib/Support/CommandLine.cpp b/lib/Support/CommandLine.cpp
index f73ec6d..73d26cf 100644
--- a/lib/Support/CommandLine.cpp
+++ b/lib/Support/CommandLine.cpp
@@ -1,10 +1,10 @@
//===-- CommandLine.cpp - Command line parser implementation --------------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
//
// This class implements a command line argument processor that is useful when
@@ -68,7 +68,7 @@
static void AddArgument(const char *ArgName, Option *Opt) {
if (getOption(ArgName)) {
- std::cerr << ProgramName << ": CommandLine Error: Argument '"
+ std::cerr << ProgramName << ": CommandLine Error: Argument '"
<< ArgName << "' defined more than once!\n";
} else {
// Add argument to the argument map!
@@ -78,7 +78,7 @@
// RemoveArgument - It's possible that the argument is no longer in the map if
// options have already been processed and the map has been deleted!
-//
+//
static void RemoveArgument(const char *ArgName, Option *Opt) {
if(getOpts().empty()) return;
@@ -107,15 +107,15 @@
break;
case ValueDisallowed:
if (*Value != 0)
- return Handler->error(" does not allow a value! '" +
+ return Handler->error(" does not allow a value! '" +
std::string(Value) + "' specified.");
break;
- case ValueOptional:
+ case ValueOptional:
break;
- default:
- std::cerr << ProgramName
- << ": Bad ValueMask flag! CommandLine usage error:"
- << Handler->getValueExpectedFlag() << "\n";
+ default:
+ std::cerr << ProgramName
+ << ": Bad ValueMask flag! CommandLine usage error:"
+ << Handler->getValueExpectedFlag() << "\n";
abort();
break;
}
@@ -124,7 +124,7 @@
return Handler->addOccurrence(i, ArgName, Value);
}
-static bool ProvidePositionalOption(Option *Handler, const std::string &Arg,
+static bool ProvidePositionalOption(Option *Handler, const std::string &Arg,
int i) {
int Dummy = i;
return ProvideOption(Handler, Handler->ArgStr, Arg.c_str(), 0, 0, Dummy);
@@ -147,7 +147,7 @@
//
static Option *getOptionPred(std::string Name, unsigned &Length,
bool (*Pred)(const Option*)) {
-
+
Option *Op = getOption(Name);
if (Op && Pred(Op)) {
Length = Name.length();
@@ -236,7 +236,7 @@
// Check args.
assert(progName && "Program name not specified");
assert(envVar && "Environment variable name missing");
-
+
// Get the environment variable they want us to parse options out of.
const char *envValue = getenv (envVar);
if (!envValue)
@@ -265,7 +265,7 @@
/// that as well.
static Option *LookupOption(const char *&Arg, const char *&Value) {
while (*Arg == '-') ++Arg; // Eat leading dashes
-
+
const char *ArgEnd = Arg;
while (*ArgEnd && *ArgEnd != '=')
++ArgEnd; // Scan till end of argument name...
@@ -273,7 +273,7 @@
Value = ArgEnd;
if (*Value) // If we have an equals sign...
++Value; // Advance to value...
-
+
if (*Arg == 0) return 0;
// Look up the option.
@@ -366,7 +366,7 @@
// All of the positional arguments have been fulfulled, give the rest to
// the consume after option... if it's specified...
//
- if (PositionalVals.size() >= NumPositionalRequired &&
+ if (PositionalVals.size() >= NumPositionalRequired &&
ConsumeAfterOpt != 0) {
for (++i; i < argc; ++i)
PositionalVals.push_back(std::make_pair(argv[i],i));
@@ -402,7 +402,7 @@
if (RealName.size() > 1) {
unsigned Length = 0;
Option *PGOpt = getOptionPred(RealName, Length, isPrefixedOrGrouping);
-
+
// If the option is a prefixed option, then the value is simply the
// rest of the name... so fall through to later processing, by
// setting up the argument name flags and value fields.
@@ -415,13 +415,13 @@
} else if (PGOpt) {
// This must be a grouped option... handle them now.
assert(isGrouping(PGOpt) && "Broken getOptionPred!");
-
+
do {
// Move current arg name out of RealName into RealArgName...
std::string RealArgName(RealName.begin(),
RealName.begin() + Length);
RealName.erase(RealName.begin(), RealName.begin() + Length);
-
+
// Because ValueRequired is an invalid flag for grouped arguments,
// we don't need to pass argc/argv in...
//
@@ -430,11 +430,11 @@
int Dummy;
ErrorParsing |= ProvideOption(PGOpt, RealArgName.c_str(),
"", 0, 0, Dummy);
-
+
// Get the next grouping option...
PGOpt = getOptionPred(RealName, Length, isGrouping);
} while (PGOpt && Length != RealName.size());
-
+
Handler = PGOpt; // Ate all of the options.
}
}
@@ -473,13 +473,13 @@
// active one...
if (Handler->getFormattingFlag() == cl::Positional)
ActivePositionalArg = Handler;
- else
+ else
ErrorParsing |= ProvideOption(Handler, ArgName, Value, argc, argv, i);
}
// Check and handle positional arguments now...
if (NumPositionalRequired > PositionalVals.size()) {
- std::cerr << ProgramName
+ std::cerr << ProgramName
<< ": Not enough positional command line arguments specified!\n"
<< "Must specify at least " << NumPositionalRequired
<< " positional arguments: See: " << argv[0] << " --help\n";
@@ -491,7 +491,7 @@
unsigned ValNo = 0, NumVals = PositionalVals.size();
for (unsigned i = 0, e = PositionalOpts.size(); i != e; ++i) {
if (RequiresValue(PositionalOpts[i])) {
- ProvidePositionalOption(PositionalOpts[i], PositionalVals[ValNo].first,
+ ProvidePositionalOption(PositionalOpts[i], PositionalVals[ValNo].first,
PositionalVals[ValNo].second);
ValNo++;
--NumPositionalRequired; // We fulfilled our duty...
@@ -542,7 +542,7 @@
PositionalVals[ValNo].second);
ValNo++;
}
-
+
// Handle over all of the rest of the arguments to the
// cl::ConsumeAfter command line option...
for (; ValNo != PositionalVals.size(); ++ValNo)
@@ -552,7 +552,7 @@
}
// Loop over args and make sure all required args are specified!
- for (std::map<std::string, Option*>::iterator I = Opts.begin(),
+ for (std::map<std::string, Option*>::iterator I = Opts.begin(),
E = Opts.end(); I != E; ++I) {
switch (I->second->getNumOccurrencesFlag()) {
case Required:
@@ -688,7 +688,7 @@
return Len + 6;
}
-// printOptionInfo - Print out information about this option. The
+// printOptionInfo - Print out information about this option. The
// to-be-maintained width is specified.
//
void basic_parser_impl::printOptionInfo(const Option &O,
@@ -709,7 +709,7 @@
//
bool parser<bool>::parse(Option &O, const char *ArgName,
const std::string &Arg, bool &Value) {
- if (Arg == "" || Arg == "true" || Arg == "TRUE" || Arg == "True" ||
+ if (Arg == "" || Arg == "true" || Arg == "TRUE" || Arg == "True" ||
Arg == "1") {
Value = true;
} else if (Arg == "false" || Arg == "FALSE" || Arg == "False" || Arg == "0") {
@@ -727,7 +727,7 @@
const std::string &Arg, int &Value) {
char *End;
Value = (int)strtol(Arg.c_str(), &End, 0);
- if (*End != 0)
+ if (*End != 0)
return O.error(": '" + Arg + "' value invalid for integer argument!");
return false;
}
@@ -753,7 +753,7 @@
const char *ArgStart = Arg.c_str();
char *End;
Value = strtod(ArgStart, &End);
- if (*End != 0)
+ if (*End != 0)
return O.error(": '" +Arg+ "' value invalid for floating point argument!");
return false;
}
@@ -808,7 +808,7 @@
}
}
-// printOptionInfo - Print out information about this option. The
+// printOptionInfo - Print out information about this option. The
// to-be-maintained width is specified.
//
void generic_parser_base::printOptionInfo(const Option &O,
@@ -825,7 +825,7 @@
}
} else {
if (O.HelpStr[0])
- std::cerr << " " << O.HelpStr << "\n";
+ std::cerr << " " << O.HelpStr << "\n";
for (unsigned i = 0, e = getNumOptions(); i != e; ++i) {
unsigned L = std::strlen(getOption(i));
std::cerr << " -" << getOption(i) << std::string(GlobalWidth-L-8, ' ')
@@ -867,7 +867,7 @@
copy(getOpts().begin(), getOpts().end(), std::back_inserter(Options));
// Eliminate Hidden or ReallyHidden arguments, depending on ShowHidden
- Options.erase(std::remove_if(Options.begin(), Options.end(),
+ Options.erase(std::remove_if(Options.begin(), Options.end(),
std::ptr_fun(ShowHidden ? isReallyHidden : isHidden)),
Options.end());
@@ -928,7 +928,7 @@
public:
void operator=(bool OptionWasSpecified) {
if (OptionWasSpecified) {
- std::cerr << "Low Level Virtual Machine (" << PACKAGE_NAME << ") "
+ std::cerr << "Low Level Virtual Machine (" << PACKAGE_NAME << ") "
<< PACKAGE_VERSION << " (see http://llvm.cs.uiuc.edu/)\n";
getOpts().clear(); // Don't bother making option dtors remove from map.
exit(1);
@@ -943,7 +943,7 @@
HelpPrinter NormalPrinter(false);
HelpPrinter HiddenPrinter(true);
-cl::opt<HelpPrinter, true, parser<bool> >
+cl::opt<HelpPrinter, true, parser<bool> >
HOp("help", cl::desc("display available options (--help-hidden for more)"),
cl::location(NormalPrinter), cl::ValueDisallowed);
@@ -954,7 +954,7 @@
// Define the --version option that prints out the LLVM version for the tool
VersionPrinter VersionPrinterInstance;
cl::opt<VersionPrinter, true, parser<bool> >
-VersOp("version", cl::desc("display the version"),
+VersOp("version", cl::desc("display the version"),
cl::location(VersionPrinterInstance), cl::ValueDisallowed);
@@ -962,10 +962,10 @@
// Utility function for printing the help message.
void cl::PrintHelpMessage() {
- // This looks weird, but it actually prints the help message. The
+ // This looks weird, but it actually prints the help message. The
// NormalPrinter variable is a HelpPrinter and the help gets printed when
// its operator= is invoked. That's because the "normal" usages of the
- // help printer is to be assigned true/false depending on whether the
+ // help printer is to be assigned true/false depending on whether the
// --help option was given or not. Since we're circumventing that we have
// to make it look like --help was given, so we assign true.
NormalPrinter = true;
diff --git a/lib/Support/Compressor.cpp b/lib/Support/Compressor.cpp
index 49088b8..7396d4a 100644
--- a/lib/Support/Compressor.cpp
+++ b/lib/Support/Compressor.cpp
@@ -1,10 +1,10 @@
//===- lib/Support/Compressor.cpp -------------------------------*- C++ -*-===//
-//
+//
// The LLVM Compiler Infrastructure
//
-// This file was developed by Reid Spencer and is distributed under the
+// This file was developed by Reid Spencer and is distributed under the
// University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
//
// This file implements the llvm::Compressor class, an abstraction for memory
@@ -26,7 +26,7 @@
COMP_TYPE_BZIP2 = '2',
};
-static int getdata(char*& buffer, size_t &size,
+static int getdata(char*& buffer, size_t &size,
llvm::Compressor::OutputDataCallback* cb, void* context) {
buffer = 0;
size = 0;
@@ -36,7 +36,7 @@
return result;
}
-static int getdata_uns(char*& buffer, unsigned &size,
+static int getdata_uns(char*& buffer, unsigned &size,
llvm::Compressor::OutputDataCallback* cb, void* context) {
size_t SizeOut;
int Res = getdata(buffer, SizeOut, cb, context);
@@ -45,7 +45,7 @@
}
//===----------------------------------------------------------------------===//
-//=== NULLCOMP - a compression like set of routines that just copies data
+//=== NULLCOMP - a compression like set of routines that just copies data
//=== without doing any compression. This is provided so that if the
//=== configured environment doesn't have a compression library the
//=== program can still work, albeit using more data/memory.
@@ -121,26 +121,26 @@
/// This structure is only used when a bytecode file is compressed.
/// As bytecode is being decompressed, the memory buffer might need
-/// to be reallocated. The buffer allocation is handled in a callback
+/// to be reallocated. The buffer allocation is handled in a callback
/// and this structure is needed to retain information across calls
/// to the callback.
/// @brief An internal buffer object used for handling decompression
struct BufferContext {
char* buff;
size_t size;
- BufferContext(size_t compressedSize) {
+ BufferContext(size_t compressedSize) {
// Null to indicate malloc of a new block
- buff = 0;
+ buff = 0;
// Compute the initial length of the uncompression buffer. Note that this
// is twice the length of the compressed buffer and will be doubled again
- // in the callback for an initial allocation of 4x compressedSize. This
- // calculation is based on the typical compression ratio of bzip2 on LLVM
- // bytecode files which typically ranges in the 50%-75% range. Since we
- // typically get at least 50%, doubling is insufficient. By using a 4x
+ // in the callback for an initial allocation of 4x compressedSize. This
+ // calculation is based on the typical compression ratio of bzip2 on LLVM
+ // bytecode files which typically ranges in the 50%-75% range. Since we
+ // typically get at least 50%, doubling is insufficient. By using a 4x
// multiplier on the first allocation, we minimize the impact of having to
// copy the buffer on reallocation.
- size = compressedSize*2;
+ size = compressedSize*2;
}
/// trimTo - Reduce the size of the buffer down to the specified amount. This
@@ -154,7 +154,7 @@
/// This function handles allocation of the buffer used for decompression of
/// compressed bytecode files. It is called by Compressor::decompress which is
- /// called by BytecodeReader::ParseBytecode.
+ /// called by BytecodeReader::ParseBytecode.
static size_t callback(char*&buff, size_t &sz, void* ctxt){
// Case the context variable to our BufferContext
BufferContext* bc = reinterpret_cast<BufferContext*>(ctxt);
@@ -168,9 +168,9 @@
// Figure out what to return to the Compressor. If this is the first call,
// then bc->buff will be null. In this case we want to return the entire
// buffer because there was no previous allocation. Otherwise, when the
- // buffer is reallocated, we save the new base pointer in the
- // BufferContext.buff field but return the address of only the extension,
- // mid-way through the buffer (since its size was doubled). Furthermore,
+ // buffer is reallocated, we save the new base pointer in the
+ // BufferContext.buff field but return the address of only the extension,
+ // mid-way through the buffer (since its size was doubled). Furthermore,
// the sz result must be 1/2 the total size of the buffer.
if (bc->buff == 0 ) {
buff = bc->buff = new_buff;
@@ -189,18 +189,18 @@
}
};
-} // end anonymous namespace
+} // end anonymous namespace
namespace {
// This structure retains the context when compressing the bytecode file. The
// WriteCompressedData function below uses it to keep track of the previously
-// filled chunk of memory (which it writes) and how many bytes have been
+// filled chunk of memory (which it writes) and how many bytes have been
// written.
struct WriterContext {
// Initialize the context
- WriterContext(std::ostream*OS, size_t CS)
+ WriterContext(std::ostream*OS, size_t CS)
: chunk(0), sz(0), written(0), compSize(CS), Out(OS) {}
// Make sure we clean up memory
@@ -219,10 +219,10 @@
sz = 0;
}
- // This function is a callback used by the Compressor::compress function to
+ // This function is a callback used by the Compressor::compress function to
// allocate memory for the compression buffer. This function fulfills that
// responsibility but also writes the previous (now filled) buffer out to the
- // stream.
+ // stream.
static size_t callback(char*& buffer, size_t &size, void* context) {
// Cast the context to the structure it must point to.
WriterContext* ctxt = reinterpret_cast<WriterContext*>(context);
@@ -259,7 +259,7 @@
} // end anonymous namespace
// Compress in one of three ways
-size_t Compressor::compress(const char* in, size_t size,
+size_t Compressor::compress(const char* in, size_t size,
OutputDataCallback* cb, void* context) {
assert(in && "Can't compress null buffer");
assert(size && "Can't compress empty buffer");
@@ -355,7 +355,7 @@
return result;
}
-size_t
+size_t
Compressor::compressToStream(const char*in, size_t size, std::ostream& out) {
// Set up the context and writer
WriterContext ctxt(&out, size / 2);
@@ -460,7 +460,7 @@
return result;
}
-size_t
+size_t
Compressor::decompressToNewBuffer(const char* in, size_t size, char*&out) {
BufferContext bc(size);
size_t result = decompress(in,size,BufferContext::callback,(void*)&bc);
@@ -468,7 +468,7 @@
return result;
}
-size_t
+size_t
Compressor::decompressToStream(const char*in, size_t size, std::ostream& out){
// Set up the context and writer
WriterContext ctxt(&out,size / 2);
diff --git a/lib/Support/Debug.cpp b/lib/Support/Debug.cpp
index a587167..394d9c1 100644
--- a/lib/Support/Debug.cpp
+++ b/lib/Support/Debug.cpp
@@ -1,10 +1,10 @@
//===-- Debug.cpp - An easy way to add debug output to your code ----------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
//
// This file implements a handle way of adding debugging information to your
diff --git a/lib/Support/FileUtilities.cpp b/lib/Support/FileUtilities.cpp
index 6a65cca..dd296f3 100644
--- a/lib/Support/FileUtilities.cpp
+++ b/lib/Support/FileUtilities.cpp
@@ -1,10 +1,10 @@
//===- Support/FileUtilities.cpp - File System Utilities ------------------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
//
// This file implements a family of utility functions which are useful for doing
@@ -24,7 +24,7 @@
static bool isNumberChar(char C) {
switch (C) {
case '0': case '1': case '2': case '3': case '4':
- case '5': case '6': case '7': case '8': case '9':
+ case '5': case '6': case '7': case '8': case '9':
case '.': case '+': case '-':
case 'e':
case 'E': return true;
@@ -47,7 +47,7 @@
double AbsTolerance, double RelTolerance,
std::string *ErrorMsg) {
char *F1NumEnd, *F2NumEnd;
- double V1 = 0.0, V2 = 0.0;
+ double V1 = 0.0, V2 = 0.0;
// If one of the positions is at a space and the other isn't, chomp up 'til
// the end of the space.
@@ -142,7 +142,7 @@
return 1;
// Now its safe to mmap the files into memory becasue both files
- // have a non-zero size.
+ // have a non-zero size.
sys::MappedFile F1(FileA);
sys::MappedFile F2(FileB);
F1.map();
@@ -171,7 +171,7 @@
// If the files need padding, do so now.
PadFileIfNeeded(File1Start, File1End, F1P);
PadFileIfNeeded(File2Start, File2End, F2P);
-
+
bool CompareFailed = false;
while (1) {
// Scan for the end of file or next difference.
diff --git a/lib/Support/IsInf.cpp b/lib/Support/IsInf.cpp
index e2943b0..070ed4f 100644
--- a/lib/Support/IsInf.cpp
+++ b/lib/Support/IsInf.cpp
@@ -1,10 +1,10 @@
//===-- IsInf.cpp - Platform-independent wrapper around C99 isinf() -------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
#include "llvm/Config/config.h"
@@ -26,7 +26,7 @@
#define isinf(X) (!_finite(X))
#elif defined(_AIX) && defined(__GNUC__)
// GCC's fixincludes seems to be removing the isinf() declaration from the
-// system header /usr/include/math.h
+// system header /usr/include/math.h
# include <math.h>
static int isinf(double x) { return !finite(x) && x==x; }
#else
diff --git a/lib/Support/IsNAN.cpp b/lib/Support/IsNAN.cpp
index f7bb4e3..3300b7b 100644
--- a/lib/Support/IsNAN.cpp
+++ b/lib/Support/IsNAN.cpp
@@ -1,13 +1,13 @@
//===-- IsNAN.cpp ---------------------------------------------------------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
//
-// Platform-independent wrapper around C99 isnan().
+// Platform-independent wrapper around C99 isnan().
//
//===----------------------------------------------------------------------===//
diff --git a/lib/Support/PluginLoader.cpp b/lib/Support/PluginLoader.cpp
index 39e3c0a..85b2a31 100644
--- a/lib/Support/PluginLoader.cpp
+++ b/lib/Support/PluginLoader.cpp
@@ -1,10 +1,10 @@
//===-- PluginLoader.cpp - Implement -load command line option ------------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
//
// This file implements the -load <plugin> command line option handler.
diff --git a/lib/Support/SlowOperationInformer.cpp b/lib/Support/SlowOperationInformer.cpp
index 43faaad..671add1 100644
--- a/lib/Support/SlowOperationInformer.cpp
+++ b/lib/Support/SlowOperationInformer.cpp
@@ -1,12 +1,12 @@
//===-- SlowOperationInformer.cpp - Keep the user informed ----------------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
-//
+//
// This file implements the SlowOperationInformer class for the LLVM debugger.
//
//===----------------------------------------------------------------------===//
diff --git a/lib/Support/Statistic.cpp b/lib/Support/Statistic.cpp
index f4d9c7b..f94f246 100644
--- a/lib/Support/Statistic.cpp
+++ b/lib/Support/Statistic.cpp
@@ -1,10 +1,10 @@
//===-- Statistic.cpp - Easy way to expose stats information --------------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
//
// This file implements the 'Statistic' class, which is designed to be an easy
@@ -78,9 +78,9 @@
// Figure out how long the biggest Value and Name fields are...
unsigned MaxNameLen = 0, MaxValLen = 0;
for (unsigned i = 0, e = AccumStats->size(); i != e; ++i) {
- MaxValLen = std::max(MaxValLen,
+ MaxValLen = std::max(MaxValLen,
(unsigned)(*AccumStats)[i].Value.length());
- MaxNameLen = std::max(MaxNameLen,
+ MaxNameLen = std::max(MaxNameLen,
(unsigned)std::strlen((*AccumStats)[i].Name));
}
diff --git a/lib/Support/StringExtras.cpp b/lib/Support/StringExtras.cpp
index e8d423a..c4016f3 100644
--- a/lib/Support/StringExtras.cpp
+++ b/lib/Support/StringExtras.cpp
@@ -1,10 +1,10 @@
//===-- StringExtras.cpp - Implement the StringExtras header --------------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
//
// This file implements the StringExtras.h header
@@ -35,9 +35,9 @@
// Create the return token.
std::string Result = std::string(Source.begin()+Start, Source.begin()+End);
-
+
// Erase the token that we read in.
Source.erase(Source.begin(), Source.begin()+End);
-
+
return Result;
}
diff --git a/lib/Support/SystemUtils.cpp b/lib/Support/SystemUtils.cpp
index 764f6be..c77f962 100644
--- a/lib/Support/SystemUtils.cpp
+++ b/lib/Support/SystemUtils.cpp
@@ -1,10 +1,10 @@
//===- SystemUtils.cpp - Utilities for low-level system tasks -------------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
//
// This file contains functions used to do a variety of low-level, often
@@ -42,14 +42,14 @@
#undef FindExecutable // needed on windows :(
sys::Path llvm::FindExecutable(const std::string &ExeName,
const std::string &ProgramPath) {
- // First check the directory that the calling program is in. We can do this
+ // First check the directory that the calling program is in. We can do this
// if ProgramPath contains at least one / character, indicating that it is a
// relative path to bugpoint itself.
sys::Path Result ( ProgramPath );
Result.elideFile();
if (!Result.isEmpty()) {
Result.appendFile(ExeName);
- if (Result.executable())
+ if (Result.executable())
return Result;
}
diff --git a/lib/Support/Timer.cpp b/lib/Support/Timer.cpp
index be58238..b0012ce 100644
--- a/lib/Support/Timer.cpp
+++ b/lib/Support/Timer.cpp
@@ -1,10 +1,10 @@
//===-- Timer.cpp - Interval Timing Support -------------------------------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
//
// Interval Timing implementation.
@@ -238,7 +238,7 @@
if (Total.getProcessTime())
printVal(getProcessTime(), Total.getProcessTime(), OS);
printVal(Elapsed, Total.Elapsed, OS);
-
+
OS << " ";
if (Total.MemUsed) {
@@ -294,10 +294,10 @@
{ // Scope to contain Total timer... don't allow total timer to drop us to
// zero timers...
Timer Total("TOTAL");
-
+
for (unsigned i = 0, e = TimersToPrint.size(); i != e; ++i)
Total.sum(TimersToPrint[i]);
-
+
// Print out timing header...
*OutStream << "===" << std::string(73, '-') << "===\n"
<< std::string(Padding, ' ') << Name << "\n"
@@ -329,11 +329,11 @@
if (Total.getPeakMem())
*OutStream << " -PeakMem-";
*OutStream << " --- Name ---\n";
-
+
// Loop through all of the timing data, printing it out...
for (unsigned i = 0, e = TimersToPrint.size(); i != e; ++i)
TimersToPrint[i].print(Total, *OutStream);
-
+
Total.print(Total, *OutStream);
*OutStream << std::endl; // Flush output
}
diff --git a/lib/Support/ToolRunner.cpp b/lib/Support/ToolRunner.cpp
index 2f6f2f4..9ef14c5 100644
--- a/lib/Support/ToolRunner.cpp
+++ b/lib/Support/ToolRunner.cpp
@@ -1,10 +1,10 @@
//===-- ToolRunner.cpp ----------------------------------------------------===//
-//
+//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
-//
+//
//===----------------------------------------------------------------------===//
//
// This file implements the interfaces described in the ToolRunner.h file.
@@ -36,8 +36,8 @@
redirects[0] = &StdInFile;
redirects[1] = &StdOutFile;
redirects[2] = &StdErrFile;
-
- return
+
+ return
sys::Program::ExecuteAndWait(ProgramPath, Args, 0, redirects, NumSeconds);
}
@@ -82,12 +82,12 @@
ToolArgs.clear ();
if (Args) { ToolArgs = *Args; }
}
-
+
virtual int ExecuteProgram(const std::string &Bytecode,
const std::vector<std::string> &Args,
const std::string &InputFile,
const std::string &OutputFile,
- const std::vector<std::string> &SharedLibs =
+ const std::vector<std::string> &SharedLibs =
std::vector<std::string>(),
unsigned Timeout = 0);
};
@@ -124,7 +124,7 @@
std::cerr << "\n";
);
return RunProgramWithTimeout(sys::Path(LLIPath), &LLIArgs[0],
- sys::Path(InputFile), sys::Path(OutputFile), sys::Path(OutputFile),
+ sys::Path(InputFile), sys::Path(OutputFile), sys::Path(OutputFile),
Timeout);
}
@@ -168,7 +168,7 @@
std::cerr << " " << LLCArgs[i];
std::cerr << "\n";
);
- if (RunProgramWithTimeout(sys::Path(LLCPath), &LLCArgs[0],
+ if (RunProgramWithTimeout(sys::Path(LLCPath), &LLCArgs[0],
sys::Path(), sys::Path(), sys::Path()))
ProcessFailure(sys::Path(LLCPath), &LLCArgs[0]);
}
@@ -228,12 +228,12 @@
ToolArgs.clear ();
if (Args) { ToolArgs = *Args; }
}
-
+
virtual int ExecuteProgram(const std::string &Bytecode,
const std::vector<std::string> &Args,
const std::string &InputFile,
const std::string &OutputFile,
- const std::vector<std::string> &SharedLibs =
+ const std::vector<std::string> &SharedLibs =
std::vector<std::string>(), unsigned Timeout =0);
};
}
@@ -271,7 +271,7 @@
);
DEBUG(std::cerr << "\nSending output to " << OutputFile << "\n");
return RunProgramWithTimeout(sys::Path(LLIPath), &JITArgs[0],
- sys::Path(InputFile), sys::Path(OutputFile), sys::Path(OutputFile),
+ sys::Path(InputFile), sys::Path(OutputFile), sys::Path(OutputFile),
Timeout);
}
@@ -313,7 +313,7 @@
std::cerr << " " << LLCArgs[i];
std::cerr << "\n";
);
- if (RunProgramWithTimeout(LLCPath, &LLCArgs[0], sys::Path(), sys::Path(),
+ if (RunProgramWithTimeout(LLCPath, &LLCArgs[0], sys::Path(), sys::Path(),
sys::Path()))
ProcessFailure(LLCPath, &LLCArgs[0]);
}
@@ -335,7 +335,7 @@
FileRemover CFileRemove(OutputCFile);
- return gcc->ExecuteProgram(OutputCFile.toString(), Args, GCC::CFile,
+ return gcc->ExecuteProgram(OutputCFile.toString(), Args, GCC::CFile,
InputFile, OutputFile, SharedLibs, Timeout);
}
@@ -346,7 +346,7 @@
const std::vector<std::string> *Args) {
sys::Path LLCPath = FindExecutable("llc", ProgramPath);
if (LLCPath.isEmpty()) {
- Message =
+ Message =
"Cannot find `llc' in executable directory or PATH!\n";
return 0;
}
@@ -377,7 +377,7 @@
// Specify the shared libraries to link in...
for (unsigned i = 0, e = SharedLibs.size(); i != e; ++i)
GCCArgs.push_back(SharedLibs[i].c_str());
-
+
// Specify -x explicitly in case the extension is wonky
GCCArgs.push_back("-x");
if (fileType == CFile) {
@@ -423,7 +423,7 @@
FileRemover OutputBinaryRemover(OutputBinary);
return RunProgramWithTimeout(OutputBinary, &ProgramArgs[0],
- sys::Path(InputFile), sys::Path(OutputFile), sys::Path(OutputFile),
+ sys::Path(InputFile), sys::Path(OutputFile), sys::Path(OutputFile),
Timeout);
}
@@ -458,9 +458,9 @@
"-O2", // Optimize the program a bit...
0
};
-
+
std::cout << "<gcc>" << std::flush;
- if (RunProgramWithTimeout(GCCPath, GCCArgs, sys::Path(), sys::Path(),
+ if (RunProgramWithTimeout(GCCPath, GCCArgs, sys::Path(), sys::Path(),
sys::Path())) {
ProcessFailure(GCCPath, GCCArgs);
return 1;
diff --git a/lib/Support/bzip2/bzlib.h b/lib/Support/bzip2/bzlib.h
index 9ac43a1..6a004f6 100644
--- a/lib/Support/bzip2/bzlib.h
+++ b/lib/Support/bzip2/bzlib.h
@@ -17,16 +17,16 @@
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
- 2. The origin of this software must not be misrepresented; you must
- not claim that you wrote the original software. If you use this
- software in a product, an acknowledgment in the product
+ 2. The origin of this software must not be misrepresented; you must
+ not claim that you wrote the original software. If you use this
+ software in a product, an acknowledgment in the product
documentation would be appreciated but is not required.
3. Altered source versions must be plainly marked as such, and must
not be misrepresented as being the original software.
- 4. The name of the author may not be used to endorse or promote
- products derived from this software without specific prior written
+ 4. The name of the author may not be used to endorse or promote
+ products derived from this software without specific prior written
permission.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS
@@ -85,7 +85,7 @@
#define BZ_OUTBUFF_FULL (-8)
#define BZ_CONFIG_ERROR (-9)
-typedef
+typedef
struct {
char *next_in;
unsigned int avail_in;
@@ -102,7 +102,7 @@
void *(*bzalloc)(void *,int,int);
void (*bzfree)(void *,void *);
void *opaque;
- }
+ }
bz_stream;
@@ -135,34 +135,34 @@
/*-- Core (low-level) library functions --*/
-BZ_EXTERN int BZ_API(BZ2_bzCompressInit) (
- bz_stream* strm,
- int blockSize100k,
- int verbosity,
- int workFactor
+BZ_EXTERN int BZ_API(BZ2_bzCompressInit) (
+ bz_stream* strm,
+ int blockSize100k,
+ int verbosity,
+ int workFactor
);
-BZ_EXTERN int BZ_API(BZ2_bzCompress) (
- bz_stream* strm,
- int action
+BZ_EXTERN int BZ_API(BZ2_bzCompress) (
+ bz_stream* strm,
+ int action
);
-BZ_EXTERN int BZ_API(BZ2_bzCompressEnd) (
- bz_stream* strm
+BZ_EXTERN int BZ_API(BZ2_bzCompressEnd) (
+ bz_stream* strm
);
-BZ_EXTERN int BZ_API(BZ2_bzDecompressInit) (
- bz_stream *strm,
- int verbosity,
+BZ_EXTERN int BZ_API(BZ2_bzDecompressInit) (
+ bz_stream *strm,
+ int verbosity,
int small
);
-BZ_EXTERN int BZ_API(BZ2_bzDecompress) (
- bz_stream* strm
+BZ_EXTERN int BZ_API(BZ2_bzDecompress) (
+ bz_stream* strm
);
-BZ_EXTERN int BZ_API(BZ2_bzDecompressEnd) (
- bz_stream *strm
+BZ_EXTERN int BZ_API(BZ2_bzDecompressEnd) (
+ bz_stream *strm
);
@@ -174,64 +174,64 @@
typedef void BZFILE;
-BZ_EXTERN BZFILE* BZ_API(BZ2_bzReadOpen) (
- int* bzerror,
- FILE* f,
- int verbosity,
+BZ_EXTERN BZFILE* BZ_API(BZ2_bzReadOpen) (
+ int* bzerror,
+ FILE* f,
+ int verbosity,
int small,
- void* unused,
- int nUnused
+ void* unused,
+ int nUnused
);
-BZ_EXTERN void BZ_API(BZ2_bzReadClose) (
- int* bzerror,
- BZFILE* b
+BZ_EXTERN void BZ_API(BZ2_bzReadClose) (
+ int* bzerror,
+ BZFILE* b
);
-BZ_EXTERN void BZ_API(BZ2_bzReadGetUnused) (
- int* bzerror,
- BZFILE* b,
- void** unused,
- int* nUnused
+BZ_EXTERN void BZ_API(BZ2_bzReadGetUnused) (
+ int* bzerror,
+ BZFILE* b,
+ void** unused,
+ int* nUnused
);
-BZ_EXTERN int BZ_API(BZ2_bzRead) (
- int* bzerror,
- BZFILE* b,
- void* buf,
- int len
+BZ_EXTERN int BZ_API(BZ2_bzRead) (
+ int* bzerror,
+ BZFILE* b,
+ void* buf,
+ int len
);
-BZ_EXTERN BZFILE* BZ_API(BZ2_bzWriteOpen) (
- int* bzerror,
- FILE* f,
- int blockSize100k,
- int verbosity,
- int workFactor
+BZ_EXTERN BZFILE* BZ_API(BZ2_bzWriteOpen) (
+ int* bzerror,
+ FILE* f,
+ int blockSize100k,
+ int verbosity,
+ int workFactor
);
-BZ_EXTERN void BZ_API(BZ2_bzWrite) (
- int* bzerror,
- BZFILE* b,
- void* buf,
- int len
+BZ_EXTERN void BZ_API(BZ2_bzWrite) (
+ int* bzerror,
+ BZFILE* b,
+ void* buf,
+ int len
);
-BZ_EXTERN void BZ_API(BZ2_bzWriteClose) (
- int* bzerror,
- BZFILE* b,
- int abandon,
- unsigned int* nbytes_in,
- unsigned int* nbytes_out
+BZ_EXTERN void BZ_API(BZ2_bzWriteClose) (
+ int* bzerror,
+ BZFILE* b,
+ int abandon,
+ unsigned int* nbytes_in,
+ unsigned int* nbytes_out
);
-BZ_EXTERN void BZ_API(BZ2_bzWriteClose64) (
- int* bzerror,
- BZFILE* b,
- int abandon,
- unsigned int* nbytes_in_lo32,
- unsigned int* nbytes_in_hi32,
- unsigned int* nbytes_out_lo32,
+BZ_EXTERN void BZ_API(BZ2_bzWriteClose64) (
+ int* bzerror,
+ BZFILE* b,
+ int abandon,
+ unsigned int* nbytes_in_lo32,
+ unsigned int* nbytes_in_hi32,
+ unsigned int* nbytes_out_lo32,
unsigned int* nbytes_out_hi32
);
#endif
@@ -239,23 +239,23 @@
/*-- Utility functions --*/
-BZ_EXTERN int BZ_API(BZ2_bzBuffToBuffCompress) (
- char* dest,
+BZ_EXTERN int BZ_API(BZ2_bzBuffToBuffCompress) (
+ char* dest,
unsigned int* destLen,
- char* source,
+ char* source,
unsigned int sourceLen,
- int blockSize100k,
- int verbosity,
- int workFactor
+ int blockSize100k,
+ int verbosity,
+ int workFactor
);
-BZ_EXTERN int BZ_API(BZ2_bzBuffToBuffDecompress) (
- char* dest,
+BZ_EXTERN int BZ_API(BZ2_bzBuffToBuffDecompress) (
+ char* dest,
unsigned int* destLen,
- char* source,
+ char* source,
unsigned int sourceLen,
- int small,
- int verbosity
+ int small,
+ int verbosity
);
@@ -283,17 +283,17 @@
int fd,
const char *mode
);
-
+
BZ_EXTERN int BZ_API(BZ2_bzread) (
- BZFILE* b,
- void* buf,
- int len
+ BZFILE* b,
+ void* buf,
+ int len
);
BZ_EXTERN int BZ_API(BZ2_bzwrite) (
- BZFILE* b,
- void* buf,
- int len
+ BZFILE* b,
+ void* buf,
+ int len
);
BZ_EXTERN int BZ_API(BZ2_bzflush) (
@@ -305,7 +305,7 @@
);
BZ_EXTERN const char * BZ_API(BZ2_bzerror) (
- BZFILE *b,
+ BZFILE *b,
int *errnum
);
#endif
diff --git a/lib/Support/bzip2/bzlib_private.h b/lib/Support/bzip2/bzlib_private.h
index ff973c3..5683341 100644
--- a/lib/Support/bzip2/bzlib_private.h
+++ b/lib/Support/bzip2/bzlib_private.h
@@ -17,16 +17,16 @@
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
- 2. The origin of this software must not be misrepresented; you must
- not claim that you wrote the original software. If you use this
- software in a product, an acknowledgment in the product
+ 2. The origin of this software must not be misrepresented; you must
+ not claim that you wrote the original software. If you use this
+ software in a product, an acknowledgment in the product
documentation would be appreciated but is not required.
3. Altered source versions must be plainly marked as such, and must
not be misrepresented as being the original software.
- 4. The name of the author may not be used to endorse or promote
- products derived from this software without specific prior written
+ 4. The name of the author may not be used to endorse or promote
+ products derived from this software without specific prior written
permission.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS
@@ -91,7 +91,7 @@
#ifndef __GNUC__
#define __inline__ /* */
-#endif
+#endif
#ifndef BZ_NO_STDIO
extern void BZ2_bz__AssertH__fail ( int errcode );
@@ -143,7 +143,7 @@
#define BZ_HDR_Z 0x5a /* 'Z' */
#define BZ_HDR_h 0x68 /* 'h' */
#define BZ_HDR_0 0x30 /* '0' */
-
+
/*-- Constants for the back end. --*/
#define BZ_MAX_ALPHA_SIZE 258
@@ -303,19 +303,19 @@
/*-- externs for compression. --*/
-extern void
+extern void
BZ2_blockSort ( EState* );
-extern void
+extern void
BZ2_compressBlock ( EState*, Bool );
-extern void
+extern void
BZ2_bsInitWrite ( EState* );
-extern void
+extern void
BZ2_hbAssignCodes ( Int32*, UChar*, Int32, Int32, Int32 );
-extern void
+extern void
BZ2_hbMakeCodeLengths ( UChar*, Int32*, Int32, Int32 );
@@ -459,7 +459,7 @@
Int32 save_N;
Int32 save_curr;
Int32 save_zt;
- Int32 save_zn;
+ Int32 save_zn;
Int32 save_zvec;
Int32 save_zj;
Int32 save_gSel;
@@ -509,13 +509,13 @@
/*-- externs for decompression. --*/
-extern Int32
+extern Int32
BZ2_indexIntoF ( Int32, Int32* );
-extern Int32
+extern Int32
BZ2_decompress ( DState* );
-extern void
+extern void
BZ2_hbCreateDecodeTables ( Int32*, Int32*, Int32*, UChar*,
Int32, Int32, Int32 );