LOGIN   :::   RECOVER PASS   :::   GET ACCOUNT    
Browse
  • Projects
  • Code (CVS)
  • Forums
  • News
  • Articles
  • Polls
  •  
    OpenCores
  • FAQ
  • CVS HowTo
  • Mission
  • Media
  • Tools
  • Advertise
  • Mirrors
  • Logos
  • Contact us
  • Job Opportunity
  •  
    Tools
  • Search
      
  • Download Cores (CVSGet)
  •  
    More
  • Wishbone
  • Perlilog
  • EDA tools
  • OpenTech CD
  •  
    Navigation: All forums > Cvs-checkins > Message List > Message Post

    Message

    Reply | Reply all
    Date Prev | Date Next | Thread Prev | Thread Next Date Index | Thread Index

    From: cvs at opencores.org<cvs@o...>
    Date: Tue Feb 26 21:18:37 CET 2008
    Subject: [cvs-checkins] MODIFIED: jop ...
    Top
    Date: 00/08/02 26:21:18

    Modified: jop/java/tools/src/joptimizer/config ArchConfig.java
    jvm-arch.properties jop-arch.properties
    Log:
    load maxsizes and ramcycles from configfile too


    Revision Changes Path
    1.5 jop/java/tools/src/joptimizer/config/ArchConfig.java

    http://www.opencores.org/cvsweb.shtml/jop/java/tools/src/joptimizer/config/ArchConfig.java.diff?r1=1.4&r2=1.5

    (In the diff below, changes in quantity of whitespace are not shown.)

    Index: ArchConfig.java
    ===================================================================
    RCS file: /cvsroot/stefant/jop/java/tools/src/joptimizer/config/ArchConfig.java,v
    retrieving revision 1.4
    retrieving revision 1.5
    diff -u -b -r1.4 -r1.5
    --- ArchConfig.java 25 Feb 2008 23:30:40 -0000 1.4
    +++ ArchConfig.java 26 Feb 2008 20:18:37 -0000 1.5
    @@ -37,11 +37,26 @@
    private ArchTiming timing;
    private Set systemClasses;
    private String nativeClass;
    + private int maxMethodSize;
    + private int maxLocalVars;
    + private int maxStackSize;
    + private int ramReadCycles;
    + private int ramWriteCycles;

    public static final String CONF_SYSTEM_CLASSES = "systemclasses";

    public static final String CONF_NATIVE_CLASS = "nativeclass";

    + public static final String CONF_MAX_METHOD_SIZE = "maxmethodsize";
    +
    + public static final String CONF_MAX_LOCALS = "maxlocalvars";
    +
    + public static final String CONF_MAX_STACK_SIZE = "maxstacksize";
    +
    + public static final String CONF_RAM_READ_CYCLES = "ramreadcycles";
    +
    + public static final String CONF_RAM_WRITE_CYCLES = "ramwritecycles";
    +
    public ArchConfig() {
    systemClasses = Collections.EMPTY_SET;
    nativeClass = "";
    @@ -73,23 +88,23 @@
    }

    public int getMaxMethodSize() {
    - return 256;
    + return maxMethodSize;
    }

    public int getMaxLocalVars() {
    - return 31;
    + return maxLocalVars;
    }

    public int getMaxStackSize() {
    - return 31;
    + return maxStackSize;
    }

    public int getRamReadCycles() {
    - return 2;
    + return ramReadCycles;
    }

    public int getRamWriteCycles() {
    - return 2;
    + return ramWriteCycles;
    }

    private void loadConfig(URL config) throws ConfigurationException {
    @@ -118,5 +133,24 @@
    nativeClass = "";
    }

    + maxMethodSize = loadIntConfig(props, CONF_MAX_METHOD_SIZE, 65535);
    + maxLocalVars = loadIntConfig(props, CONF_MAX_LOCALS, 1024);
    + maxStackSize = loadIntConfig(props, CONF_MAX_STACK_SIZE, 1024);
    + ramReadCycles = loadIntConfig(props, CONF_RAM_READ_CYCLES, 1);
    + ramWriteCycles = loadIntConfig(props, CONF_RAM_WRITE_CYCLES, 1);
    + }
    +
    + private int loadIntConfig(Properties props, String name, int defaultValue) throws ConfigurationException {
    +
    + Object val = props.get(name);
    + if ( val == null ) {
    + return defaultValue;
    + }
    +
    + try {
    + return Integer.parseInt(String.valueOf(val));
    + } catch (NumberFormatException e) {
    + throw new ConfigurationException("Invalid number {"+val+"} for key {"+name+"}.");
    + }
    } } 1.2 jop/java/tools/src/joptimizer/config/jvm-arch.properties http://www.opencores.org/cvsweb.shtml/jop/java/tools/src/joptimizer/config/jvm-arch.properties.diff?r1=1.1&r2=1.2 (In the diff below, changes in quantity of whitespace are not shown.) Index: jvm-arch.properties =================================================================== RCS file: /cvsroot/stefant/jop/java/tools/src/joptimizer/config/jvm-arch.properties,v retrieving revision 1.1 retrieving revision 1.2 diff -u -b -r1.1 -r1.2 --- jvm-arch.properties 25 Feb 2008 02:49:21 -0000 1.1 +++ jvm-arch.properties 26 Feb 2008 20:18:37 -0000 1.2 @@ -18,3 +18,8 @@ # systemclasses= nativeclass= +maxmethodsize=65535 +maxlocalvars=1024 +maxstacksize=1024 +ramreadcycles=1 +ramwritecycles=1 1.2 jop/java/tools/src/joptimizer/config/jop-arch.properties http://www.opencores.org/cvsweb.shtml/jop/java/tools/src/joptimizer/config/jop-arch.properties.diff?r1=1.1&r2=1.2 (In the diff below, changes in quantity of whitespace are not shown.) Index: jop-arch.properties =================================================================== RCS file: /cvsroot/stefant/jop/java/tools/src/joptimizer/config/jop-arch.properties,v retrieving revision 1.1 retrieving revision 1.2 diff -u -b -r1.1 -r1.2 --- jop-arch.properties 25 Feb 2008 02:49:21 -0000 1.1 +++ jop-arch.properties 26 Feb 2008 20:18:37 -0000 1.2 @@ -18,4 +18,8 @@ # systemclasses=com.jopdesign.sys.JVMHelp,com.jopdesign.sys.JVM,com.jopdesign.sys.Startup nativeclass=com.jopdesign.sys.Native - +maxmethodsize=255 +maxlocalvars=31 +maxstacksize=31 +ramreadcycles=2 +ramwritecycles=2

     
    Copyright (c) 1999 OPENCORES.ORG. All rights reserved.