diff options
author | Misha Brukman <brukman+llvm@gmail.com> | 2005-04-21 20:48:15 +0000 |
---|---|---|
committer | Misha Brukman <brukman+llvm@gmail.com> | 2005-04-21 20:48:15 +0000 |
commit | 63b3afa98460ce38a1c48d3c44ef6edfdaf37b77 (patch) | |
tree | c0f475480b9d884ebcd5fce42a6dac1a4ad1831e /include/llvm/Support | |
parent | 14f342978cbd07436388eb7046bca96ada24cb63 (diff) | |
download | external_llvm-63b3afa98460ce38a1c48d3c44ef6edfdaf37b77.tar.gz external_llvm-63b3afa98460ce38a1c48d3c44ef6edfdaf37b77.tar.bz2 external_llvm-63b3afa98460ce38a1c48d3c44ef6edfdaf37b77.zip |
Remove trailing whitespace
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21411 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Support')
32 files changed, 216 insertions, 216 deletions
diff --git a/include/llvm/Support/AIXDataTypesFix.h b/include/llvm/Support/AIXDataTypesFix.h index 3a7e7f0d4b..256e45fec4 100644 --- a/include/llvm/Support/AIXDataTypesFix.h +++ b/include/llvm/Support/AIXDataTypesFix.h @@ -1,10 +1,10 @@ //===-- llvm/Support/AIXDataTypesFix.h - Fix datatype defs ------*- C++ -*-===// -// +// // 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 overrides default system-defined types and limits which cannot be diff --git a/include/llvm/Support/Annotation.h b/include/llvm/Support/Annotation.h index 2331ca5a23..1b0d048fb6 100644 --- a/include/llvm/Support/Annotation.h +++ b/include/llvm/Support/Annotation.h @@ -1,10 +1,10 @@ //===-- llvm/Support/Annotation.h - Annotation classes ----------*- C++ -*-===// -// +// // 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 the declarations for two classes: Annotation & Annotable. @@ -81,7 +81,7 @@ public: //===----------------------------------------------------------------------===// // // Annotable - This class is used as a base class for all objects that would -// like to have annotation capability. One notable subclass is Value, which +// like to have annotation capability. One notable subclass is Value, which // means annotations can be attached to almost everything in LLVM. // // Annotable objects keep their annotation list sorted as annotations are @@ -157,13 +157,13 @@ public: // one-to-one mapping between string Annotation names and Annotation ID numbers. // // Compared to the rest of the Annotation system, these mapping methods are -// relatively slow, so they should be avoided by locally caching Annotation +// relatively slow, so they should be avoided by locally caching Annotation // ID #'s. These methods are safe to call at any time, even by static ctors, so // they should be used by static ctors most of the time. // // This class also provides support for annotations that are created on demand // by the Annotable::getOrCreateAnnotation method. To get this to work, simply -// register an annotation handler +// register an annotation handler // struct AnnotationManager { typedef Annotation *(*Factory)(AnnotationID, const Annotable *, void*); @@ -183,7 +183,7 @@ struct AnnotationManager { // Annotation creation on demand support... // 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::getOrCreateAnnotation method. // static void registerAnnotationFactory(AnnotationID ID, Factory Func, diff --git a/include/llvm/Support/CFG.h b/include/llvm/Support/CFG.h index 231531a7ae..4efefa7253 100644 --- a/include/llvm/Support/CFG.h +++ b/include/llvm/Support/CFG.h @@ -1,10 +1,10 @@ //===-- llvm/Support/CFG.h - Process LLVM structures as graphs --*- C++ -*-===// -// +// // 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 defines specializations of GraphTraits that allow Function and @@ -34,40 +34,40 @@ class PredIterator : public forward_iterator<_Ptr, ptrdiff_t> { public: typedef PredIterator<_Ptr,_USE_iterator> _Self; typedef typename super::pointer pointer; - + inline void advancePastNonTerminators() { // Loop to ignore non terminator uses (for example PHI nodes)... while (It != BB->use_end() && !isa<TerminatorInst>(*It)) ++It; } - + inline PredIterator(_Ptr *bb) : BB(bb), It(bb->use_begin()) { advancePastNonTerminators(); } inline PredIterator(_Ptr *bb, bool) : BB(bb), It(bb->use_end()) {} - + inline bool operator==(const _Self& x) const { return It == x.It; } inline bool operator!=(const _Self& x) const { return !operator==(x); } - - inline pointer operator*() const { + + inline pointer operator*() const { assert(It != BB->use_end() && "pred_iterator out of range!"); - return cast<TerminatorInst>(*It)->getParent(); + return cast<TerminatorInst>(*It)->getParent(); } inline pointer *operator->() const { return &(operator*()); } - + inline _Self& operator++() { // Preincrement assert(It != BB->use_end() && "pred_iterator out of range!"); ++It; advancePastNonTerminators(); - return *this; + return *this; } - + inline _Self operator++(int) { // Postincrement - _Self tmp = *this; ++*this; return tmp; + _Self tmp = *this; ++*this; return tmp; } }; typedef PredIterator<BasicBlock, Value::use_iterator> pred_iterator; -typedef PredIterator<const BasicBlock, +typedef PredIterator<const BasicBlock, Value::use_const_iterator> pred_const_iterator; inline pred_iterator pred_begin(BasicBlock *BB) { return pred_iterator(BB); } @@ -94,7 +94,7 @@ public: typedef SuccIterator<Term_, BB_> _Self; typedef typename super::pointer pointer; // TODO: This can be random access iterator, need operator+ and stuff tho - + inline SuccIterator(Term_ T) : Term(T), idx(0) { // begin iterator assert(T && "getTerminator returned null!"); } @@ -112,18 +112,18 @@ public: /// getSuccessorIndex - This is used to interface between code that wants to /// operate on terminator instructions directly. unsigned getSuccessorIndex() const { return idx; } - + inline bool operator==(const _Self& x) const { return idx == x.idx; } inline bool operator!=(const _Self& x) const { return !operator==(x); } - + inline pointer operator*() const { return Term->getSuccessor(idx); } inline pointer operator->() const { return operator*(); } - + inline _Self& operator++() { ++idx; return *this; } // Preincrement inline _Self operator++(int) { // Postincrement - _Self tmp = *this; ++*this; return tmp; + _Self tmp = *this; ++*this; return tmp; } - + inline _Self& operator--() { --idx; return *this; } // Predecrement inline _Self operator--(int) { // Postdecrement _Self tmp = *this; --*this; return tmp; @@ -153,7 +153,7 @@ inline succ_const_iterator succ_end(const BasicBlock *BB) { // GraphTraits specializations for basic block graphs (CFGs) //===--------------------------------------------------------------------===// -// Provide specializations of GraphTraits to be able to treat a function as a +// Provide specializations of GraphTraits to be able to treat a function as a // graph of basic blocks... template <> struct GraphTraits<BasicBlock*> { @@ -161,10 +161,10 @@ template <> struct GraphTraits<BasicBlock*> { typedef succ_iterator ChildIteratorType; static NodeType *getEntryNode(BasicBlock *BB) { return BB; } - static inline ChildIteratorType child_begin(NodeType *N) { + static inline ChildIteratorType child_begin(NodeType *N) { return succ_begin(N); } - static inline ChildIteratorType child_end(NodeType *N) { + static inline ChildIteratorType child_end(NodeType *N) { return succ_end(N); } }; @@ -175,15 +175,15 @@ template <> struct GraphTraits<const BasicBlock*> { static NodeType *getEntryNode(const BasicBlock *BB) { return BB; } - static inline ChildIteratorType child_begin(NodeType *N) { + static inline ChildIteratorType child_begin(NodeType *N) { return succ_begin(N); } - static inline ChildIteratorType child_end(NodeType *N) { + static inline ChildIteratorType child_end(NodeType *N) { return succ_end(N); } }; -// Provide specializations of GraphTraits to be able to treat a function as a +// Provide specializations of GraphTraits to be able to treat a function as a // graph of basic blocks... and to walk it in inverse order. Inverse order for // a function is considered to be when traversing the predecessor edges of a BB // instead of the successor edges. @@ -192,10 +192,10 @@ template <> struct GraphTraits<Inverse<BasicBlock*> > { typedef BasicBlock NodeType; typedef pred_iterator ChildIteratorType; static NodeType *getEntryNode(Inverse<BasicBlock *> G) { return G.Graph; } - static inline ChildIteratorType child_begin(NodeType *N) { + static inline ChildIteratorType child_begin(NodeType *N) { return pred_begin(N); } - static inline ChildIteratorType child_end(NodeType *N) { + static inline ChildIteratorType child_end(NodeType *N) { return pred_end(N); } }; @@ -204,12 +204,12 @@ template <> struct GraphTraits<Inverse<const BasicBlock*> > { typedef const BasicBlock NodeType; typedef pred_const_iterator ChildIteratorType; static NodeType *getEntryNode(Inverse<const BasicBlock*> G) { - return G.Graph; + return G.Graph; } - static inline ChildIteratorType child_begin(NodeType *N) { + static inline ChildIteratorType child_begin(NodeType *N) { return pred_begin(N); } - static inline ChildIteratorType child_end(NodeType *N) { + static inline ChildIteratorType child_end(NodeType *N) { return pred_end(N); } }; @@ -220,7 +220,7 @@ template <> struct GraphTraits<Inverse<const BasicBlock*> > { // GraphTraits specializations for function basic block graphs (CFGs) //===--------------------------------------------------------------------===// -// Provide specializations of GraphTraits to be able to treat a function as a +// Provide specializations of GraphTraits to be able to treat a function as a // graph of basic blocks... these are the same as the basic block iterators, // except that the root node is implicitly the first node of the function. // @@ -243,7 +243,7 @@ template <> struct GraphTraits<const Function*> : }; -// Provide specializations of GraphTraits to be able to treat a function as a +// Provide specializations of GraphTraits to be able to treat a function as a // graph of basic blocks... and to walk it in inverse order. Inverse order for // a function is considered to be when traversing the predecessor edges of a BB // instead of the successor edges. diff --git a/include/llvm/Support/CallSite.h b/include/llvm/Support/CallSite.h index 1efc34e56a..9df71a2743 100644 --- a/include/llvm/Support/CallSite.h +++ b/include/llvm/Support/CallSite.h @@ -1,10 +1,10 @@ //===-- llvm/Support/CallSite.h - Abstract Call & Invoke instrs -*- C++ -*-===// -// +// // 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 defines the CallSite class, which is a handy wrapper for code that diff --git a/include/llvm/Support/Casting.h b/include/llvm/Support/Casting.h index d189754865..5132b4ec28 100644 --- a/include/llvm/Support/Casting.h +++ b/include/llvm/Support/Casting.h @@ -1,10 +1,10 @@ //===-- llvm/Support/Casting.h - Allow flexible, checked, casts -*- C++ -*-===// -// +// // 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 defines the isa<X>(), cast<X>(), dyn_cast<X>(), cast_or_null<X>(), @@ -48,7 +48,7 @@ template<typename From> struct simplify_type<const From> { // if (isa<Type*>(myVal)) { ... } // template <typename To, typename From> -inline bool isa_impl(const From &Val) { +inline bool isa_impl(const From &Val) { return To::classof(&Val); } @@ -57,7 +57,7 @@ struct isa_impl_wrap { // When From != SimplifiedType, we can simplify the type some more by using // the simplify_type template. static bool doit(const From &Val) { - return isa_impl_cl<const SimpleType>::template + return isa_impl_cl<const SimpleType>::template isa<To>(simplify_type<const From>::getSimplifiedValue(Val)); } }; @@ -159,7 +159,7 @@ struct cast_retty_wrap<To, FromTy, FromTy> { template<class To, class From> struct cast_retty { - typedef typename cast_retty_wrap<To, From, + typedef typename cast_retty_wrap<To, From, typename simplify_type<From>::SimpleType>::ret_type ret_type; }; @@ -248,7 +248,7 @@ struct foo { }*/ }; -template <> inline bool isa_impl<foo,bar>(const bar &Val) { +template <> inline bool isa_impl<foo,bar>(const bar &Val) { cerr << "Classof: " << &Val << "\n"; return true; } @@ -279,7 +279,7 @@ void test(bar &B1, const bar *B2) { const foo *F12 = cast_or_null<foo>(B2); const foo *F13 = cast_or_null<foo>(B4); const foo *F14 = cast_or_null<foo>(fub()); // Shouldn't print. - + // These lines are errors... //foo *F20 = cast<foo>(B2); // Yields const foo* //foo &F21 = cast<foo>(B3); // Yields const foo& diff --git a/include/llvm/Support/CommandLine.h b/include/llvm/Support/CommandLine.h index 90f38bce2d..e0c5c8f8c0 100644 --- a/include/llvm/Support/CommandLine.h +++ b/include/llvm/Support/CommandLine.h @@ -1,10 +1,10 @@ //===- llvm/Support/CommandLine.h - Command line handler --------*- C++ -*-===// -// +// // 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 @@ -126,14 +126,14 @@ class Option { // an argument. Should return true if there was an error processing the // argument and the program should exit. // - virtual bool handleOccurrence(unsigned pos, const char *ArgName, + virtual bool handleOccurrence(unsigned pos, const char *ArgName, const std::string &Arg) = 0; - virtual enum NumOccurrences getNumOccurrencesFlagDefault() const { + virtual enum NumOccurrences getNumOccurrencesFlagDefault() const { return Optional; } virtual enum ValueExpected getValueExpectedFlagDefault() const { - return ValueOptional; + return ValueOptional; } virtual enum OptionHidden getOptionHiddenFlagDefault() const { return NotHidden; @@ -216,14 +216,14 @@ public: // Return the width of the option tag for printing... virtual unsigned getOptionWidth() const = 0; - // printOptionInfo - Print out information about this option. The + // printOptionInfo - Print out information about this option. The // to-be-maintained width is specified. // virtual void printOptionInfo(unsigned GlobalWidth) const = 0; // addOccurrence - Wrapper around handleOccurrence that enforces Flags // - bool addOccurrence(unsigned pos, const char *ArgName, + bool addOccurrence(unsigned pos, const char *ArgName, const std::string &Value); // Prints option name followed by message. Always returns true. @@ -311,7 +311,7 @@ class ValuesClass { std::vector<std::pair<const char *, std::pair<int, const char *> > > Values; void processValues(va_list Vals); public: - ValuesClass(const char *EnumName, DataType Val, const char *Desc, + ValuesClass(const char *EnumName, DataType Val, const char *Desc, va_list ValueArgs) { // Insert the first value, which is required. Values.push_back(std::make_pair(EnumName, std::make_pair(Val, Desc))); @@ -366,14 +366,14 @@ struct generic_parser_base { // getOption - Return option name N. virtual const char *getOption(unsigned N) const = 0; - + // getDescription - Return description N virtual const char *getDescription(unsigned N) const = 0; // Return the width of the option tag for printing... virtual unsigned getOptionWidth(const Option &O) const; - // printOptionInfo - Print out information about this option. The + // printOptionInfo - Print out information about this option. The // to-be-maintained width is specified. // virtual void printOptionInfo(const Option &O, unsigned GlobalWidth) const; @@ -442,7 +442,7 @@ public: } // parse - Return true on error. - bool parse(Option &O, const char *ArgName, const std::string &Arg, + bool parse(Option &O, const char *ArgName, const std::string &Arg, DataType &V) { std::string ArgVal; if (hasArgStr) @@ -485,12 +485,12 @@ struct basic_parser_impl { // non-template implementation of basic_parser<t> enum ValueExpected getValueExpectedFlagDefault() const { return ValueRequired; } - + void initialize(Option &O) {} - + // Return the width of the option tag for printing... unsigned getOptionWidth(const Option &O) const; - + // printOptionInfo - Print out information about this option. The // to-be-maintained width is specified. // @@ -519,7 +519,7 @@ public: bool parse(Option &O, const char *ArgName, const std::string &Arg, bool &Val); enum ValueExpected getValueExpectedFlagDefault() const { - return ValueOptional; + return ValueOptional; } // getValueName - Do not print =<value> at all @@ -590,7 +590,7 @@ template<> class parser<std::string> : public basic_parser<std::string> { public: // parse - Return true on error. - bool parse(Option &O, const char *AN, const std::string &Arg, + bool parse(Option &O, const char *AN, const std::string &Arg, std::string &Value) { Value = Arg; return false; @@ -727,12 +727,12 @@ public: // template <class DataType, bool ExternalStorage = false, class ParserClass = parser<DataType> > -class opt : public Option, +class opt : public Option, public opt_storage<DataType, ExternalStorage, is_class<DataType>::value> { ParserClass Parser; - virtual bool handleOccurrence(unsigned pos, const char *ArgName, + virtual bool handleOccurrence(unsigned pos, const char *ArgName, const std::string &Arg) { typename ParserClass::parser_data_type Val; if (Parser.parse(*this, ArgName, Arg, Val)) @@ -884,14 +884,14 @@ class list : public Option, public list_storage<DataType, Storage> { std::vector<unsigned> Positions; ParserClass Parser; - virtual enum NumOccurrences getNumOccurrencesFlagDefault() const { + virtual enum NumOccurrences getNumOccurrencesFlagDefault() const { return ZeroOrMore; } virtual enum ValueExpected getValueExpectedFlagDefault() const { return Parser.getValueExpectedFlagDefault(); } - virtual bool handleOccurrence(unsigned pos, const char *ArgName, + virtual bool handleOccurrence(unsigned pos, const char *ArgName, const std::string &Arg) { typename ParserClass::parser_data_type Val; if (Parser.parse(*this, ArgName, Arg, Val)) @@ -915,9 +915,9 @@ class list : public Option, public list_storage<DataType, Storage> { public: ParserClass &getParser() { return Parser; } - unsigned getPosition(unsigned optnum) const { + unsigned getPosition(unsigned optnum) const { assert(optnum < this->size() && "Invalid option index"); - return Positions[optnum]; + return Positions[optnum]; } // One option... @@ -987,7 +987,7 @@ public: class alias : public Option { Option *AliasFor; - virtual bool handleOccurrence(unsigned pos, const char *ArgName, + virtual bool handleOccurrence(unsigned pos, const char *ArgName, const std::string &Arg) { return AliasFor->handleOccurrence(pos, AliasFor->ArgStr, Arg); } diff --git a/include/llvm/Support/Compressor.h b/include/llvm/Support/Compressor.h index 4545628dc0..596e62905c 100644 --- a/include/llvm/Support/Compressor.h +++ b/include/llvm/Support/Compressor.h @@ -1,10 +1,10 @@ //===- llvm/Support/Compressor.h --------------------------------*- 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 declares the llvm::Compressor class. @@ -23,15 +23,15 @@ namespace llvm { /// a block of memory. The algorithm used here is currently bzip2 but that /// may change without notice. Should newer algorithms prove to compress /// bytecode better than bzip2, that newer algorithm will be added, but won't - /// replace bzip2. This interface allows us to abstract the notion of - /// compression and deal with alternate compression schemes over time. - /// The type of compression used can be determined by inspecting the - /// first byte of the compressed output. Currently value '0' means no + /// replace bzip2. This interface allows us to abstract the notion of + /// compression and deal with alternate compression schemes over time. + /// The type of compression used can be determined by inspecting the + /// first byte of the compressed output. Currently value '0' means no /// compression was used (for very small files) and value '2' means bzip2 - /// compression was used. The Compressor is intended for use with memory + /// compression was used. The Compressor is intended for use with memory /// mapped files where the entire data block to be compressed or decompressed /// is available in memory. However, output can be gathered in repeated calls - /// to a callback. Utilities for sending compressed or decompressed output + /// to a callback. Utilities for sending compressed or decompressed output /// to a stream or directly to a memory block are also provided. /// @since 1.4 /// @brief An abstraction for memory to memory data (de)compression @@ -39,8 +39,8 @@ namespace llvm { /// @name High Level Interface /// @{ public: - /// This method compresses a block of memory pointed to by \p in with - /// size \p size to a block of memory, \p out, that is allocated with + /// This method compresses a block of memory pointed to by \p in with + /// size \p size to a block of memory, \p out, that is allocated with /// malloc. It is the caller's responsibility to free \p out. The \p hint /// indicates which type of compression the caller would *prefer*. /// @throws std::string explaining error if a compression error occurs @@ -52,10 +52,10 @@ namespace llvm { char*&out ///< The returned output buffer ); - /// This method compresses a block of memory pointed to by \p in with + /// This method compresses a block of memory pointed to by \p in with /// size \p size to a stream. The stream \p out must be open and ready for /// writing when this method is called. The stream will not be closed by - /// this method. The \p hint argument indicates which type of + /// this method. The \p hint argument indicates which type of /// compression the caller would *prefer*. /// @returns The amount of data written to \p out. /// @brief Compress memory to a file. @@ -65,9 +65,9 @@ namespace llvm { std::ostream& out ///< The output stream to write data on ); - /// This method decompresses a block of memory pointed to by \p in with + /// This method decompresses a block of memory pointed to by \p in with /// size \p size to a new block of memory, \p out, \p that was allocated - /// by malloc. It is the caller's responsibility to free \p out. + /// by malloc. It is the caller's responsibility to free \p out. /// @returns The size of the output buffer \p out. /// @brief Decompress memory to a new memory buffer. static size_t decompressToNewBuffer( @@ -76,10 +76,10 @@ namespace llvm { char*&out ///< The returned output buffer ); - /// This method decompresses a block of memory pointed to by \p in with + /// This method decompresses a block of memory pointed to by \p in with /// size \p size to a stream. The stream \p out must be open and ready for /// writing when this method is called. The stream will not be closed by - /// this method. + /// this method. /// @returns The amount of data written to \p out. /// @brief Decompress memory to a stream. static size_t decompressToStream( @@ -93,10 +93,10 @@ namespace llvm { /// @{ public: /// A callback function type used by the Compressor's low level interface - /// to get the next chunk of data to which (de)compressed output will be - /// written. This callback completely abstracts the notion of how to + /// to get the next chunk of data to which (de)compressed output will be + /// written. This callback completely abstracts the notion of how to /// handle the output data of compression or decompression. The callback - /// is responsible for determining both the storage location and the size + /// is responsible for determining both the storage location and the size /// of the output. The callback may also do other things with the data /// such as write it, transmit it, etc. Note that providing very small /// values for \p size will make the compression run very inefficiently. @@ -138,7 +138,7 @@ namespace llvm { /// Note that the callback function will be called as many times as /// necessary to complete the compression of the \p in block but that the /// total size will generally be greater than \p size. It is a good idea - /// to provide as large a value to the callback's \p size parameter as + /// to provide as large a value to the callback's \p size parameter as /// possible so that fewer calls to the callback are made. /// @throws std::string if an error occurs /// @returns the total size of the decompressed data diff --git a/include/llvm/Support/ConstantRange.h b/include/llvm/Support/ConstantRange.h index 0c8b3b6b4c..41073b7b95 100644 --- a/include/llvm/Support/ConstantRange.h +++ b/include/llvm/Support/ConstantRange.h @@ -1,10 +1,10 @@ //===-- llvm/Support/ConstantRange.h - Represent a range --------*- C++ -*-===// -// +// // 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. -// +// //===----------------------------------------------------------------------===// // // Represent a range of possible values that may occur when the program is run @@ -39,7 +39,7 @@ class ConstantRange { /// Initialize a full (the default) or empty set for the specified type. /// ConstantRange(const Type *Ty, bool isFullSet = true); - + /// Initialize a range to hold the single specified value. /// ConstantRange(Constant *Value); @@ -49,7 +49,7 @@ class ConstantRange { /// have different types, or if the constant are not integral values. /// ConstantRange(Constant *Lower, Constant *Upper); - + /// Initialize a set of values that all satisfy the condition with C. /// ConstantRange(unsigned SetCCOpcode, ConstantIntegral *C); @@ -65,12 +65,12 @@ class ConstantRange { /// getType - Return the LLVM data type of this range. /// const Type *getType() const; - + /// isFullSet - Return true if this set contains all of the elements possible /// for this data-type /// bool isFullSet() const; - + /// isEmptySet - Return true if this set contains no members. /// bool isEmptySet() const; @@ -83,12 +83,12 @@ class ConstantRange { /// contains - Return true if the specified value is in the set. /// bool contains(ConstantInt *Val) const; - + /// getSingleElement - If this set contains a single element, return it, /// otherwise return null. /// ConstantIntegral *getSingleElement() const; - + /// isSingleElement - Return true if this set contains exactly one member. /// bool isSingleElement() const { return getSingleElement() != 0; } diff --git a/include/llvm/Support/DOTGraphTraits.h b/include/llvm/Support/DOTGraphTraits.h index d734efffe1..02a508790c 100644 --- a/include/llvm/Support/DOTGraphTraits.h +++ b/include/llvm/Support/DOTGraphTraits.h @@ -1,10 +1,10 @@ //===-- llvm/Support/DotGraphTraits.h - Customize .dot output ---*- C++ -*-===// -// +// // 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 defines a template class that can be used to customize dot output diff --git a/include/llvm/Support/Debug.h b/include/llvm/Support/Debug.h index 263547c980..dc2c288873 100644 --- a/include/llvm/Support/Debug.h +++ b/include/llvm/Support/Debug.h @@ -1,10 +1,10 @@ //===- llvm/Support/Debug.h - Easy way to add debug output ------*- C++ -*-===// -// +// // 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/include/llvm/Support/DynamicLinker.h b/include/llvm/Support/DynamicLinker.h index 4f0bb58cab..e996b0f573 100644 --- a/include/llvm/Support/DynamicLinker.h +++ b/include/llvm/Support/DynamicLinker.h @@ -1,10 +1,10 @@ //===-- llvm/Support/DynamicLinker.h - Portable Dynamic Linker --*- C++ -*-===// -// +// // 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. -// +// //===----------------------------------------------------------------------===// // // Lightweight interface to dynamic library linking and loading, and dynamic @@ -31,7 +31,7 @@ bool LinkDynamicObject (const char *filename, std::string *ErrorMessage); /// the currently running process, as reported by the dynamic linker, /// or NULL if the symbol does not exist or some other error has /// occurred. -/// +/// void *GetAddressOfSymbol (const char *symbolName); void *GetAddressOfSymbol (const std::string &symbolName); diff --git a/include/llvm/Support/ELF.h b/include/llvm/Support/ELF.h index 8d9f693cf6..cd811f288e 100644 --- a/include/llvm/Support/ELF.h +++ b/include/llvm/Support/ELF.h @@ -1,15 +1,15 @@ //===-- llvm/Support/ELF.h - ELF constants and data structures --*- C++ -*-===// -// +// // 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 header contains common, non-processor-specific data structures and // constants for the ELF file format. -// +// // The details of the ELF32 bits in this file are largely based on // the Tool Interface Standard (TIS) Executable and Linking Format // (ELF) Specification Version 1.2, May 1995. The ELF64 stuff is not @@ -137,7 +137,7 @@ struct Elf32_Shdr { Elf32_Addr sh_addr; // Address where section is to be loaded Elf32_Off sh_offset; // File offset of section data, in bytes Elf32_Word sh_size; // Size of section, in bytes - Elf32_Word sh_link; // Section type-specific header table index link + Elf32_Word sh_link; // Section type-specific header table index link Elf32_Word sh_info; // Section type-specific extra information Elf32_Word sh_addralign; // Section address alignment Elf32_Word sh_entsize; // Size of records contained within the section @@ -204,7 +204,7 @@ struct Elf32_Sym { unsigned char st_info; // Symbol's type and binding attributes unsigned char st_other; // Must be zero; reserved Elf32_Half st_shndx; // Which section (header table index) it's defined in - + // These accessors and mutators correspond to the ELF32_ST_BIND, // ELF32_ST_TYPE, and ELF32_ST_INFO macros defined in the ELF specification: unsigned char getBinding () const { return st_info >> 4; } @@ -238,9 +238,9 @@ enum { // Relocation entry, without explicit addend. struct Elf32_Rel { - Elf32_Addr r_offset; // Location (file byte offset, or program virtual addr) + Elf32_Addr r_offset; // Location (file byte offset, or program virtual addr) Elf32_Word r_info; // Symbol table index and type of relocation to apply - + // These accessors and mutators correspond to the ELF32_R_SYM, ELF32_R_TYPE, // and ELF32_R_INFO macros defined in the ELF specification: Elf32_Word getSymbol () const { return (r_info >> 8); } @@ -254,10 +254,10 @@ struct Elf32_Rel { // Relocation entry with explicit addend. struct Elf32_Rela { - Elf32_Addr r_offset; // Location (file byte offset, or program virtual addr) + Elf32_Addr r_offset; // Location (file byte offset, or program virtual addr) Elf32_Word r_info; // Symbol table index and type of relocation to apply Elf32_Sword r_addend; // Compute value for relocatable field by adding this - + // These accessors and mutators correspond to the ELF32_R_SYM, ELF32_R_TYPE, // and ELF32_R_INFO macros defined in the ELF specification: Elf32_Word getSymbol () const { return (r_info >> 8); } diff --git a/include/llvm/Support/FileUtilities.h b/include/llvm/Support/FileUtilities.h index f563d1ac44..6712c32576 100644 --- a/include/llvm/Support/FileUtilities.h +++ b/include/llvm/Support/FileUtilities.h @@ -1,10 +1,10 @@ //===- llvm/Support/FileUtilities.h - File System Utilities -----*- C++ -*-===// -// +// // 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 defines a family of utility functions which are useful for doing @@ -41,7 +41,7 @@ namespace llvm { public: FileRemover(const sys::Path &filename, bool deleteIt = true) : Filename(filename), DeleteIt(deleteIt) {} - + ~FileRemover() { if (DeleteIt) try { diff --git a/include/llvm/Support/GetElementPtrTypeIterator.h b/include/llvm/Support/GetElementPtrTypeIterator.h index 8f6c224a26..846332ecee 100644 --- a/include/llvm/Support/GetElementPtrTypeIterator.h +++ b/include/llvm/Support/GetElementPtrTypeIterator.h @@ -1,10 +1,10 @@ //===- llvm/Support/GetElementPtrTypeIterator.h -----------------*- C++ -*-===// -// +// // 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 an iterator for walking through the types indexed by @@ -42,14 +42,14 @@ namespace llvm { return I; } - bool operator==(const generic_gep_type_iterator& x) const { + bool operator==(const generic_gep_type_iterator& x) const { return OpIt == x.OpIt; } bool operator!=(const generic_gep_type_iterator& x) const { return !operator==(x); } - const Type *operator*() const { + const Type *operator*() const { return CurTy; } @@ -61,7 +61,7 @@ namespace llvm { // This is a non-standard operator->. It allows you to call methods on the // current type directly. const Type *operator->() const { return operator*(); } - + Value *getOperand() const { return *OpIt; } generic_gep_type_iterator& operator++() { // Preincrement @@ -71,11 +71,11 @@ namespace llvm { CurTy = 0; } ++OpIt; - return *this; + return *this; } generic_gep_type_iterator operator++(int) { // Postincrement - generic_gep_type_iterator tmp = *this; ++*this; return tmp; + generic_gep_type_iterator tmp = *this; ++*this; return tmp; } }; diff --git a/include/llvm/Support/GraphWriter.h b/include/llvm/Support/GraphWriter.h index ffbf066c46..e898733a58 100644 --- a/include/llvm/Support/GraphWriter.h +++ b/include/llvm/Support/GraphWriter.h @@ -1,10 +1,10 @@ //===-- llvm/Support/GraphWriter.h - Write graph to a .dot file -*- C++ -*-===// -// +// // 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 defines a simple interface that can be used to print out generic @@ -99,33 +99,33 @@ public: I != E; ++I) writeNode(&*I); } - + void writeNode(NodeType *const *Node) { writeNode(*Node); } - + void writeNode(NodeType *Node) { std::string NodeAttributes = DOTTraits::getNodeAttributes(Node); - + O << "\tNode" << reinterpret_cast<const void*>(Node) << " [shape=record,"; if (!NodeAttributes.empty()) O << NodeAttributes << ","; O << "label=\"{"; if (!DOTTraits::renderGraphFromBottomUp()) O << DOT::EscapeString(DOTTraits::getNodeLabel(Node, G)); - + // Print out the fields of the current node... child_iterator EI = GTraits::child_begin(Node); child_iterator EE = GTraits::child_end(Node); if (EI != EE) { if (!DOTTraits::renderGraphFromBottomUp()) O << "|"; O << "{"; - + for (unsigned i = 0; EI != EE && i != 64; ++EI, ++i) { if (i) O << "|"; O << "<g" << i << ">" << DOTTraits::getEdgeSourceLabel(Node, EI); } - + if (EI != EE) O << "|<g64>truncated..."; O << "}"; @@ -133,9 +133,9 @@ public: } if (DOTTraits::renderGraphFromBottomUp()) O << DOT::EscapeString(DOTTraits::getNodeLabel(Node, G)); - + O << "}\"];\n"; // Finish printing the "node" line - + // Output all of the edges now EI = GTraits::child_begin(Node); for (unsigned i = 0; EI != EE && i != 64; ++EI, ++i) @@ -174,7 +174,7 @@ public: O << DOT::EscapeString(Label); if (NumEdgeSources) { O << "|{"; - + for (unsigned i = 0; i != NumEdgeSources; ++i) { if (i) O << "|"; O << "<g" << i << ">"; @@ -197,7 +197,7 @@ public: O << ":g" << SrcNodePort; O << " -> Node" << reinterpret_cast<const void*>(DestNodeID); if (DestNodePort >= 0) - O << ":g" << DestNodePort; + O << ":g" << DestNodePort; if (!Attrs.empty()) O << "[" << Attrs << "]"; diff --git a/include/llvm/Support/InstIterator.h b/include/llvm/Support/InstIterator.h index cdb78e9042..6f3a45e32c 100644 --- a/include/llvm/Support/InstIterator.h +++ b/include/llvm/Support/InstIterator.h @@ -1,10 +1,10 @@ //===- llvm/Support/InstIterator.h - Classes for inst iteration -*- C++ -*-===// -// +// // 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 definitions of two iterators for iterating over the @@ -54,8 +54,8 @@ public: template<typename A, typename B, typename C, typename D> InstIterator(InstIterator<A,B,C,D> &II) : BBs(II.BBs), BB(II.BB), BI(II.BI) {} - - template<class M> InstIterator(M &m) + + template<class M> InstIterator(M &m) : BBs(&m.getBasicBlockList()), BB(BBs->begin()) { // begin ctor if (BB != BBs->end()) { BI = BB->begin(); @@ -63,43 +63,43 @@ public: } } - template<class M> InstIterator(M &m, bool) + template<class M> InstIterator(M &m, bool) : BBs(&m.getBasicBlockList()), BB(BBs->end()) { // end ctor } // Accessors to get at the underlying iterators... inline BBIty &getBasicBlockIterator() { return BB; } inline BIty &getInstructionIterator() { return BI; } - + inline reference operator*() const { return *BI; } inline pointer operator->() const { return &operator*(); } - - inline bool operator==(const InstIterator &y) const { + + inline bool operator==(const InstIterator &y) const { return BB == y.BB && (BB == BBs->end() || BI == y.BI); } - inline bool operator!=(const InstIterator& y) const { + inline bool operator!=(const InstIterator& y) const { return !operator==(y); } - InstIterator& operator++() { + InstIterator& operator++() { ++BI; advanceToNextBB(); - return *this; + return *this; } - inline InstIterator operator++(int) { - InstIterator tmp = *this; ++*this; return tmp; + inline InstIterator operator++(int) { + InstIterator tmp = *this; ++*this; return tmp; } - - InstIterator& operator--() { + + InstIterator& operator--() { while (BB == BBs->end() || BI == BB->begin()) { --BB; BI = BB->end(); } --BI; - return *this; + return *this; } - inline InstIterator operator--(int) { - InstIterator tmp = *this; --*this; return tmp; + inline InstIterator operator--(int) { + InstIterator tmp = *this; --*this; return tmp; } inline bool atEnd() const { return BB == BBs->end(); } @@ -121,7 +121,7 @@ typedef InstIterator<iplist<BasicBlock>, Function::iterator, BasicBlock::iterator, Instruction> inst_iterator; typedef InstIterator<const iplist<BasicBlock>, - Function::const_iterator, + Function::const_iterator, BasicBlock::const_iterator, const Instruction> const_inst_iterator; diff --git a/include/llvm/Support/InstVisitor.h b/include/llvm/Support/InstVisitor.h index 49b5ee109c..38cd74ab87 100644 --- a/include/llvm/Support/InstVisitor.h +++ b/include/llvm/Support/InstVisitor.h @@ -1,10 +1,10 @@ //===- llvm/Support/InstVisitor.h - Define instruction visitors -*- C++ -*-===// -// +// // 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 template class is used to define instruction visitors in a typesafe diff --git a/include/llvm/Support/LeakDetector.h b/include/llvm/Support/LeakDetector.h index 6ca5405bc4..92784ee4c8 100644 --- a/include/llvm/Support/LeakDetector.h +++ b/include/llvm/Support/LeakDetector.h @@ -1,10 +1,10 @@ //===-- llvm/Support/LeakDetector.h - Provide leak detection ----*- C++ -*-===// -// +// // 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 defines a class that can be used to provide very simple memory leak @@ -48,7 +48,7 @@ struct LeakDetector { removeGarbageObjectImpl(Object); #endif } - + /// checkForGarbage - Traverse the internal representation of garbage /// pointers. If there are any pointers that have been add'ed, but not /// remove'd, big obnoxious warnings about memory leaks are issued. diff --git a/include/llvm/Support/Mangler.h b/include/llvm/Support/Mangler.h index 14d68b59d3..c5edd3d2a6 100644 --- a/include/llvm/Support/Mangler.h +++ b/include/llvm/Support/Mangler.h @@ -1,10 +1,10 @@ //===-- llvm/Support/Mangler.h - Self-contained name mangler ----*- C++ -*-===// -// +// // 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. -// +// //===----------------------------------------------------------------------===// // // Unified name mangler for various backends. @@ -63,7 +63,7 @@ public: /// doesn't guarantee unique names for values. getValueName already /// does this for you, so there's no point calling it on the result /// from getValueName. - /// + /// static std::string makeNameProper(const std::string &x); }; diff --git a/include/llvm/Support/MathExtras.h b/include/llvm/Support/MathExtras.h index bfc175f2c1..1f5f86bf0a 100644 --- a/include/llvm/Support/MathExtras.h +++ b/include/llvm/Support/MathExtras.h @@ -1,10 +1,10 @@ //===-- llvm/Support/MathExtras.h - Useful math functions -------*- C++ -*-===// -// +// // 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 some functions that are useful for math stuff. diff --git a/include/llvm/Support/PassNameParser.h b/include/llvm/Support/PassNameParser.h index 71ebe41a45..6b7a88c5b6 100644 --- a/include/llvm/Support/PassNameParser.h +++ b/include/llvm/Support/PassNameParser.h @@ -1,10 +1,10 @@ //===- llvm/Support/PassNameParser.h ----------------------------*- C++ -*-===// -// +// // 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 the PassNameParser and FilteredPassNameParser<> classes, which are @@ -34,12 +34,12 @@ namespace llvm { // PassNameParser class - Make use of the pass registration mechanism to // automatically add a command line argument to opt for each pass. // -class PassNameParser : public PassRegistrationListener, +class PassNameParser : public PassRegistrationListener, public cl::parser<const PassInfo*> { cl::Option *Opt; public: PassNameParser() : Opt(0) {} - + void initialize(cl::Option &O) { Opt = &O; cl::parser<const PassInfo*>::initialize(O); diff --git a/include/llvm/Support/PatternMatch.h b/include/llvm/Support/PatternMatch.h index ae1d30cc08..0be4cd97b5 100644 --- a/include/llvm/Support/PatternMatch.h +++ b/include/llvm/Support/PatternMatch.h @@ -1,10 +1,10 @@ //===-- llvm/Support/PatternMatch.h - Match on the LLVM IR ------*- C++ -*-===// -// +// // 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 provides a simple and efficient mechanism for performing general @@ -33,7 +33,7 @@ #include "llvm/Instructions.h" namespace llvm { -namespace PatternMatch { +namespace PatternMatch { template<typename Val, typename Pattern> bool match(Val *V, const Pattern &P) { @@ -88,7 +88,7 @@ struct BinaryOp_match { R.match(CE->getOperand(1)); return false; } -}; +}; template<typename LHS, typename RHS> inline BinaryOp_match<LHS, RHS, Instruction::Add> m_Add(const LHS &L, @@ -178,7 +178,7 @@ struct BinaryOpClass_match { #endif return false; } -}; +}; template<typename LHS, typename RHS> inline BinaryOpClass_match<LHS, RHS, SetCondInst> @@ -216,7 +216,7 @@ private: else return LHS == ConstantFP::get(LHS->getType(), -0.0) && L.match(RHS); } -}; +}; template<typename LHS> inline neg_match<LHS> m_Neg(const LHS &L) { return L; } diff --git a/include/llvm/Support/PluginLoader.h b/include/llvm/Support/PluginLoader.h index 48f8a7d8dc..74e5a0394d 100644 --- a/include/llvm/Support/PluginLoader.h +++ b/include/llvm/Support/PluginLoader.h @@ -1,10 +1,10 @@ //===-- llvm/Support/PluginLoader.h - Plugin Loader for Tools ---*- C++ -*-===// -// +// // 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. -// +// //===----------------------------------------------------------------------===// // // A tool can #include this file to get a -load option that allows the user to diff --git a/include/llvm/Support/SlowOperationInformer.h b/include/llvm/Support/SlowOperationInformer.h index 896fd3fb06..0486406138 100644 --- a/include/llvm/Support/SlowOperationInformer.h +++ b/include/llvm/Support/SlowOperationInformer.h @@ -1,10 +1,10 @@ //===- llvm/Support/SlowOperationInformer.h - Keep user informed *- C++ -*-===// -// +// // 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 defines a simple object which can be used to let the user know what @@ -38,13 +38,13 @@ namespace llvm { class SlowOperationInformer { std::string OperationName; unsigned LastPrintAmount; - + SlowOperationInformer(const SlowOperationInformer&); // DO NOT IMPLEMENT void operator=(const SlowOperationInformer&); // DO NOT IMPLEMENT public: SlowOperationInformer(const std::string &Name); ~SlowOperationInformer(); - + /// progress - Clients should periodically call this method when they are in /// an exception-safe state. The Amount variable should indicate how far /// along the operation is, given in 1/10ths of a percent (in other words, diff --git a/include/llvm/Support/StableBasicBlockNumbering.h b/include/llvm/Support/StableBasicBlockNumbering.h index 4673ca9275..7780b025a5 100644 --- a/include/llvm/Support/StableBasicBlockNumbering.h +++ b/include/llvm/Support/StableBasicBlockNumbering.h @@ -1,10 +1,10 @@ //===- StableBasicBlockNumbering.h - Provide BB identifiers -----*- C++ -*-===// -// +// // 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 provides a *stable* numbering of basic blocks that does not depend diff --git a/include/llvm/Support/SystemUtils.h b/include/llvm/Support/SystemUtils.h index 09e1549b6a..93432b57bf 100644 --- a/include/llvm/Support/SystemUtils.h +++ b/include/llvm/Support/SystemUtils.h @@ -1,10 +1,10 @@ //===- SystemUtils.h - Utilities to do low-level system stuff ---*- C++ -*-===// -// +// // 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 @@ -19,8 +19,8 @@ namespace llvm { -/// Determine if the ostream provided is connected to the std::cout and -/// displayed or not (to a console window). If so, generate a warning message +/// Determine if the ostream provided is connected to the std::cout and +/// displayed or not (to a console window). If so, generate a warning message /// advising against display of bytecode and return true. Otherwise just return /// false /// @brief Check for output written to a console diff --git a/include/llvm/Support/ThreadSupport-NoSupport.h b/include/llvm/Support/ThreadSupport-NoSupport.h index 3602e21cea..058f82b41f 100644 --- a/include/llvm/Support/ThreadSupport-NoSupport.h +++ b/include/llvm/Support/ThreadSupport-NoSupport.h @@ -1,10 +1,10 @@ //===-- llvm/Support/ThreadSupport-NoSupport.h - Generic Impl ---*- C++ -*-===// -// +// // 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 defines a generic ThreadSupport implementation used when there is diff --git a/include/llvm/Support/ThreadSupport-PThreads.h b/include/llvm/Support/ThreadSupport-PThreads.h index 34b90909aa..84c6fac588 100644 --- a/include/llvm/Support/ThreadSupport-PThreads.h +++ b/include/llvm/Support/ThreadSupport-PThreads.h @@ -1,10 +1,10 @@ //===-- llvm/Support/ThreadSupport-PThreads.h - PThreads support *- C++ -*-===// -// +// // 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 defines pthreads implementations of the generic threading @@ -39,7 +39,7 @@ namespace llvm { errorcode = pthread_mutexattr_settype(&Attr, PTHREAD_MUTEX_RECURSIVE); assert(errorcode == 0); - + errorcode = pthread_mutex_init(&mutex, &Attr); assert(errorcode == 0); diff --git a/include/llvm/Support/Timer.h b/include/llvm/Support/Timer.h index 94cac6a7dd..5a97f49723 100644 --- a/include/llvm/Support/Timer.h +++ b/include/llvm/Support/Timer.h @@ -1,10 +1,10 @@ //===-- llvm/Support/Timer.h - Interval Timing Support ----------*- C++ -*-===// -// +// // 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 defines three classes: Timer, TimeRegion, and TimerGroup, @@ -74,7 +74,7 @@ public: return Elapsed < T.Elapsed; } bool operator>(const Timer &T) const { return T.operator<(*this); } - + /// startTimer - Start the timer running. Time between calls to /// startTimer/stopTimer is counted by the Timer class. Note that these calls /// must be correctly paired. diff --git a/include/llvm/Support/ToolRunner.h b/include/llvm/Support/ToolRunner.h index e44cd65741..addeda6292 100644 --- a/include/llvm/Support/ToolRunner.h +++ b/include/llvm/Support/ToolRunner.h @@ -1,10 +1,10 @@ //===-- llvm/Support/ToolRunner.h -------------------------------*- C++ -*-===// -// +// // 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 exposes an abstraction around a platform C compiler, used to @@ -63,7 +63,7 @@ public: FileType fileType, 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); /// MakeSharedObject - This compiles the specified file (which is either a .c @@ -110,7 +110,7 @@ public: 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) = 0; }; @@ -140,7 +140,7 @@ public: 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); @@ -177,7 +177,7 @@ public: 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); diff --git a/include/llvm/Support/TypeInfo.h b/include/llvm/Support/TypeInfo.h index 54043af9de..0dfa583c6d 100644 --- a/include/llvm/Support/TypeInfo.h +++ b/include/llvm/Support/TypeInfo.h @@ -1,10 +1,10 @@ //===- llvm/Support/TypeInfo.h - Support for type_info objects -*- C++ -*-===// -// +// // 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 makes std::type_info objects behave like first class objects that @@ -45,7 +45,7 @@ struct TypeInfo { private: const std::type_info *Info; }; - + // Comparison operators inline bool operator==(const TypeInfo &lhs, const TypeInfo &rhs) { return lhs.get() == rhs.get(); @@ -62,11 +62,11 @@ inline bool operator!=(const TypeInfo &lhs, const TypeInfo &rhs) { inline bool operator>(const TypeInfo &lhs, const TypeInfo &rhs) { return rhs < lhs; } - + inline bool operator<=(const TypeInfo &lhs, const TypeInfo &rhs) { return !(lhs > rhs); } - + inline bool operator>=(const TypeInfo &lhs, const TypeInfo &rhs) { return !(lhs < rhs); } diff --git a/include/llvm/Support/type_traits.h b/include/llvm/Support/type_traits.h index 36bbdb8ea4..8befb255b7 100644 --- a/include/llvm/Support/type_traits.h +++ b/include/llvm/Support/type_traits.h @@ -1,16 +1,16 @@ //===- llvm/Support/type_traits.h - Simplfied type traits -------*- C++ -*-===// -// +// // 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 provides a template class that determines if a type is a class or // not. The basic mechanism, based on using the pointer to member function of -// a zero argument to a function was "boosted" from the boost type_traits -// library. See http://www.boost.org/ for all the gory details. +// a zero argument to a function was "boosted" from the boost type_traits +// library. See http://www.boost.org/ for all the gory details. // //===----------------------------------------------------------------------===// @@ -27,13 +27,13 @@ namespace llvm { namespace dont_use { // These two functions should never be used. They are helpers to - // the is_class template below. They cannot be located inside + // the is_class template below. They cannot be located inside // is_class because doing so causes at least GCC to think that // the value of the "value" enumerator is not constant. Placing - // them out here (for some strange reason) allows the sizeof + // them out here (for some strange reason) allows the sizeof // operator against them to magically be constant. This is // important to make the is_class<T>::value idiom zero cost. it - // evaluates to a constant 1 or 0 depending on whether the + // evaluates to a constant 1 or 0 depending on whether the // parameter T is a class or not (respectively). template<typename T> char is_class_helper(void(T::*)(void)); template<typename T> double is_class_helper(...); |