harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hinde...@apache.org
Subject svn commit: r413288 - in /incubator/harmony/enhanced/drlvm/trunk: build/patches/common/LOG4CXX/ build/patches/common/LOG4CXX/include/ build/patches/common/LOG4CXX/include/log4cxx/ build/patches/common/LOG4CXX/include/log4cxx/helpers/ build/patches/comm...
Date Sat, 10 Jun 2006 12:26:43 GMT
Author: hindessm
Date: Sat Jun 10 05:26:41 2006
New Revision: 413288

URL: http://svn.apache.org/viewvc?rev=413288&view=rev
Log:
Apply patch DRLVM-GCC-3.4_and_4.x-cumulative.patch from HARMONY-443

Added:
    incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/
    incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/
    incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/
    incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/helpers/
    incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/helpers/unicodehelper.h   (with props)
    incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/xml/
    incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/xml/domconfigurator.h   (with props)
Modified:
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/CodeGenIntfc.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CFG.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CallingConvention.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CodeLayout.cpp
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CodeLayout.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Encoder.cpp
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Inst.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32InstCodeSelector.cpp
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32InstCodeSelector.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Printer.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/CSEHash.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/FlowGraph.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/IRBuilder.cpp
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/Inst.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/Opnd.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/abcd/abcdbounds.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/abcd/abcdsolver.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/aliasanalyzer.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/constantfolder.cpp
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/dataflow.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/multiplybyconstant.cpp
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/reassociate.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/simplifier.cpp
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/simplifier.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/BitSet.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Category.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/ControlFlowGraph.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Counter.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Graph.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/HashTable.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/InlineInfo.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Stl.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Tree.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Type.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/ByteCodeParser.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/ExceptionInfo.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/TranslatorIntfc.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/java/JavaLabelPrepass.cpp
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/java/JavaLabelPrepass.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/vm/VMInterface.h
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/vm/drl/DrlVMInterface.h
    incubator/harmony/enhanced/drlvm/trunk/vm/vmcore/src/class_support/Class_File_Loader.cpp

Added: incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/helpers/unicodehelper.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/helpers/unicodehelper.h?rev=413288&view=auto
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/helpers/unicodehelper.h (added)
+++ incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/helpers/unicodehelper.h Sat Jun 10 05:26:41 2006
@@ -0,0 +1,123 @@
+/*
+ * Copyright 2003,2005 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _LOG4CXX_HELPERS_UNICODEHELPER_H
+#define _LOG4CXX_HELPERS_UNICODEHELPER_H
+
+#include <string>
+#include <log4cxx/logstring.h>
+
+namespace log4cxx {
+    namespace helpers {
+          /**
+           *   UnicodeHelper provides static methods for encoding and decoding
+         *   UTF-8, UTF-16 and wchar_t from UCS-4 values.
+           *
+           */
+          class UnicodeHelper {
+          private:
+              /**
+               * Inaccessible constructor.
+               */
+              UnicodeHelper() {
+              }
+
+          public:
+              /**
+               *   Decodes next character from a sequence of UTF-8 bytes.
+               *   @param src start of character, will be modified to point at next character.
+               *   @param srcEnd end of sequence.
+               *   @return scalar value (UCS-4) or 0xFFFF if invalid sequence.
+               */
+              static unsigned int decodeUTF8(const char*& src,
+                  const char* srcEnd);
+
+
+              /**
+               *   Encodes a character using UTF-8.
+               *   @param ch UCS-4 value.
+               *   @param dst buffer to receive UTF-8 encoding (must be at least 8 bytes)
+               *   @return number of bytes needed to represent character
+               */
+              static int encodeUTF8(unsigned int ch, char* dst);
+
+              /**
+               *   Encodes a character using UTF-16BE.
+               *   @param ch UCS-4 value.
+               *   @param dst buffer to receive UTF-16BE encoding (must be at least 4 bytes)
+               *   @return number of bytes needed to represent character
+               */
+              static int encodeUTF16BE(unsigned int ch, char* dst);
+
+              /**
+               *   Encodes a character using UTF-16LE.
+               *   @param ch UCS-4 value.
+               *   @param dst buffer to receive UTF-16BE encoding (must be at least 4 bytes)
+               *   @return number of bytes needed to represent character
+               */
+              static int encodeUTF16LE(unsigned int ch, char* dst);
+
+
+#if LOG4CXX_HAS_WCHAR_T
+              /**
+               *   Decodes next character from a sequence of wchar_t values.
+               *   @param src start of character, will be modified to point at next character.
+               *   @param srcEnd end of sequence.
+               *   @return scalar value (UCS-4) or 0xFFFF if invalid sequence.
+               */
+              static unsigned int decodeWide(const wchar_t*& src, const wchar_t* srcEnd);
+
+
+              /**
+               *   Encodes a character to wchar_t.
+               *   @param ch UCS-4 value.
+               *   @param dst buffer to receive wchar_t (must be at least 2 wchar_t)
+               *   @return number of wchar_t needed to represent character
+               */
+              static int encodeWide(unsigned int ch, wchar_t* str);
+
+           /**
+            *   Determines the number of UTF-8 bytes required to express
+            *   the wchar_t value.
+            *   @param ch wchar_t value
+            *   @return number of bytes required.
+            */
+              static int lengthUTF8(wchar_t ch);
+
+#endif
+
+              /**
+               *   Decodes next character from a LogString.
+               *   @param in string from which the character is extracted.
+               *   @param iter iterator addressing start of character, will be
+            *   advanced to next character if successful.
+               *   @return scalar value (UCS-4) or 0xFFFF if invalid sequence.
+               */
+              static unsigned int decode(const LogString& in,
+                  LogString::const_iterator& iter);
+
+              /**
+               *   Encodes a UCS-4 value to logchar.
+               *   @param ch UCS-4 value.
+               *   @param dst buffer to receive logchar encoding (must be at least 8)
+               *   @return number of logchar needed to represent character
+               */
+              static int encode(unsigned int ch, logchar* dst);
+
+          };
+    }
+}
+#endif

Propchange: incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/helpers/unicodehelper.h
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/xml/domconfigurator.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/xml/domconfigurator.h?rev=413288&view=auto
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/xml/domconfigurator.h (added)
+++ incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/xml/domconfigurator.h Sat Jun 10 05:26:41 2006
@@ -0,0 +1,260 @@
+/*
+ * Copyright 2003-2005 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _LOG4CXX_XML_DOM_CONFIGURATOR_H
+#define _LOG4CXX_XML_DOM_CONFIGURATOR_H
+
+#include <log4cxx/logstring.h>
+#include <log4cxx/helpers/objectptr.h>
+#include <log4cxx/helpers/objectimpl.h>
+#include <map>
+#include <log4cxx/appender.h>
+#include <log4cxx/layout.h>
+#include <log4cxx/logger.h>
+#include <log4cxx/helpers/properties.h>
+#include <log4cxx/spi/configurator.h>
+
+namespace log4cxx
+{
+        class File;
+
+        namespace spi
+        {
+                class LoggerRepository;
+                typedef helpers::ObjectPtrT<LoggerRepository> LoggerRepositoryPtr;
+
+                class Filter;
+                typedef helpers::ObjectPtrT<Filter> FilterPtr;
+
+                class AppenderAttachable;
+                typedef helpers::ObjectPtrT<AppenderAttachable> AppenderAttachablePtr;
+
+                class OptionHandler;
+                typedef helpers::ObjectPtrT<OptionHandler> OptionHandlerPtr;
+        }
+
+        namespace helpers
+        {
+                class XMLDOMDocument;
+                typedef helpers::ObjectPtrT<XMLDOMDocument> XMLDOMDocumentPtr;
+
+                class XMLDOMElement;
+                typedef helpers::ObjectPtrT<XMLDOMElement> XMLDOMElementPtr;
+        }
+
+        namespace config
+        {
+                class PropertySetter;
+        }
+
+        namespace rolling
+        {
+                class RollingPolicy;
+                typedef helpers::ObjectPtrT<RollingPolicy> RollingPolicyPtr;
+
+                class TriggeringPolicy;
+                typedef helpers::ObjectPtrT<TriggeringPolicy> TriggeringPolicyPtr;
+        }
+
+
+
+        namespace xml
+        {
+                class AppenderMap
+                {
+                public:
+                        AppenderPtr get(const LogString& appenderName);
+                        void put(const LogString& appenderName, AppenderPtr appender);
+
+                protected:
+                        std::map<LogString, AppenderPtr> map;
+                };
+
+              /**
+              Use this class to initialize the log4cxx environment using a DOM tree.
+
+              <p>Sometimes it is useful to see how log4cxx is reading configuration
+              files. You can enable log4cxx internal logging by setting the
+              <code>debug</code> attribute in the
+              <code>log4cxx</code> element. As in
+              <pre>
+                      &lt;log4j:configuration <b>debug="true"</b> xmlns:log4j="http://jakarta.apache.org/log4j/">
+                      ...
+                      &lt;/log4j:configuration>
+              </pre>
+
+              <p>There are sample XML files included in the package.
+              */
+                class LOG4CXX_EXPORT DOMConfigurator :
+                        virtual public spi::Configurator,
+                        virtual public helpers::ObjectImpl
+                {
+                protected:
+                        /**
+                        Used internally to parse appenders by IDREF name.
+                        */
+                        AppenderPtr findAppenderByName(helpers::XMLDOMDocumentPtr doc,
+                                const LogString& appenderName);
+
+                        /**
+                        Used internally to parse appenders by IDREF element.
+                        */
+                        AppenderPtr findAppenderByReference(
+                                helpers::XMLDOMElementPtr appenderRef);
+
+                        /**
+                        Used internally to parse an appender element.
+                        */
+                        AppenderPtr parseAppender(helpers::XMLDOMElementPtr appenderElement);
+
+                        /**
+                        Used internally to parse an {@link spi::ErrorHandler ErrorHandler } element.
+                        */
+                        void parseErrorHandler(helpers::XMLDOMElementPtr element, AppenderPtr appender);
+
+                        /**
+                         Used internally to parse a filter element.
+                        */
+                        void parseFilters(helpers::XMLDOMElementPtr element,
+                           std::vector<log4cxx::spi::FilterPtr>& filters);
+
+                        /**
+                        Used internally to parse a logger element.
+                        */
+                        void parseLogger(helpers::XMLDOMElementPtr loggerElement);
+
+                        /**
+                         Used internally to parse the logger factory element.
+                        */
+                        void parseLoggerFactory(helpers::XMLDOMElementPtr factoryElement);
+
+                        /**
+                         Used internally to parse the logger factory element.
+                        */
+                        log4cxx::rolling::TriggeringPolicyPtr parseTriggeringPolicy(helpers::XMLDOMElementPtr factoryElement);
+
+                        /**
+                         Used internally to parse the logger factory element.
+                        */
+                        log4cxx::rolling::RollingPolicyPtr parseRollingPolicy(helpers::XMLDOMElementPtr factoryElement);
+
+                        /**
+                         Used internally to parse the roor category element.
+                        */
+                        void parseRoot(helpers::XMLDOMElementPtr rootElement);
+
+                        /**
+                         Used internally to parse the children of a category element.
+                        */
+                        void parseChildrenOfLoggerElement(helpers::XMLDOMElementPtr catElement,
+                                LoggerPtr logger, bool isRoot);
+
+                        /**
+                         Used internally to parse a layout element.
+                        */
+                        LayoutPtr parseLayout(helpers::XMLDOMElementPtr layout_element);
+
+                        /**
+                         Used internally to parse a level  element.
+                        */
+                        void parseLevel(helpers::XMLDOMElementPtr element,
+                                LoggerPtr logger, bool isRoot);
+
+                        void setParameter(helpers::XMLDOMElementPtr elem,
+                                config::PropertySetter& propSetter);
+
+                        /**
+                         Used internally to configure the log4cxx framework by parsing a DOM
+                         tree of XML elements based on <a
+                         href="docs/log4j.dtd">log4j.dtd</a>.
+
+                        */
+                        void parse(helpers::XMLDOMElementPtr element);
+
+                public:
+                        DOMConfigurator();
+
+                        DECLARE_LOG4CXX_OBJECT(DOMConfigurator)
+                        BEGIN_LOG4CXX_CAST_MAP()
+                                LOG4CXX_CAST_ENTRY(spi::Configurator)
+                        END_LOG4CXX_CAST_MAP()
+
+                        DOMConfigurator(log4cxx::helpers::Pool& p);
+
+                        /**
+                        A static version of #doConfigure.
+                        */
+                        static void configure(const std::string& filename);
+#if LOG4CXX_HAS_WCHAR_T
+                        static void configure(const std::wstring& filename);
+#endif
+                        /**
+                        Like #configureAndWatch(const String& configFilename, long delay)
+                        except that the default delay as defined by
+                        helpers::FileWatchdog#DEFAULT_DELAY is used.
+                        @param configFilename A log4j configuration file in XML format.
+                        */
+                        static void configureAndWatch(const std::string& configFilename);
+#if LOG4CXX_HAS_WCHAR_T
+                        static void configureAndWatch(const std::wstring& configFilename);
+#endif
+                        /**
+                        Read the configuration file <code>configFilename</code> if it
+                        exists. Moreover, a thread will be created that will periodically
+                        check if <code>configFilename</code> has been created or
+                        modified. The period is determined by the <code>delay</code>
+                        argument. If a change or file creation is detected, then
+                        <code>configFilename</code> is read to configure log4cxx.
+
+                        @param configFilename A log4j configuration file in XML format.
+                        @param delay The delay in milliseconds to wait between each check.
+                        */
+                        static void configureAndWatch(const std::string& configFilename,
+                                long delay);
+#if LOG4CXX_HAS_WCHAR_T
+                        static void configureAndWatch(const std::wstring& configFilename,
+                                long delay);
+#endif
+
+                        /**
+                        Interpret the XML file pointed by <code>filename</code> and set up
+                        log4cxx accordingly.
+                        <p>The configuration is done relative to the hierarchy parameter.
+                        @param filename The file to parse.
+                        @param repository The hierarchy to operation upon.
+                        */
+                        void doConfigure(const File& filename,
+                                spi::LoggerRepositoryPtr& repository);
+
+                protected:
+                        LogString subst(const LogString& value);
+
+                protected:
+                        void * appenderBag;
+
+                        helpers::Properties props;
+                        spi::LoggerRepositoryPtr repository;
+                        spi::LoggerFactoryPtr loggerFactory;
+
+                 private:
+                        //   prevent assignment or copy statements
+                        DOMConfigurator(const DOMConfigurator&);
+                        DOMConfigurator& operator=(const DOMConfigurator&);
+                };
+        }  // namespace xml
+} // namespace log4cxx
+
+#endif // _LOG4CXX_XML_DOM_CONFIGURATOR_H

Propchange: incubator/harmony/enhanced/drlvm/trunk/build/patches/common/LOG4CXX/include/log4cxx/xml/domconfigurator.h
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/CodeGenIntfc.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/CodeGenIntfc.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/CodeGenIntfc.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/CodeGenIntfc.h Sat Jun 10 05:26:41 2006
@@ -175,6 +175,7 @@
 
 class InstructionCallback {
 public:
+    virtual ~InstructionCallback() {}
     virtual void            opndMaybeGlobal(CG_OpndHandle* opnd) = 0;
 
     // tau generating instructions
@@ -468,8 +469,10 @@
 //
 class VarCodeSelector {
 public:
+    virtual ~VarCodeSelector() {}
     class Callback {
     public:
+    virtual ~Callback() {}
     virtual uint32 defVar(Type* varType,bool isAddressTaken,bool isPinned) = 0;
 	virtual void setManagedPointerBase(uint32 managedPtrVarNum, uint32 baseVarNum) = 0;
     };
@@ -481,6 +484,7 @@
 //
 class BlockCodeSelector {
 public:
+    virtual ~BlockCodeSelector() {}
     virtual void genCode(InstructionCallback&) = 0;
 };
 
@@ -489,8 +493,10 @@
 //
 class CFGCodeSelector {
 public:
+    virtual ~CFGCodeSelector() {}
     class Callback {
     public:
+	virtual ~Callback() {}
         enum BlockKind {Prolog, InnerBlock, Epilog};
         virtual uint32  genDispatchNode(uint32 numInEdges,uint32 numOutEdges,double cnt) = 0;
         virtual uint32  genBlock(uint32 numInEdges,uint32 numOutEdges, BlockKind blockKind,
@@ -518,9 +524,11 @@
 //
 class MethodCodeSelector {
 public:
+    virtual ~MethodCodeSelector() {}
     MethodCodeSelector() {}
     class Callback {
     public:
+	virtual ~Callback() {}
         virtual void    genVars(uint32 numLocals,VarCodeSelector&) = 0;
         virtual void    setMethodDesc(MethodDesc * desc) = 0;
         virtual void    genCFG(uint32 numNodes,CFGCodeSelector&,bool useProfile) = 0;
@@ -531,6 +539,7 @@
 
 class CodeGenerator {
 public:
+    virtual ~CodeGenerator() {}
     virtual bool genCode(MethodCodeSelector&) = 0;
     static void readFlagsFromCommandLine(CompilationContext* cs, bool ia32Cg);
     static void showFlagsFromCommandLine(bool ia32Cg);
@@ -538,12 +547,14 @@
 
 class CodeGeneratorFactory {
 public:
+    virtual ~CodeGeneratorFactory() {}
     virtual CodeGenerator* getCodeGenerator(MemoryManager &mm, 
                                             CompilationInterface& compInterface) = 0;
 };
 
 class RuntimeInterface {
 public:
+    virtual ~RuntimeInterface() {}
     virtual void  unwindStack(MethodDesc* methodDesc, ::JitFrameContext* context, bool isFirst) = 0;
 
     virtual void  getGCRootSet(MethodDesc* methodDesc, GCInterface* gcInterface, 

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CFG.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CFG.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CFG.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CFG.h Sat Jun 10 05:26:41 2006
@@ -39,6 +39,7 @@
     class DispatchNode;
     class BasicBlock;
     class Inst;
+    class CFG;
 
     typedef double  ProbValue;
     typedef double  ExecCntValue;
@@ -266,6 +267,7 @@
         };
 
         //---------------------------------------------------------------------------------------------
+	virtual ~Node() {}
         /** Returns the ID of the node */
         uint32              getId()const {return id;}
         /** Returns the kind of the node representing its class */
@@ -372,6 +374,7 @@
     class DispatchNode : public Node 
     {
     public:
+	virtual ~DispatchNode() {}
 
         /** Auxiliary method, returns true if the catch edges are sorted */
         bool catchEdgesAreSorted()const;
@@ -399,6 +402,7 @@
     protected: 
         UnwindNode(CFG * cfg, uint32 id, ExecCntValue cnt = UnknownExecCnt) :Node(cfg, id, cnt) 
         {setKind(Kind_UnwindNode); }
+	virtual ~UnwindNode() {}
         //---------------------------------------------------------------------------------------------
         friend class CFG;
     };
@@ -412,6 +416,7 @@
     protected: 
         ExitNode(CFG * cfg, uint32 id, ExecCntValue cnt = UnknownExecCnt) :Node(cfg, id, cnt) 
         {setKind(Kind_ExitNode); }
+	virtual ~ExitNode() {}
         //---------------------------------------------------------------------------------------------
         friend class CFG;
     };
@@ -547,7 +552,7 @@
         void    verify();
     //---------------------------------------------------------------------------------------------
     protected: 
-        BasicBlock::BasicBlock(CFG * cfg, uint32 id, ExecCntValue cnt) 
+        BasicBlock(CFG * cfg, uint32 id, ExecCntValue cnt) 
             : Node(cfg, id, cnt), layoutSucc(NULL), codeOffset(0), codeSize(0), fallThroughEdge(0), directBranchEdge(0)
         {setKind(Kind_BasicBlock); }
 

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CallingConvention.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CallingConvention.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CallingConvention.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CallingConvention.h Sat Jun 10 05:26:41 2006
@@ -48,6 +48,7 @@
 class CallingConvention
 {	
 public:	
+        virtual ~CallingConvention() {}
 	//--------------------------------------------------------------
 
 	struct OpndInfo
@@ -103,7 +104,7 @@
 class STDCALLCallingConvention: public CallingConvention
 {	
 public:	
-
+        virtual ~STDCALLCallingConvention() {}
 	virtual void	getOpndInfo(ArgKind kind, uint32 argCount, OpndInfo * infos)const;
 	virtual uint32	getCalleeSavedRegs(OpndKind regKind)const;
 	virtual bool	calleeRestoresStack()const{ return true; }
@@ -119,6 +120,7 @@
 class DRLCallingConvention: public STDCALLCallingConvention
 {	
 public:	
+        virtual ~DRLCallingConvention() {}
 	virtual bool	pushLastToFirst()const{ return false; }
 
 };
@@ -131,6 +133,7 @@
 class CDECLCallingConvention: public STDCALLCallingConvention
 {	
 public:	
+        virtual ~CDECLCallingConvention() {}
 	virtual bool	calleeRestoresStack()const{ return false; }
 };
 

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CodeLayout.cpp
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CodeLayout.cpp?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CodeLayout.cpp (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CodeLayout.cpp Sat Jun 10 05:26:41 2006
@@ -352,7 +352,7 @@
         } else if (!strcmp(params, "topdown")) {
             type = Linearizer::TOPDOWN;
         } else if (!strcmp(params, "mixed")) {
-            type = irManager.hasLoops() ? Linearizer::BOTTOM_UP  : type = Linearizer::TOPDOWN;
+            type = irManager.hasLoops() ? Linearizer::BOTTOM_UP  : Linearizer::TOPDOWN;
         } else if (!strcmp(params, "topological")) {
             type = Linearizer::TOPOLOGICAL;
         } else {

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CodeLayout.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CodeLayout.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CodeLayout.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32CodeLayout.h Sat Jun 10 05:26:41 2006
@@ -40,6 +40,7 @@
  */
 class Linearizer {
 public:
+    virtual ~Linearizer() {}
     enum LinearizerType { TOPOLOGICAL, TOPDOWN, BOTTOM_UP};
     static void doLayout(LinearizerType t, IRManager* irManager);
     static bool hasValidLayout(IRManager* irm);
@@ -88,6 +89,7 @@
     friend class Linearizer;
 protected:
     TopologicalLayout(IRManager* irManager) : Linearizer(irManager){};
+    virtual ~TopologicalLayout() {}
     void linearizeCfgImpl();
 };
 

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Encoder.cpp
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Encoder.cpp?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Encoder.cpp (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Encoder.cpp Sat Jun 10 05:26:41 2006
@@ -27,11 +27,11 @@
 const Encoder::OpcodeGroupDescription Encoder::dummyOpcodeGroupDescription;
 
 const Encoder::MemOpndConstraints Encoder::memOpndConstraints[16]= {
-    {
+    {{
     Constraint(OpndKind_GPReg, OpndSize_32), 
     Constraint(OpndKind_GPReg, OpndSize_32),
     Constraint(OpndKind_Imm, OpndSize_32),
-    Constraint(OpndKind_Imm, OpndSize_32) }, 
+    Constraint(OpndKind_Imm, OpndSize_32) }}, 
     // others contain null constraints, to be fixed later
 };
 

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Inst.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Inst.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Inst.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Inst.h Sat Jun 10 05:26:41 2006
@@ -182,14 +182,14 @@
 	Type * getType()const{ return type; }
 
 	/** returns the constraint of the specified kind sk */
-	Constraint Opnd::getConstraint(ConstraintKind ck)const
+	Constraint getConstraint(ConstraintKind ck)const
 	{
 		if (ck==ConstraintKind_Current)
 			return constraints[ConstraintKind_Location].isNull()?constraints[ConstraintKind_Calculated]:constraints[ConstraintKind_Location];
 		return ck==ConstraintKind_Size?Constraint(OpndKind_Any, constraints[ConstraintKind_Initial].getSize()):constraints[ck];
 	}
 
-	Constraint Opnd::getConstraint(ConstraintKind ck, OpndSize size)const
+	Constraint getConstraint(ConstraintKind ck, OpndSize size)const
 	{	Constraint c=getConstraint(ck); return size==OpndSize_Any?c:c.getAliasConstraint(size); }
 
     /** returns true if the operand CAN BE assigned to a location defined by constraint
@@ -291,7 +291,7 @@
 private:
 
 	//-------------------------------------------------------------------------
-	Opnd::Opnd(uint32 _id, Type * t, Constraint c)
+	Opnd(uint32 _id, Type * t, Constraint c)
 		:id(_id), firstId(_id), type(t), memOpndKind(MemOpndKind_Null), baseReg(RegName_Null)
 		{ constraints[ConstraintKind_Initial]=constraints[ConstraintKind_Calculated]=c; }
 
@@ -709,6 +709,8 @@
 	typedef uint32 iterator;
 	inline Opnds(const Inst * inst, uint32 r)
 	{
+	        rolesToCheck = 0;
+		roles = NULL;
 		opnds = inst->getOpnds();
 
 		if (r & Inst::OpndRole_InstLevel) {
@@ -728,7 +730,7 @@
 				roles = inst->getOpndRoles();
 				rolesToCheck = r;
 				startIndex = next(startIndex - 1);
-			}else roles = NULL;
+			}
 		}else{
 			instEndIndex = inst->opndCount;
 			endIndex = instEndIndex + (instEndIndex<<2);

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32InstCodeSelector.cpp
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32InstCodeSelector.cpp?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32InstCodeSelector.cpp (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32InstCodeSelector.cpp Sat Jun 10 05:26:41 2006
@@ -26,6 +26,7 @@
 #include "Ia32CodeGenerator.h"
 #include "Ia32Printer.h"
 #include <float.h>
+#include <math.h>
 
 #ifdef PLATFORM_POSIX
 #define _isnan isnan

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32InstCodeSelector.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32InstCodeSelector.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32InstCodeSelector.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32InstCodeSelector.h Sat Jun 10 05:26:41 2006
@@ -314,7 +314,7 @@
 	Opnd * simpleOp_I8(Mnemonic mn, Type * dstType, Opnd * src1, Opnd * src2);
 
 	Opnd * simpleOp_I4(Mnemonic mn, Type * dstType, Opnd * src1, Opnd * src2);
-	Opnd * InstCodeSelector::fpOp(Mnemonic mn, Type * dstType, Opnd * src1, Opnd * src2);	
+	Opnd * fpOp(Mnemonic mn, Type * dstType, Opnd * src1, Opnd * src2);	
 
 	Opnd * createResultOpnd(Type * dstType);
 

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Printer.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Printer.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Printer.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/codegenerator/ia32/Ia32Printer.h Sat Jun 10 05:26:41 2006
@@ -182,7 +182,7 @@
 	static void printOpndRoles(::std::ostream& os, uint32 roles)
 	{ IRPrinter p; p.setStream(os); p.printOpndRoles(roles); }
 
-	void IRPrinter::printOpndName(const Opnd * opnd);
+	void printOpndName(const Opnd * opnd);
 	static void printOpndName(::std::ostream& os, const Opnd * opnd)
 	{ IRPrinter p; p.setStream(os); p.printOpndName(opnd); }
 
@@ -254,7 +254,7 @@
 	IRInstConstraintPrinter(const IRManager * irm=0, const char * _title=0)
 		:IRPrinter(irm, _title){}
 
-	virtual void IRInstConstraintPrinter::printOpnd(const Inst * inst, uint32 opndIdx, bool isLiveBefore=false, bool isLiveAfter=false);
+	virtual void printOpnd(const Inst * inst, uint32 opndIdx, bool isLiveBefore=false, bool isLiveAfter=false);
 };
 
 //========================================================================================

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/CSEHash.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/CSEHash.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/CSEHash.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/CSEHash.h Sat Jun 10 05:26:41 2006
@@ -155,6 +155,7 @@
 public:
     CSEHashTable(MemoryManager& mm) 
         : numCSE(0), hashTable(mm, CSE_HASH_TABLE_SIZE) {}
+    virtual ~CSEHashTable() {}
 
     void    kill() {hashTable.removeAll();}
     virtual Inst*  lookupKey(CSEHashKey* key) { return lookupKeyBase(key); }
@@ -210,6 +211,7 @@
 
 class ScopedCSEHashTable : public CSEHashTable {
 public:
+    virtual ~ScopedCSEHashTable() {}
     ScopedCSEHashTable(MemoryManager& mm, ScopedCSEHashTable* outerScope) 
         : CSEHashTable(mm), _outerScope(outerScope) {
     }

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/FlowGraph.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/FlowGraph.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/FlowGraph.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/FlowGraph.h Sat Jun 10 05:26:41 2006
@@ -166,6 +166,7 @@
 
     class ProfileAnnotator : public ControlFlowNode::Annotator {
     public:
+	virtual ~ProfileAnnotator() {}
         void annotateNode(::std::ostream& os, ControlFlowNode* _node) {
             CFGNode* node = (CFGNode*) _node;
             os << "[Freq=" << ::std::setprecision(4) << node->getFreq();

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/IRBuilder.cpp
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/IRBuilder.cpp?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/IRBuilder.cpp (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/IRBuilder.cpp Sat Jun 10 05:26:41 2006
@@ -1075,13 +1075,13 @@
         tauTypesChecked = propagateCopy(tauTypesChecked);
     }
     if (irBuilderFlags.doSimplify) {
-        Opnd *dst = dst = simplifier.simplifyTauVirtualCall(methodDesc,
-                                                            returnType,
-                                                            tauNullCheckedFirstArg,
-                                                            tauTypesChecked,
-                                                            numArgs,
-                                                            args,
-                                                            inlineInfoBuilder);
+        Opnd *dst = simplifier.simplifyTauVirtualCall(methodDesc,
+                                                      returnType,
+                                                      tauNullCheckedFirstArg,
+                                                      tauTypesChecked,
+                                                      numArgs,
+                                                      args,
+                                                      inlineInfoBuilder);
         if (dst) return dst;
     }
     

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/Inst.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/Inst.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/Inst.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/Inst.h Sat Jun 10 05:26:41 2006
@@ -82,6 +82,7 @@
 //
 class InstFormatVisitor {
 public:
+    virtual ~InstFormatVisitor() {}
     virtual void accept(Inst*) = 0;
     virtual void accept(BranchInst*) = 0;
     virtual void accept(CallInst*) = 0;
@@ -112,6 +113,7 @@
 
 class Inst : private Dlink {
 public:
+    virtual ~Inst() {}
     // modified Dlink methods
     void unlink() {
         Dlink::unlink(); 
@@ -1563,6 +1565,7 @@
 
 class InstOptimizer {
 public:
+    virtual ~InstOptimizer() {}
     // returns 0 or an optimized version of inst;
     virtual Inst*
     optimizeInst(Inst* inst) {

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/Opnd.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/Opnd.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/Opnd.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/Opnd.h Sat Jun 10 05:26:41 2006
@@ -48,6 +48,7 @@
 
 class OpndBase {    // rename to Opnd
 public:
+    virtual ~OpndBase() {}
     uint32  getId() const                 {return id;}
     Type*   getType() const               {return type;}
     void    setType(Type *t)              {type = t;}
@@ -104,6 +105,7 @@
 
 class Opnd : public OpndBase {
 public:
+    virtual ~Opnd() {}
     void    setIsGlobal(bool val)   {isGlobalFlag = val;}
     bool    isGlobal() const        {return isGlobalFlag;}
     //
@@ -126,6 +128,7 @@
 
 class SsaOpnd : public Opnd {
 public:
+    virtual ~SsaOpnd() {}
     virtual bool isSsaOpnd() const    {return true;}
 protected:
     friend class OpndManager;
@@ -136,6 +139,7 @@
 
 class SsaTmpOpnd : public SsaOpnd {
 public:
+    virtual ~SsaTmpOpnd() {}
     virtual bool isSsaTmpOpnd() const    {return true;}
 private:
     friend class OpndManager;
@@ -144,6 +148,7 @@
 
 class PiOpnd : public SsaOpnd {
 public:
+    virtual ~PiOpnd() {}
     virtual bool isSsaTmpOpnd() const    {return false;};
     virtual bool isPiOpnd() const        {return true;};
     const Opnd *getOrg() const { return orgOpnd; };
@@ -162,6 +167,7 @@
 
 class VarOpnd : public Opnd {
 public:
+    virtual ~VarOpnd() {}
     virtual bool    isVarOpnd() const      {return true;}
     bool            isAddrTaken() const    {return isAddrTakenFlag;}
     void            setAddrTaken()         {isAddrTakenFlag = true;}
@@ -216,6 +222,7 @@
 //
 class SsaVarOpnd : public SsaOpnd {
 public:
+    virtual ~SsaVarOpnd() {}
     virtual bool isSsaVarOpnd() const {return true;}
     VarOpnd* getVar()           {return var;}
     //
@@ -305,6 +312,7 @@
 public:
     OpndRenameTable(MemoryManager& mm, uint32 size = 16, bool renameSSA = false): 
         HashTable<Opnd,Opnd>(mm,size) {renameSsaOpnd = renameSSA;}
+    virtual ~OpndRenameTable() {}
     
     Opnd *getMapping(Opnd *from)   {return lookup(from); }
     void  setMapping(Opnd *from, Opnd *to) {

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/abcd/abcdbounds.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/abcd/abcdbounds.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/abcd/abcdbounds.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/abcd/abcdbounds.h Sat Jun 10 05:26:41 2006
@@ -537,6 +537,7 @@
     return (nega == a);
 };
 
+#if 0
 template <typename inttype>
 inline bool mul_overflowed(inttype prod, inttype a, inttype b) {
     // let's just be really conservative.
@@ -552,6 +553,7 @@
     else
         return false;
 };
+#endif
 
 } //namespace Jitrino 
 

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/abcd/abcdsolver.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/abcd/abcdsolver.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/abcd/abcdsolver.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/abcd/abcdsolver.h Sat Jun 10 05:26:41 2006
@@ -191,12 +191,12 @@
     // by considering either var1 or var2, depending on derefVar1
     // if (!checkVar1), var2 should have been fully dereferenced 
     // and checked first.; sets noneApply=true if none apply 
-    ProofLattice AbcdSolver::proveForSpecialCases(const VarBound &var1,
-                                                  const VarBound &var2,
-                                                  ConstBound c,
-                                                  bool checkVar1,
-                                                  bool &noneApply,
-                                                  AbcdReasons *why); // if non-null and proven true, reasons why
+    ProofLattice proveForSpecialCases(const VarBound &var1,
+                                      const VarBound &var2,
+                                      ConstBound c,
+                                      bool checkVar1,
+                                      bool &noneApply,
+                                      AbcdReasons *why); // if non-null and proven true, reasons why
     void tryToEliminate(Inst *); // solve for an instruction;
     void tryToFoldBranch(Inst *);
     void tryToFoldCompare(Inst *);

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/aliasanalyzer.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/aliasanalyzer.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/aliasanalyzer.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/aliasanalyzer.h Sat Jun 10 05:26:41 2006
@@ -34,6 +34,7 @@
 class AliasAnalyzer
 {
 public:
+    virtual ~AliasAnalyzer() {}
     /**
      * Return false if op1 and op2 cannot point to same location in memory.
      * Both op1 and op2 must be reference or pointer typed.  The method will
@@ -52,6 +53,7 @@
 class TypeAliasAnalyzer : public AliasAnalyzer
 {
 public:
+    virtual ~TypeAliasAnalyzer() {}
     bool mayAlias(Opnd* op1, Opnd* op2);
 
     bool mayAlias(Type* t1, Type* t2);

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/constantfolder.cpp
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/constantfolder.cpp?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/constantfolder.cpp (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/constantfolder.cpp Sat Jun 10 05:26:41 2006
@@ -26,6 +26,7 @@
 #define CAST(a, b) ((a)b)
 
 #include <float.h>
+#include <math.h>
 
 /*
  * The constant folding optimization is described in [S.Muchnick. Advanced Compiler
@@ -37,7 +38,7 @@
 
 using namespace std;
 
-inline int isfinite(double s) {
+inline int isFinite(double s) {
     return finite(s);
 }
 
@@ -51,7 +52,7 @@
 
 // isnan(double s) is declared in float.h
 #else
-inline int isfinite(double s) {
+inline int isFinite(double s) {
     return _finite(s);
 }
 
@@ -92,7 +93,7 @@
 inline tointtype float2int(fromfloattype f)
 {
     if (isnan(f)) return (tointtype) 0;
-    if (isfinite(f) && 
+    if (isFinite(f) && 
         (((fromfloattype(minint<tointtype>(0))) < f) &&
          (f < fromfloattype(maxint<tointtype>(0)))))
         return (tointtype) f; // both C++ and Java truncate
@@ -104,7 +105,7 @@
 inline tointtype float2uint(fromfloattype s)
 {
     if (isnan(s) || (s < 0.0)) return (tointtype) 0;
-    if (isfinite(s) && (s < maxuintasfloat<tointtype>(0)))
+    if (isFinite(s) && (s < maxuintasfloat<tointtype>(0)))
         return (tointtype) s;
     return maxuint<tointtype>(0);
 }

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/dataflow.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/dataflow.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/dataflow.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/dataflow.h Sat Jun 10 05:26:41 2006
@@ -38,6 +38,7 @@
 template <typename DataflowValue>
 class DataflowTF {
 public:
+    virtual ~DataflowTF() {}
     // returns true if changed
     virtual bool apply(const DataflowValue &in, DataflowValue &out) = 0;
 };
@@ -45,6 +46,7 @@
 template <typename DataflowValue>
 class DataflowInstance {
 public:
+    virtual ~DataflowInstance() {}
     typedef DataflowValue ValueType;
     virtual DataflowTF<DataflowValue> *getNodeBehavior(CFGNode *node) = 0;
     virtual DataflowValue getEntryValue() = 0;

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/multiplybyconstant.cpp
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/multiplybyconstant.cpp?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/multiplybyconstant.cpp (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/multiplybyconstant.cpp Sat Jun 10 05:26:41 2006
@@ -52,6 +52,7 @@
 #include "CompilationContext.h"
 
 #include <float.h>
+#include <math.h>
 
 #include "Stl.h"
 #include "simplifier.h"
@@ -63,14 +64,8 @@
 namespace Jitrino {
 
 #ifdef PLATFORM_POSIX
-inline bool isfinite(double s) {
-    return (finite(s) != 0);
-}
 // isnan(double s) is declared in float.h
 #else
-inline bool isfinite(double s) {
-    return (_finite(s) != 0);
-}
 inline bool isnan(double s) {
     return (_isnan(s) != 0);
 }

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/reassociate.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/reassociate.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/reassociate.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/reassociate.h Sat Jun 10 05:26:41 2006
@@ -61,6 +61,8 @@
 
 DEFINE_OPTPASS(LateDepthReassociationPass)
 
+class Simplifier;
+
 //
 // Try to re-associate expressions to either
 //    - reduce expression height

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/simplifier.cpp
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/simplifier.cpp?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/simplifier.cpp (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/simplifier.cpp Sat Jun 10 05:26:41 2006
@@ -38,6 +38,7 @@
 #include "CompilationContext.h"
 
 #include <float.h>
+#include <math.h>
 
 namespace Jitrino {
 /*
@@ -48,12 +49,12 @@
  */
 
 #ifdef PLATFORM_POSIX
-inline bool isfinite(double s) {
+inline bool isFinite(double s) {
     return (finite(s) != 0);
 }
 // isnan(double s) is declared in float.h
 #else
-inline bool isfinite(double s) {
+inline bool isFinite(double s) {
     return (_finite(s) != 0);
 }
 inline bool isnan(double s) {
@@ -3050,7 +3051,7 @@
         case Type::Single: // single
             {
                 float s = value.s;
-                if (!isfinite((double)s)) {
+                if (!isFinite((double)s)) {
                     alwaysThrows = true;
                     return genTauUnsafe()->getDst();
                 }
@@ -3059,7 +3060,7 @@
         case Type::Double:
             {
                 double d = value.d;
-                if (!isfinite(d)) {
+                if (!isFinite(d)) {
                     alwaysThrows = true;
                     return genTauUnsafe()->getDst();
                 }

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/simplifier.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/simplifier.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/simplifier.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/optimizer/simplifier.h Sat Jun 10 05:26:41 2006
@@ -1079,17 +1079,17 @@
     // re-association machinery
     friend class Reassociate;
     Opnd*
-    Simplifier::simplifyAddViaReassociation2(Type* type, Opnd* src1, Opnd* src2);
+    simplifyAddViaReassociation2(Type* type, Opnd* src1, Opnd* src2);
     Opnd*
-    Simplifier::simplifyNegViaReassociation2(Type* type, Opnd* src1);
+    simplifyNegViaReassociation2(Type* type, Opnd* src1);
     Opnd*
-    Simplifier::simplifySubViaReassociation2(Type* type, Opnd* src1, Opnd *src2);
+    simplifySubViaReassociation2(Type* type, Opnd* src1, Opnd *src2);
     Opnd*
-    Simplifier::simplifyMulViaReassociation2(Type* type, Opnd* src1, Opnd* src2);
+    simplifyMulViaReassociation2(Type* type, Opnd* src1, Opnd* src2);
     Opnd*
-    Simplifier::simplifyAddOffsetViaReassociation(Opnd* uncompBase, Opnd *offset);
+    simplifyAddOffsetViaReassociation(Opnd* uncompBase, Opnd *offset);
     Opnd*
-    Simplifier::simplifyAddOffsetPlusHeapbaseViaReassociation(Opnd *compBase,
+    simplifyAddOffsetPlusHeapbaseViaReassociation(Opnd *compBase,
                                                               Opnd *offsetPlusHeapbase);
     Reassociate *theReassociate;
 };

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/BitSet.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/BitSet.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/BitSet.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/BitSet.h Sat Jun 10 05:26:41 2006
@@ -187,6 +187,7 @@
 
 class BitSet::Visitor {
 public:
+        virtual ~Visitor() {}
 	virtual void visit(uint32 elem) = 0;
 };
 
@@ -194,7 +195,8 @@
 class BitSet::Printer : public BitSet::Visitor {
 public:
 	Printer(::std::ostream & _os) : os(_os) {}
-    void visit(uint32 i) { os << " " << (int) i;}
+        virtual ~Printer() {}
+        void visit(uint32 i) { os << " " << (int) i;}
 private:
 	::std::ostream & os;
 };

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Category.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Category.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Category.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Category.h Sat Jun 10 05:26:41 2006
@@ -68,6 +68,7 @@
 const LogLevel
 LogDefaultThreshold = LogNone;
 
+class Category;
 
 /**
  * A stream-like class for logging output.
@@ -77,26 +78,8 @@
     friend class Category;
 public:
     template <class T>
-    CategoryStream<level>& operator<<(const T& value) {
-        // Should be compile-time NOP if first test fails.
-        if(level >= LogStaticThreshold) {
-            if(cat->isLogDynamicEnabled(level)) {
-                cat->out() << value;
-            }
-        }
-        return *this;
-    }
-
-    CategoryStream& operator << (::std::ostream& (*f)(::std::ostream&))
-    {
-        // Should be compile-time NOP if first test fails.
-        if(level >= LogStaticThreshold) {
-            if(cat->isLogDynamicEnabled(level)) {
-                f(cat->out());
-            }
-        }
-        return *this;
-    }
+    inline CategoryStream<level>& operator<<(const T& value);
+    inline CategoryStream& operator << (::std::ostream& (*f)(::std::ostream&));
 
 private:
     CategoryStream() {}
@@ -211,6 +194,32 @@
     bool parentOverride;
 
 };
+
+
+template <LogLevel level>
+template <class T>
+CategoryStream<level>&
+CategoryStream<level>::operator<<(const T& value) {
+    // Should be compile-time NOP if first test fails.
+    if(level >= LogStaticThreshold) {
+	if(cat->isLogDynamicEnabled(level)) {
+	    cat->out() << value;
+	}
+    }
+    return *this;
+}
+
+template <LogLevel level>
+CategoryStream<level>&
+CategoryStream<level>::operator << (::std::ostream& (*f)(::std::ostream&)) {
+    // Should be compile-time NOP if first test fails.
+    if(level >= LogStaticThreshold) {
+	if(cat->isLogDynamicEnabled(level)) {
+	    f(cat->out());
+	}
+    }
+    return *this;
+}
 
 } //namespace Jitrino 
 

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/ControlFlowGraph.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/ControlFlowGraph.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/ControlFlowGraph.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/ControlFlowGraph.h Sat Jun 10 05:26:41 2006
@@ -166,6 +166,7 @@
 
         class Annotator {
         public:
+	    virtual ~Annotator() {}
             virtual void annotateNode(::std::ostream& os, Node* node) = 0;
         };
 

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Counter.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Counter.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Counter.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Counter.h Sat Jun 10 05:26:41 2006
@@ -26,7 +26,17 @@
 namespace Jitrino 
 {
 
-class CountWriter;
+class CountWriter
+{
+public:
+
+	virtual ~CountWriter ()		{}
+
+	virtual void write (const char* key, const char*  value)    	= 0;
+	virtual void write (const char* key, int          value)		= 0;
+	virtual void write (const char* key, unsigned int value)		= 0;
+	virtual void write (const char* key, double       value)		= 0;
+};
 
 
 class CounterBase
@@ -64,18 +74,6 @@
 	T value;
 };
 
-
-class CountWriter
-{
-public:
-
-	virtual ~CountWriter ()		{}
-
-	virtual void write (const char* key, const char*  value)    	= 0;
-	virtual void write (const char* key, int          value)		= 0;
-	virtual void write (const char* key, unsigned int value)		= 0;
-	virtual void write (const char* key, double       value)		= 0;
-};
 
 
 } //namespace Jitrino 

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Graph.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Graph.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Graph.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Graph.h Sat Jun 10 05:26:41 2006
@@ -49,7 +49,8 @@
 class Edge {
 
 public:
-        Edge() : predNode(NULL), succNode(NULL), nextPredEdge(NULL), nextSuccEdge(NULL) {}
+    Edge() : predNode(NULL), succNode(NULL), nextPredEdge(NULL), nextSuccEdge(NULL) {}
+    virtual ~Edge() {}
     Node*    getPredNode()            {return predNode; }
     Node*    getSuccNode()            {return succNode; }
     Edge*    getNextPredEdge()        {return nextPredEdge; }
@@ -83,7 +84,8 @@
 class Node : public Dlink {
 
    public:
-       Node():  traversalNum(0), dfnum(INVALID_DFN), succs(NULL), preds(NULL) {}
+    Node():  traversalNum(0), dfnum(INVALID_DFN), succs(NULL), preds(NULL) {}
+    virtual ~Node() {}
     //
     //  true if there is any edge to a successor node.
     bool    hasEdge(Node* succNode);

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/HashTable.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/HashTable.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/HashTable.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/HashTable.h Sat Jun 10 05:26:41 2006
@@ -60,6 +60,7 @@
 		: memManager(mm), table(t), tableSize(size) {
 		removeAll();
 	}
+	virtual ~HashTableImpl() {}
 	void* lookup(void* key) const {
 		HashTableLink* entry = lookupEntry(key);
 		if (entry == NULL)
@@ -198,6 +199,7 @@
 class KeyLinkHashTable : HashTableImpl {
 public:
 	KeyLinkHashTable(MemoryManager& mm,uint32 size) : HashTableImpl(mm,size) {}
+	virtual ~KeyLinkHashTable() {}
 	void*	lookup(KEY* key) const {return HashTableImpl::lookup(key);}
 	void	insert(KEY* key,void* value) {HashTableImpl::insert(key,value);}
 	void	remove(KEY* key) {HashTableImpl::remove(key);}
@@ -244,7 +246,7 @@
 		if (freeList == NULL) {
 			// get last guy at the end of mru list
 			link = (Link*)mruList.getPrev()->getElem();
-			remove(&link->key);
+			FixedKeyLinkHashTable<KEY,NUM_LINKS>::remove(&link->key);
 		}
 		assert(freeList != NULL);
 		link = freeList;
@@ -301,6 +303,7 @@
 public:
 	DoubleKeyHashTable(MemoryManager& mm,uint32 size) 
 		: KeyLinkHashTable<DoublePtrKey>(mm,size) {}
+	virtual ~DoubleKeyHashTable() {}
 	void*	lookup(void* key1,void* key2) const {
 		DoublePtrKey key(key1,key2);
 		return KeyLinkHashTable<DoublePtrKey>::lookup(&key);

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/InlineInfo.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/InlineInfo.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/InlineInfo.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/InlineInfo.h Sat Jun 10 05:26:41 2006
@@ -129,6 +129,7 @@
     InlineInfoBuilder(InlineInfoBuilder* parentBuilder) : 
         parent(parentBuilder)
     {}
+    virtual ~InlineInfoBuilder() {}
 
     void setParentBuilder(InlineInfoBuilder* builder) { parent = builder; }
 

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Stl.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Stl.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Stl.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Stl.h Sat Jun 10 05:26:41 2006
@@ -41,7 +41,11 @@
 
 #include <ext/hash_set>
 #include <ext/hash_map>
+#if (defined __GNUC__) && ((__GNUC__ >= 3 && __GNUC_MINOR__ > 3) || __GNUC__ > 3)
+#include <ext/hash_fun.h>
+#else
 #include <ext/stl_hash_fun.h>
+#endif
 
 #else
 
@@ -218,7 +222,7 @@
   StlVectorSet(Allocator const& a) : Vector(a) {}
   StlVectorSet(Allocator const& a, size_type n, const T& x = T()) : Vector(n, x, a) {}
   StlVectorSet(const Vector & a) :  Vector(a) {
-      sort(begin(), end());
+      sort(StlVectorSet<T,Allocator>::begin(), StlVectorSet<T,Allocator>::end());
   }
   StlVectorSet& operator=(const Vector & a) { Vector::operator=(a); return *this; };
   StlVectorSet& operator=(const StlVectorSet & a) { 
@@ -242,8 +246,8 @@
       }
   }
   void insert(iterator i1, iterator i2) {
-      Vector::insert(end(), i1, i2);
-      ::std::sort(begin(), end());
+      Vector::insert(StlVectorSet<T>::end(), i1, i2);
+      ::std::sort(StlVectorSet<T>::begin(), StlVectorSet<T>::end());
   }
   size_type erase(const T& x) { 
       ::std::pair<iterator, iterator> found= equal_range(x);
@@ -264,31 +268,31 @@
       else return 0;
   }
     const_iterator lower_bound(const T& x) const {
-      return ::std::lower_bound(begin(), end(), x);
+      return ::std::lower_bound(StlVectorSet<T,Allocator>::begin(), StlVectorSet<T,Allocator>::end(), x);
   }
   iterator lower_bound(const T& x) {
-      return ::std::lower_bound(begin(), end(), x);
+      return ::std::lower_bound(StlVectorSet<T,Allocator>::begin(), StlVectorSet<T,Allocator>::end(), x);
   }
   const_iterator upper_bound(const T& x) const {
-      return ::std::upper_bound(begin(), end(), x);
+      return ::std::upper_bound(StlVectorSet<T,Allocator>::begin(), StlVectorSet<T,Allocator>::end(), x);
   }
   iterator upper_bound(const T& x) {
-      return ::std::upper_bound(begin(), end(), x);
+      return ::std::upper_bound(StlVectorSet<T,Allocator>::begin(), StlVectorSet<T,Allocator>::end(), x);
   }
   ::std::pair<const_iterator, const_iterator> equal_range(const T& x) const {
-      return ::std::equal_range(begin(), end(), x);
+      return ::std::equal_range(StlVectorSet<T,Allocator>::begin(), StlVectorSet<T,Allocator>::end(), x);
   }
   ::std::pair<iterator, iterator> equal_range(const T& x) {
-      return ::std::equal_range(begin(), end(), x);
+      return ::std::equal_range(StlVectorSet<T,Allocator>::begin(), StlVectorSet<T,Allocator>::end(), x);
   }
   const_iterator find(const T& x) const {
       ::std::pair<const_iterator, const_iterator> found= equal_range(x);
-      if (found.first == found.second) return end();
+      if (found.first == found.second) return StlVectorSet<T,Allocator>::end();
       else return found.first;
   }
   iterator find(const T& x) { 
       ::std::pair<iterator, iterator> found= equal_range(x);
-      if (found.first == found.second) return end();
+      if (found.first == found.second) return StlVectorSet<T,Allocator>::end();
       else return found.first;
   }
   bool has(const T& x) const { 
@@ -312,8 +316,8 @@
   StlBoolVector(Allocator const& a, size_type n, bool x = false) : Vector(n, x, a) {}
 
   // Automatically resize as needed.
-  bool getBit(size_type n) { if(n < size()) return at(n); else return false; }
-  bool setBit(size_type n, bool value=true) { if(n >= size()) resize(n+1); bool old = at(n); at(n) = value; return old; }
+  bool getBit(size_type n) { if(n < StlBoolVector<Allocator>::size()) return at(n); else return false; }
+  bool setBit(size_type n, bool value=true) { if(n >= StlBoolVector<Allocator>::size()) resize(n+1); bool old = at(n); at(n) = value; return old; }
 };
 typedef StlBoolVector<> StlBitVector;
 
@@ -339,7 +343,7 @@
   StlSet(Allocator const& a) : Set(Traits(), a) {}
   StlSet(Traits const& t, Allocator const& a) : Set(t, a) {}
 
-  bool has(const KeyT& k) const { return (find(k) != end()); };
+  bool has(const KeyT& k) const { return (find(k) != StlSet<KeyT,Traits,Allocator>::end()); };
 };
 
 /**
@@ -353,7 +357,7 @@
   StlMultiSet(Allocator const& a) : MultiSet(Traits(), a) {}
   StlMultiSet(Traits const& t, Allocator const& a) : MultiSet(t, a) {}
 
-  bool has(const KeyT& k) const { return (find(k) != end()); };
+  bool has(const KeyT& k) const { return (find(k) != StlMultiSet<KeyT>::end()); };
 };
 
 /**
@@ -367,7 +371,7 @@
   StlMap(Allocator const& a) : Map(Traits(), a) {}
   StlMap(Traits const& t, Allocator const& a) : Map(t, a) {}
 
-  bool has(const KeyT& k) const { return (find(k) != end()); };
+  bool has(const KeyT& k) const { return (find(k) != StlMap<KeyT,ValueT,Traits,Allocator>::end()); };
 };
 
 /**
@@ -381,7 +385,7 @@
   StlMultiMap(Allocator const& a) : MultiMap(Traits(), a) {}
   StlMultiMap(Traits const& t, Allocator const& a) : MultiMap(t, a) {}
 
-  bool has(const KeyT& k) const { return (find(k) != end()); };
+  bool has(const KeyT& k) const { return (find(k) != StlMultiMap<KeyT,ValueT,Traits,Allocator>::end()); };
 };
 
 /**
@@ -424,7 +428,7 @@
   StlHashSet(Allocator const& a) : HashSet(HashCompareFun(), a) {}
   StlHashSet(Allocator const& a, size_type n) : HashSet(HashCompareFun(), a) {}
 
-  bool has(const T& k) const { return (find(k) != end()); };
+  bool has(const T& k) const { return (find(k) != StlHashSet<T,HashCompareFun,Allocator>::end()); };
 };
 #else
 template<class T, class HashFun = StlSimpleHash, class CompareFun = ::std::equal_to<T>, class Allocator = StlMMAllocator<T> >
@@ -455,7 +459,7 @@
   StlHashMultiSet(Allocator const& a) : HashMultiSet(HashCompareFun(), a) {}
   StlHashMultiSet(Allocator const& a, size_type n) : HashMultiSet(HashCompareFun(), a) {}
 
-  bool has(const T& k) const { return (find(k) != end()); };
+  bool has(const T& k) const { return (find(k) != StlHashMultiSet<T,HashCompareFun,Allocator>::end()); };
 };
 #else
 template<class T, class HashFun = StlSimpleHash, class CompareFun = ::std::equal_to<T>, class Allocator = StlMMAllocator<T> >
@@ -486,7 +490,7 @@
   StlHashMap(Allocator const& a) : HashMap(HashCompareFun(), a) {}
   StlHashMap(Allocator const& a, size_type n) : HashMap(HashCompareFun(), a) {}
 
-  bool has(const KeyT& k) const { return (find(k) != end()); };
+  bool has(const KeyT& k) const { return (find(k) != StlHashMap<KeyT,ValueT,HashCompareFun,Allocator>::end()); };
 };
 
 #else
@@ -518,7 +522,7 @@
   StlHashMultiMap(Allocator const& a) : HashMultiMap(HashCompareFun(), a) {}
   StlHashMultiMap(Allocator const& a, size_type n) : HashMultiMap(HashCompareFun(), a) {}
 
-  bool has(const KeyT& k) const { return (find(k) != end()); };
+  bool has(const KeyT& k) const { return (find(k) != StlHashMultiMap<KeyT,ValueT,HashCompareFun,Allocator>::end()); };
 };
 #else
 template<class KeyT, class ValueT, class HashFun = StlSimpleHash, class CompareFun = ::std::equal_to<KeyT>, class Allocator = StlMMAllocator<ValueT> >

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Tree.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Tree.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Tree.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Tree.h Sat Jun 10 05:26:41 2006
@@ -40,6 +40,8 @@
         child = chd;
     }
 
+    virtual ~TreeNode() {}
+
     virtual void print(::std::ostream& os) { os << "T"; }
     virtual void printTag(::std::ostream& os) { print(os); }
 
@@ -148,7 +150,7 @@
     Tree(): root(NULL) {}
     TreeNode* getRoot() {return root;}
 
-    virtual void Tree::printDotFile(MethodDesc& mh, char *suffix) {
+    virtual void printDotFile(MethodDesc& mh, char *suffix) {
         if (root == NULL) return;
         PrintDotFile::printDotFile(mh,suffix);
     }

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Type.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Type.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Type.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/Type.h Sat Jun 10 05:26:41 2006
@@ -147,6 +147,7 @@
 		InavlidTag = NumTypeTags
     };
     Type(Tag t) : tag(t), id(++nextTypeId) {}
+    virtual ~Type() {}
     const Tag tag;
     bool    isBuiltinValue()   {return isBuiltinValue(tag); }
     bool    isNumeric()        {return isNumeric(tag);      }
@@ -369,6 +370,7 @@
     PtrType(Type* t,bool isManagedPtr,ValueName array=NULL, ValueName index=NULL) 
         : Type(isManagedPtr ? ManagedPtr : UnmanagedPtr), pointedToType(t), array(array), index(index) {}
     PtrType* asPtrType() { return this; }
+    virtual ~PtrType() {}
     Type*   getPointedToType()            {return pointedToType;}
     ValueName getArrayName() { return array; }
     ValueName getIndexName() { return index; }
@@ -383,6 +385,7 @@
 public:
     FunctionPtrType(bool isCompressed=false) : Type(isCompressed ? CompressedMethodPtr : MethodPtr) { }
     FunctionPtrType* asFunctionPtrType() { return this; }
+    virtual ~FunctionPtrType() {}
     virtual uint32 getNumParams() = 0;
     virtual Type* getParamType(uint32) = 0;
     virtual Type* getReturnType() = 0;
@@ -393,6 +396,7 @@
 public:
     MethodPtrType(MethodDesc* md, TypeManager& tm, bool isCompressed=false, ValueName obj=NULL) 
         : FunctionPtrType(isCompressed), methodDesc(md), methodSig(md->getMethodSig()), typeManager(tm), object(obj) {}
+    virtual ~MethodPtrType() {}
     MethodPtrType* asMethodPtrType() { return this; }
     uint32 getNumParams() { return methodSig->getNumParams(); }
     Type* getParamType(uint32 i);
@@ -412,6 +416,7 @@
 public:
     VTablePtrType(Type* t, bool isCompressed=false) : Type(isCompressed? CompressedVTablePtr : VTablePtr), 
                                                       baseType(t) {}
+    virtual ~VTablePtrType() {}
     Type*          getBaseType()            {return baseType;}
     virtual void   print(::std::ostream& os);
 private:
@@ -429,6 +434,7 @@
 public:
     NamedType(Tag t, void* td, TypeManager& tm) 
         : Type(t), vmTypeHandle(td), typeManager(tm) {}
+    virtual ~NamedType() {}
 
     NamedType* asNamedType() { return this; }
     bool needsInitialization();
@@ -452,11 +458,13 @@
 class ValueType : public Type {
 public:
     ValueType(Tag t) : Type(t) {}
+    virtual ~ValueType() {}
 };
 
 class UserValueType : public NamedType {
 public:
     UserValueType(void* td,TypeManager& tm) : NamedType(Value,td,tm) {}
+    virtual ~UserValueType() {}
     virtual const char* getName();
     virtual const char* getNameQualifier();
     //
@@ -626,6 +634,7 @@
 class TypeManager {
 public:
     TypeManager(MemoryManager& mm);
+    virtual ~TypeManager() {}
     void    init(CompilationInterface &compInt);
     void    init();
     MemoryManager&  getMemManager()        {return memManager;}

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/ByteCodeParser.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/ByteCodeParser.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/ByteCodeParser.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/ByteCodeParser.h Sat Jun 10 05:26:41 2006
@@ -30,6 +30,7 @@
 
 class ByteCodeParserCallback {
 public:
+    virtual ~ByteCodeParserCallback() {}
     // parses one byte code starting at given offset,
     // updates nextOffset to point at next byte code,
     // returns false if parsing should stop

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/ExceptionInfo.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/ExceptionInfo.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/ExceptionInfo.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/ExceptionInfo.h Sat Jun 10 05:26:41 2006
@@ -29,6 +29,7 @@
 
 class ExceptionInfo {
 public:
+    virtual ~ExceptionInfo() {}
     uint32  getId()            {return id;}
     uint32  getBeginOffset(){return beginOffset;}
     uint32  getEndOffset()    {return endOffset;}
@@ -65,6 +66,7 @@
             uint32 endOffset,
             ExceptionInfo* _tryBlock) 
     : ExceptionInfo(id,beginOffset,endOffset), tryBlock(_tryBlock) {}
+    virtual ~Handler() {}
     uint32 getTryRegionId()            {return tryBlock->getId();}
     ExceptionInfo* getTryBlock()    {return tryBlock;}
 private:
@@ -81,6 +83,7 @@
                  uint32 endOffset,
                  CatchBlock* tryBlock,
                  Type* excType);
+    virtual ~CatchHandler() {}
 
     Type*          getExceptionType()              {return exceptionType;}
     uint32         getExceptionOrder()             {return order;        }
@@ -101,6 +104,7 @@
                uint32 endOffset,
                uint32 exceptionIndex) 
     : ExceptionInfo(id,beginOffset,endOffset), handlers(NULL), excTableIndex(exceptionIndex) {}
+    virtual ~CatchBlock() {}
     bool isCatchBlock()                {return true;}
     uint32 getExcTableIndex() { return excTableIndex; }
     void addHandler(CatchHandler* handler) {

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/TranslatorIntfc.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/TranslatorIntfc.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/TranslatorIntfc.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/TranslatorIntfc.h Sat Jun 10 05:26:41 2006
@@ -64,6 +64,8 @@
 
 class TranslatorIntfc {
 public:
+
+    virtual ~TranslatorIntfc() {}
     
     // all TranslatorIntfc::flags fields are initialized by readTranslatorCommandLineParams()
     static void readFlagsFromCommandLine(CompilationContext* cs, bool ia32Cg);

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/java/JavaLabelPrepass.cpp
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/java/JavaLabelPrepass.cpp?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/java/JavaLabelPrepass.cpp (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/java/JavaLabelPrepass.cpp Sat Jun 10 05:26:41 2006
@@ -1123,6 +1123,9 @@
 
 void JavaLabelPrepass::new_(uint32 constPoolIndex)         { 
     StateInfo::SlotInfo slot;
+    slot.slotFlags = 0;
+    slot.varNumber = 0;
+    slot.jsrLabelOffset = 0;
     StateInfo::setNonNull(&slot);
     StateInfo::setExactType(&slot);
     Type* nType = resolveTypeNew(constPoolIndex);
@@ -1162,6 +1165,10 @@
 void JavaLabelPrepass::anewarray(uint32 constPoolIndex)    { 
     popAndCheck(int32Type); 
     StateInfo::SlotInfo slot;
+    slot.slotFlags = 0;
+    slot.varNumber = 0;
+    slot.jsrLabelOffset = 0;
+
     StateInfo::setNonNull(&slot);
     StateInfo::setExactType(&slot);
     Type* type = resolveType(constPoolIndex);

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/java/JavaLabelPrepass.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/java/JavaLabelPrepass.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/java/JavaLabelPrepass.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/translator/java/JavaLabelPrepass.h Sat Jun 10 05:26:41 2006
@@ -128,6 +128,7 @@
         uint16 slotFlags;
         SlotVar *vars;
         uint32 jsrLabelOffset;
+	SlotInfo() : type(0), varNumber(0), slotFlags(0), vars(0), jsrLabelOffset(0) {}
     };
 
     // remove all slots containing returnAddress for RET instruction with jsrNexOffset == offset
@@ -272,7 +273,7 @@
     StateInfo*              getStateInfo()  { return &stateInfo; }
     StateTable*             getStateTable() { return stateTable; }
 
-    static JavaLabelPrepass::JavaVarType JavaLabelPrepass::getJavaType(Type *type) {
+    static JavaVarType getJavaType(Type *type) {
         assert(type);
         switch(type->tag) {
         case Type::Boolean:  case Type::Char:

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/vm/VMInterface.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/vm/VMInterface.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/vm/VMInterface.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/vm/VMInterface.h Sat Jun 10 05:26:41 2006
@@ -56,6 +56,8 @@
 
 class ExceptionCallback {
 public:
+
+    virtual ~ExceptionCallback() {}
     virtual void catchBlock(uint32 tryOffset,
                             uint32 tryLength,
                             uint32 handlerOffset,
@@ -81,6 +83,7 @@
 //
 class MethodSignatureDesc {
 public:
+    virtual ~MethodSignatureDesc() {}
     virtual uint32   getNumParams()                  = 0;
     virtual Type**   getParamTypes()                 = 0;
     virtual Type*    getParamType(uint32 paramIndex) = 0;
@@ -89,6 +92,7 @@
 
 class TypeMemberDesc {
 public:
+    virtual ~TypeMemberDesc() {}
     virtual const char* getName()            = 0;
     virtual const char* getSignatureString() = 0;
 	virtual void  printFullName(::std::ostream& os) = 0;
@@ -100,6 +104,7 @@
 
 class FieldDesc : public TypeMemberDesc {
 public:
+    virtual ~FieldDesc() {}
     //
     // this field is constant after it is initialized
     // can only be mutated by constructor (instance fields) or
@@ -120,6 +125,7 @@
 
 class MethodDesc : public TypeMemberDesc {
 public:
+    virtual ~MethodDesc() {}
     virtual bool isNative()              = 0;
     virtual bool isSynchronized()        = 0;
     virtual bool isNoInlining()          = 0;
@@ -206,6 +212,7 @@
 
 class ClassHierarchyIterator {
 public:
+    virtual ~ClassHierarchyIterator() {}
     virtual bool isValid() = 0; // true if iterator is valid
     virtual bool hasNext() = 0; // true if iterator is not done 
     virtual ObjectType* getNext() = 0; // return next class in iterator and advance iterator
@@ -213,6 +220,7 @@
 
 class ClassHierarchyMethodIterator {
 public:
+    virtual ~ClassHierarchyMethodIterator() {}
     virtual bool hasNext() = 0; // true if iterator is not done 
     virtual MethodDesc* getNext() = 0; // return next class in iterator and advance iterator
 };
@@ -220,6 +228,7 @@
 
 class CompilationInterface {
 public:
+    virtual ~CompilationInterface() {}
     virtual TypeManager&  getTypeManager() = 0;
     //
     // returns the method to compile
@@ -541,6 +550,7 @@
 
 class DataInterface {
 public:
+    virtual ~DataInterface() {}
     //
     // returns true if instance fields that are references are compressed
     //
@@ -554,6 +564,7 @@
 
 class GCInterface {
 public:
+    virtual ~GCInterface() {}
     virtual void enumerateRootReference(void** reference) = 0;
     virtual void enumerateCompressedRootReference(uint32* reference) = 0;
     virtual void enumerateRootManagedReference(void** slotReference, int slotOffset) = 0;
@@ -565,11 +576,13 @@
 
 class BinaryRewritingInterface {
 public:
+    virtual ~BinaryRewritingInterface() {}
     virtual void rewriteCodeBlock(Byte* codeBlock, Byte* newCode, size_t length) = 0;
 };
 
 class Compiler {
 public:
+    virtual ~Compiler() {}
     //
     //  Return true if the method has been successfully compiled,
     //  false - otherwise
@@ -596,7 +609,7 @@
 
 class ProfilingInterface {
 public:
-    virtual ~ProfilingInterface(){};
+    virtual ~ProfilingInterface() {}
     
     virtual MethodProfile* getMethodProfile(MemoryManager& mm, ProfileType type, MethodDesc& md, JITProfilingRole role=JITProfilingRole_USE) const = 0;
     virtual bool hasMethodProfile(ProfileType type, MethodDesc& md, JITProfilingRole role=JITProfilingRole_USE) const = 0;

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/vm/drl/DrlVMInterface.h
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/vm/drl/DrlVMInterface.h?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/vm/drl/DrlVMInterface.h (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/vm/drl/DrlVMInterface.h Sat Jun 10 05:26:41 2006
@@ -148,6 +148,7 @@
        case VM_DATA_TYPE_F4:      return getSingleType();
        case VM_DATA_TYPE_BOOLEAN: return getBooleanType();
        case VM_DATA_TYPE_CHAR:    return getCharType();
+       default: assert(0);
        }
        return NULL;
     }

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/vmcore/src/class_support/Class_File_Loader.cpp
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/vmcore/src/class_support/Class_File_Loader.cpp?rev=413288&r1=413287&r2=413288&view=diff
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/vmcore/src/class_support/Class_File_Loader.cpp (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/vmcore/src/class_support/Class_File_Loader.cpp Sat Jun 10 05:26:41 2006
@@ -530,14 +530,19 @@
 bool Handler::parse(Const_Pool* cp, unsigned cp_size, unsigned code_length,
                     ByteReader &cfs)
 {
-    if(!cfs.parse_u2_be((uint16*)&_start_pc))
+    uint16 start = 0;
+    if(!cfs.parse_u2_be(&start))
         return false;
 
+    _start_pc = (unsigned) start;
+
     if (_start_pc >= code_length)
         return false;
 
-    if (!cfs.parse_u2_be((uint16 *)&_end_pc))
+    uint16 end;
+    if (!cfs.parse_u2_be(&end))
         return false;
+    _end_pc = (unsigned) end;
 
     if (_end_pc > code_length)
         return false;
@@ -545,8 +550,10 @@
     if (_start_pc >= _end_pc)
         return false;
 
-    if (!cfs.parse_u2_be((uint16 *)&_handler_pc))
+    uint16 handler;
+    if (!cfs.parse_u2_be(&handler))
         return false;
+    _handler_pc = (unsigned) handler;
 
     if (_handler_pc >= code_length)
         return false;



Mime
View raw message