OpenCores
URL https://opencores.org/ocsvn/openmsp430/openmsp430/trunk

Subversion Repositories openmsp430

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /openmsp430/trunk/core/sim
    from Rev 142 to Rev 145
    Reverse comparison

Rev 142 → Rev 145

/rtl_sim/run/run_c
1,5 → 1,9
#!/bin/bash
 
###############################################################################
# Configuration #
###############################################################################
 
# Enable/Disable waveform dumping
OMSP_NODUMP=0
export OMSP_NODUMP
14,6 → 18,35
OMSP_SIMULATOR=iverilog
export OMSP_SIMULATOR
 
###############################################################################
# Parameter Check #
###############################################################################
EXPECTED_ARGS=1
if [ $# -ne $EXPECTED_ARGS ]; then
echo "ERROR : wrong number of arguments"
echo "USAGE : run_c <test name>"
echo "Example : run_c sandbox"
echo ""
echo "Available tests:"
echo -ne " "
ls ../src-c/
echo ""
exit 1
fi
 
../bin/msp430sim_c sandbox
###############################################################################
# Check if the required files exist #
###############################################################################
softdir=../src-c/$1;
 
if [ ! -e $softdir ]; then
echo "ERROR: test directory doesn't exist: $softdir"
echo ""
echo "Available tests:"
echo -ne " "
ls ../src-c/
echo ""
exit 1
fi
 
../bin/msp430sim_c $1
/rtl_sim/src/ldscript_example.x
1,146 → 1,185
/* Default linker script, for normal executables */
OUTPUT_FORMAT("elf32-msp430","elf32-msp430","elf32-msp430")
OUTPUT_FORMAT("elf32-msp430")
OUTPUT_ARCH("msp430")
MEMORY
{
text (rx) : ORIGIN = 0xf800, LENGTH = 2048
data (rwx) : ORIGIN = 0x0200, LENGTH = 128
vectors (rw) : ORIGIN = 0xffe0, LENGTH = 32
MEMORY {
sfr : ORIGIN = 0x0000, LENGTH = 0x0010
peripheral_8bit : ORIGIN = 0x0010, LENGTH = 0x00f0
peripheral_16bit : ORIGIN = 0x0100, LENGTH = 0x0100
 
ram (wx) : ORIGIN = 0x0200, LENGTH = 128
rom (rx) : ORIGIN = 0xf800, LENGTH = 2048-32
 
vectors : ORIGIN = 0xffe0, LENGTH = 32
 
/* Remaining banks are absent */
bsl : ORIGIN = 0x0000, LENGTH = 0x0000
infomem : ORIGIN = 0x0000, LENGTH = 0x0000
infob : ORIGIN = 0x0000, LENGTH = 0x0000
infoa : ORIGIN = 0x0000, LENGTH = 0x0000
infoc : ORIGIN = 0x0000, LENGTH = 0x0000
infod : ORIGIN = 0x0000, LENGTH = 0x0000
ram2 (wx) : ORIGIN = 0x0000, LENGTH = 0x0000
ram_mirror (wx) : ORIGIN = 0x0000, LENGTH = 0x0000
usbram (wx) : ORIGIN = 0x0000, LENGTH = 0x0000
far_rom : ORIGIN = 0x00000000, LENGTH = 0x00000000
}
REGION_ALIAS("REGION_TEXT", rom);
REGION_ALIAS("REGION_DATA", ram);
REGION_ALIAS("REGION_FAR_ROM", far_rom);
__WDTCTL = 0x0120;
__MPY = 0x0130;
__MPYS = 0x0132;
__MAC = 0x0134;
__MACS = 0x0136;
__OP2 = 0x0138;
__RESLO = 0x013A;
__RESHI = 0x013C;
__SUMEXT = 0x013E;
 
SECTIONS
{
PROVIDE (__stack = 0x0280) ;
 
/* Read-only sections, merged into text segment. */
.hash : { *(.hash) }
.dynsym : { *(.dynsym) }
.dynstr : { *(.dynstr) }
.gnu.version : { *(.gnu.version) }
.gnu.version_d : { *(.gnu.version_d) }
.gnu.version_r : { *(.gnu.version_r) }
.rel.init : { *(.rel.init) }
.hash : { *(.hash) }
.dynsym : { *(.dynsym) }
.dynstr : { *(.dynstr) }
.gnu.version : { *(.gnu.version) }
.gnu.version_d : { *(.gnu.version_d) }
.gnu.version_r : { *(.gnu.version_r) }
.rel.init : { *(.rel.init) }
.rela.init : { *(.rela.init) }
.rel.text :
{
*(.rel.text)
*(.rel.text.*)
*(.rel.gnu.linkonce.t*)
}
.rela.text :
{
*(.rela.text)
*(.rela.text.*)
*(.rela.gnu.linkonce.t*)
}
.rel.fini : { *(.rel.fini) }
.rel.fini : { *(.rel.fini) }
.rela.fini : { *(.rela.fini) }
.rel.rodata :
{
*(.rel.rodata)
*(.rel.rodata.*)
*(.rel.gnu.linkonce.r*)
}
.rela.rodata :
{
*(.rela.rodata)
*(.rela.rodata.*)
*(.rela.gnu.linkonce.r*)
}
.rel.data :
{
*(.rel.data)
*(.rel.data.*)
*(.rel.gnu.linkonce.d*)
}
.rela.data :
{
*(.rela.data)
*(.rela.data.*)
*(.rela.gnu.linkonce.d*)
}
.rel.ctors : { *(.rel.ctors) }
.rela.ctors : { *(.rela.ctors) }
.rel.dtors : { *(.rel.dtors) }
.rela.dtors : { *(.rela.dtors) }
.rel.got : { *(.rel.got) }
.rela.got : { *(.rela.got) }
.rel.bss : { *(.rel.bss) }
.rela.bss : { *(.rela.bss) }
.rel.plt : { *(.rel.plt) }
.rela.plt : { *(.rela.plt) }
/* Internal text space. */
.rel.text : { *(.rel.text .rel.text.* .rel.gnu.linkonce.t.*) }
.rela.text : { *(.rela.text .rela.text.* .rela.gnu.linkonce.t.*) }
.rel.rodata : { *(.rel.rodata .rel.rodata.* .rel.gnu.linkonce.r.*) }
.rela.rodata : { *(.rela.rodata .rela.rodata.* .rela.gnu.linkonce.r.*) }
.rel.data : { *(.rel.data .rel.data.* .rel.gnu.linkonce.d.*) }
.rela.data : { *(.rela.data .rela.data.* .rela.gnu.linkonce.d.*) }
.rel.bss : { *(.rel.bss .rel.bss.* .rel.gnu.linkonce.b.*) }
.rela.bss : { *(.rela.bss .rela.bss.* .rela.gnu.linkonce.b.*) }
.rel.ctors : { *(.rel.ctors) }
.rela.ctors : { *(.rela.ctors) }
.rel.dtors : { *(.rel.dtors) }
.rela.dtors : { *(.rela.dtors) }
.rel.got : { *(.rel.got) }
.rela.got : { *(.rela.got) }
.rel.plt : { *(.rel.plt) }
.rela.plt : { *(.rela.plt) }
.text :
{
. = ALIGN(2);
*(.init)
*(.init0) /* Start here after reset. */
*(.init1)
*(.init2) /* Copy data loop */
*(.init3)
*(.init4) /* Clear bss */
*(.init5)
*(.init6) /* C++ constructors. */
*(.init7)
*(.init8)
*(.init9) /* Call main(). */
. = ALIGN(2);
KEEP(*(.init .init.*))
KEEP(*(.init0)) /* Start here after reset. */
KEEP(*(.init1)) /* User definable. */
KEEP(*(.init2)) /* Initialize stack. */
KEEP(*(.init3)) /* Initialize hardware, user definable. */
KEEP(*(.init4)) /* Copy data to .data, clear bss. */
KEEP(*(.init5)) /* User definable. */
KEEP(*(.init6)) /* C++ constructors. */
KEEP(*(.init7)) /* User definable. */
KEEP(*(.init8)) /* User definable. */
KEEP(*(.init9)) /* Call main(). */
KEEP(*(.fini9)) /* Falls into here after main(). User definable. */
KEEP(*(.fini8)) /* User definable. */
KEEP(*(.fini7)) /* User definable. */
KEEP(*(.fini6)) /* C++ destructors. */
KEEP(*(.fini5)) /* User definable. */
KEEP(*(.fini4)) /* User definable. */
KEEP(*(.fini3)) /* User definable. */
KEEP(*(.fini2)) /* User definable. */
KEEP(*(.fini1)) /* User definable. */
KEEP(*(.fini0)) /* Infinite loop after program termination. */
KEEP(*(.fini .fini.*))
. = ALIGN(2);
__ctors_start = . ;
*(.ctors)
KEEP(*(.ctors))
__ctors_end = . ;
__dtors_start = . ;
*(.dtors)
KEEP(*(.dtors))
__dtors_end = . ;
. = ALIGN(2);
*(.text)
. = ALIGN(2);
*(.text.*)
. = ALIGN(2);
*(.fini9) /* */
*(.fini8)
*(.fini7)
*(.fini6) /* C++ destructors. */
*(.fini5)
*(.fini4)
*(.fini3)
*(.fini2)
*(.fini1)
*(.fini0) /* Infinite loop after program termination. */
*(.fini)
_etext = . ;
} > text
.data : AT (ADDR (.text) + SIZEOF (.text))
. = ALIGN(2);
*(.text .text.* .gnu.linkonce.t.*)
. = ALIGN(2);
} > REGION_TEXT
.rodata :
{
. = ALIGN(2);
*(.rodata .rodata.* .gnu.linkonce.r.*)
. = ALIGN(2);
} > REGION_TEXT
_etext = .; /* Past last read-only (loadable) segment */
.data :
{
. = ALIGN(2);
PROVIDE (__data_start = .) ;
. = ALIGN(2);
*(.data)
. = ALIGN(2);
*(.gnu.linkonce.d*)
. = ALIGN(2);
_edata = . ;
} > data
.bss SIZEOF(.data) + ADDR(.data) :
*(.data .data.* .gnu.linkonce.d.*)
. = ALIGN(2);
_edata = . ; /* Past last read-write (loadable) segment */
} > REGION_DATA AT > REGION_TEXT
PROVIDE (__data_load_start = LOADADDR(.data) );
PROVIDE (__data_size = SIZEOF(.data) );
.bss :
{
PROVIDE (__bss_start = .) ;
*(.bss)
*(.bss .bss.*)
*(COMMON)
. = ALIGN(2);
PROVIDE (__bss_end = .) ;
_end = . ;
} > data
.noinit SIZEOF(.bss) + ADDR(.bss) :
} > REGION_DATA
PROVIDE (__bss_size = SIZEOF(.bss) );
.noinit :
{
PROVIDE (__noinit_start = .) ;
*(.noinit)
*(COMMON)
*(.noinit .noinit.*)
. = ALIGN(2);
PROVIDE (__noinit_end = .) ;
_end = . ;
} > data
} > REGION_DATA
. = ALIGN(2);
_end = . ; /* Past last write (loadable) segment */
.infomem :
{
*(.infomem)
. = ALIGN(2);
*(.infomem.*)
} > infomem
.infomemnobits :
{
*(.infomemnobits)
. = ALIGN(2);
*(.infomemnobits.*)
} > infomem
.infoa :
{
*(.infoa .infoa.*)
} > infoa
.infob :
{
*(.infob .infob.*)
} > infob
.infoc :
{
*(.infoc .infoc.*)
} > infoc
.infod :
{
*(.infod .infod.*)
} > infod
.vectors :
{
PROVIDE (__vectors_start = .) ;
*(.vectors*)
KEEP(*(.vectors*))
_vectors_end = . ;
} > vectors
.fartext :
{
. = ALIGN(2);
*(.fartext)
. = ALIGN(2);
*(.fartext.*)
_efartext = .;
} > REGION_FAR_ROM
/* Stabs for profiling information*/
.profiler 0 : { *(.profiler) }
/* Stabs debugging sections. */
.stab 0 : { *(.stab) }
.stabstr 0 : { *(.stabstr) }
169,8 → 208,10
.debug_str 0 : { *(.debug_str) }
.debug_loc 0 : { *(.debug_loc) }
.debug_macinfo 0 : { *(.debug_macinfo) }
PROVIDE (__data_start_rom = _etext) ;
PROVIDE (__data_end_rom = _etext + SIZEOF (.data)) ;
PROVIDE (__noinit_start_rom = _etext + SIZEOF (.data)) ;
PROVIDE (__noinit_end_rom = _etext + SIZEOF (.data) + SIZEOF (.noinit)) ;
/* DWARF 3 */
.debug_pubtypes 0 : { *(.debug_pubtypes) }
.debug_ranges 0 : { *(.debug_ranges) }
PROVIDE (__stack = ORIGIN(ram) + LENGTH(ram));
PROVIDE (__data_start_rom = _etext);
PROVIDE (__data_end_rom = _etext + SIZEOF (.data));
}
/rtl_sim/src-c/dhrystone_v2.1/omsp_func.h
0,0 → 1,124
/*===========================================================================*/
/* Copyright (C) 2001 Authors */
/* */
/* This source file may be used and distributed without restriction provided */
/* that this copyright statement is not removed from the file and that any */
/* derivative work contains the original copyright notice and the associated */
/* disclaimer. */
/* */
/* This source file is free software; you can redistribute it and/or modify */
/* it under the terms of the GNU Lesser General Public License as published */
/* by the Free Software Foundation; either version 2.1 of the License, or */
/* (at your option) any later version. */
/* */
/* This source is distributed in the hope that it will be useful, but WITHOUT*/
/* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */
/* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */
/* License for more details. */
/* */
/* You should have received a copy of the GNU Lesser General Public License */
/* along with this source; if not, write to the Free Software Foundation, */
/* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */
/* */
/*===========================================================================*/
/* OMSP_FUNC HEADER FILE */
/*---------------------------------------------------------------------------*/
/* */
/* Author(s): */
/* - Olivier Girard, olgirard@gmail.com */
/* */
/*---------------------------------------------------------------------------*/
/* $Rev: 19 $ */
/* $LastChangedBy: olivier.girard $ */
/* $LastChangedDate: 2009-08-04 23:47:15 +0200 (Tue, 04 Aug 2009) $ */
/*===========================================================================*/
 
//=============================================================================
// PERIPHERALS REGISTER DEFINITIONS
//=============================================================================
 
//----------------------------------------------------------
// SPECIAL FUNCTION REGISTERS
//----------------------------------------------------------
#define IE1 (*(volatile unsigned char *) 0x0000)
#define IFG1 (*(volatile unsigned char *) 0x0002)
 
#define CPU_ID_LO (*(volatile unsigned char *) 0x0004)
#define CPU_ID_HI (*(volatile unsigned char *) 0x0006)
 
 
//----------------------------------------------------------
// GPIOs
//----------------------------------------------------------
#define P1IN (*(volatile unsigned char *) 0x0020)
#define P1OUT (*(volatile unsigned char *) 0x0021)
#define P1DIR (*(volatile unsigned char *) 0x0022)
#define P1IFG (*(volatile unsigned char *) 0x0023)
#define P1IES (*(volatile unsigned char *) 0x0024)
#define P1IE (*(volatile unsigned char *) 0x0025)
#define P1SEL (*(volatile unsigned char *) 0x0026)
 
#define P2IN (*(volatile unsigned char *) 0x0028)
#define P2OUT (*(volatile unsigned char *) 0x0029)
#define P2DIR (*(volatile unsigned char *) 0x002A)
#define P2IFG (*(volatile unsigned char *) 0x002B)
#define P2IES (*(volatile unsigned char *) 0x002C)
#define P2IE (*(volatile unsigned char *) 0x002D)
#define P2SEL (*(volatile unsigned char *) 0x002E)
 
#define P3IN (*(volatile unsigned char *) 0x0018)
#define P3OUT (*(volatile unsigned char *) 0x0019)
#define P3DIR (*(volatile unsigned char *) 0x001A)
#define P3SEL (*(volatile unsigned char *) 0x001B)
 
#define P4IN (*(volatile unsigned char *) 0x001C)
#define P4OUT (*(volatile unsigned char *) 0x001D)
#define P4DIR (*(volatile unsigned char *) 0x001E)
#define P4SEL (*(volatile unsigned char *) 0x001F)
 
#define P5IN (*(volatile unsigned char *) 0x0030)
#define P5OUT (*(volatile unsigned char *) 0x0031)
#define P5DIR (*(volatile unsigned char *) 0x0032)
#define P5SEL (*(volatile unsigned char *) 0x0033)
 
#define P6IN (*(volatile unsigned char *) 0x0034)
#define P6OUT (*(volatile unsigned char *) 0x0035)
#define P6DIR (*(volatile unsigned char *) 0x0036)
#define P6SEL (*(volatile unsigned char *) 0x0037)
 
 
//----------------------------------------------------------
// WATCHDOG TIMER
//----------------------------------------------------------
 
// Addresses
#define WDTCTL (*(volatile unsigned int *) 0x0120)
 
// Bit masks
#define WDTIS0 (0x0001)
#define WDTIS1 (0x0002)
#define WDTSSEL (0x0004)
#define WDTCNTCL (0x0008)
#define WDTTMSEL (0x0010)
#define WDTNMI (0x0020)
#define WDTNMIES (0x0040)
#define WDTHOLD (0x0080)
#define WDTPW (0x5A00)
 
 
//=============================================================================
// MACROS
//=============================================================================
 
#define STOP_WATCHDOG WDTCTL = WDTPW | WDTHOLD
 
#define START_TIME P3OUT = 0x01
#define END_TIME P3OUT = 0x00
 
#define DHRYSTONE_DONE P4OUT = 0x01
 
//=============================================================================
// FUNCTIONS
//=============================================================================
 
int putchar (int txdata);
rtl_sim/src-c/dhrystone_v2.1/omsp_func.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/doc/reu05b0134_rxap.pdf =================================================================== Cannot display: file marked as a binary type. svn:mime-type = application/octet-stream Index: rtl_sim/src-c/dhrystone_v2.1/doc/reu05b0134_rxap.pdf =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/doc/reu05b0134_rxap.pdf (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/doc/reu05b0134_rxap.pdf (revision 145)
rtl_sim/src-c/dhrystone_v2.1/doc/reu05b0134_rxap.pdf Property changes : Added: svn:mime-type ## -0,0 +1 ## +application/octet-stream \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/cc_dry2reg =================================================================== Cannot display: file marked as a binary type. svn:mime-type = application/octet-stream Index: rtl_sim/src-c/dhrystone_v2.1/original_files/cc_dry2reg =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/cc_dry2reg (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/cc_dry2reg (revision 145)
rtl_sim/src-c/dhrystone_v2.1/original_files/cc_dry2reg Property changes : Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +application/octet-stream \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/README.RER =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/README.RER (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/README.RER (revision 145) @@ -0,0 +1,126 @@ +12/04/88 + +Here is Reinhold Weicker's DHRYSTONE 2.1 benchmark, slightly modified +by me for instrumentation purposes only. This is an integer CPU +benchmark. The differences between 2.0 and 2.1 are minor, and +I believe that 2.0 and 2.1 results are comparable. + +For purists, I've enclosed context diffs to turn what I'm posting +as 2.1 back into what Reinhold sent me as 2.1. The changes +are in pure2_1.dif. As you can see, it is only the instrumentation +that is slightly different. + +Both the C and the Pascal versions are here. The Ada version I +have is marked preliminary (not to be posted). + +I've enclosed a new submission form (note new address for mailings). +Please deluge this mailbox (..!uunet!pcrat!dry2) with your results. +I'll summarize and repost when the dust clears. Please do not +assume that I will pull posted results off of the net (I won't, its +too much work). + +I've attempted to include a Makefile for UNIX and Microsoft C (with ndmake). +Pay particular attention to the HZ parameter, even though your power may +be 50 or 60 hertz, your computer may not be. You may have to ask someone, +read the manual, or check: + /usr/include/sys/param.h + /usr/include/limits.h (CLK_TCK==HZ) +for this information. + +REPEAT: HZ IS NOT NECESSARILY THE FREQUENCY OF YOUR AC POWER !!!!!! + +There are two versions to run, one with register variables, and one +without. Please let the benchmark run for 30,000 loops on sixteen +bit machines, and for much longer (a minute or two) on faster machines. +Please note that "time(2)" has a resolution of 1 second, and may give +variable results. No matter how time is measured, a sanity check with +a stopwatch is prudent. We've run into systems that lie about time, +and there is always the configuration error problem. When it comes +to time measurement on UNIX, there is no widely adhered to standard. + +For segmented architectures, it is appropriate to submit results for +all memory models, as shown below. + +I dropped the CODESIZE information that I attempted to add the last +time I posted this. People couldn't follow directions, and the +information wasn't very useful anyway. + +Here's a sample submission of results: + +DHRYSTONE 2.1 BENCHMARK REPORTING FORM +MANUF: IBM +MODEL: PC/AT +PROC: 80286 +CLOCK: 8 +OS: Venix +OVERSION: SVr2.3 +COMPILER: AT&T cc +CVERSION: 11/8/84 +OPTIONS: -O +NOREG: 1450 +REG: 1450 +NOTES: HZ=60; Small Model +DATE: 03/04/88 +SUBMITTER: pcrat!rick (Rick Richardson) +MAILTO: uunet!pcrat!dry2 + +DHRYSTONE 2.1 BENCHMARK REPORTING FORM +MANUF: IBM +MODEL: PC/AT +PROC: 80286 +CLOCK: 8 +OS: Venix +OVERSION: SVr2.3 +COMPILER: AT&T cc +CVERSION: 11/8/84 +OPTIONS: -O -Ml +NOREG: 1043 +REG: 1043 +NOTES: HZ=60; Large Model +DATE: 03/04/88 +SUBMITTER: pcrat!rick (Rick Richardson) +MAILTO: uunet!pcrat!dry2 + +The program that processes submission forms is rather dumb. Please +do not change the order, add or removes lines in the form. If your +NOTES are longer than the space provided, then they are too long for +the summary. Keep it terse, please. + +A form consists of all lines between: + DHRYSTONE 2.1 BENCHMARK REPORTING FORM +and + MAILTO: uunet!pcrat!dry2 +both lines must be present for the form to be processed. If +a field does not apply or is not known, leave it blank. The fields +are: + MANUF: Computer manufacturer, e.g. AT&T, IBM + MODEL: Model number of computer + PROC: If a microprocessor CPU, the part number, e.g. 68030 + CLOCK: Clock in Mhz, if known. Numeric only, e.g. 16.67 + OS: Operating system, e.g. UNIX + OVERSION: OS version, e.g. SVR3 + COMPILER: Compiler name, e.g. cc, Microsoft, or Green Hills + CVERSION: Compiler version, e.g. 5.10 + OPTIONS: Relevant compiler options, e.g. -O3 + NOREG: Dhrystones/second, no register attribute + REG: Dhrystones/second, with register attribute + NOTES: Additional, terse comments on one line + DATE: Date of test, US format MM/DD/YY + SUBMITTER: uucp or domain address (full name) + + +HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ + +Please, if you are using times(2) to measure time, indicate +the HZ value you used in the NOTES field. Something like this is OK: + + NOTES: HZ=100; no inlining... + +HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ HZ + +-- + Rick Richardson, President, PC Research, Inc. + +(201) 542-3734 (voice, nights) OR (201) 389-8963 (voice, days) +uunet!pcrat!rick (UUCP) rick%pcrat.uucp@uunet.uu.net (INTERNET) + uunet!pcrat!dry2 (Dhrystone submission forms only)
rtl_sim/src-c/dhrystone_v2.1/original_files/README.RER Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/cc_dry2 =================================================================== Cannot display: file marked as a binary type. svn:mime-type = application/octet-stream Index: rtl_sim/src-c/dhrystone_v2.1/original_files/cc_dry2 =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/cc_dry2 (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/cc_dry2 (revision 145)
rtl_sim/src-c/dhrystone_v2.1/original_files/cc_dry2 Property changes : Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +application/octet-stream \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/submit.frm =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/submit.frm (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/submit.frm (revision 145) @@ -0,0 +1,16 @@ +DHRYSTONE 2.1 BENCHMARK REPORTING FORM +MANUF: +MODEL: +PROC: +CLOCK: +OS: +OVERSION: +COMPILER: +CVERSION: +OPTIONS: +NOREG: +REG: +NOTES: +DATE: +SUBMITTER: +MAILTO: uunet!pcrat!dry2
rtl_sim/src-c/dhrystone_v2.1/original_files/submit.frm Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/byperf =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/byperf (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/byperf (revision 145) @@ -0,0 +1,858 @@ + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Heurikon |HK68 |68010 |10.00|UniPlus+|5.0 |pcc | |-O | 507| 558| |07/08/88|johnl@gronk.UUCP | +| | | | |System V| | | | | | | | |(John Limpert) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |Professional 380| | |VENIX |SVR2.0 |cc | |-O | 528| 568| |07/11/88|magnus@rhi.hi.is | +| | | | | | | | | | | | | |(Magnus Gislason) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 11/750 |VAX 11| |Unix |BSD 4.3 |gcc |1.24 | | 538| 568|HZ=60; multiuser; |07/21/88|thos@cca.ucsf.edu | +| | | | | | | | | | | |avg middle 3 of 5 | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 11/750 |VAX 11| |Unix |BSD 4.3 |cc |4.3 | | 583| 622|HZ=60; times call |07/12/88|thos@cca.ucsf.edu | +| | | | | | | | | | | |and time cmd | | | +| | | | | | | | | | | |consistent; | | | +| | | | | | | | | | | |multiuser | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Frank Hogg|QT+ |68000 |10.00|Os9/68k |2.1 |Microware C |2.2 | | 610| 649| |03/11/88|blarson@skat.usc.edu| +|Labs | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 11/750 |VAX 11| |Unix |BSD 4.3 |cc |4.3 |-O | 675| 701|HZ=60; times call |07/12/88|thos@cca.ucsf.edu | +| | | | | | | | | | | |and time cmd | | | +| | | | | | | | | | | |consistent; | | | +| | | | | | | | | | | |multiuser | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 9.00|SCO |2.2.1 |cc | |-Ox -M2l -K | 715| 727|Large Model |03/09/88|wrp@virginia.EDU | +| | | | |Xenix | | | | | | | | |(Bill Pearson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Heurikon |HK68 |68010 |10.00|UniPlus+|5.0 |Green Hills |1.8.0 |-O | 719| 750| |07/08/88|johnl@gronk.UUCP | +| | | | |System V| | | | | | | | |(John Limpert) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |Vax 11/750 |Vax 11| |Unix |BSD 4.3 |Unix Pascal |4.3 | | 767| 767| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 11/750 |VAX 11| |Unix |BSD 4.3 |gcc |1.24 |-O | 735| 772|HZ=60; multiuser; |07/21/88|thos@cca.ucsf.edu | +| | | | | | | | | | | |avg middle 3 of 5 | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Apple |Macintosh Plus |68000 | 7.83|Macintos|System |Lightspeed |1.11a | | 781| 781|used TickCount for|03/09/88|andrew.cmu.edu!rich.| +|Computer | | | |h OS |version |Pascal | | | | |timing. | |siegel (Rich Siegel)| +| | | | | |4.2 | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Apple |Macintosh Plus |68000 | 7.83|Macintos|System |LightspeedC |2.15 | | 719| 789|Used TickCount() |03/09/88|andrew.cmu.edu!rich.| +|Computer | | | |h OS |version | | | | | |for 60HZ accuracy | |siegel (Rich Siegel)| +| | | | | |4.2 | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Intel |310 |80286 |12.00|Xenix |3.5 |cc | |-O -Ml | 806| 817|Large Model |07/11/88|ficc!karl (Karl | +| | | | | | | | | | | | | |Lehenbauer) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Apple |Macintosh Plus |68000 | 7.83|Macintos|System |MPW Pascal |2.0.2 |-r (no range| 832| 832|used TickCount. |03/09/88|andrew.cmu.edu!rich.| +|Computer | | | |h OS |version | | |check) | | | | |siegel (Rich Siegel)| +| | | | | |4.2 | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + + + + Page 1 + + + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Siemens |Siemens |Custom| |BS 2000 |BS 2000 |Pascal |3.10 B |d-----,o+++ | 844| 844|don't laugh: |03/10/88|mcvax!unido!infko! | +|GmbH, |7.536-200 | | |V 7.5 | | | | | | |option are: "full | |droege | +|Munich | | | | | | | | | | |optimize, no debug| | | +| | | | | | | | | | | |code" | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Atari |MEGA 2 |68000 | 8.00|TOS |1.4 |Aztec C |3.6A |+L | 783| 851|32 bit int's |08/31/88|uunet!yunexus!yugas!| +|Corp. | | | | | | | | | | | | |julius (Julius | +| | | | | | | | | | | | | |Oklamcak) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |11/750 | | |MACH/4.3| |pcc | |-O | 840| 863| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Motorola/ |PC/68000 |68000 | 8.00|System |Release |cc |Version |-O -HZ60 | 882| 882|Running on a |08/10/88|pyramid!sultra! | +|Four- | | | |V/68 |2 Versio| |1.1 | | | |Compaq DeskPro-286| |dtynan | +|Phase/ | | | | |n 1 | | | | | |w/ a PC/68000 | | | +|Sritek | | | | | | | | | | |co-processor. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|PC's |286 |80286 | 8.00|Micropor|2.3 |cc | |-O -Ml | 911| 912|Large memory model|03/30/88|uunet!actnyc!jhs | +|Limited | | | |t System| | | | | | | | | | +| | | | |V/AT | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Honeywell |DPS-8/49 | | |GCOS8 |SR3000 |Waterloo SDG|8cl3.1 | | 960| 960|single-segment |03/10/88|gamiddleton@math. | +| | | | | | |C | | | | |mode | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |Vax 11/750 |Vax 11| |Unix |BSD 4.3 |Unix C |4.3 |-O | 901| 971| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |11/750 | | |UNIX |4.3 BSD |cc | |-O | 962| 976| |03/13/88|Sharan Kalwani | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|BBN |BBN Butterfly |68020 | |Chrysali|3.0.1fp |Green Hills |(?) |-O | 961| 1000|Single proc, timed|03/14/88|cdaf@iuvax.cs. | +|Advanced | | | |s | |C | | | | |by REAL TIME clock| |indiana.edu | +|Computers | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|Venix |SVr2.3 |AT&T cc |11/8/84 |-O -Ml | 1043| 1043|Large Model |03/04/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|Venix |SVr2.3 |AT&T cc |11/8/84 |-O -Ml | 1043| 1043|Large Model |03/04/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Honeywell |DPS-8/49 | | |GCOS8 |SR3000 |Waterloo SDG|8cv1.0 | | 1094| 1094|native-segment |03/10/88|gamiddleton@math. | +| | | | | | |C | | | | |mode | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|SEQUENT |BALANCE 8000 |32032 | |Mach | | | |-O | 1058| 1110|1 of 32 processors|03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 11/750 | | |BSD |4.3 |cc |?? |-O | 1160| 1160| |03/08/88|thompson@dalcs.uucp | +| | | | | | | | | | | | | |(Michael Thompson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Tandy |3000HD |80286 |10.00|Xenix |System V|Microsoft cc|03/03/87|-Ot -Ml2 | 1111| 1167|Large Model |03/14/88|cpe!oswald (Roy | +| | | | | | | | | | | | | |Oswald) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|HP |9000 ser500 | | |HP-UX |5.2 |cc | |-O | 1176| 1176|single CPU used |04/01/88|mck-csc!bmg | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AT&T |3B2/310 |32100 |10.00|Unix |3.1.1 |cc |3.1 |-O | 1220| 1250| |07/15/88|len@netsys | +| | | | |System V| | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + Page 2 + + + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|CCI |Power 5/32 |68010 |12.50|Unix |BSD 4.2 |MIT cc |? |-O | 1111| 1250| |03/11/88|rutgers!cci632! | +| | | | | | | | | | | | | |walden!jjg | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Pinnacle |XL |68000 |12.00|UNIX |System |cc |2.3 |-O | 1162| 1260|The OS claims to |07/22/88|uunet!mcl!stacy | +| | | | | |V.~2 | |83/07/08| | | |be V.2 but is sure| |(Stacy L. Millions) | +| | | | | | | | | | | |aint SVID | | | +| | | | | | | | | | | |compliant. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|PC's |286 |80286 | 8.00|Micropor|2.3 |cc | |-O | 1266| 1266|Small memory model|03/30/88|uunet!actnyc!jhs | +|Limited | | | |t System| | | | | | | | | | +| | | | |V/AT | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|ENCORE |MULTIMAX |32020 | |Mach | | | |-O -q | 1323| 1323|1 of 16 processors|03/14/88|Lawrence Butcher | +| | | | | | | | |novolatile | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|ENCORE |MULTIMAX |32032 |10.00|Mach | | | |-O -q | 1323| 1323|1 of 16 processors|03/14/88|Lawrence Butcher | +| | | | | | | | |novolatile | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|PCS Cadmus|Cadmus 9230 / |Mc6801|10.00|MUNIX |System |cc |1.July |-O -f | 1258| 1348|cc needs -f option|03/10/88|mcvax!unido!infko! | +|GmbH, |Qu68050-A |0 | |V.2/6b-v|V.2 | |86 | | | |for floating point| |droege | +|Munich | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Everex/AT |1800A |80286 |10.00|Micropor|SysVr2; |AT&T cc | |-O -Ml | 1336| 1352|large model |03/15/88|Jay Maynard | +|Plus | | | |t System|SV/AT | | | | | | | |(uunet!nuchat!splut!| +| | | | |V/AT |2.3.0-L | | | | | | | |jay) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|PCS GmbH |Cadmus 9230-a |68010 |10.00|UNIX |V.2/06b |cc | |-O | 1268| 1363| |08/17/88|droege@infko.UUCP | +|Munich | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AST |Premium/286 |80286 |10.00|IBM |3.30 |Borland |3.02A |(none) | 1380| 1380|MemW[seg:off] used|03/13/88|Charles Marslett | +| | | | |PCDOS | |Turbo Pascal| | | | |to read 18.2 Hz | |(chasm@killer.UUCP) | +| | | | | | | | | | | |clock | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |uVAX II | | |Ultrix |1.2 |cc | |-O | 1365| 1412| |07/11/88|magnus@rhi.hi.is | +| | | | | | | | | | | | | |(Magnus Gislason) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |UVAX II | | |Ultrix |2.0 |cc |?? |-O | 1415| 1415| |03/08/88|thompson@dalcs.uucp | +| | | | | | | | | | | | | |(Michael Thompson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |11/780 | | |Ultrix |2.0-1 |/bin/cc |(?) |-O | 1336| 1418|100000 iters |03/14/88|cdaf@iuvax.cs. | +| | | | | | | | | | | | | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AH | 1437| 1434|Huge Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|Venix |SVr2.3 |AT&T cc |11/8/84 |-O | 1318| 1450|Small Model |03/04/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|BBN |Butterfly Plus |68020 |16.00|Chrysali|3.9.2 |Green Hills |180I |-O | 1371| 1469|Timed with REAL |03/11/88|dfk@cs.duke.edu | +|Advanced | | | |s | |C | | | | |TIME, but | | | +|Computers | | | | | | | | | | |effectively | | | +| | | | | | | | | | | |single-user. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |uVAX II | | |MACH/4.3| |pcc | |-O | 1450| 1476| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + Page 3 + + + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Sperry |5000/60 |68000 |12.50|UNIX |SVR2 |cc | |-O | 1371| 1484|Sperry 5000/60 is |07/12/88|ficc!peter (Peter da| +| | | | | | | | | | | |actually Arete | |Silva) | +| | | | | | | | | | | |(now ARIX) | | | +| | | | | | | | | | | |1100/???. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|BBN |Butterfly Plus |68020 |16.00|Chrysali|3.9.2 |Green Hills |180I |none | 1489| 1487|Timed with REAL |03/11/88|dfk@cs.duke.edu | +|Advanced | | | |s | |C | | | | |TIME not user | | | +|Computers | | | | | | | | | | |time, but | | | +|Inc | | | | | | | | | | |effectively | | | +| | | | | | | | | | | |single-user. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 780 | | |MACH/4.3| |pcc | |-O | 1424| 1517| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 8250 | | |MACH/4.3| |pcc | |-O | 1521| 1571| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Alliant |FX/8 |Allian| |Concentr|3.0 |Alliant cc |(?) |-O -ip | 2525| 1615|Compiled for IP's.|03/14/88|cdaf@iuvax.cs. | +|Computer | |t IP | |ix | | | | | | |NOREG faster than | |indiana.edu | +| | | | | | | | | | | |REG. 100K iters | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Honeywell |DPS 8/70 | | |GCOS8 |SR3000 |Waterloo SDG|8cl3.1 | | 1653| 1653|single-segment |03/15/88|gamiddleton@math. | +| | | | | | |C | | | | |mode | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Intel |310 |80286 |12.00|Xenix |3.5 |cc | |-O -Ms | 1630| 1705|Small Model |07/11/88|ficc!karl (Karl | +| | | | | | | | | | | | | |Lehenbauer) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AL | 1706| 1717|Large Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Atari |MEGA 2 |68000 | 8.00|TOS |1.4 |Turbo C |1.0 |-G -J -M -P | 1650| 1730|For NOREG all |09/21/88|uunet!nexus!yugas! | +|Corp. | | | | | | | |-R -Z | | |optimization was | |julius (Julius | +| | | | | | | | | | | |turned off | |Oklamcak) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AC | 1767| 1784|Compact Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 50 |80286 |10.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AH | 1791| 1784|Huge Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 785 | | |BSD Unix|4.3 |pc | | | 1864| 1864|pascal version |03/17/88|gamiddleton@math. | +| | | | | | | | | | | | | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|GMX |Micro-20 |68020 |20.00|OS-9 |2 |Microware |5 | | 1875| 1875| |03/27/88|Peter Dibble | +| | | | | | |Pascal | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Tandy |3000HD |80286 |10.00|Xenix |System V|Microsoft cc|03/03/87|-Ot | 1764| 1875|Small Model |03/14/88|cpe!oswald (Roy | +| | | | | | | | | | | | | |Oswald) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Everex/AT |1800A |80286 |10.00|Micropor|SysVr2; |AT&T cc | |-O | 1875| 1879|small model |03/15/88|Jay Maynard | +|Plus | | | |t System|SV/AT | | | | | | | |(uunet!nuchat!splut!| +| | | | |V/AT |2.3.0-L | | | | | | | |jay) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SunOS |3.4 |Sun Pascal |3.4 | | 1884| 1884| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + + Page 4 + + + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|IBM |PC/AT |80286 | 9.00|Xenix |2.2.1 |cc | |-Ox -M2 -K | 1821| 1926|20000 iterations |03/09/88|wrp@virginia.EDU | +| | | | | | | | | | | | | |(Bill Pearson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 785 | | |BSD Unix|4.3 |cc | | | 1857| 1948| |03/17/88|gamiddleton@math. | +| | | | | | | | | | | | | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 785 | | |BSD Unix|4.3 |cc | |-O | 1929| 1960| |03/17/88|gamiddleton@math. | +| | | | | | | | | | | | | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 785 | | |MACH/4.3| |pcc | |-O | 1972| 2004| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AM | 2008| 2022|Medium Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Harris |H-1200 | | |VOS |6.1.1 |VOS C |6.1.1 | | 2024| 2024| | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |785 | | |VMS |4.4 |VAX C |2.1 | | 2040| 2040|real time at high |03/14/88|egisin@Waterloo.EDU | +| | | | | | | | | | | |priority | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AS | 2084| 2117|Small Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 50 |80286 |10.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AL | 2133| 2150|Large Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Computer |Mini-286 |80286 |12.00|Micropor|SVr2.3.0|AT&T pcc |1.3 |-O | 2187| 2187|Small Model |8/15/88 |...!uunet!dmk3b1! | +|Products | | | |t System| | | | | | | | |cocktrice!mdm (Mike | +|United | | | |V/AT | | | | | | | | |Mitchell) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 50 |80286 |10.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AC | 2202| 2220|Compact Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Apollo |DN560 |68020 | |Domain/ |9.7 |Apollo cc | |-O | 2320| 2320|100000 iters. |03/14/88|cdaf@iuvax.cs. | +|Computer | | | |IX | | | | | | | | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Apollo |DN3000 |68020 | |Domain/ |9.7 |Apollo cc | | | 2345| 2344|100000 iters |03/14/88|cdaf@iuvax.cs. | +|Computer | | | |IX | | | | | | | | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/180 |68020 |16.67|SunOS |3.4 |Sun Pascal |3.4 | | 2371| 2371| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Apple |Macintosh II |68020 |15.70|Multifin|1.0 |Lightspeed C|2.15 |none | 2469| 2469| |03/09/88|Christohper Chow | +|Computer | | | |der | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Honeywell |DPS 8000 | | |GCOS8 |SR3000 |Waterloo SDG|8cl3.1 | | 2483| 2483|single-segment |03/15/88|gamiddleton@math. | +| | | | | | |C | | | | |mode | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|APOLLO |DN3000 |68020 |16.00|DOMAIN | |Domain cc |rev 4.81|-O -M90 | 2519| 2519| |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 50 |80286 |10.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AM | 2506| 2527|Medium Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|APOLLO |DN560 |68020 |16.00|DOMAIN | |Domain cc |rev 4.81|-O -M90 | 2533| 2533| |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + + + Page 5 + + + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|AST |Premium/286 |80286 |10.00|IBM |3.30 |Borland |1.0 |-ms/-mc/-ml | 2553| 2553|Loop counter made |03/13/88|Charles Marslett | +| | | | |PCDOS | |Turbo C | |-O-G-Z-a-d | | |"long" for 120,000| |(chasm@killer.UUCP) | +| | | | | | | | | | | |passes | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|NEC |PC-9801 VX |NEC |16.00|DRI |1.3 |MetaWare |1.4 | | 2566| 2566|100000 iterations |07/08/88|amdahl!drivax! | +| |(SB-8500 V60 CPU|V60 | |FlexOS | |High C V60 | | | | | | |alexande (Mark | +| |board) |(uPD70| |V60 | | | | | | | | |Alexander) | +| | |616) | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SunOS |3.4 |cc |3.4 |-O | 2344| 2578|100000 iterations |03/09/88|mikew@x2.wyse.com | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|GMX |Micro-20 |68020 |20.00|OS-9 |2 |Microware C |3 |-k2f | 2128| 2632| |03/27/88|Peter Dibble | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|GMX |Micro-20 |68020 |20.00|OS-9 |2 |Microware C |3 |-k2wf | 2222| 2632| |03/27/88|Peter Dibble | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 50 |80286 |10.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AS | 2601| 2638|Small Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|PCS Cadmus|Cadmus 9600 / |Mc6802|12.50|MUNIX |System |cc |20.Oct. |-O -fH | 2448| 2646|cc needs -fH |03/10/88|mcvax!unido!infko! | +|GmbH, |MWS-3 |0 | |V.2/32- |V.2 | |86 | | | |option to include | |droege | +|Munich | | | |1.1 | | | | | | |floating point | | | +| | | | | | | | | | | |processor | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|PCS GmbH |Cadmus 9600 |68020 |12.50|UNIX |V.2/1.2 |cc | |-O | 2447| 2665| |08/17/88|droege@infko.UUCP | +|Munich |MWS/3 | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SunOS |3.4 |Sun C |3.4 |-O | 2374| 2702| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SUN 3.5 | |cc | |-O | 2557| 2859|display ON |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|HP |9000/320 |68020 |16.67|HPUX | | | |-O | 2660| 2870| |06/25/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |16.67|SUNOS |4.5 |gcc |1.17 |-O | 2911| 2906|display ON |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AST |Premium/286 |80286 |10.00|IBM |3.30 |Microsoft |5.10 |-AS/-AC/-AL | 2907| 2907|50K loops,used |03/13/88| | +| | | | |PCDOS | | |(Beta) |-Oalt -Gs | | |18.2 Hz ctr, Max. | | | +| | | | | | | | | | | |SAFE Opt. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|GMX |Micro-20 |68020 |20.00|OS-9 |2.2 |Microware C |3 |-k2l | 2500| 2941| |07/27/88|Peter Dibble | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AT&T |6386 WGS |80386 |16.00|MS-DOS |3.2 |Microsoft C |5.0 |-Ox -G2 -AH | 3000| 2985|Huge Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|ENCORE |MULTIMAX |32332 |15.00|Mach | | | |-O -q | 3059| 3071|1 of 16 processors|04/16/88|Lawrence Butcher | +| | | | | | | | |novolatile | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SunOS |3.4EXPOR|SUN cc |?? |-O | 3183| 3183| |03/08/88|thompson@dalcs.uucp | +| | | | | |T | | | | | | | |(Michael Thompson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SunOS |3.4EXPOR|SUN cc |?? |-O | 3183| 3183| |03/08/88|thompson@dalcs.uucp | +| | | | | |T | | | | | | | |(Michael Thompson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + + Page 6 + + + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Sun |3/60 |68020 |20.00|SunOS |3.4 |Sun Pascal |3.4 | | 3255| 3255| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/160c |68020 |16.67|SUN UNIX|3.5 |cc | |-O | 3260| 3296|300,000 Loops |03/09/88|ncsa.uiuc.edu!steve | +| | | | | | | | | | | | | |(Steve Christensen) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AST |Premium/286 |80286 |10.00|IBM |3.30 |Microsoft |5.10 |-AS/-AC/-AL | 3309| 3309|50K loops, used |03/13/88| | +| | | | |PCDOS | | |(Beta) |-Ox | | |18.2Hz ctr, Max. | | | +| | | | | | | | | | | |Opt. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 80 |80386 |16.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AH | 3390| 3410|Huge Model |03/18/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AEON |332/AT |NS3233|15.00|GENIX |V.3 |NS CTP |2.4 |-O -KC332 | 3413| 3413| |03/12/88|John Behrs | +|Technologi| |2 | | | | | | | | | | |(boulder!fesk! | +|es | | | | | | | | | | | | |ativax!john) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/180 |68020 |16.67|SunOS |3.4 |Sun C |3.4 |-O | 3123| 3452| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SUN 3.5 | |cc | |-O | 3099| 3452|display OFF |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |16.67|SUNOS |4.5 |gcc |1.17 |-O | 3460| 3460|display OFF |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AT&T |6386 WGS |80386 |16.00|MS-DOS |3.2 |Microsoft C |5.0 |-Ox -G2 -AL | 3500| 3521|Large Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/160 |68020 |16.67|SUN 3.3n| |cc | |-O | 3271| 3624| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |4341-12 | | |Amdahl |SVr2 |UTS cc |1.27 -- |-O | 3632| 3631| |03/12/87|newton@csvax. | +| | | | |UTS |Version | |6/6/86 | | | | | |caltech.edu (Mike | +| | | | | |1.1.3 | | | | | | | |Newton) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|386/ix |1.0.4 |cc |1.0.2 |-O | 3369| 3652|64K cache OFF |07/08/88|pcrat!rick | +| | | | | | | | | | | |(1ws) | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/160 |68020 |16.67|SUNOS |4.5 |gcc |1.17 |-O | 3681| 3681| |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AT&T |6386 WGS |80386 |16.00|MS-DOS |3.2 |Microsoft C |5.0 |-Ox -G2 -AC | 3740| 3740|Compact Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Intel |320 |80386 |16.00|Xenix |3.5 |cc | |-O -Ms | 3586| 3782|Small Model, 286 |07/11/88|ficc!karl (Karl | +| | | | | | | | | | | |mode | |Lehenbauer) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |4341-12 | | |Amdahl |SVr2 |UTS cc |1.27 -- |-O -OM | 3820| 3818|'MN' -- with the |3/12/87 |newton@csvax. | +| | | | |UTS |Version | |6/6/86 | | | |`optimizer' I | |caltech.edu (Mike | +| | | | | |1.1.3 | | | | | |posted to USENET | |Newton) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 6220 |CVAX |12.50|MACH/4.3| |4.3 pcc | |-O | 3706| 3859|1 of 4 processors |05/15/88|Lawrence Butcher | +| | |chips | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Alliant |FX/8 |Allian| |Concentr|3.0 |Alliant cc |(?) |-O -ce | 3790| 3929|Compiled for CE's.|03/14/88|cdaf@iuvax.cs. | +|Computer | |t CE | |ix | | | | | | |300K iters | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + Page 7 + + + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Mylex |386 Motherboard |80386 |16.00|MS-DOS |3.0 |Microsoft C |5.10 |-Ox -G2 -AH | 3956| 3932|Huge Model |07/08/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AT&T |6386 WGS |80386 |16.00|MS-DOS |3.2 |Microsoft C |5.0 |-Ox -G2 -AM | 3957| 3957|Medium Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|Sun O/S |3.4 |Sun cc | |-O | 4543| 4035| |03/09/88|alberta!steve | +| | | | | | | | | | | | | |(Steven Sutphen) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 80 |80386 |16.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AL | 3980| 4040|Large Model |03/18/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Harris |MCX-3/40 |68020 |16.67|HS/UX |3.0B |HS/UX C |3.0B |-O | 4178| 4215| | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AT&T |6386 WGS |80386 |16.00|MS-DOS |3.2 |Microsoft C |5.0 |-Ox -G2 -AS | 4201| 4267|Small Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/280 |68020 |25.00|SunOS |3.4 |Sun Pascal |3.4 | | 4310| 4310| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 80 |80386 |16.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AC | 4300| 4330|Compact Model |03/18/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|Sun Unix|3.4.2 |Sun cc |3.4.2 |-O | 3947| 4335| |03/11/88|wright@fluke.COM | +| | | | | | | | | | | | | |(Dave Wright) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 80 |80386 |16.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AM | 4470| 4470|Medium Model |03/18/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |RT Model 125 | | |MACH/4.3| |Metaware |1.4R |-O | 4474| 4474| |03/10/88|Lawrence Butcher | +| | | | | | |HighC | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|SUN 3.5 | |cc | |-O | 4065| 4487| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Wyse |3216 |80386 |16.00|Unix |SVR3 |cc |3.0 |-O | 4208| 4526|100000 loops |03/09/88|mikew@x2.wyse.com | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|GOULD |9080 | | | | | | |-O | 4335| 4545|1 of 2 proc.'s |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|SUNOS |4.5 |gcc |1.17 |-O | 4558| 4558| |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|MS-DOS |3.0 |Microsoft C |5.10 |-Ox -G2 -AL | 4623| 4639|Large Model |07/08/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|SunOS |3.4 |Sun C |3.4 |-O | 4200| 4702| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|SUN 3.5 | |SUN 3.5 cc | |-O | 4243| 4706|Some 3/60's seem |03/09/88|Lawrence Butcher | +| | | | | | | | | | | |faster than | | | +| | | | | | | | | | | |others. Rev lvl? | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 80 |80386 |16.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AS | 4790| 4910|Small Model |03/18/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|386/ix |1.0.4 |cc |1.0.2 |-O | 4703| 4950|64K cache ON |07/08/88|pcrat!rick | +| | | | | | | | | | | |(~0ws) | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + + + + Page 8 + + + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Whole |Mylex 386/AT |80386 |16.00|Unix |SVr3.0 |AT&T cc |7/2/87 |-O | 4704| 4955|64 kbyte 0-wait |07/11/88|sugar!karl (Karl | +|Earth | | | | | | | | | | |cache enabled | |Lehenbauer) | +|Electronic| | | | | | | | | | | | | | +|s | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|386/ix |1.0.4 |GNU gcc |1.26 |-O | 5022| 5022|64K cache ON |08/21/88|pcrat!rick | +| | | | | | | | | | | |(~0ws) | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|MS-DOS |3.0 |Microsoft C |5.10 |-Ox -G2 -AC | 5015| 5058|Compact Model |07/08/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|MS-DOS |3.0 |Microsoft C |5.10 |-Ox -G2 -AM | 5237| 5237|Medium Model |07/08/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MicroSage |Stride 800 |68030 |25.00|UniStrid|SVr2.2 |PCC2 |2 |-O | 5092| 5371|Native PCC2 based |07/08/88|Bruce Robertson | +|Computer |Series | | |e | | | | | | |C compiler | | | +|Systems | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|COMPAQ |DESKPRO 386/20 |80386 |20.00|COMPAQ |3.31 |Datalight |3.14 |-o | 5434| 5434|Large Model; avg. |07/08/88|amdahl!drivax! | +| | | | |MS-DOS | |Optimum-C | | | | |of best, worst | |alexande (Mark | +| | | | | | | | | | | |results | |Alexander) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|APOLLO |DN4000 |68020 |25.00|DOMAIN | |Domain cc |rev 4.81|-O -M90 | 5714| 5714| |05/15/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MicroSage |Stride 800 |68030 |25.00|UniStrid|SVr2.2 |GNU C |1.24 |-O | 5727| 5727| |07/08/88|Bruce Robertson | +|Computer |Series | | |e | | | | | | | | | | +|Systems | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|MS-DOS |3.0 |Microsoft C |5.10 |-Ox -G2 -AS | 5772| 5772|Small Model |07/08/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|COMPAQ |DESKPRO 386/20 |80386 |20.00|COMPAQ |3.31 |Datalight |3.14 |-o | 5949| 5949|Compact Model; |07/08/88|amdahl!drivax! | +| | | | |MS-DOS | |Optimum-C | | | | |avg. of best, | |alexande (Mark | +| | | | | | | | | | | |worst results | |Alexander) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Wyse |3216 |80386 |16.00|Unix |SVR3 |Greenhills |1.8.2H |-O | 5988| 6038|100000 loops, Yes|03/09/88|mikew@x2.wyse.com | +| | | | | | |C-386 | | | | |it really was | | | +| | | | | | | | | | | |slower with the -O| | | +| | | | | | | | | | | |switch | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|COMPAQ |DESKPRO 386/20 |80386 |20.00|COMPAQ |3.31 |Datalight |3.14 |-o | 6097| 6097|Program (P) Model;|07/08/88|amdahl!drivax! | +| | | | |MS-DOS | |Optimum-C | | | | |avg. of best, | |alexande (Mark | +| | | | | | | | | | | |worst results | |Alexander) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MicroSage |Stride 800 |68030 |25.00|UniStrid|SVr2.2 |GNU C |1.24 |-O | 6112| 6112|Maximum |07/08/88|Bruce Robertson | +|Computer |Series | | |e | | | |-fomit- | | |optimization | | | +|Systems | | | | | | | |frame- | | | | | | +| | | | | | | | |pointer | | | | | | +| | | | | | | | |-finline- | | | | | | +| | | | | | | | |functions | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Honeywell |DPS 88 | | |GCOS8 |SR3000 |Waterloo SDG|8cl3.1 | | 6172| 6172|single-segment |03/15/88|gamiddleton@math. | +| | | | | | |C | | | | |mode | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + + + Page 9 + + + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|MIPS |M/500 |R2000 | 8.00|MIPS |UMIPS- |MIPS Pascal |1.11 | | 6225| 6225| |03/10/88|Chuck Musciano | +| | | | |Unix |BSD 2.0 | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |20.00|386/ix |1.0.4 |cc |1.0.2 |-O | 5970| 6246|64K cache ON |07/19/88|pcrat!rick | +| | | | | | | | | | | |(~0ws) | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Wyse |3216 |80386 |16.00|Unix |SVR3 |Greenhills |1.8.2H | | 6157| 6297|100000 loops |03/09/88|mikew@x2.wyse.com | +| | | | | | |C-386 | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|COMPAQ |DESKPRO 386/20 |80386 |20.00|DRI |1.42 |MetaWare |1.4 | | 6385| 6385|"Small" 32-bit |07/08/88|amdahl!drivax! | +| | | | |FlexOS | |High C 386 | | | | |flat model | |alexande (Mark | +| | | | |386 | | | | | | | | |Alexander) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/280 |68020 |25.00|SunOS |3.5 |cc |3.5 |-O | 5853| 6410|100000 loops |03/09/88|mikew@x2.wyse.com | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|COMPAQ |DESKPRO 386/20 |80386 |20.00|COMPAQ |3.31 |Datalight |3.14 |-o | 6787| 6787|Small Model; avg. |07/08/88|amdahl!drivax! | +| | | | |MS-DOS | |Optimum-C | | | | |of best, worst | |alexande (Mark | +| | | | | | | | | | | |results | |Alexander) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Dell |System 310 |80386 |20.00|SCO |2.2.2 |XENIX386 |2.2 |-Ox | 6500| 6975| |11/05/88|Joe Carlson | +|Computers | | | |XENIX/ | |Development | | | | | | |(carlson@lll-winken.| +| | | | |386 | |Sys | | | | | | |llnl.gov) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/260 |68020 |25.00|SUNOS |4.5 |gcc |1.17 |-O | 6993| 7012| |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/280 |68020 |25.00|SunOS |3.4 |Sun C |3.4 |-O | 6255| 7012| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Prime |EXL 316 |80386 |16.00|UNIX |SVR3.0 |SVS C |2.8 |-O | 6878| 7025|500000 iter |07/07/88|uunet!ssgp32!pj | +|Computer | | | | | | | | | | | | |(Peter Weyman) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/260 |68020 |25.00|SUN 3.3 | |cc | |-O | 6438| 7146| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |Vax 8800 | | |Ultrix |2.0-1 |/usr/ucb/pc |(?) |-O | 7846| 7846|300000 iters |03/14/88|cdaf@iuvax.cs. | +| | | | | | | | | | | | | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |8650 | | |Ultrix |2.0-1 |/bin/cc |(?) |-O | 7762| 8021|30000 iters |03/14/88|cdaf@iuvax.cs. | +| | | | | | | | | | | | | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |386i/250 |80386 |25.00|Beta | |Beta 3.4? | |-O | 8000| 8356| |04/06/88|Lawrence Butcher | +| | | | |3.4? | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |386i/250 |80386 |25.00|UNIX |SunOS |Sun CC |Feb 88 |-O | 8113| 8469|1E6 loops |03/22/88|..!uunet!edsews! | +| | | | | |4.0 | | | | | | | |peter (Peter | +| | | | | |(BETA) | | | | | | | |Zadrozny) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 8650 | | |MACH/4.3| |pcc | |-O | 8392| 8593|dry ratings vary |03/09/88|Lawrence Butcher | +| | | | | | | | | | | |wildly +- 2000 | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Honeywell |DPS 90 | | |GCOS8 |SR2500 |Waterloo SDG|8cl3.1 | | 8658| 8658|single-segment |03/15/88|gamiddleton@math. | +| | | | | | |C | | | | |mode | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + Page 10 + + + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|DEC |Vax 8800 | | |Ultrix |2.0-1 |/bin/cc |(?) |-O | 8867| 8991|300000 iters |03/14/88|cdaf@iuvax.cs. | +| | | | | | | | | | | | | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 8800 | | |MACH/4.3| |pcc | |-O | 9569| 9696|one processor |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AEON |532/AT |NS3253|25.00|GENIX |V.3 |NS CTP |2.4 |-O -KC532 | 9998| 9998|pipelining |03/12/88|John Behrs | +|Technologi| |2-A1 | | | | | | | | |disabled, chip | |(boulder!fesk! | +|es | | | | | | | | | | |restrictions in | |ativax!john) | +| | | | | | | | | | | |effect | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|HP |9000/840 |RISC | |HP-UX |A.B1.20 |cc |A.00.09 |+O2 | 10141| 10172| |07/11/88|magnus@rhi.hi.is | +| | | | | |C | | | | | | | |(Magnus Gislason) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Cray |Cray-2 | | |UNICOS | |cc | |-O | 9375| 10344|300,000 loops |03/14/88|ncsa.uiuc.edu!steve | +|Research | | | | | | | | | | | | |(Steve Christensen) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Prime |EXL 325 |80386 |25.00|UNIX |SVR3.0 |SVS C |2.8 |-O | 10711| 10860|500000 iter |07/07/88|uunet!ssgp32!pj | +|Computer | | | | | | | | | | | | |(Peter Weyman) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Prime |6350 | | |Primos |21.0.1. |Prime C |21.0 |-32ix | 11111| 10869|strcpy etc. |03/11/88| | +| | | | | |R4 | | |-optimize 1 | | |generate inline | | | +| | | | | | | | |-standardint| | |code | | | +| | | | | | | | |rinsics | | | | | | +| | | | | | | | |-pbstring | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |4/280s |SPARC |16.67|SunOS |3.2_ |cc |?? | | 10889| 10889| |03/08/88|thompson@dalcs.uucp | +| | | | | |EXPORT | | | | | | | |(Michael Thompson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 8700 | | |UNIX |SVR2.0v2|cc | |-O | 10791| 11082| |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Encore |Multimax 320 |NS3253|25.00|Umax4.2 |A3.3 |C-32000 |1.8.4 |-O -q o=t | 11117| 11223|Alpha HW. |12/03/88|James R. Grier | +|Computer | |2 | | | |Green Hills | | | | |Production will be| | | +|Corporatio| | | | | |Software, | | | | |30Mhz. | | | +|n | | | | | |Inc. | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MIPS |M/500 |R2000 | 8.00|MIPS |UMIPS- |MIPS C |1.11 |-O | 12135| 12019| |03/10/88|Chuck Musciano | +| | | | |Unix |BSD 2.0 | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MIPS |M500 |MIPS | 8.00|UMIPS | |cc | |-O | 12235| 12083| |03/09/88|Lawrence Butcher | +| | | | |BSD 2.1 | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |4/110 |SPARC |14.80|SUN 3.2 | |SUN 3.2 | |-O3 global | 12579| 12579| |04/06/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MIPS |M500 |MIPS | 8.00|UMIPS | |cc | |-O3 global | 12806| 12752| |03/09/88|Lawrence Butcher | +| | | | |BSD 2.1 | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Cray |Cray-2 | | |UNICOS | |vcc | |-O | 13043| 13043|300,000 loops, no |03/14/88|Steve Christensen, | +|Research | | | | | | | | | | |attempt at further| |NCSA, University of | +| | | | | | | | | | | |optimizations made| |Illinois at | +| | | | | | | | | | | | | |Urbana-Champaign | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + + Page 11 + + + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Silicon |4D/70G |MIPS |25.00|Unix |SGI |MIPS ucode C|1.21 |none | 12621| 13455|1000000 cycles |07/11/88|cherry@mgh-frodo. | +|Graphics, | |R2000 | |System V|4D1-3.0 | | | | | | | |harvard.edu | +|Inc. | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |4/260 |SPARC |16.67|SUN 3.2 | |cc | |-O | 17868| 17868| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |4/280S |SPARC |16.67|SunOS |3.2_ |SUN cc |?? |-O | 17910| 17910| |03/08/88|thompson@dalcs.uucp | +| | | | | |EXPORT | | | | | | | |(Michael Thompson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |4/260 |SPARC |16.67|SUN 3.2 | |cc | |-O3 global | 18048| 18048| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |4/460hm |Sparc |16.67|SUN UNIX|3.2 |cc | |-O3 | 18750| 19230|300,000 loops |03/09/88|ncsa.uiuc.edu!steve | +| | | | | | | | | | | | | |(Steve Christensen) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|CONVEX |C210 |propri|25.00|CONVEX |X7.0.0.4|CONVEX |X3.0.0.2|-O2 -uo -rl | 20114| 20107|1 CPU, 1000000 |10/24/88|convex!kcollins | +|Computer | |etary | |UNIX | |Vector C | | | | |iterations | |(Kirby Collins) | +|Corp. | |ECL | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MIPS |M/1000 |R2000 |16.00|UMIPS/ |2.1 |MIPS cc |1.21 |-O3 | 22531| 22590|1,000,000 loops |03/09/88|alberta!steve | +|Computer | | | |BSD | | | | | | | | |(Steven Sutphen) | +|Co. | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Whitechape|Hitech-10 |MIPS |16.70|WOS BSD |2.0 |cc |1.21 |-O | 24875| 24927|Default |03/16/88|Ian Kemmish | +|l |Workstation |R2000 | | | | | | | | |optimisations | |(ian@wcwvax.uucp) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Whitechape|Hitech-10 |MIPS |16.70|WOS BSD |2.0 |cc |1.21 |-O3 | 26536| 26525|Intra-module |03/16/88|Ian Kemmish | +|l |Workstation |R2000 | | | | | | | | |register | |(ian@wcwvax.uucp) | +| | | | | | | | | | | |allocation | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Amdahl |5880 | | |UTS |SVr3.1 |UTS cc |4.1 |-O | 28300| 28300|rounded to 3 sig |03/10/88|amdahl!chuck (Chuck | +| | | | | | | |8/27/86 | | | |figs | |Simmons) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Cray |Cray-2/4-128S |s/n |243.0|Unicos |4.0 |Pascal |4.0 |i46,e-,r-,z-| 28600| 28600|1E6 loops; 3 sig |03/14/88|Peter Klausler @ | +|Research | |2012 | | |pre-rel | |pre-rel | | | |figs; inline off | |Cray Research | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Whitechape|Hitech-10 |MIPS |16.70|WOS BSD |2.0 |cc |1.21 |-O4 | 29527| 29615|Global register |03/16/88|Ian Kemmish | +|l |Workstation |R2000 | | | | | | | | |allocation | |(ian@wcwvax.uucp) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Whitechape|Hitech-10 |MIPS |16.70|WOS BSD |2.0 |cc |1.21 |-O4 + | 30456| 30472|Includes procedure|03/16/88|Ian Kemmish | +|l |Workstation |R2000 | | | | | |-feedback | | |in-lining | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Motorola |Platform-88 |M88100|20.00|UNIX |880617 |Green Hills |1.8.4 |-OM -X230 | 33247| 33247|1E6 loops, Avg of |07/11/88|cs.texas.edu! | +|Computer |Software | | |SVr3 | |C-88000 |Beta | | | |10 timings, no | |oakhill!mpaton | +|Division |Development | | | | | | | | | |inlining | | | +| |Platform | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Amdahl |5880 | | |UTS |SVr3.1 |GNU cc |xperimnt|-O | 32600| 33400|rounded to 3 sig |03/10/88|amdahl!chuck (Chuck | +| | | | | | | |l 3/10/ | | | |figs | |Simmons) | +| | | | | | | |88 | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Cray |X-MP/4-16 |s/n |117.0|Unicos |3.0 |Pascal |4.0 |i46,e-,r-,z-| 41500| 41500|1E6 loops; 3 sig |03/14/88|Peter Klausler @ | +|Research | |218 | | | | |pre-rel | | | |figs; inline off | |Cray Research | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + Page 12 + + + + + DHRYSTONE 2.n RESULTS SORTED BY PERFORMANCE Sun Dec 4 02:10:39 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Amdahl |5890-300E |Dual | |UTS1.2 |SVr3.1 |UTS cc |4.1+ |-O | 48309| 48309|Dhrystones per CPU|05/08/88|amdahl!chuck (Chuck | +| | |CPU | | | | |5/04/88 | | | | | |Simmons) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Amdahl |5890-300E |Dual | |UTS1.2 |SVr3.1 |GNU cc |xperimnt|-O | 55658| 55658|Dhrystones per CPU|05/08/88|amdahl!chuck (Chuck | +| | |CPU | | | | |l 3/10/ | | | | | |Simmons) | +| | | | | | | |88 | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Amdahl |5990-700 |Dual | |UTS1.2 |SVr3.1 |UTS cc |4.1+ |-O | 74074| 74074|Dhrystones per CPU|05/08/88|amdahl!chuck (Chuck | +| | |CPU | | | | |5/04/88 | | | | | |Simmons) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Amdahl |5990-700 |Dual | |UTS1.2 |SVr3.1 |GNU cc |xperimnt|-O | 91463| 91463|Dhrystones per CPU|05/08/88|amdahl!chuck (Chuck | +| | |CPU | | | | |l 3/10/ | | | | | |Simmons) | +| | | | | | | |88 | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Page 13 + +
rtl_sim/src-c/dhrystone_v2.1/original_files/byperf Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/dhry.h =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/dhry.h (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/dhry.h (revision 145) @@ -0,0 +1,431 @@ +/* + **************************************************************************** + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: C, Version 2.1 + * + * File: dhry.h (part 1 of 3) + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * Siemens AG, E STE 35 + * Postfach 3240 + * 8520 Erlangen + * Germany (West) + * Phone: [xxx-49]-9131-7-20330 + * (8-17 Central European Time) + * Usenet: ..!mcvax!unido!estevax!weicker + * + * Original Version (in Ada) published in + * "Communications of the ACM" vol. 27., no. 10 (Oct. 1984), + * pp. 1013 - 1030, together with the statistics + * on which the distribution of statements etc. is based. + * + * In this C version, the following C library functions are used: + * - strcpy, strcmp (inside the measurement loop) + * - printf, scanf (outside the measurement loop) + * In addition, Berkeley UNIX system calls "times ()" or "time ()" + * are used for execution time measurement. For measurements + * on other systems, these calls have to be changed. + * + * Collection of Results: + * Reinhold Weicker (address see above) and + * + * Rick Richardson + * PC Research. Inc. + * 94 Apple Orchard Drive + * Tinton Falls, NJ 07724 + * Phone: (201) 389-8963 (9-17 EST) + * Usenet: ...!uunet!pcrat!rick + * + * Please send results to Rick Richardson and/or Reinhold Weicker. + * Complete information should be given on hardware and software used. + * Hardware information includes: Machine type, CPU, type and size + * of caches; for microprocessors: clock frequency, memory speed + * (number of wait states). + * Software information includes: Compiler (and runtime library) + * manufacturer and version, compilation switches, OS version. + * The Operating System version may give an indication about the + * compiler; Dhrystone itself performs no OS calls in the measurement loop. + * + * The complete output generated by the program should be mailed + * such that at least some checks for correctness can be made. + * + *************************************************************************** + * + * History: This version C/2.1 has been made for two reasons: + * + * 1) There is an obvious need for a common C version of + * Dhrystone, since C is at present the most popular system + * programming language for the class of processors + * (microcomputers, minicomputers) where Dhrystone is used most. + * There should be, as far as possible, only one C version of + * Dhrystone such that results can be compared without + * restrictions. In the past, the C versions distributed + * by Rick Richardson (Version 1.1) and by Reinhold Weicker + * had small (though not significant) differences. + * + * 2) As far as it is possible without changes to the Dhrystone + * statistics, optimizing compilers should be prevented from + * removing significant statements. + * + * This C version has been developed in cooperation with + * Rick Richardson (Tinton Falls, NJ), it incorporates many + * ideas from the "Version 1.1" distributed previously by + * him over the UNIX network Usenet. + * I also thank Chaim Benedelac (National Semiconductor), + * David Ditzel (SUN), Earl Killian and John Mashey (MIPS), + * Alan Smith and Rafael Saavedra-Barrera (UC at Berkeley) + * for their help with comments on earlier versions of the + * benchmark. + * + * Changes: In the initialization part, this version follows mostly + * Rick Richardson's version distributed via Usenet, not the + * version distributed earlier via floppy disk by Reinhold Weicker. + * As a concession to older compilers, names have been made + * unique within the first 8 characters. + * Inside the measurement loop, this version follows the + * version previously distributed by Reinhold Weicker. + * + * At several places in the benchmark, code has been added, + * but within the measurement loop only in branches that + * are not executed. The intention is that optimizing compilers + * should be prevented from moving code out of the measurement + * loop, or from removing code altogether. Since the statements + * that are executed within the measurement loop have NOT been + * changed, the numbers defining the "Dhrystone distribution" + * (distribution of statements, operand types and locality) + * still hold. Except for sophisticated optimizing compilers, + * execution times for this version should be the same as + * for previous versions. + * + * Since it has proven difficult to subtract the time for the + * measurement loop overhead in a correct way, the loop check + * has been made a part of the benchmark. This does have + * an impact - though a very minor one - on the distribution + * statistics which have been updated for this version. + * + * All changes within the measurement loop are described + * and discussed in the companion paper "Rationale for + * Dhrystone version 2". + * + * Because of the self-imposed limitation that the order and + * distribution of the executed statements should not be + * changed, there are still cases where optimizing compilers + * may not generate code for some statements. To a certain + * degree, this is unavoidable for small synthetic benchmarks. + * Users of the benchmark are advised to check code listings + * whether code is generated for all statements of Dhrystone. + * + * Version 2.1 is identical to version 2.0 distributed via + * the UNIX network Usenet in March 1988 except that it corrects + * some minor deficiencies that were found by users of version 2.0. + * The only change within the measurement loop is that a + * non-executed "else" part was added to the "if" statement in + * Func_3, and a non-executed "else" part removed from Proc_3. + * + *************************************************************************** + * + * Defines: The following "Defines" are possible: + * -DREG=register (default: Not defined) + * As an approximation to what an average C programmer + * might do, the "register" storage class is applied + * (if enabled by -DREG=register) + * - for local variables, if they are used (dynamically) + * five or more times + * - for parameters if they are used (dynamically) + * six or more times + * Note that an optimal "register" strategy is + * compiler-dependent, and that "register" declarations + * do not necessarily lead to faster execution. + * -DNOSTRUCTASSIGN (default: Not defined) + * Define if the C compiler does not support + * assignment of structures. + * -DNOENUMS (default: Not defined) + * Define if the C compiler does not support + * enumeration types. + * -DTIMES (default) + * -DTIME + * The "times" function of UNIX (returning process times) + * or the "time" function (returning wallclock time) + * is used for measurement. + * For single user machines, "time ()" is adequate. For + * multi-user machines where you cannot get single-user + * access, use the "times ()" function. If you have + * neither, use a stopwatch in the dead of night. + * "printf"s are provided marking the points "Start Timer" + * and "Stop Timer". DO NOT use the UNIX "time(1)" + * command, as this will measure the total time to + * run this program, which will (erroneously) include + * the time to allocate storage (malloc) and to perform + * the initialization. + * -DHZ=nnn + * In Berkeley UNIX, the function "times" returns process + * time in 1/HZ seconds, with HZ = 60 for most systems. + * CHECK YOUR SYSTEM DESCRIPTION BEFORE YOU JUST APPLY + * A VALUE. + * + *************************************************************************** + * + * Compilation model and measurement (IMPORTANT): + * + * This C version of Dhrystone consists of three files: + * - dhry.h (this file, containing global definitions and comments) + * - dhry_1.c (containing the code corresponding to Ada package Pack_1) + * - dhry_2.c (containing the code corresponding to Ada package Pack_2) + * + * The following "ground rules" apply for measurements: + * - Separate compilation + * - No procedure merging + * - Otherwise, compiler optimizations are allowed but should be indicated + * - Default results are those without register declarations + * See the companion paper "Rationale for Dhrystone Version 2" for a more + * detailed discussion of these ground rules. + * + * For 16-Bit processors (e.g. 80186, 80286), times for all compilation + * models ("small", "medium", "large" etc.) should be given if possible, + * together with a definition of these models for the compiler system used. + * + ************************************************************************** + * + * Dhrystone (C version) statistics: + * + * [Comment from the first distribution, updated for version 2. + * Note that because of language differences, the numbers are slightly + * different from the Ada version.] + * + * The following program contains statements of a high level programming + * language (here: C) in a distribution considered representative: + * + * assignments 52 (51.0 %) + * control statements 33 (32.4 %) + * procedure, function calls 17 (16.7 %) + * + * 103 statements are dynamically executed. The program is balanced with + * respect to the three aspects: + * + * - statement type + * - operand type + * - operand locality + * operand global, local, parameter, or constant. + * + * The combination of these three aspects is balanced only approximately. + * + * 1. Statement Type: + * ----------------- number + * + * V1 = V2 9 + * (incl. V1 = F(..) + * V = Constant 12 + * Assignment, 7 + * with array element + * Assignment, 6 + * with record component + * -- + * 34 34 + * + * X = Y +|-|"&&"|"|" Z 5 + * X = Y +|-|"==" Constant 6 + * X = X +|- 1 3 + * X = Y *|/ Z 2 + * X = Expression, 1 + * two operators + * X = Expression, 1 + * three operators + * -- + * 18 18 + * + * if .... 14 + * with "else" 7 + * without "else" 7 + * executed 3 + * not executed 4 + * for ... 7 | counted every time + * while ... 4 | the loop condition + * do ... while 1 | is evaluated + * switch ... 1 + * break 1 + * declaration with 1 + * initialization + * -- + * 34 34 + * + * P (...) procedure call 11 + * user procedure 10 + * library procedure 1 + * X = F (...) + * function call 6 + * user function 5 + * library function 1 + * -- + * 17 17 + * --- + * 103 + * + * The average number of parameters in procedure or function calls + * is 1.82 (not counting the function values aX * + * + * 2. Operators + * ------------ + * number approximate + * percentage + * + * Arithmetic 32 50.8 + * + * + 21 33.3 + * - 7 11.1 + * * 3 4.8 + * / (int div) 1 1.6 + * + * Comparison 27 42.8 + * + * == 9 14.3 + * /= 4 6.3 + * > 1 1.6 + * < 3 4.8 + * >= 1 1.6 + * <= 9 14.3 + * + * Logic 4 6.3 + * + * && (AND-THEN) 1 1.6 + * | (OR) 1 1.6 + * ! (NOT) 2 3.2 + * + * -- ----- + * 63 100.1 + * + * + * 3. Operand Type (counted once per operand reference): + * --------------- + * number approximate + * percentage + * + * Integer 175 72.3 % + * Character 45 18.6 % + * Pointer 12 5.0 % + * String30 6 2.5 % + * Array 2 0.8 % + * Record 2 0.8 % + * --- ------- + * 242 100.0 % + * + * When there is an access path leading to the final operand (e.g. a record + * component), only the final data type on the access path is counted. + * + * + * 4. Operand Locality: + * ------------------- + * number approximate + * percentage + * + * local variable 114 47.1 % + * global variable 22 9.1 % + * parameter 45 18.6 % + * value 23 9.5 % + * reference 22 9.1 % + * function result 6 2.5 % + * constant 55 22.7 % + * --- ------- + * 242 100.0 % + * + * + * The program does not compute anything meaningful, but it is syntactically + * and semantically correct. All variables have a value assigned to them + * before they are used as a source operand. + * + * There has been no explicit effort to account for the effects of a + * cache, or to balance the use of long or short displacements for code or + * data. + * + *************************************************************************** + */ + +/* Compiler and system dependent definitions: */ + +#ifndef TIME +#undef TIMES +#define TIMES +#endif + /* Use times(2) time function unless */ + /* explicitly defined otherwise */ + +#ifdef MSC_CLOCK +#undef HZ +#undef TIMES +#include +#define HZ CLK_TCK +#endif + /* Use Microsoft C hi-res clock */ + +#ifdef TIMES +#include +#include + /* for "times" */ +#endif + +#define Mic_secs_Per_Second 1000000.0 + /* Berkeley UNIX C returns process times in seconds/HZ */ + +#ifdef NOSTRUCTASSIGN +#define structassign(d, s) memcpy(&(d), &(s), sizeof(d)) +#else +#define structassign(d, s) d = s +#endif + +#ifdef NOENUM +#define Ident_1 0 +#define Ident_2 1 +#define Ident_3 2 +#define Ident_4 3 +#define Ident_5 4 + typedef int Enumeration; +#else + typedef enum {Ident_1, Ident_2, Ident_3, Ident_4, Ident_5} + Enumeration; +#endif + /* for boolean and enumeration types in Ada, Pascal */ + +/* General definitions: */ + +#include + /* for strcpy, strcmp */ + +#define Null 0 + /* Value of a Null pointer */ +#define true 1 +#define false 0 + +typedef int One_Thirty; +typedef int One_Fifty; +typedef char Capital_Letter; +typedef int Boolean; +typedef char Str_30 [31]; +typedef int Arr_1_Dim [50]; +typedef int Arr_2_Dim [50] [50]; + +typedef struct record + { + struct record *Ptr_Comp; + Enumeration Discr; + union { + struct { + Enumeration Enum_Comp; + int Int_Comp; + char Str_Comp [31]; + } var_1; + struct { + Enumeration E_Comp_2; + char Str_2_Comp [31]; + } var_2; + struct { + char Ch_1_Comp; + char Ch_2_Comp; + } var_3; + } variant; + } Rec_Type, *Rec_Pointer; + +
rtl_sim/src-c/dhrystone_v2.1/original_files/dhry.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/README =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/README (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/README (revision 145) @@ -0,0 +1,64 @@ +This floppy disk contains the source code of the Dhrystone benchmark +(version 2.1) in three languages: + +Files containing the Ada version (*.s: Specifications, *.b: Bodies): + + d_global.s + d_main.b + d_pack_1.b + d_pack_1.s + d_pack_2.b + d_pack_2.s + + (The file names have been abbreviated to 8 characters plus extension + for MS-DOS) + +Files containing the C version (*.h: Header File, *.c: C Modules) + + dhry.h + dhry_1.c + dhry_2.c + +File containing the Pascal version: + + dhry.p + +The file RATIONALE contains the article + + "Dhrystone Benchmark: Rationale for Version 2 and Measurement Rules" + +which has been published, together with the C source code (Version 2.0), +in SIGPLAN Notices vol. 23, no. 8 (Aug. 1988), pp. 49-62. +This article explains all changes that have been made for Version 2, +compared with the version of the original publication +in Communications of the ACM vol. 27, no. 10 (Oct. 1984), pp. 1013-1030. +It also contains "ground rules" for benchmarking with Dhrystone +which should be followed by everyone who uses the program and publishes +Dhrystone results. + +Compared with the Version 2.0 published in SIGPLAN Notices, Version 2.1 +contains a few corrections that have been made after Version 2.0 was +distriobuted over the UNIX network Usenet. These small differences between +Version 2.0 and 2.1 should not affect execution time measurements. +For those who want to compare the exact contents of both versions, +the file "dhry_c.dif" contains the differences between the two versions, +as generated by a file comparison of the corresponding files with the +UNIX utility "diff". + +Recipients of this floppy disk who perform measurements are asked +to send measurement results to the author and/or to Rick Richardson. +Rick Richardson publishes regularly Dhrystone results on the UNIX network +Usenet. For submissions of results to him (preferably by electronic mail, +see address in the program header), he has provided a form which is contained +in the file "submit.frm". + +August 17, 1988 + + Reinhold P. Weicker + Siemens AG, E STE 35 + Postfach 3240 + D-8520 Erlangen + Germany (West) + + Phone: [xxx-49]-9131-7-20330 (8-17 Central European Time) + Usenet: ..!mcvax!unido!estevax!weicker
rtl_sim/src-c/dhrystone_v2.1/original_files/README Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/clarify.doc =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/clarify.doc (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/clarify.doc (revision 145) @@ -0,0 +1,74 @@ +CLARIFICATION +There seems to have been a great deal of confusion over what this +benchmark measures, and how to use these results. Let me try to clarify +this: + + 1) DHRYSTONE is a measure of processor+compiler efficiency in + executing a 'typical' program. The 'typical' program was + designed by measuring statistics on a great number of + 'real' programs. The 'typical' program was then written + by Reinhold P. Weicker using these statistics. The + program is balanced according to statement type, as well + as data type. + + 2) DHRYSTONE does not use floating point. Typical programs don't. + + 3) DHRYSTONE does not do I/O. Typical programs do, but then + we'd have a whole can of worms opened up. + + 4) DHRYSTONE does not contain much code that can be optimized + by vector processors. That is why a CRAY doesn't look real + fast, they weren't built to do this sort of computing. + + 5) DHRYSTONE does not measure OS performance, as it avoids + calling the O.S. The O.S. is indicated in the results only + to help in identifying the compiler technology. + + 6) DHRYSTONE is not perfect, but is a hell of a lot better than + the "sieve", or "SI". + + 7) DHRYSTONE gives results in dhrystones/second. Bigger + numbers are better. As a baseline, the original IBM PC + gives around 300-400 dhrystones/second with a good compiler. + The fastest machines today are approaching 100,000. + +If somebody asked me to pick out the best machine for the money, I +wouldn't look at just the results of DHRYSTONE. I'd probably: + + 1) Run DHRYSTONE to get a feel for the compiler+processor + speed. + 2) Run any number of benchmarks to check disk I/O bandwidth, + using both sequential and random read/writes. + 3) Run a multitasking benchmark to check multi-user response + time. Typically, these benchmarks run several types of + programs such as editors, shell scripts, sorts, compiles, + and plot the results against the number of simulated users. + 4) If appropriate for the intended use, run something like + WHETSTONE, to determine floating point performance. + 5) If appropriate for intended use, run some programs which do + vector and matrix computations. + 6) Figure out what the box will: + - cost to buy + - cost to operate and maintain + - be worth when it is sold + - be worth if the manufacturer goes out of business + 7) Having done the above, I probably have a hand-full of + machines which meet my price/performance requirements. + Now, I find out if the applications programs I'd like + to use will run on any of these machines. I also find + out how much interest people have in writing new software + for the machine, and look carefully at the migration path + I will have to take when I reach the (inevitable) limits + of the machine. + +To summarize, DHRYSTONES by themselves are not anything more than +a way to win free beers when arguing 'Box-A versus Box-B' religion. +They do provide insight into Box-A/Compiler-A versus Box-A/Compiler-B +comparisons. + + Rick Richardson + PC Research, Inc. + (201) 389-8963 (9-17 EST) + (201) 542-3734 (7-9,17-24 EST) + ...!uunet!pcrat!rick (normal mail) + ...!uunet!pcrat!dry2 (results only)
rtl_sim/src-c/dhrystone_v2.1/original_files/clarify.doc Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/doit =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/doit (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/doit (revision 145) @@ -0,0 +1,22 @@ +#!/bin/sh +PASSES=1000000 + +echo "cc without register ($PASSES passes)" > results +cc_dry2 <>results +$PASSES +MIC +echo "" >>results +echo "cc with register ($PASSES passes)" >>results +cc_dry2reg <>results +$PASSES +MIC +echo "" >>results +echo "gcc without register ($PASSES passes)" >>results +gcc_dry2 <>results +$PASSES +MIC +echo "" >>results +echo "gcc with register ($PASSES passes)" >>results +gcc_dry2reg <>results +$PASSES +MIC
rtl_sim/src-c/dhrystone_v2.1/original_files/doit Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/results =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/results (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/results (revision 145) @@ -0,0 +1,11 @@ +cc without register (1000000 passes) +Microseconds for one run through Dhrystone: 63.2 +Dhrystones per Second: 15835.3 + +cc with register (1000000 passes) +Microseconds for one run through Dhrystone: 63.0 +Dhrystones per Second: 15885.6 + +gcc without register (1000000 passes) + +gcc with register (1000000 passes)
rtl_sim/src-c/dhrystone_v2.1/original_files/results Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/bymanuf =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/bymanuf (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/bymanuf (revision 145) @@ -0,0 +1,858 @@ + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|AEON |332/AT |NS3233|15.00|GENIX |V.3 |NS CTP |2.4 |-O -KC332 | 3413| 3413| |03/12/88|John Behrs | +|Technologi| |2 | | | | | | | | | | |(boulder!fesk! | +|es | | | | | | | | | | | | |ativax!john) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AEON |532/AT |NS3253|25.00|GENIX |V.3 |NS CTP |2.4 |-O -KC532 | 9998| 9998|pipelining |03/12/88|John Behrs | +|Technologi| |2-A1 | | | | | | | | |disabled, chip | |(boulder!fesk! | +|es | | | | | | | | | | |restrictions in | |ativax!john) | +| | | | | | | | | | | |effect | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Alliant |FX/8 |Allian| |Concentr|3.0 |Alliant cc |(?) |-O -ip | 2525| 1615|Compiled for IP's.|03/14/88|cdaf@iuvax.cs. | +|Computer | |t IP | |ix | | | | | | |NOREG faster than | |indiana.edu | +| | | | | | | | | | | |REG. 100K iters | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Alliant |FX/8 |Allian| |Concentr|3.0 |Alliant cc |(?) |-O -ce | 3790| 3929|Compiled for CE's.|03/14/88|cdaf@iuvax.cs. | +|Computer | |t CE | |ix | | | | | | |300K iters | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Amdahl |5880 | | |UTS |SVr3.1 |UTS cc |4.1 |-O | 28300| 28300|rounded to 3 sig |03/10/88|amdahl!chuck (Chuck | +| | | | | | | |8/27/86 | | | |figs | |Simmons) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Amdahl |5880 | | |UTS |SVr3.1 |GNU cc |xperimnt|-O | 32600| 33400|rounded to 3 sig |03/10/88|amdahl!chuck (Chuck | +| | | | | | | |l 3/10/ | | | |figs | |Simmons) | +| | | | | | | |88 | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Amdahl |5890-300E |Dual | |UTS1.2 |SVr3.1 |UTS cc |4.1+ |-O | 48309| 48309|Dhrystones per CPU|05/08/88|amdahl!chuck (Chuck | +| | |CPU | | | | |5/04/88 | | | | | |Simmons) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Amdahl |5890-300E |Dual | |UTS1.2 |SVr3.1 |GNU cc |xperimnt|-O | 55658| 55658|Dhrystones per CPU|05/08/88|amdahl!chuck (Chuck | +| | |CPU | | | | |l 3/10/ | | | | | |Simmons) | +| | | | | | | |88 | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Amdahl |5990-700 |Dual | |UTS1.2 |SVr3.1 |UTS cc |4.1+ |-O | 74074| 74074|Dhrystones per CPU|05/08/88|amdahl!chuck (Chuck | +| | |CPU | | | | |5/04/88 | | | | | |Simmons) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Amdahl |5990-700 |Dual | |UTS1.2 |SVr3.1 |GNU cc |xperimnt|-O | 91463| 91463|Dhrystones per CPU|05/08/88|amdahl!chuck (Chuck | +| | |CPU | | | | |l 3/10/ | | | | | |Simmons) | +| | | | | | | |88 | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|APOLLO |DN3000 |68020 |16.00|DOMAIN | |Domain cc |rev 4.81|-O -M90 | 2519| 2519| |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|APOLLO |DN560 |68020 |16.00|DOMAIN | |Domain cc |rev 4.81|-O -M90 | 2533| 2533| |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|APOLLO |DN4000 |68020 |25.00|DOMAIN | |Domain cc |rev 4.81|-O -M90 | 5714| 5714| |05/15/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Apollo |DN560 |68020 | |Domain/ |9.7 |Apollo cc | |-O | 2320| 2320|100000 iters. |03/14/88|cdaf@iuvax.cs. | +|Computer | | | |IX | | | | | | | | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Apollo |DN3000 |68020 | |Domain/ |9.7 |Apollo cc | | | 2345| 2344|100000 iters |03/14/88|cdaf@iuvax.cs. | +|Computer | | | |IX | | | | | | | | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Apple |Macintosh Plus |68000 | 7.83|Macintos|System |Lightspeed |1.11a | | 781| 781|used TickCount for|03/09/88|andrew.cmu.edu!rich.| +|Computer | | | |h OS |version |Pascal | | | | |timing. | |siegel (Rich Siegel)| +| | | | | |4.2 | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + Page 1 + + + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Apple |Macintosh Plus |68000 | 7.83|Macintos|System |LightspeedC |2.15 | | 719| 789|Used TickCount() |03/09/88|andrew.cmu.edu!rich.| +|Computer | | | |h OS |version | | | | | |for 60HZ accuracy | |siegel (Rich Siegel)| +| | | | | |4.2 | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Apple |Macintosh Plus |68000 | 7.83|Macintos|System |MPW Pascal |2.0.2 |-r (no range| 832| 832|used TickCount. |03/09/88|andrew.cmu.edu!rich.| +|Computer | | | |h OS |version | | |check) | | | | |siegel (Rich Siegel)| +| | | | | |4.2 | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Apple |Macintosh II |68020 |15.70|Multifin|1.0 |Lightspeed C|2.15 |none | 2469| 2469| |03/09/88|Christohper Chow | +|Computer | | | |der | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AST |Premium/286 |80286 |10.00|IBM |3.30 |Borland |3.02A |(none) | 1380| 1380|MemW[seg:off] used|03/13/88|Charles Marslett | +| | | | |PCDOS | |Turbo Pascal| | | | |to read 18.2 Hz | |(chasm@killer.UUCP) | +| | | | | | | | | | | |clock | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AST |Premium/286 |80286 |10.00|IBM |3.30 |Borland |1.0 |-ms/-mc/-ml | 2553| 2553|Loop counter made |03/13/88|Charles Marslett | +| | | | |PCDOS | |Turbo C | |-O-G-Z-a-d | | |"long" for 120,000| |(chasm@killer.UUCP) | +| | | | | | | | | | | |passes | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AST |Premium/286 |80286 |10.00|IBM |3.30 |Microsoft |5.10 |-AS/-AC/-AL | 2907| 2907|50K loops,used |03/13/88| | +| | | | |PCDOS | | |(Beta) |-Oalt -Gs | | |18.2 Hz ctr, Max. | | | +| | | | | | | | | | | |SAFE Opt. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AST |Premium/286 |80286 |10.00|IBM |3.30 |Microsoft |5.10 |-AS/-AC/-AL | 3309| 3309|50K loops, used |03/13/88| | +| | | | |PCDOS | | |(Beta) |-Ox | | |18.2Hz ctr, Max. | | | +| | | | | | | | | | | |Opt. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AT&T |3B2/310 |32100 |10.00|Unix |3.1.1 |cc |3.1 |-O | 1220| 1250| |07/15/88|len@netsys | +| | | | |System V| | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AT&T |6386 WGS |80386 |16.00|MS-DOS |3.2 |Microsoft C |5.0 |-Ox -G2 -AH | 3000| 2985|Huge Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AT&T |6386 WGS |80386 |16.00|MS-DOS |3.2 |Microsoft C |5.0 |-Ox -G2 -AL | 3500| 3521|Large Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AT&T |6386 WGS |80386 |16.00|MS-DOS |3.2 |Microsoft C |5.0 |-Ox -G2 -AC | 3740| 3740|Compact Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AT&T |6386 WGS |80386 |16.00|MS-DOS |3.2 |Microsoft C |5.0 |-Ox -G2 -AM | 3957| 3957|Medium Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|AT&T |6386 WGS |80386 |16.00|MS-DOS |3.2 |Microsoft C |5.0 |-Ox -G2 -AS | 4201| 4267|Small Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Atari |MEGA 2 |68000 | 8.00|TOS |1.4 |Aztec C |3.6A |+L | 783| 851|32 bit int's |08/31/88|uunet!yunexus!yugas!| +|Corp. | | | | | | | | | | | | |julius (Julius | +| | | | | | | | | | | | | |Oklamcak) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Atari |MEGA 2 |68000 | 8.00|TOS |1.4 |Turbo C |1.0 |-G -J -M -P | 1650| 1730|For NOREG all |09/21/88|uunet!nexus!yugas! | +|Corp. | | | | | | | |-R -Z | | |optimization was | |julius (Julius | +| | | | | | | | | | | |turned off | |Oklamcak) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|BBN |BBN Butterfly |68020 | |Chrysali|3.0.1fp |Green Hills |(?) |-O | 961| 1000|Single proc, timed|03/14/88|cdaf@iuvax.cs. | +|Advanced | | | |s | |C | | | | |by REAL TIME clock| |indiana.edu | +|Computers | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + Page 2 + + + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|BBN |Butterfly Plus |68020 |16.00|Chrysali|3.9.2 |Green Hills |180I |-O | 1371| 1469|Timed with REAL |03/11/88|dfk@cs.duke.edu | +|Advanced | | | |s | |C | | | | |TIME, but | | | +|Computers | | | | | | | | | | |effectively | | | +| | | | | | | | | | | |single-user. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|BBN |Butterfly Plus |68020 |16.00|Chrysali|3.9.2 |Green Hills |180I |none | 1489| 1487|Timed with REAL |03/11/88|dfk@cs.duke.edu | +|Advanced | | | |s | |C | | | | |TIME not user | | | +|Computers | | | | | | | | | | |time, but | | | +|Inc | | | | | | | | | | |effectively | | | +| | | | | | | | | | | |single-user. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|CCI |Power 5/32 |68010 |12.50|Unix |BSD 4.2 |MIT cc |? |-O | 1111| 1250| |03/11/88|rutgers!cci632! | +| | | | | | | | | | | | | |walden!jjg | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|COMPAQ |DESKPRO 386/20 |80386 |20.00|COMPAQ |3.31 |Datalight |3.14 |-o | 5434| 5434|Large Model; avg. |07/08/88|amdahl!drivax! | +| | | | |MS-DOS | |Optimum-C | | | | |of best, worst | |alexande (Mark | +| | | | | | | | | | | |results | |Alexander) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|COMPAQ |DESKPRO 386/20 |80386 |20.00|COMPAQ |3.31 |Datalight |3.14 |-o | 5949| 5949|Compact Model; |07/08/88|amdahl!drivax! | +| | | | |MS-DOS | |Optimum-C | | | | |avg. of best, | |alexande (Mark | +| | | | | | | | | | | |worst results | |Alexander) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|COMPAQ |DESKPRO 386/20 |80386 |20.00|COMPAQ |3.31 |Datalight |3.14 |-o | 6097| 6097|Program (P) Model;|07/08/88|amdahl!drivax! | +| | | | |MS-DOS | |Optimum-C | | | | |avg. of best, | |alexande (Mark | +| | | | | | | | | | | |worst results | |Alexander) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|COMPAQ |DESKPRO 386/20 |80386 |20.00|DRI |1.42 |MetaWare |1.4 | | 6385| 6385|"Small" 32-bit |07/08/88|amdahl!drivax! | +| | | | |FlexOS | |High C 386 | | | | |flat model | |alexande (Mark | +| | | | |386 | | | | | | | | |Alexander) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|COMPAQ |DESKPRO 386/20 |80386 |20.00|COMPAQ |3.31 |Datalight |3.14 |-o | 6787| 6787|Small Model; avg. |07/08/88|amdahl!drivax! | +| | | | |MS-DOS | |Optimum-C | | | | |of best, worst | |alexande (Mark | +| | | | | | | | | | | |results | |Alexander) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Computer |Mini-286 |80286 |12.00|Micropor|SVr2.3.0|AT&T pcc |1.3 |-O | 2187| 2187|Small Model |8/15/88 |...!uunet!dmk3b1! | +|Products | | | |t System| | | | | | | | |cocktrice!mdm (Mike | +|United | | | |V/AT | | | | | | | | |Mitchell) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|CONVEX |C210 |propri|25.00|CONVEX |X7.0.0.4|CONVEX |X3.0.0.2|-O2 -uo -rl | 20114| 20107|1 CPU, 1000000 |10/24/88|convex!kcollins | +|Computer | |etary | |UNIX | |Vector C | | | | |iterations | |(Kirby Collins) | +|Corp. | |ECL | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Cray |Cray-2 | | |UNICOS | |cc | |-O | 9375| 10344|300,000 loops |03/14/88|ncsa.uiuc.edu!steve | +|Research | | | | | | | | | | | | |(Steve Christensen) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Cray |Cray-2 | | |UNICOS | |vcc | |-O | 13043| 13043|300,000 loops, no |03/14/88|Steve Christensen, | +|Research | | | | | | | | | | |attempt at further| |NCSA, University of | +| | | | | | | | | | | |optimizations made| |Illinois at | +| | | | | | | | | | | | | |Urbana-Champaign | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Cray |Cray-2/4-128S |s/n |243.0|Unicos |4.0 |Pascal |4.0 |i46,e-,r-,z-| 28600| 28600|1E6 loops; 3 sig |03/14/88|Peter Klausler @ | +|Research | |2012 | | |pre-rel | |pre-rel | | | |figs; inline off | |Cray Research | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + Page 3 + + + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Cray |X-MP/4-16 |s/n |117.0|Unicos |3.0 |Pascal |4.0 |i46,e-,r-,z-| 41500| 41500|1E6 loops; 3 sig |03/14/88|Peter Klausler @ | +|Research | |218 | | | | |pre-rel | | | |figs; inline off | |Cray Research | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |Professional 380| | |VENIX |SVR2.0 |cc | |-O | 528| 568| |07/11/88|magnus@rhi.hi.is | +| | | | | | | | | | | | | |(Magnus Gislason) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 11/750 |VAX 11| |Unix |BSD 4.3 |gcc |1.24 | | 538| 568|HZ=60; multiuser; |07/21/88|thos@cca.ucsf.edu | +| | | | | | | | | | | |avg middle 3 of 5 | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 11/750 |VAX 11| |Unix |BSD 4.3 |cc |4.3 | | 583| 622|HZ=60; times call |07/12/88|thos@cca.ucsf.edu | +| | | | | | | | | | | |and time cmd | | | +| | | | | | | | | | | |consistent; | | | +| | | | | | | | | | | |multiuser | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 11/750 |VAX 11| |Unix |BSD 4.3 |cc |4.3 |-O | 675| 701|HZ=60; times call |07/12/88|thos@cca.ucsf.edu | +| | | | | | | | | | | |and time cmd | | | +| | | | | | | | | | | |consistent; | | | +| | | | | | | | | | | |multiuser | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |Vax 11/750 |Vax 11| |Unix |BSD 4.3 |Unix Pascal |4.3 | | 767| 767| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 11/750 |VAX 11| |Unix |BSD 4.3 |gcc |1.24 |-O | 735| 772|HZ=60; multiuser; |07/21/88|thos@cca.ucsf.edu | +| | | | | | | | | | | |avg middle 3 of 5 | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |11/750 | | |MACH/4.3| |pcc | |-O | 840| 863| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |Vax 11/750 |Vax 11| |Unix |BSD 4.3 |Unix C |4.3 |-O | 901| 971| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |11/750 | | |UNIX |4.3 BSD |cc | |-O | 962| 976| |03/13/88|Sharan Kalwani | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 11/750 | | |BSD |4.3 |cc |?? |-O | 1160| 1160| |03/08/88|thompson@dalcs.uucp | +| | | | | | | | | | | | | |(Michael Thompson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |uVAX II | | |Ultrix |1.2 |cc | |-O | 1365| 1412| |07/11/88|magnus@rhi.hi.is | +| | | | | | | | | | | | | |(Magnus Gislason) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |UVAX II | | |Ultrix |2.0 |cc |?? |-O | 1415| 1415| |03/08/88|thompson@dalcs.uucp | +| | | | | | | | | | | | | |(Michael Thompson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |11/780 | | |Ultrix |2.0-1 |/bin/cc |(?) |-O | 1336| 1418|100000 iters |03/14/88|cdaf@iuvax.cs. | +| | | | | | | | | | | | | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |uVAX II | | |MACH/4.3| |pcc | |-O | 1450| 1476| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 780 | | |MACH/4.3| |pcc | |-O | 1424| 1517| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 8250 | | |MACH/4.3| |pcc | |-O | 1521| 1571| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + + Page 4 + + + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|DEC |VAX 785 | | |BSD Unix|4.3 |pc | | | 1864| 1864|pascal version |03/17/88|gamiddleton@math. | +| | | | | | | | | | | | | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 785 | | |BSD Unix|4.3 |cc | | | 1857| 1948| |03/17/88|gamiddleton@math. | +| | | | | | | | | | | | | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 785 | | |BSD Unix|4.3 |cc | |-O | 1929| 1960| |03/17/88|gamiddleton@math. | +| | | | | | | | | | | | | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 785 | | |MACH/4.3| |pcc | |-O | 1972| 2004| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |785 | | |VMS |4.4 |VAX C |2.1 | | 2040| 2040|real time at high |03/14/88|egisin@Waterloo.EDU | +| | | | | | | | | | | |priority | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 6220 |CVAX |12.50|MACH/4.3| |4.3 pcc | |-O | 3706| 3859|1 of 4 processors |05/15/88|Lawrence Butcher | +| | |chips | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |Vax 8800 | | |Ultrix |2.0-1 |/usr/ucb/pc |(?) |-O | 7846| 7846|300000 iters |03/14/88|cdaf@iuvax.cs. | +| | | | | | | | | | | | | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |8650 | | |Ultrix |2.0-1 |/bin/cc |(?) |-O | 7762| 8021|30000 iters |03/14/88|cdaf@iuvax.cs. | +| | | | | | | | | | | | | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 8650 | | |MACH/4.3| |pcc | |-O | 8392| 8593|dry ratings vary |03/09/88|Lawrence Butcher | +| | | | | | | | | | | |wildly +- 2000 | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |Vax 8800 | | |Ultrix |2.0-1 |/bin/cc |(?) |-O | 8867| 8991|300000 iters |03/14/88|cdaf@iuvax.cs. | +| | | | | | | | | | | | | |indiana.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 8800 | | |MACH/4.3| |pcc | |-O | 9569| 9696|one processor |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|DEC |VAX 8700 | | |UNIX |SVR2.0v2|cc | |-O | 10791| 11082| |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Dell |System 310 |80386 |20.00|SCO |2.2.2 |XENIX386 |2.2 |-Ox | 6500| 6975| |11/05/88|Joe Carlson | +|Computers | | | |XENIX/ | |Development | | | | | | |(carlson@lll-winken.| +| | | | |386 | |Sys | | | | | | |llnl.gov) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|ENCORE |MULTIMAX |32020 | |Mach | | | |-O -q | 1323| 1323|1 of 16 processors|03/14/88|Lawrence Butcher | +| | | | | | | | |novolatile | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|ENCORE |MULTIMAX |32032 |10.00|Mach | | | |-O -q | 1323| 1323|1 of 16 processors|03/14/88|Lawrence Butcher | +| | | | | | | | |novolatile | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|ENCORE |MULTIMAX |32332 |15.00|Mach | | | |-O -q | 3059| 3071|1 of 16 processors|04/16/88|Lawrence Butcher | +| | | | | | | | |novolatile | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Encore |Multimax 320 |NS3253|25.00|Umax4.2 |A3.3 |C-32000 |1.8.4 |-O -q o=t | 11117| 11223|Alpha HW. |12/03/88|James R. Grier | +|Computer | |2 | | | |Green Hills | | | | |Production will be| | | +|Corporatio| | | | | |Software, | | | | |30Mhz. | | | +|n | | | | | |Inc. | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + + + Page 5 + + + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Everex/AT |1800A |80286 |10.00|Micropor|SysVr2; |AT&T cc | |-O -Ml | 1336| 1352|large model |03/15/88|Jay Maynard | +|Plus | | | |t System|SV/AT | | | | | | | |(uunet!nuchat!splut!| +| | | | |V/AT |2.3.0-L | | | | | | | |jay) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Everex/AT |1800A |80286 |10.00|Micropor|SysVr2; |AT&T cc | |-O | 1875| 1879|small model |03/15/88|Jay Maynard | +|Plus | | | |t System|SV/AT | | | | | | | |(uunet!nuchat!splut!| +| | | | |V/AT |2.3.0-L | | | | | | | |jay) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Frank Hogg|QT+ |68000 |10.00|Os9/68k |2.1 |Microware C |2.2 | | 610| 649| |03/11/88|blarson@skat.usc.edu| +|Labs | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|GMX |Micro-20 |68020 |20.00|OS-9 |2 |Microware |5 | | 1875| 1875| |03/27/88|Peter Dibble | +| | | | | | |Pascal | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|GMX |Micro-20 |68020 |20.00|OS-9 |2 |Microware C |3 |-k2f | 2128| 2632| |03/27/88|Peter Dibble | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|GMX |Micro-20 |68020 |20.00|OS-9 |2 |Microware C |3 |-k2wf | 2222| 2632| |03/27/88|Peter Dibble | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|GMX |Micro-20 |68020 |20.00|OS-9 |2.2 |Microware C |3 |-k2l | 2500| 2941| |07/27/88|Peter Dibble | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|GOULD |9080 | | | | | | |-O | 4335| 4545|1 of 2 proc.'s |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Harris |H-1200 | | |VOS |6.1.1 |VOS C |6.1.1 | | 2024| 2024| | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Harris |MCX-3/40 |68020 |16.67|HS/UX |3.0B |HS/UX C |3.0B |-O | 4178| 4215| | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Heurikon |HK68 |68010 |10.00|UniPlus+|5.0 |pcc | |-O | 507| 558| |07/08/88|johnl@gronk.UUCP | +| | | | |System V| | | | | | | | |(John Limpert) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Heurikon |HK68 |68010 |10.00|UniPlus+|5.0 |Green Hills |1.8.0 |-O | 719| 750| |07/08/88|johnl@gronk.UUCP | +| | | | |System V| | | | | | | | |(John Limpert) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Honeywell |DPS-8/49 | | |GCOS8 |SR3000 |Waterloo SDG|8cl3.1 | | 960| 960|single-segment |03/10/88|gamiddleton@math. | +| | | | | | |C | | | | |mode | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Honeywell |DPS-8/49 | | |GCOS8 |SR3000 |Waterloo SDG|8cv1.0 | | 1094| 1094|native-segment |03/10/88|gamiddleton@math. | +| | | | | | |C | | | | |mode | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Honeywell |DPS 8/70 | | |GCOS8 |SR3000 |Waterloo SDG|8cl3.1 | | 1653| 1653|single-segment |03/15/88|gamiddleton@math. | +| | | | | | |C | | | | |mode | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Honeywell |DPS 8000 | | |GCOS8 |SR3000 |Waterloo SDG|8cl3.1 | | 2483| 2483|single-segment |03/15/88|gamiddleton@math. | +| | | | | | |C | | | | |mode | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Honeywell |DPS 88 | | |GCOS8 |SR3000 |Waterloo SDG|8cl3.1 | | 6172| 6172|single-segment |03/15/88|gamiddleton@math. | +| | | | | | |C | | | | |mode | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Honeywell |DPS 90 | | |GCOS8 |SR2500 |Waterloo SDG|8cl3.1 | | 8658| 8658|single-segment |03/15/88|gamiddleton@math. | +| | | | | | |C | | | | |mode | |waterloo.edu | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|HP |9000 ser500 | | |HP-UX |5.2 |cc | |-O | 1176| 1176|single CPU used |04/01/88|mck-csc!bmg | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|HP |9000/320 |68020 |16.67|HPUX | | | |-O | 2660| 2870| |06/25/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + Page 6 + + + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|HP |9000/840 |RISC | |HP-UX |A.B1.20 |cc |A.00.09 |+O2 | 10141| 10172| |07/11/88|magnus@rhi.hi.is | +| | | | | |C | | | | | | | |(Magnus Gislason) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 9.00|SCO |2.2.1 |cc | |-Ox -M2l -K | 715| 727|Large Model |03/09/88|wrp@virginia.EDU | +| | | | |Xenix | | | | | | | | |(Bill Pearson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|Venix |SVr2.3 |AT&T cc |11/8/84 |-O -Ml | 1043| 1043|Large Model |03/04/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|Venix |SVr2.3 |AT&T cc |11/8/84 |-O -Ml | 1043| 1043|Large Model |03/04/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AH | 1437| 1434|Huge Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|Venix |SVr2.3 |AT&T cc |11/8/84 |-O | 1318| 1450|Small Model |03/04/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AL | 1706| 1717|Large Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AC | 1767| 1784|Compact Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 50 |80286 |10.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AH | 1791| 1784|Huge Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 9.00|Xenix |2.2.1 |cc | |-Ox -M2 -K | 1821| 1926|20000 iterations |03/09/88|wrp@virginia.EDU | +| | | | | | | | | | | | | |(Bill Pearson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AM | 2008| 2022|Medium Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PC/AT |80286 | 8.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AS | 2084| 2117|Small Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 50 |80286 |10.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AL | 2133| 2150|Large Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 50 |80286 |10.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AC | 2202| 2220|Compact Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 50 |80286 |10.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AM | 2506| 2527|Medium Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 50 |80286 |10.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AS | 2601| 2638|Small Model |03/11/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 80 |80386 |16.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AH | 3390| 3410|Huge Model |03/18/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |4341-12 | | |Amdahl |SVr2 |UTS cc |1.27 -- |-O | 3632| 3631| |03/12/87|newton@csvax. | +| | | | |UTS |Version | |6/6/86 | | | | | |caltech.edu (Mike | +| | | | | |1.1.3 | | | | | | | |Newton) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |4341-12 | | |Amdahl |SVr2 |UTS cc |1.27 -- |-O -OM | 3820| 3818|'MN' -- with the |3/12/87 |newton@csvax. | +| | | | |UTS |Version | |6/6/86 | | | |`optimizer' I | |caltech.edu (Mike | +| | | | | |1.1.3 | | | | | |posted to USENET | |Newton) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 80 |80386 |16.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AL | 3980| 4040|Large Model |03/18/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 80 |80386 |16.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AC | 4300| 4330|Compact Model |03/18/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |PS/2 Model 80 |80386 |16.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AM | 4470| 4470|Medium Model |03/18/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|IBM |RT Model 125 | | |MACH/4.3| |Metaware |1.4R |-O | 4474| 4474| |03/10/88|Lawrence Butcher | +| | | | | | |HighC | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + Page 7 + + + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|IBM |PS/2 Model 80 |80386 |16.00|PC-DOS |3.3 |Microsoft C |5.0 |-Ox -G2 -AS | 4790| 4910|Small Model |03/18/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Intel |310 |80286 |12.00|Xenix |3.5 |cc | |-O -Ml | 806| 817|Large Model |07/11/88|ficc!karl (Karl | +| | | | | | | | | | | | | |Lehenbauer) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Intel |310 |80286 |12.00|Xenix |3.5 |cc | |-O -Ms | 1630| 1705|Small Model |07/11/88|ficc!karl (Karl | +| | | | | | | | | | | | | |Lehenbauer) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Intel |320 |80386 |16.00|Xenix |3.5 |cc | |-O -Ms | 3586| 3782|Small Model, 286 |07/11/88|ficc!karl (Karl | +| | | | | | | | | | | |mode | |Lehenbauer) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MicroSage |Stride 800 |68030 |25.00|UniStrid|SVr2.2 |PCC2 |2 |-O | 5092| 5371|Native PCC2 based |07/08/88|Bruce Robertson | +|Computer |Series | | |e | | | | | | |C compiler | | | +|Systems | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MicroSage |Stride 800 |68030 |25.00|UniStrid|SVr2.2 |GNU C |1.24 |-O | 5727| 5727| |07/08/88|Bruce Robertson | +|Computer |Series | | |e | | | | | | | | | | +|Systems | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MicroSage |Stride 800 |68030 |25.00|UniStrid|SVr2.2 |GNU C |1.24 |-O | 6112| 6112|Maximum |07/08/88|Bruce Robertson | +|Computer |Series | | |e | | | |-fomit- | | |optimization | | | +|Systems | | | | | | | |frame- | | | | | | +| | | | | | | | |pointer | | | | | | +| | | | | | | | |-finline- | | | | | | +| | | | | | | | |functions | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MIPS |M/500 |R2000 | 8.00|MIPS |UMIPS- |MIPS Pascal |1.11 | | 6225| 6225| |03/10/88|Chuck Musciano | +| | | | |Unix |BSD 2.0 | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MIPS |M/500 |R2000 | 8.00|MIPS |UMIPS- |MIPS C |1.11 |-O | 12135| 12019| |03/10/88|Chuck Musciano | +| | | | |Unix |BSD 2.0 | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MIPS |M500 |MIPS | 8.00|UMIPS | |cc | |-O | 12235| 12083| |03/09/88|Lawrence Butcher | +| | | | |BSD 2.1 | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MIPS |M500 |MIPS | 8.00|UMIPS | |cc | |-O3 global | 12806| 12752| |03/09/88|Lawrence Butcher | +| | | | |BSD 2.1 | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|MIPS |M/1000 |R2000 |16.00|UMIPS/ |2.1 |MIPS cc |1.21 |-O3 | 22531| 22590|1,000,000 loops |03/09/88|alberta!steve | +|Computer | | | |BSD | | | | | | | | |(Steven Sutphen) | +|Co. | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Motorola |Platform-88 |M88100|20.00|UNIX |880617 |Green Hills |1.8.4 |-OM -X230 | 33247| 33247|1E6 loops, Avg of |07/11/88|cs.texas.edu! | +|Computer |Software | | |SVr3 | |C-88000 |Beta | | | |10 timings, no | |oakhill!mpaton | +|Division |Development | | | | | | | | | |inlining | | | +| |Platform | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Motorola/ |PC/68000 |68000 | 8.00|System |Release |cc |Version |-O -HZ60 | 882| 882|Running on a |08/10/88|pyramid!sultra! | +|Four- | | | |V/68 |2 Versio| |1.1 | | | |Compaq DeskPro-286| |dtynan | +|Phase/ | | | | |n 1 | | | | | |w/ a PC/68000 | | | +|Sritek | | | | | | | | | | |co-processor. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + Page 8 + + + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Mylex |386 Motherboard |80386 |16.00|386/ix |1.0.4 |cc |1.0.2 |-O | 3369| 3652|64K cache OFF |07/08/88|pcrat!rick | +| | | | | | | | | | | |(1ws) | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|MS-DOS |3.0 |Microsoft C |5.10 |-Ox -G2 -AH | 3956| 3932|Huge Model |07/08/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|MS-DOS |3.0 |Microsoft C |5.10 |-Ox -G2 -AL | 4623| 4639|Large Model |07/08/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|386/ix |1.0.4 |cc |1.0.2 |-O | 4703| 4950|64K cache ON |07/08/88|pcrat!rick | +| | | | | | | | | | | |(~0ws) | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|386/ix |1.0.4 |GNU gcc |1.26 |-O | 5022| 5022|64K cache ON |08/21/88|pcrat!rick | +| | | | | | | | | | | |(~0ws) | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|MS-DOS |3.0 |Microsoft C |5.10 |-Ox -G2 -AC | 5015| 5058|Compact Model |07/08/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|MS-DOS |3.0 |Microsoft C |5.10 |-Ox -G2 -AM | 5237| 5237|Medium Model |07/08/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |16.00|MS-DOS |3.0 |Microsoft C |5.10 |-Ox -G2 -AS | 5772| 5772|Small Model |07/08/88|pcrat!rick | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Mylex |386 Motherboard |80386 |20.00|386/ix |1.0.4 |cc |1.0.2 |-O | 5970| 6246|64K cache ON |07/19/88|pcrat!rick | +| | | | | | | | | | | |(~0ws) | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|NEC |PC-9801 VX |NEC |16.00|DRI |1.3 |MetaWare |1.4 | | 2566| 2566|100000 iterations |07/08/88|amdahl!drivax! | +| |(SB-8500 V60 CPU|V60 | |FlexOS | |High C V60 | | | | | | |alexande (Mark | +| |board) |(uPD70| |V60 | | | | | | | | |Alexander) | +| | |616) | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|PC's |286 |80286 | 8.00|Micropor|2.3 |cc | |-O -Ml | 911| 912|Large memory model|03/30/88|uunet!actnyc!jhs | +|Limited | | | |t System| | | | | | | | | | +| | | | |V/AT | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|PC's |286 |80286 | 8.00|Micropor|2.3 |cc | |-O | 1266| 1266|Small memory model|03/30/88|uunet!actnyc!jhs | +|Limited | | | |t System| | | | | | | | | | +| | | | |V/AT | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|PCS Cadmus|Cadmus 9230 / |Mc6801|10.00|MUNIX |System |cc |1.July |-O -f | 1258| 1348|cc needs -f option|03/10/88|mcvax!unido!infko! | +|GmbH, |Qu68050-A |0 | |V.2/6b-v|V.2 | |86 | | | |for floating point| |droege | +|Munich | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|PCS Cadmus|Cadmus 9600 / |Mc6802|12.50|MUNIX |System |cc |20.Oct. |-O -fH | 2448| 2646|cc needs -fH |03/10/88|mcvax!unido!infko! | +|GmbH, |MWS-3 |0 | |V.2/32- |V.2 | |86 | | | |option to include | |droege | +|Munich | | | |1.1 | | | | | | |floating point | | | +| | | | | | | | | | | |processor | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|PCS GmbH |Cadmus 9230-a |68010 |10.00|UNIX |V.2/06b |cc | |-O | 1268| 1363| |08/17/88|droege@infko.UUCP | +|Munich | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|PCS GmbH |Cadmus 9600 |68020 |12.50|UNIX |V.2/1.2 |cc | |-O | 2447| 2665| |08/17/88|droege@infko.UUCP | +|Munich |MWS/3 | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + + + + Page 9 + + + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Pinnacle |XL |68000 |12.00|UNIX |System |cc |2.3 |-O | 1162| 1260|The OS claims to |07/22/88|uunet!mcl!stacy | +| | | | | |V.~2 | |83/07/08| | | |be V.2 but is sure| |(Stacy L. Millions) | +| | | | | | | | | | | |aint SVID | | | +| | | | | | | | | | | |compliant. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Prime |6350 | | |Primos |21.0.1. |Prime C |21.0 |-32ix | 11111| 10869|strcpy etc. |03/11/88| | +| | | | | |R4 | | |-optimize 1 | | |generate inline | | | +| | | | | | | | |-standardint| | |code | | | +| | | | | | | | |rinsics | | | | | | +| | | | | | | | |-pbstring | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Prime |EXL 316 |80386 |16.00|UNIX |SVR3.0 |SVS C |2.8 |-O | 6878| 7025|500000 iter |07/07/88|uunet!ssgp32!pj | +|Computer | | | | | | | | | | | | |(Peter Weyman) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Prime |EXL 325 |80386 |25.00|UNIX |SVR3.0 |SVS C |2.8 |-O | 10711| 10860|500000 iter |07/07/88|uunet!ssgp32!pj | +|Computer | | | | | | | | | | | | |(Peter Weyman) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|SEQUENT |BALANCE 8000 |32032 | |Mach | | | |-O | 1058| 1110|1 of 32 processors|03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Siemens |Siemens |Custom| |BS 2000 |BS 2000 |Pascal |3.10 B |d-----,o+++ | 844| 844|don't laugh: |03/10/88|mcvax!unido!infko! | +|GmbH, |7.536-200 | | |V 7.5 | | | | | | |option are: "full | |droege | +|Munich | | | | | | | | | | |optimize, no debug| | | +| | | | | | | | | | | |code" | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Silicon |4D/70G |MIPS |25.00|Unix |SGI |MIPS ucode C|1.21 |none | 12621| 13455|1000000 cycles |07/11/88|cherry@mgh-frodo. | +|Graphics, | |R2000 | |System V|4D1-3.0 | | | | | | | |harvard.edu | +|Inc. | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sperry |5000/60 |68000 |12.50|UNIX |SVR2 |cc | |-O | 1371| 1484|Sperry 5000/60 is |07/12/88|ficc!peter (Peter da| +| | | | | | | | | | | |actually Arete | |Silva) | +| | | | | | | | | | | |(now ARIX) | | | +| | | | | | | | | | | |1100/???. | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SunOS |3.4 |Sun Pascal |3.4 | | 1884| 1884| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/180 |68020 |16.67|SunOS |3.4 |Sun Pascal |3.4 | | 2371| 2371| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SunOS |3.4 |cc |3.4 |-O | 2344| 2578|100000 iterations |03/09/88|mikew@x2.wyse.com | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SunOS |3.4 |Sun C |3.4 |-O | 2374| 2702| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SUN 3.5 | |cc | |-O | 2557| 2859|display ON |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |16.67|SUNOS |4.5 |gcc |1.17 |-O | 2911| 2906|display ON |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SunOS |3.4EXPOR|SUN cc |?? |-O | 3183| 3183| |03/08/88|thompson@dalcs.uucp | +| | | | | |T | | | | | | | |(Michael Thompson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + Page 10 + + + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Sun |3/50 |68020 |15.00|SunOS |3.4EXPOR|SUN cc |?? |-O | 3183| 3183| |03/08/88|thompson@dalcs.uucp | +| | | | | |T | | | | | | | |(Michael Thompson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|SunOS |3.4 |Sun Pascal |3.4 | | 3255| 3255| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/160c |68020 |16.67|SUN UNIX|3.5 |cc | |-O | 3260| 3296|300,000 Loops |03/09/88|ncsa.uiuc.edu!steve | +| | | | | | | | | | | | | |(Steve Christensen) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/180 |68020 |16.67|SunOS |3.4 |Sun C |3.4 |-O | 3123| 3452| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |15.00|SUN 3.5 | |cc | |-O | 3099| 3452|display OFF |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/50 |68020 |16.67|SUNOS |4.5 |gcc |1.17 |-O | 3460| 3460|display OFF |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/160 |68020 |16.67|SUN 3.3n| |cc | |-O | 3271| 3624| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/160 |68020 |16.67|SUNOS |4.5 |gcc |1.17 |-O | 3681| 3681| |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|Sun O/S |3.4 |Sun cc | |-O | 4543| 4035| |03/09/88|alberta!steve | +| | | | | | | | | | | | | |(Steven Sutphen) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/280 |68020 |25.00|SunOS |3.4 |Sun Pascal |3.4 | | 4310| 4310| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|Sun Unix|3.4.2 |Sun cc |3.4.2 |-O | 3947| 4335| |03/11/88|wright@fluke.COM | +| | | | | | | | | | | | | |(Dave Wright) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|SUN 3.5 | |cc | |-O | 4065| 4487| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|SUNOS |4.5 |gcc |1.17 |-O | 4558| 4558| |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|SunOS |3.4 |Sun C |3.4 |-O | 4200| 4702| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/60 |68020 |20.00|SUN 3.5 | |SUN 3.5 cc | |-O | 4243| 4706|Some 3/60's seem |03/09/88|Lawrence Butcher | +| | | | | | | | | | | |faster than | | | +| | | | | | | | | | | |others. Rev lvl? | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/280 |68020 |25.00|SunOS |3.5 |cc |3.5 |-O | 5853| 6410|100000 loops |03/09/88|mikew@x2.wyse.com | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/260 |68020 |25.00|SUNOS |4.5 |gcc |1.17 |-O | 6993| 7012| |03/14/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/280 |68020 |25.00|SunOS |3.4 |Sun C |3.4 |-O | 6255| 7012| |03/10/88|Chuck Musciano | +| | | | | | | | | | | | | |(chuck@trantor. | +| | | | | | | | | | | | | |harris-atd.com) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |3/260 |68020 |25.00|SUN 3.3 | |cc | |-O | 6438| 7146| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + Page 11 + + + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Sun |386i/250 |80386 |25.00|Beta | |Beta 3.4? | |-O | 8000| 8356| |04/06/88|Lawrence Butcher | +| | | | |3.4? | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |386i/250 |80386 |25.00|UNIX |SunOS |Sun CC |Feb 88 |-O | 8113| 8469|1E6 loops |03/22/88|..!uunet!edsews! | +| | | | | |4.0 | | | | | | | |peter (Peter | +| | | | | |(BETA) | | | | | | | |Zadrozny) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |4/280s |SPARC |16.67|SunOS |3.2_ |cc |?? | | 10889| 10889| |03/08/88|thompson@dalcs.uucp | +| | | | | |EXPORT | | | | | | | |(Michael Thompson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |4/110 |SPARC |14.80|SUN 3.2 | |SUN 3.2 | |-O3 global | 12579| 12579| |04/06/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |4/260 |SPARC |16.67|SUN 3.2 | |cc | |-O | 17868| 17868| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |4/280S |SPARC |16.67|SunOS |3.2_ |SUN cc |?? |-O | 17910| 17910| |03/08/88|thompson@dalcs.uucp | +| | | | | |EXPORT | | | | | | | |(Michael Thompson) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |4/260 |SPARC |16.67|SUN 3.2 | |cc | |-O3 global | 18048| 18048| |03/09/88|Lawrence Butcher | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Sun |4/460hm |Sparc |16.67|SUN UNIX|3.2 |cc | |-O3 | 18750| 19230|300,000 loops |03/09/88|ncsa.uiuc.edu!steve | +| | | | | | | | | | | | | |(Steve Christensen) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Tandy |3000HD |80286 |10.00|Xenix |System V|Microsoft cc|03/03/87|-Ot -Ml2 | 1111| 1167|Large Model |03/14/88|cpe!oswald (Roy | +| | | | | | | | | | | | | |Oswald) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Tandy |3000HD |80286 |10.00|Xenix |System V|Microsoft cc|03/03/87|-Ot | 1764| 1875|Small Model |03/14/88|cpe!oswald (Roy | +| | | | | | | | | | | | | |Oswald) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Whitechape|Hitech-10 |MIPS |16.70|WOS BSD |2.0 |cc |1.21 |-O | 24875| 24927|Default |03/16/88|Ian Kemmish | +|l |Workstation |R2000 | | | | | | | | |optimisations | |(ian@wcwvax.uucp) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Whitechape|Hitech-10 |MIPS |16.70|WOS BSD |2.0 |cc |1.21 |-O3 | 26536| 26525|Intra-module |03/16/88|Ian Kemmish | +|l |Workstation |R2000 | | | | | | | | |register | |(ian@wcwvax.uucp) | +| | | | | | | | | | | |allocation | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Whitechape|Hitech-10 |MIPS |16.70|WOS BSD |2.0 |cc |1.21 |-O4 | 29527| 29615|Global register |03/16/88|Ian Kemmish | +|l |Workstation |R2000 | | | | | | | | |allocation | |(ian@wcwvax.uucp) | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Whitechape|Hitech-10 |MIPS |16.70|WOS BSD |2.0 |cc |1.21 |-O4 + | 30456| 30472|Includes procedure|03/16/88|Ian Kemmish | +|l |Workstation |R2000 | | | | | |-feedback | | |in-lining | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Whole |Mylex 386/AT |80386 |16.00|Unix |SVr3.0 |AT&T cc |7/2/87 |-O | 4704| 4955|64 kbyte 0-wait |07/11/88|sugar!karl (Karl | +|Earth | | | | | | | | | | |cache enabled | |Lehenbauer) | +|Electronic| | | | | | | | | | | | | | +|s | | | | | | | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Wyse |3216 |80386 |16.00|Unix |SVR3 |cc |3.0 |-O | 4208| 4526|100000 loops |03/09/88|mikew@x2.wyse.com | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|Wyse |3216 |80386 |16.00|Unix |SVR3 |Greenhills |1.8.2H |-O | 5988| 6038|100000 loops, Yes|03/09/88|mikew@x2.wyse.com | +| | | | | | |C-386 | | | | |it really was | | | +| | | | | | | | | | | |slower with the -O| | | +| | | | | | | | | | | |switch | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + Page 12 + + + + + DHRYSTONE 2.n RESULTS SORTED BY MANUFACTURER Sun Dec 4 02:10:56 EST 1988 + + +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|manuf |model |proc |clock|os |osver |compiler |cver |options | noreg| reg|notes |date |submit | +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| +|Wyse |3216 |80386 |16.00|Unix |SVR3 |Greenhills |1.8.2H | | 6157| 6297|100000 loops |03/09/88|mikew@x2.wyse.com | +| | | | | | |C-386 | | | | | | | | +|__________|________________|______|_____|________|________|____________|________|____________|_______|_______|__________________|________|____________________| +|--------------------------------------------------------------------------------------------------------------------------------------------------------------| + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Page 13 + +
rtl_sim/src-c/dhrystone_v2.1/original_files/bymanuf Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/dhry-2.1.p =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/dhry-2.1.p (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/dhry-2.1.p (revision 145) @@ -0,0 +1,839 @@ +(* + **************************************************************************** + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: Pascal, Version 2.1 + * + * File: dhry.p + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * Siemens AG, E STE 35 + * Postfach 3220 + * 8520 Erlangen + * Germany (West) + * Phone: [xxx-49]-9131-7-20330 + * (8-17 Central European Time) + * Usenet: ..!mcvax!unido!estevax!weicker + * + * Original Version (in Ada) published in + * "Communications of the ACM" vol. 27., no. 10 (Oct. 1984), + * pp. 1013 - 1030, together with the statistics + * on which the distribution of statements etc. is based, + * + * This version uses calls to the Pascal runtime library of the + * Berkeley UNIX system (4.3 bsd) for time measurement. + * For measurements on other systems, these calls need to be + * modified. + * + * Collection of Results: + * Reinhold Weicker (address see above) and + * + * Rick Richardson + * PC Research. Inc. + * 94 Apple Orchard Drive + * Tinton Falls, NJ 07724 + * Phone: (201) 834-1378 (9-17 EST) + * Usenet: ...!seismo!uunet!pcrat!rick + * + * Please send results to Rick Richardson and/or Reinhold Weicker. + * Complete information should be given on hardware and software used. + * Hardware information includes: Machine type, CPU, type and size + * of caches; for microprocessors: clock frequency, memory speed + * (number of wait states). + * Software information includes: Compiler (and runtime library) + * manufacturer and version, compilation switches, OS version. + * The Operating System version may give an indication about the + * compiler; Dhrystone itself performs no OS calls in the measurement loop. + * + * The complete output generated by the program should be mailed + * such that at least some checks for correctness can be made. + * + **************************************************************************** + * + * History: This version Pascal/2.1 has been made for two reasons: + * + * 1) There is a need for a common Pascal version of + * Dhrystone. Although translation from the published (Ada) + * version to Pascal is straightforward in most aspects, + * there are cases where it may not be obvious to everyone. + * There should be, as far as possible, only one Pascal version + * of Dhrystone such that results can be compared without + * restrictions. Also, a Pascal version of Dhrystone has not yet + * found a network distribution comparable to the C version + * (version 1.1) distributed by Rick Richardson. + * + * 2) As far as it is possible without changes to the Dhrystone + * statistics, optimizing compilers should be prevented from + * removing significant statements. + * + * This Pascal version 2.1 has been made consistent with the + * C version 2.1; therefore the acknowledgments for the C version + * are due for the Pascal version as well: I thank + * Rick Richardson (Tinton Falls, NJ), Chaim Benedelac (Nat. + * Semi.), David Ditzel (SUN), Earl Killian and John Mashey (MIPS), + * Alan Smith and Rafael Saavedra-Barrera (UC at Berkeley) + * for their help with comments on earlier versions of the + * benchmark. + * + * Changes: In the initialization part, this version differs + * from the Pascal version previously distributed by Reinhold + * Weicker, the number of runs through Dhrystone is obtained + * interactively from the terminal. Output of the result + * has been changed to conform to the C version (2.1). + * The changes in the initialization part and in the printing + * of the result have no impact on performance measurement + * since they are outside the measaurement loop. + * + * Inside the measurement loop, this version follows the + * version previously distributed by Reinhold Weicker. + * As a correction to the published version, a statement + * initializing Array2Glob [8,7] (outside the measurement + * loop) has been added. Otherwise, this array element would + * have an undefined value. + * + * At several places in the benchmark, code has been added, + * but within the measurement loop only in branches that + * are not executed. The intention is that optimizing compilers + * should be prevented from moving code out of the measurement + * loop, or from removing code altogether. Since the statements + * that are executed within the measurement loop have NOT been + * changed, all numbers defining the "Dhrystone distribution" + * (distribution of statements, operand types and locality) + * still hold. Except for sophisticated optimizing compilers, + * execution times for this version should be the same as + * for previous versions. + * + * Since it has proven difficult to subtract the time for the + * measurement loop overhead in a correct way, the loop check + * has been made a part of the benchmark. This does have + * an impact - though a very minor one - on the distribution + * statistics which have been updated for this version. + * + * All changes within the measurement loop are described + * and discussed in the companion paper "Rationale for + * Dhrystone version 2". + * + * Because of the self-imposed limitation that the order and + * distribution of the executed statements should not be + * changed, there are still cases where optimizing compilers + * may not generate code for some statements. To a certain + * degree, this is unavoidable for small synthetic benchmarks. + * Users of the benchmark are advised to check code listings + * whether code is generated for all statements of Dhrystone. + * + * Version 2.1 is identical to version 2.0 distributed via + * the UNIX network Usenet in March 1988 except that it corrects + * some minor deficiencies that were found by users of version 2.0. + * The only change within the measurement loop is that a + * non-executed "else" part was added to the "if" statement in + * Func3, and a non-executed "else" part removed from Proc3. + * + *************************************************************************** + * + * Compilation model and measurement (IMPORTANT): + * + * This program contains the Dhrystone program, including measurement setup, + * in one file. The original (Ada) program contained three packages, + * - a package with global type definitions, + * - Pack_1, containing the main program (Proc_0 in Ada) and procedures + * Proc_1, ... , Proc_5, + * - Pack_2, containing Proc_6, ... , Proc_8, Func_1, ..., Func_3. + * Since ISO/ANSI Standard Pascal provides no means to express separate + * compilation (although many Pascal implementations provide such a feature), + * it is not possible to formulate a portable Pascal version with the program + * in several modules, corresponding more closely to the Ada and C versions. + * Therefore, no attempt has been made to construct a Pascal version with + * the program consisting of several modules. + * + * This difference may impact execution time because the compiler can + * perform more data flow analysis for a single-module program; + * sophisticated compilers may be able to suppress code generation for + * some parts of the program. + * Users should check machine code listings generated by the compiler + * to ensure that code is generated for all parts of the program. + * + * The following "ground rules" apply for measurements: + * - No procedure merging + * - Otherwise, compiler optimizations are allowed but should be indicated + * See the companion paper "Rationale for Dhrystone Version 2" for a more + * detailed discussion of these ground rules. + * + * For 16-Bit processors (e.g. 80x86), times for all compilation models + * ("small", "medium", "large") should be given if possible, together + * with a definition of these models for the compiler system used. + * + ************************************************************************** + * + * Dhrystone (Pascal version) statistics: + * + * [Comment from the first distribution by Reinhold Weicker, + * the distribution statistics have been updated for Version 2.1. + * Note that because of language differences, the numbers are different + * from the Ada version. The main difference is that the variables that + * are local variables of "Proc_0" (Ada) or "main" (C) are global + * variables in the Pascal version.] + * + * The following program contains statements of a high level programming + * language (here: Pascal) in a distribution considered representative: + * + * assignments 58 + * control statements 28 + * procedure, function calls 15 + * + * 100 statements are dynamically executed. The program is balanced with + * respect to the three aspects: + * + * - statement type + * - operand type (for simple data types) + * - operand access + * operand global, local, parameter, or constant. + * There is no static nesting of blocks or procedures, + * therefore all variables are either global or local. + * + * The combination of these three aspects is balanced only approximately. + * + * 1. Statement Type: + * ----------------- number + * + * V1 := V2 15 + * V := Constant 12 + * (incl. V1 := F(..) + * Assignment, 7 + * with array element + * Assignment, 6 + * with record component + * -- + * 40 40 + * + * X := Y +|-|and|or Z 5 + * X := Y +|-|"=" Constant 6 + * X := X +|- 1 3 + * X := Y *|/ Z 2 + * X := Expression, 1 + * two operators + * X := Expression, 1 + * three operators + * -- + * 18 18 + * + * if .... then .... 14 + * with "else" 7 + * without "else" 7 + * executed 3 + * not executed 4 + * for I in 1..N do ... 7 | counted every time + * while ... do ... 4 | the loop condition + * repeat ... until 1 | is evaluated + * case ... end 1 + * with 1 + * -- + * 28 28 + * + * P (...) procedure call 10 + * X := F (...) + * function call 5 + * -- + * 15 15 + * --- + * 101 + * + * 22 of the 58 assignments have a variable of a constrained + * (sub-)type as their destination. In general, discriminant checks + * will be necessary in these cases; however, the compiler may + * optimize out some of these checks. + * + * The average number of parameters in procedure or function calls + * is 1.80 (not counting the function values as implicit parameters). + * + * + * 2. Operators + * ------------ + * number approximate + * percentage + * + * Arithmetic 27 52.9 + * + * + 16 31.4 + * - 7 13.7 + * * 3 5.9 + * div 1 2.0 + * + * Comparison 20 39.2 + * + * = 9 17.6 + * <> 4 7.8 + * > 1 2.0 + * < 3 5.9 + * >= 1 2.0 + * <= 2 3.9 + * + * Logic 4 7.8 + * + * AND 1 2.0 + * OR 1 2.0 + * NOT 2 3.9 + * + * -- ----- + * 51 99.9 + * + * + * 3. Operand Type (counted once per operand reference): + * --------------- + * number approximate + * percentage + * + * Integer 135 54.7 % + * Character 47 19.0 % + * Enumeration 31 12.6 % + * Boolean 13 5.3 % + * Pointer 11 4.5 % + * String30 6 2.4 % + * Array 2 0.8 % + * Record 2 0.8 % + * --- ------- + * 247 100.1 % + * + * When there is an access path leading to the final operand (e.g. a record + * component), only the final data type on the access path is counted. + * + * There are 16 accesses to components of a record, 9 of them go to + * a component in a variant part. For some of these accesses, the + * compiler may suppress generation of code checking the tag field + * during optimization. + * + * + * 3. Operand Locality: + * ------------------- + * + * local variable 84 34.0 % + * global variable 58 23.5 % + * parameter 45 18.2 % + * value 23 9.3 % + * reference 22 8.9 % + * function result 5 2.0 % + * constant 55 22.3 % + * --- ------- + * 247 100.0 % + * + * + * The program does not compute anything meaningful, but it is syntactically + * and semantically correct. All variables have a value assigned to them + * before they are used as a source operand. + * + * There may be cases where a highly optimizing compiler may recognize + * unnecessary statements and may not generate code for them. + * + * There has been no explicit effort to account for the effects of a + * cache, or to balance the use of long or short displacements for code or + * data. + * + **************************************************************************** + *) + +program Dhrystone (input, output); +(***************) + +const (* for measurement *) + + MicrosecondsPerClock = 1000; + ClocksPerSecond = 1000; + (* In Berkeley UNIX Pascal, the function "clock" *) + (* returns milliseconds *) + TooSmallTime = 2000; + (* Measurements should last at least 2 seconds *) + +type + + (* Global type definitions *) + + Enumeration = (Ident1, Ident2, Ident3, Ident4, Ident5); + + OneToThirty = 1..30; + OneToFifty = 1..50; + CapitalLetter = 'A'..'Z'; + + String30 = packed array [OneToThirty] of char; + + Array1DimInteger = array [OneToFifty] of integer; + Array2DimInteger = array [OneToFifty, OneToFifty] of integer; + + RecordPointer = ^RecordType; + + RecordType = + record + PointerComp: RecordPointer; + case Discr: Enumeration of + Ident1: (* only this variant is used, *) + (* but in some cases discriminant *) + (* checks are necessary *) + (EnumComp: Enumeration; + IntComp: OneToFifty; + StringComp: String30); + Ident2: + (Enum2Comp: Enumeration; + String2Comp: String30); + Ident3, Ident4, Ident5: + (Char1Comp, + Char2Comp: char); + end; (* record *) + +var + + (* Ada version: Variables local in Proc_0 *) + + Int1Glob, + Int2Glob, + Int3Glob: OneToFifty; + CharIndex: char; + EnumGlob: Enumeration; + String1Glob, + String2Glob: String30; + + (* Ada version: Variables global in Pack_1 *) + + PointerGlob, + NextPointerGlob: RecordPointer; + IntGlob: integer; + + BoolGlob: boolean; + Char1Glob, + Char2Glob: char; + Array1Glob: Array1DimInteger; + Array2Glob: Array2DimInteger; + + (* Variables for measurement *) + + RunIndex, + NumberOfRuns, + BeginClock, + EndClock, + SumClocks: integer; + Microseconds, + DhrystonesPerSecond: real; + I: integer; + + (* end of variables for measurement *) + +procedure Proc1 ( PointerParVal: RecordPointer); forward; + +procedure Proc2 (var IntParRef: OneToFifty); forward; + +procedure Proc3 (var PointerParRef: RecordPointer); forward; + +procedure Proc4; forward; + (* without parameters *) + +procedure Proc5; forward; + (* without parameters *) + +procedure Proc6 ( EnumParVal: Enumeration; + var EnumParRef: Enumeration); forward; + +procedure Proc7 ( Int1ParVal, + Int2ParVal: OneToFifty; + var IntParRef: OneToFifty); forward; + +procedure Proc8 (var Array1ParRef: Array1DimInteger; + var Array2ParRef: Array2DimInteger; + Int1ParVal, + Int2ParVal: integer); forward; + +function Func1 ( Char1ParVal, + Char2ParVal: CapitalLetter): + Enumeration; forward; + +function Func2 (var String1ParRef, + String2ParRef: String30): + boolean; forward; + +function Func3 ( EnumParVal: Enumeration): + boolean; forward; + + +procedure Proc1; (* (PointerParVal: RecordPointer) *) + (* executed once *) +begin + with PointerParVal^.PointerComp^ (* = PointerGlobNext *) do + begin + PointerParVal^.PointerComp^ := PointerGlob^; + PointerParVal^.IntComp := 5; + IntComp := PointerParVal^.IntComp; + PointerComp := PointerParVal^.PointerComp; + Proc3 (PointerComp); + (* PointerParVal^.PointerComp^.PointerComp = PointerGlob^.PointerComp *) + if Discr = Ident1 + then (* executed *) + begin + IntComp := 6; + Proc6 (PointerParVal^.EnumComp, EnumComp); + PointerComp := PointerGlob^.PointerComp; + Proc7 (IntComp, 10, IntComp); + end (* then *) + else (* not executed *) + PointerParVal^ := PointerParVal^.PointerComp^; + end; (* with *) +end; (* Proc1 *) + + +procedure Proc2; (* (var IntParRef: OneToFifty) *) + (* executed once *) + (* InParRef = 3, becomes 7 *) +var + IntLoc: OneToFifty; + EnumLoc: Enumeration; +begin + IntLoc := IntParRef + 10; + repeat (* executed once *) + if Char1Glob = 'A' + then (* executed *) + begin + IntLoc := IntLoc - 1; + IntParRef := IntLoc - IntGlob; + EnumLoc := Ident1; + end (* if *) + until EnumLoc = Ident1; (* true *) +end; (* Proc2 *) + + +procedure Proc3; (* (var PointerParRef: RecordPointer) *) + (* executed once *) + (* PointerParRef becomes PointerGlob *) +begin + if PointerGlob <> nil + then (* executed *) + PointerParRef := PointerGlob^.PointerComp; + Proc7 (10, IntGlob, PointerGlob^.IntComp); +end; (* Proc3 *) + + +procedure Proc4; (* without parameters *) + (* executed once *) +var + BoolLoc: boolean; +begin + BoolLoc := Char1Glob = 'A'; + BoolGlob := BoolLoc or BoolGlob; + Char2Glob := 'B'; +end; (* Proc4 *) + + +procedure Proc5; (* without parameters *) + (* executed once *) +begin + Char1Glob := 'A'; + BoolGlob := false; +end; (* Proc5 *) + + +procedure Proc6; (* ( EnumParVal: Enumeration; + var EnumParRef: Enumeration) *) + (* executed once *) + (* EnumParVal = Ident3, EnumParRef becomes Ident2 *) +begin + EnumParRef := EnumParVal; + if not Func3 (EnumParVal) + then (* not executed *) + EnumParRef := Ident4; + case EnumParVal of + Ident1: EnumParRef := Ident1; + Ident2: if IntGlob > 100 + then EnumParRef := Ident1 + else EnumParRef := Ident4; + Ident3: EnumParRef := Ident2; (* executed *) + Ident4: ; + Ident5: EnumParRef := Ident3; + end; (* case *) +end; (* Proc6 *) + + +procedure Proc7; (* ( Int1ParVal, + Int2ParVal: OneToFifty; + var IntParRef: OneToFifty) *) + (* executed three times *) + (* first call: Int1ParVal = 2, Int2ParVal = 3, *) + (* IntParRef becomes 7 *) + (* second call: Int1ParVal = 10, Int2ParVal = 5, *) + (* IntParRef becomes 17 *) + (* third call: Int1ParVal = 6, Int2ParVal = 10, *) + (* IntParRef becomes 18 *) +var + IntLoc: OneToFifty; +begin + IntLoc := Int1ParVal + 2; + IntParRef := Int2ParVal + IntLoc; +end; (* Proc7 *) + + +procedure Proc8; (* (var Array1ParRef: Array1DimInteger; + var Array2ParRef: Array2DimInteger; + Int1ParVal, + Int2ParVal: integer) *) + (* executed once *) + (* Int1ParVal = 3 *) + (* Int2ParVal = 7 *) +var + IntIndex, + IntLoc: OneToFifty; +begin + IntLoc := Int1ParVal + 5; + Array1ParRef [IntLoc] := Int2ParVal; + Array1ParRef [IntLoc+1] := Array1ParRef [IntLoc]; + Array1ParRef [IntLoc+30] := IntLoc; + for IntIndex := IntLoc to IntLoc+1 do + Array2ParRef [IntLoc, IntIndex] := IntLoc; + Array2ParRef [IntLoc, IntLoc-1] := Array2ParRef [IntLoc, IntLoc-1] + 1; + Array2ParRef [IntLoc+20, IntLoc] := Array1ParRef [IntLoc]; + IntGlob := 5; +end; (* Proc8 *) + + +function Func1; (* (Char1ParVal, + Char2ParVal: CapitalLetter): Enumeration *) + (* executed three times, returns always Ident1 *) + (* first call: Char1ParVal = 'H', Char2ParVal = 'R' *) + (* second call: Char1ParVal = 'A', Char2ParVal = 'C' *) + (* third call: Char1ParVal = 'B', Char2ParVal = 'C' *) +var + Char1Loc, Char2Loc: CapitalLetter; +begin + Char1Loc := Char1ParVal; + Char2Loc := Char1Loc; + if Char2Loc <> Char2ParVal + then (* executed *) + Func1 := Ident1 + else (* not executed *) + begin + Char1Glob := Char1Loc; + Func1 := Ident2; + end; +end; (* Func1 *) + + +function Func2; (* (var String1ParRef, + String2ParRef: String30): boolean *) + (* executed once, returns false *) + (* String1ParRef = 'DHRYSTONE PROGRAM, 1''ST STRING' *) + (* String2ParRef = 'DHRYSTONE PROGRAM, 2''ND STRING' *) +var + IntLoc: OneToThirty; + CharLoc: CapitalLetter; +begin + IntLoc := 2; + while IntLoc <= 2 do (* loop body executed once *) + if Func1 (String1ParRef[IntLoc], + String2ParRef[IntLoc+1]) = Ident1 + then (* executed *) + begin + CharLoc := 'A'; + IntLoc := IntLoc + 1; + end; (* if, while *) + if (CharLoc >= 'W') and (CharLoc < 'Z') + then (* not executed *) + IntLoc := 7; + if CharLoc = 'R' + then (* not executed *) + Func2 := true + else (* executed *) + begin + if String1ParRef > String2ParRef + then (* not executed *) + begin + IntLoc := IntLoc + 7; + IntGlob := IntLoc; + Func2 := true + end + else (* executed *) + Func2 := false; + end; (* if CharLoc *) +end; (* Func2 *) + + +function Func3; (* (EnumParVal: Enumeration): boolean *) + (* executed once, returns true *) + (* EnumParVal = Ident3 *) +var + EnumLoc: Enumeration; +begin + EnumLoc := EnumParVal; + if EnumLoc = Ident3 + then (* executed *) + Func3 := true + else (* not executed *) + Func3 := false; +end; (* Func3 *) + + +begin (* main program, corresponds to procedures *) + (* Main and Proc_0 in the Ada version *) + + (* Initializations *) + + new (NextPointerGlob); + + new (PointerGlob); + + PointerGlob^.PointerComp := NextPointerGlob; + PointerGlob^.Discr := Ident1; + PointerGlob^.EnumComp := Ident3; + PointerGlob^.IntComp := 40; + PointerGlob^.StringComp := 'DHRYSTONE PROGRAM, SOME STRING'; + + String1Glob := 'DHRYSTONE PROGRAM, 1''ST STRING'; + + Array2Glob [8,7] := 10; + + writeln; + writeln ('Dhrystone Benchmark, Version 2.1 (Language: Pascal)'); + writeln; + writeln ('Please give the number of runs through the benchmark: '); + readln (NumberOfRuns); + writeln; + writeln ('Execution starts, ', NumberOfRuns : 7, ' runs through Dhrystone'); + + BeginClock := clock; + + (***************) + (* Start timer *) + (***************) + + for RunIndex := 1 to NumberOfRuns do + begin + + Proc5; + Proc4; + (* Char1Glob = 'A', Char2Glob = 'B', BoolGlob = false *) + Int1Glob := 2; + Int2Glob := 3; + String2Glob := 'DHRYSTONE PROGRAM, 2''ND STRING'; + EnumGlob := Ident2; + BoolGlob := not Func2 (String1Glob, String2Glob); + (* BoolGlob = true *) + while Int1Glob < Int2Glob do (* loop body executed once *) + begin + Int3Glob := 5 * Int1Glob - Int2Glob; + (* Int3Glob = 7 *) + Proc7 (Int1Glob, Int2Glob, Int3Glob); + (* Int3Glob = 7 *) + Int1Glob := Int1Glob + 1; + end; (* while *) + (* Int1Glob = 3 *) + Proc8 (Array1Glob, Array2Glob, Int1Glob, Int3Glob); + (* IntGlob = 5 *) + Proc1 (PointerGlob); + for CharIndex := 'A' to Char2Glob do (* loop body executed twice *) + if EnumGlob = Func1 (CharIndex, 'C') + then (* not executed *) + begin + Proc6 (Ident1, EnumGlob); + String2Glob := 'DHRYSTONE PROGRAM, 3''RD STRING'; + Int2Glob := RunIndex; + IntGlob := RunIndex; + end; + (* Int1Glob = 3, Int2Glob = 3, Int3Glob = 7 *) + Int2Glob := Int2Glob * Int1Glob; + Int1Glob := Int2Glob div Int3Glob; + Int2Glob := 7 * (Int2Glob - Int3Glob) - Int1Glob; + (* Int1Glob = 1, Int2Glob = 13, Int3Glob = 7 *) + Proc2 (Int1Glob); + (* Int1Glob = 5 *) + + end; (* for RunIndex *) + + EndClock := clock; + + (**************) + (* Stop timer *) + (**************) + + writeln ('Execution ends'); + writeln; + writeln ('Final values of the variables used in the benchmark:'); + writeln; + + writeln ('IntGlob: ', IntGlob : 5); + writeln (' should be: 5'); + write ('BoolGlob: '); + if BoolGlob = true + then + writeln ('TRUE') + else + writeln ('FALSE'); + writeln (' should be: TRUE'); + writeln ('Char1Glob: ', Char1Glob); + writeln (' should be: A'); + writeln ('Char2Glob: ', Char2Glob); + writeln (' should be: B'); + writeln ('Array1Glob [8]: ', Array1Glob [8] : 5); + writeln (' should be: 7'); + writeln ('Array2Glob [8,7]: ', Array2Glob [8,7] : 5); + writeln (' should be: NumberOfRuns + 10'); + writeln ('PointerGlob^.Discr: ', ord (PointerGlob^.Discr) : 5); + writeln (' should be: 0'); + writeln ('PointerGlob^.EnumComp: ', ord (PointerGlob^.EnumComp) : 5); + writeln (' should be: 2'); + writeln ('PointerGlob^.IntComp : ', PointerGlob^.IntComp : 5); + writeln (' should be: 17'); + write ('PointerGlob^.StringComp: '); + for I := 1 to 30 do + write (PointerGlob^.StringComp [I]); + writeln; + writeln (' should be: DHRYSTONE PROGRAM, SOME STRING'); + writeln ('NextPointerGlob^.Discr: ', ord (NextPointerGlob^.Discr) : 5); + writeln (' should be: 0'); + writeln ('NextPointerGlob^.EnumComp: ', + ord (NextPointerGlob^.EnumComp) : 5); + writeln (' should be: 1'); + writeln ('NextPointerGlob^.IntComp: ', NextPointerGlob^.IntComp : 5); + writeln (' should be: 18'); + write ('NextPointerGlob^.StringComp: '); + for I := 1 to 30 do + write (NextPointerGlob^.StringComp [I]); + writeln; + writeln (' should be: DHRYSTONE PROGRAM, SOME STRING'); + writeln ('Int1Glob: ', Int1Glob : 5); + writeln (' should be: 5'); + writeln ('Int2Glob: ', Int2Glob : 5); + writeln (' should be: 13'); + writeln ('Int3Glob: ', Int3Glob : 5); + writeln (' should be: 7'); + writeln ('EnumGlob: ', ord (EnumGlob) : 5); + writeln (' should be: 1'); + write ('String1Glob: '); + for I := 1 to 30 do + write (String1Glob [I]); + writeln; + writeln (' should be: DHRYSTONE PROGRAM, 1''ST STRING'); + write ('String2Glob: '); + for I := 1 to 30 do + write (String2Glob [I]); + writeln; + writeln (' should be: DHRYSTONE PROGRAM, 2''ND STRING'); + writeln; + writeln; + + SumClocks := EndClock - BeginClock; + + if SumClocks < TooSmallTime + then + begin + writeln ('Measured time too small to obtain meaningful results'); + writeln ('Please increase number of runs'); + writeln; + end + else + begin + Microseconds := SumClocks * (MicrosecondsPerClock / NumberOfRuns); + (* Brackets to prevent integer overflow *) + DhrystonesPerSecond := NumberOfRuns * (ClocksPerSecond / SumClocks); + write ('Microseconds for one run through Dhrystone: '); + writeln (Microseconds : 8 : 1); + write ('Dhrystones per Second: '); + writeln (DhrystonesPerSecond : 8 : 1); + writeln; + end; + +end.
rtl_sim/src-c/dhrystone_v2.1/original_files/dhry-2.1.p Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/dhry.p =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/dhry.p (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/dhry.p (revision 145) @@ -0,0 +1,839 @@ +(* + **************************************************************************** + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: Pascal, Version 2.1 + * + * File: dhry.p + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * Siemens AG, E STE 35 + * Postfach 3240 + * 8520 Erlangen + * Germany (West) + * Phone: [xxx-49]-9131-7-20330 + * (8-17 Central European Time) + * Usenet: ..!mcvax!unido!estevax!weicker + * + * Original Version (in Ada) published in + * "Communications of the ACM" vol. 27., no. 10 (Oct. 1984), + * pp. 1013 - 1030, together with the statistics + * on which the distribution of statements etc. is based, + * + * This version uses calls to the Pascal runtime library of the + * Berkeley UNIX system (4.3 bsd) for time measurement. + * For measurements on other systems, these calls need to be + * modified. + * + * Collection of Results: + * Reinhold Weicker (address see above) and + * + * Rick Richardson + * PC Research. Inc. + * 94 Apple Orchard Drive + * Tinton Falls, NJ 07724 + * Phone: (201) 834-1378 (9-17 EST) + * Usenet: ...!seismo!uunet!pcrat!rick + * + * Please send results to Rick Richardson and/or Reinhold Weicker. + * Complete information should be given on hardware and software used. + * Hardware information includes: Machine type, CPU, type and size + * of caches; for microprocessors: clock frequency, memory speed + * (number of wait states). + * Software information includes: Compiler (and runtime library) + * manufacturer and version, compilation switches, OS version. + * The Operating System version may give an indication about the + * compiler; Dhrystone itself performs no OS calls in the measurement loop. + * + * The complete output generated by the program should be mailed + * such that at least some checks for correctness can be made. + * + **************************************************************************** + * + * History: This version Pascal/2.1 has been made for two reasons: + * + * 1) There is a need for a common Pascal version of + * Dhrystone. Although translation from the published (Ada) + * version to Pascal is straightforward in most aspects, + * there are cases where it may not be obvious to everyone. + * There should be, as far as possible, only one Pascal version + * of Dhrystone such that results can be compared without + * restrictions. Also, a Pascal version of Dhrystone has not yet + * found a network distribution comparable to the C version + * (version 1.1) distributed by Rick Richardson. + * + * 2) As far as it is possible without changes to the Dhrystone + * statistics, optimizing compilers should be prevented from + * removing significant statements. + * + * This Pascal version 2.1 has been made consistent with the + * C version 2.1; therefore the acknowledgments for the C version + * are due for the Pascal version as well: I thank + * Rick Richardson (Tinton Falls, NJ), Chaim Benedelac (Nat. + * Semi.), David Ditzel (SUN), Earl Killian and John Mashey (MIPS), + * Alan Smith and Rafael Saavedra-Barrera (UC at Berkeley) + * for their help with comments on earlier versions of the + * benchmark. + * + * Changes: In the initialization part, this version differs + * from the Pascal version previously distributed by Reinhold + * Weicker, the number of runs through Dhrystone is obtained + * interactively from the terminal. Output of the result + * has been changed to conform to the C version (2.1). + * The changes in the initialization part and in the printing + * of the result have no impact on performance measurement + * since they are outside the measaurement loop. + * + * Inside the measurement loop, this version follows the + * version previously distributed by Reinhold Weicker. + * As a correction to the published version, a statement + * initializing Array2Glob [8,7] (outside the measurement + * loop) has been added. Otherwise, this array element would + * have an undefined value. + * + * At several places in the benchmark, code has been added, + * but within the measurement loop only in branches that + * are not executed. The intention is that optimizing compilers + * should be prevented from moving code out of the measurement + * loop, or from removing code altogether. Since the statements + * that are executed within the measurement loop have NOT been + * changed, all numbers defining the "Dhrystone distribution" + * (distribution of statements, operand types and locality) + * still hold. Except for sophisticated optimizing compilers, + * execution times for this version should be the same as + * for previous versions. + * + * Since it has proven difficult to subtract the time for the + * measurement loop overhead in a correct way, the loop check + * has been made a part of the benchmark. This does have + * an impact - though a very minor one - on the distribution + * statistics which have been updated for this version. + * + * All changes within the measurement loop are described + * and discussed in the companion paper "Rationale for + * Dhrystone version 2". + * + * Because of the self-imposed limitation that the order and + * distribution of the executed statements should not be + * changed, there are still cases where optimizing compilers + * may not generate code for some statements. To a certain + * degree, this is unavoidable for small synthetic benchmarks. + * Users of the benchmark are advised to check code listings + * whether code is generated for all statements of Dhrystone. + * + * Version 2.1 is identical to version 2.0 distributed via + * the UNIX network Usenet in March 1988 except that it corrects + * some minor deficiencies that were found by users of version 2.0. + * The only change within the measurement loop is that a + * non-executed "else" part was added to the "if" statement in + * Func3, and a non-executed "else" part removed from Proc3. + * + *************************************************************************** + * + * Compilation model and measurement (IMPORTANT): + * + * This program contains the Dhrystone program, including measurement setup, + * in one file. The original (Ada) program contained three packages, + * - a package with global type definitions, + * - Pack_1, containing the main program (Proc_0 in Ada) and procedures + * Proc_1, ... , Proc_5, + * - Pack_2, containing Proc_6, ... , Proc_8, Func_1, ..., Func_3. + * Since ISO/ANSI Standard Pascal provides no means to express separate + * compilation (although many Pascal implementations provide such a feature), + * it is not possible to formulate a portable Pascal version with the program + * in several modules, corresponding more closely to the Ada and C versions. + * Therefore, no attempt has been made to construct a Pascal version with + * the program consisting of several modules. + * + * This difference may impact execution time because the compiler can + * perform more data flow analysis for a single-module program; + * sophisticated compilers may be able to suppress code generation for + * some parts of the program. + * Users should check machine code listings generated by the compiler + * to ensure that code is generated for all parts of the program. + * + * The following "ground rules" apply for measurements: + * - No procedure merging + * - Otherwise, compiler optimizations are allowed but should be indicated + * See the companion paper "Rationale for Dhrystone Version 2" for a more + * detailed discussion of these ground rules. + * + * For 16-Bit processors (e.g. 80x86), times for all compilation models + * ("small", "medium", "large") should be given if possible, together + * with a definition of these models for the compiler system used. + * + ************************************************************************** + * + * Dhrystone (Pascal version) statistics: + * + * [Comment from the first distribution by Reinhold Weicker, + * the distribution statistics have been updated for Version 2.1. + * Note that because of language differences, the numbers are different + * from the Ada version. The main difference is that the variables that + * are local variables of "Proc_0" (Ada) or "main" (C) are global + * variables in the Pascal version.] + * + * The following program contains statements of a high level programming + * language (here: Pascal) in a distribution considered representative: + * + * assignments 58 + * control statements 28 + * procedure, function calls 15 + * + * 100 statements are dynamically executed. The program is balanced with + * respect to the three aspects: + * + * - statement type + * - operand type (for simple data types) + * - operand access + * operand global, local, parameter, or constant. + * There is no static nesting of blocks or procedures, + * therefore all variables are either global or local. + * + * The combination of these three aspects is balanced only approximately. + * + * 1. Statement Type: + * ----------------- number + * + * V1 := V2 15 + * V := Constant 12 + * (incl. V1 := F(..) + * Assignment, 7 + * with array element + * Assignment, 6 + * with record component + * -- + * 40 40 + * + * X := Y +|-|and|or Z 5 + * X := Y +|-|"=" Constant 6 + * X := X +|- 1 3 + * X := Y *|/ Z 2 + * X := Expression, 1 + * two operators + * X := Expression, 1 + * three operators + * -- + * 18 18 + * + * if .... then .... 14 + * with "else" 7 + * without "else" 7 + * executed 3 + * not executed 4 + * for I in 1..N do ... 7 | counted every time + * while ... do ... 4 | the loop condition + * repeat ... until 1 | is evaluated + * case ... end 1 + * with 1 + * -- + * 28 28 + * + * P (...) procedure call 10 + * X := F (...) + * function call 5 + * -- + * 15 15 + * --- + * 101 + * + * 22 of the 58 assignments have a variable of a constrained + * (sub-)type as their destination. In general, discriminant checks + * will be necessary in these cases; however, the compiler may + * optimize out some of these checks. + * + * The average number of parameters in procedure or function calls + * is 1.80 (not counting the function values as implicit parameters). + * + * + * 2. Operators + * ------------ + * number approximate + * percentage + * + * Arithmetic 27 52.9 + * + * + 16 31.4 + * - 7 13.7 + * * 3 5.9 + * div 1 2.0 + * + * Comparison 20 39.2 + * + * = 9 17.6 + * <> 4 7.8 + * > 1 2.0 + * < 3 5.9 + * >= 1 2.0 + * <= 2 3.9 + * + * Logic 4 7.8 + * + * AND 1 2.0 + * OR 1 2.0 + * NOT 2 3.9 + * + * -- ----- + * 51 99.9 + * + * + * 3. Operand Type (counted once per operand reference): + * --------------- + * number approximate + * percentage + * + * Integer 135 54.7 % + * Character 47 19.0 % + * Enumeration 31 12.6 % + * Boolean 13 5.3 % + * Pointer 11 4.5 % + * String30 6 2.4 % + * Array 2 0.8 % + * Record 2 0.8 % + * --- ------- + * 247 100.1 % + * + * When there is an access path leading to the final operand (e.g. a record + * component), only the final data type on the access path is counted. + * + * There are 16 accesses to components of a record, 9 of them go to + * a component in a variant part. For some of these accesses, the + * compiler may suppress generation of code checking the tag field + * during optimization. + * + * + * 3. Operand Locality: + * ------------------- + * + * local variable 84 34.0 % + * global variable 58 23.5 % + * parameter 45 18.2 % + * value 23 9.3 % + * reference 22 8.9 % + * function result 5 2.0 % + * constant 55 22.3 % + * --- ------- + * 247 100.0 % + * + * + * The program does not compute anything meaningful, but it is syntactically + * and semantically correct. All variables have a value assigned to them + * before they are used as a source operand. + * + * There may be cases where a highly optimizing compiler may recognize + * unnecessary statements and may not generate code for them. + * + * There has been no explicit effort to account for the effects of a + * cache, or to balance the use of long or short displacements for code or + * data. + * + **************************************************************************** + *) + +program Dhrystone (input, output); +(***************) + +const (* for measurement *) + + MicrosecondsPerClock = 1000; + ClocksPerSecond = 1000; + (* In Berkeley UNIX Pascal, the function "clock" *) + (* returns milliseconds *) + TooSmallTime = 2000; + (* Measurements should last at least 2 seconds *) + +type + + (* Global type definitions *) + + Enumeration = (Ident1, Ident2, Ident3, Ident4, Ident5); + + OneToThirty = 1..30; + OneToFifty = 1..50; + CapitalLetter = 'A'..'Z'; + + String30 = packed array [OneToThirty] of char; + + Array1DimInteger = array [OneToFifty] of integer; + Array2DimInteger = array [OneToFifty, OneToFifty] of integer; + + RecordPointer = ^RecordType; + + RecordType = + record + PointerComp: RecordPointer; + case Discr: Enumeration of + Ident1: (* only this variant is used, *) + (* but in some cases discriminant *) + (* checks are necessary *) + (EnumComp: Enumeration; + IntComp: OneToFifty; + StringComp: String30); + Ident2: + (Enum2Comp: Enumeration; + String2Comp: String30); + Ident3, Ident4, Ident5: + (Char1Comp, + Char2Comp: char); + end; (* record *) + +var + + (* Ada version: Variables local in Proc_0 *) + + Int1Glob, + Int2Glob, + Int3Glob: OneToFifty; + CharIndex: char; + EnumGlob: Enumeration; + String1Glob, + String2Glob: String30; + + (* Ada version: Variables global in Pack_1 *) + + PointerGlob, + NextPointerGlob: RecordPointer; + IntGlob: integer; + + BoolGlob: boolean; + Char1Glob, + Char2Glob: char; + Array1Glob: Array1DimInteger; + Array2Glob: Array2DimInteger; + + (* Variables for measurement *) + + RunIndex, + NumberOfRuns, + BeginClock, + EndClock, + SumClocks: integer; + Microseconds, + DhrystonesPerSecond: real; + I: integer; + + (* end of variables for measurement *) + +procedure Proc1 ( PointerParVal: RecordPointer); forward; + +procedure Proc2 (var IntParRef: OneToFifty); forward; + +procedure Proc3 (var PointerParRef: RecordPointer); forward; + +procedure Proc4; forward; + (* without parameters *) + +procedure Proc5; forward; + (* without parameters *) + +procedure Proc6 ( EnumParVal: Enumeration; + var EnumParRef: Enumeration); forward; + +procedure Proc7 ( Int1ParVal, + Int2ParVal: OneToFifty; + var IntParRef: OneToFifty); forward; + +procedure Proc8 (var Array1ParRef: Array1DimInteger; + var Array2ParRef: Array2DimInteger; + Int1ParVal, + Int2ParVal: integer); forward; + +function Func1 ( Char1ParVal, + Char2ParVal: CapitalLetter): + Enumeration; forward; + +function Func2 (var String1ParRef, + String2ParRef: String30): + boolean; forward; + +function Func3 ( EnumParVal: Enumeration): + boolean; forward; + + +procedure Proc1; (* (PointerParVal: RecordPointer) *) + (* executed once *) +begin + with PointerParVal^.PointerComp^ (* = PointerGlobNext *) do + begin + PointerParVal^.PointerComp^ := PointerGlob^; + PointerParVal^.IntComp := 5; + IntComp := PointerParVal^.IntComp; + PointerComp := PointerParVal^.PointerComp; + Proc3 (PointerComp); + (* PointerParVal^.PointerComp^.PointerComp = PointerGlob^.PointerComp *) + if Discr = Ident1 + then (* executed *) + begin + IntComp := 6; + Proc6 (PointerParVal^.EnumComp, EnumComp); + PointerComp := PointerGlob^.PointerComp; + Proc7 (IntComp, 10, IntComp); + end (* then *) + else (* not executed *) + PointerParVal^ := PointerParVal^.PointerComp^; + end; (* with *) +end; (* Proc1 *) + + +procedure Proc2; (* (var IntParRef: OneToFifty) *) + (* executed once *) + (* InParRef = 3, becomes 7 *) +var + IntLoc: OneToFifty; + EnumLoc: Enumeration; +begin + IntLoc := IntParRef + 10; + repeat (* executed once *) + if Char1Glob = 'A' + then (* executed *) + begin + IntLoc := IntLoc - 1; + IntParRef := IntLoc - IntGlob; + EnumLoc := Ident1; + end (* if *) + until EnumLoc = Ident1; (* true *) +end; (* Proc2 *) + + +procedure Proc3; (* (var PointerParRef: RecordPointer) *) + (* executed once *) + (* PointerParRef becomes PointerGlob *) +begin + if PointerGlob <> nil + then (* executed *) + PointerParRef := PointerGlob^.PointerComp; + Proc7 (10, IntGlob, PointerGlob^.IntComp); +end; (* Proc3 *) + + +procedure Proc4; (* without parameters *) + (* executed once *) +var + BoolLoc: boolean; +begin + BoolLoc := Char1Glob = 'A'; + BoolGlob := BoolLoc or BoolGlob; + Char2Glob := 'B'; +end; (* Proc4 *) + + +procedure Proc5; (* without parameters *) + (* executed once *) +begin + Char1Glob := 'A'; + BoolGlob := false; +end; (* Proc5 *) + + +procedure Proc6; (* ( EnumParVal: Enumeration; + var EnumParRef: Enumeration) *) + (* executed once *) + (* EnumParVal = Ident3, EnumParRef becomes Ident2 *) +begin + EnumParRef := EnumParVal; + if not Func3 (EnumParVal) + then (* not executed *) + EnumParRef := Ident4; + case EnumParVal of + Ident1: EnumParRef := Ident1; + Ident2: if IntGlob > 100 + then EnumParRef := Ident1 + else EnumParRef := Ident4; + Ident3: EnumParRef := Ident2; (* executed *) + Ident4: ; + Ident5: EnumParRef := Ident3; + end; (* case *) +end; (* Proc6 *) + + +procedure Proc7; (* ( Int1ParVal, + Int2ParVal: OneToFifty; + var IntParRef: OneToFifty) *) + (* executed three times *) + (* first call: Int1ParVal = 2, Int2ParVal = 3, *) + (* IntParRef becomes 7 *) + (* second call: Int1ParVal = 10, Int2ParVal = 5, *) + (* IntParRef becomes 17 *) + (* third call: Int1ParVal = 6, Int2ParVal = 10, *) + (* IntParRef becomes 18 *) +var + IntLoc: OneToFifty; +begin + IntLoc := Int1ParVal + 2; + IntParRef := Int2ParVal + IntLoc; +end; (* Proc7 *) + + +procedure Proc8; (* (var Array1ParRef: Array1DimInteger; + var Array2ParRef: Array2DimInteger; + Int1ParVal, + Int2ParVal: integer) *) + (* executed once *) + (* Int1ParVal = 3 *) + (* Int2ParVal = 7 *) +var + IntIndex, + IntLoc: OneToFifty; +begin + IntLoc := Int1ParVal + 5; + Array1ParRef [IntLoc] := Int2ParVal; + Array1ParRef [IntLoc+1] := Array1ParRef [IntLoc]; + Array1ParRef [IntLoc+30] := IntLoc; + for IntIndex := IntLoc to IntLoc+1 do + Array2ParRef [IntLoc, IntIndex] := IntLoc; + Array2ParRef [IntLoc, IntLoc-1] := Array2ParRef [IntLoc, IntLoc-1] + 1; + Array2ParRef [IntLoc+20, IntLoc] := Array1ParRef [IntLoc]; + IntGlob := 5; +end; (* Proc8 *) + + +function Func1; (* (Char1ParVal, + Char2ParVal: CapitalLetter): Enumeration *) + (* executed three times, returns always Ident1 *) + (* first call: Char1ParVal = 'H', Char2ParVal = 'R' *) + (* second call: Char1ParVal = 'A', Char2ParVal = 'C' *) + (* third call: Char1ParVal = 'B', Char2ParVal = 'C' *) +var + Char1Loc, Char2Loc: CapitalLetter; +begin + Char1Loc := Char1ParVal; + Char2Loc := Char1Loc; + if Char2Loc <> Char2ParVal + then (* executed *) + Func1 := Ident1 + else (* not executed *) + begin + Char1Glob := Char1Loc; + Func1 := Ident2; + end; +end; (* Func1 *) + + +function Func2; (* (var String1ParRef, + String2ParRef: String30): boolean *) + (* executed once, returns false *) + (* String1ParRef = 'DHRYSTONE PROGRAM, 1''ST STRING' *) + (* String2ParRef = 'DHRYSTONE PROGRAM, 2''ND STRING' *) +var + IntLoc: OneToThirty; + CharLoc: CapitalLetter; +begin + IntLoc := 2; + while IntLoc <= 2 do (* loop body executed once *) + if Func1 (String1ParRef[IntLoc], + String2ParRef[IntLoc+1]) = Ident1 + then (* executed *) + begin + CharLoc := 'A'; + IntLoc := IntLoc + 1; + end; (* if, while *) + if (CharLoc >= 'W') and (CharLoc < 'Z') + then (* not executed *) + IntLoc := 7; + if CharLoc = 'R' + then (* not executed *) + Func2 := true + else (* executed *) + begin + if String1ParRef > String2ParRef + then (* not executed *) + begin + IntLoc := IntLoc + 7; + IntGlob := IntLoc; + Func2 := true + end + else (* executed *) + Func2 := false; + end; (* if CharLoc *) +end; (* Func2 *) + + +function Func3; (* (EnumParVal: Enumeration): boolean *) + (* executed once, returns true *) + (* EnumParVal = Ident3 *) +var + EnumLoc: Enumeration; +begin + EnumLoc := EnumParVal; + if EnumLoc = Ident3 + then (* executed *) + Func3 := true + else (* not executed *) + Func3 := false; +end; (* Func3 *) + + +begin (* main program, corresponds to procedures *) + (* Main and Proc_0 in the Ada version *) + + (* Initializations *) + + new (NextPointerGlob); + + new (PointerGlob); + + PointerGlob^.PointerComp := NextPointerGlob; + PointerGlob^.Discr := Ident1; + PointerGlob^.EnumComp := Ident3; + PointerGlob^.IntComp := 40; + PointerGlob^.StringComp := 'DHRYSTONE PROGRAM, SOME STRING'; + + String1Glob := 'DHRYSTONE PROGRAM, 1''ST STRING'; + + Array2Glob [8,7] := 10; + + writeln; + writeln ('Dhrystone Benchmark, Version 2.1 (Language: Pascal)'); + writeln; + writeln ('Please give the number of runs through the benchmark: '); + readln (NumberOfRuns); + writeln; + writeln ('Execution starts, ', NumberOfRuns : 7, ' runs through Dhrystone'); + + BeginClock := clock; + + (***************) + (* Start timer *) + (***************) + + for RunIndex := 1 to NumberOfRuns do + begin + + Proc5; + Proc4; + (* Char1Glob = 'A', Char2Glob = 'B', BoolGlob = false *) + Int1Glob := 2; + Int2Glob := 3; + String2Glob := 'DHRYSTONE PROGRAM, 2''ND STRING'; + EnumGlob := Ident2; + BoolGlob := not Func2 (String1Glob, String2Glob); + (* BoolGlob = true *) + while Int1Glob < Int2Glob do (* loop body executed once *) + begin + Int3Glob := 5 * Int1Glob - Int2Glob; + (* Int3Glob = 7 *) + Proc7 (Int1Glob, Int2Glob, Int3Glob); + (* Int3Glob = 7 *) + Int1Glob := Int1Glob + 1; + end; (* while *) + (* Int1Glob = 3 *) + Proc8 (Array1Glob, Array2Glob, Int1Glob, Int3Glob); + (* IntGlob = 5 *) + Proc1 (PointerGlob); + for CharIndex := 'A' to Char2Glob do (* loop body executed twice *) + if EnumGlob = Func1 (CharIndex, 'C') + then (* not executed *) + begin + Proc6 (Ident1, EnumGlob); + String2Glob := 'DHRYSTONE PROGRAM, 3''RD STRING'; + Int2Glob := RunIndex; + IntGlob := RunIndex; + end; + (* Int1Glob = 3, Int2Glob = 3, Int3Glob = 7 *) + Int2Glob := Int2Glob * Int1Glob; + Int1Glob := Int2Glob div Int3Glob; + Int2Glob := 7 * (Int2Glob - Int3Glob) - Int1Glob; + (* Int1Glob = 1, Int2Glob = 13, Int3Glob = 7 *) + Proc2 (Int1Glob); + (* Int1Glob = 5 *) + + end; (* for RunIndex *) + + EndClock := clock; + + (**************) + (* Stop timer *) + (**************) + + writeln ('Execution ends'); + writeln; + writeln ('Final values of the variables used in the benchmark:'); + writeln; + + writeln ('IntGlob: ', IntGlob : 5); + writeln (' should be: 5'); + write ('BoolGlob: '); + if BoolGlob = true + then + writeln ('TRUE') + else + writeln ('FALSE'); + writeln (' should be: TRUE'); + writeln ('Char1Glob: ', Char1Glob); + writeln (' should be: A'); + writeln ('Char2Glob: ', Char2Glob); + writeln (' should be: B'); + writeln ('Array1Glob [8]: ', Array1Glob [8] : 5); + writeln (' should be: 7'); + writeln ('Array2Glob [8,7]: ', Array2Glob [8,7] : 5); + writeln (' should be: NumberOfRuns + 10'); + writeln ('PointerGlob^.Discr: ', ord (PointerGlob^.Discr) : 5); + writeln (' should be: 0'); + writeln ('PointerGlob^.EnumComp: ', ord (PointerGlob^.EnumComp) : 5); + writeln (' should be: 2'); + writeln ('PointerGlob^.IntComp : ', PointerGlob^.IntComp : 5); + writeln (' should be: 17'); + write ('PointerGlob^.StringComp: '); + for I := 1 to 30 do + write (PointerGlob^.StringComp [I]); + writeln; + writeln (' should be: DHRYSTONE PROGRAM, SOME STRING'); + writeln ('NextPointerGlob^.Discr: ', ord (NextPointerGlob^.Discr) : 5); + writeln (' should be: 0'); + writeln ('NextPointerGlob^.EnumComp: ', + ord (NextPointerGlob^.EnumComp) : 5); + writeln (' should be: 1'); + writeln ('NextPointerGlob^.IntComp: ', NextPointerGlob^.IntComp : 5); + writeln (' should be: 18'); + write ('NextPointerGlob^.StringComp: '); + for I := 1 to 30 do + write (NextPointerGlob^.StringComp [I]); + writeln; + writeln (' should be: DHRYSTONE PROGRAM, SOME STRING'); + writeln ('Int1Glob: ', Int1Glob : 5); + writeln (' should be: 5'); + writeln ('Int2Glob: ', Int2Glob : 5); + writeln (' should be: 13'); + writeln ('Int3Glob: ', Int3Glob : 5); + writeln (' should be: 7'); + writeln ('EnumGlob: ', ord (EnumGlob) : 5); + writeln (' should be: 1'); + write ('String1Glob: '); + for I := 1 to 30 do + write (String1Glob [I]); + writeln; + writeln (' should be: DHRYSTONE PROGRAM, 1''ST STRING'); + write ('String2Glob: '); + for I := 1 to 30 do + write (String2Glob [I]); + writeln; + writeln (' should be: DHRYSTONE PROGRAM, 2''ND STRING'); + writeln; + writeln; + + SumClocks := EndClock - BeginClock; + + if SumClocks < TooSmallTime + then + begin + writeln ('Measured time too small to obtain meaningful results'); + writeln ('Please increase number of runs'); + writeln; + end + else + begin + Microseconds := SumClocks * (MicrosecondsPerClock / NumberOfRuns); + (* Brackets to prevent integer overflow *) + DhrystonesPerSecond := NumberOfRuns * (ClocksPerSecond / SumClocks); + write ('Microseconds for one run through Dhrystone: '); + writeln (Microseconds : 8 : 1); + write ('Dhrystones per Second: '); + writeln (DhrystonesPerSecond : 8 : 1); + writeln; + end; + +end.
rtl_sim/src-c/dhrystone_v2.1/original_files/dhry.p Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/dhry_1.c =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/dhry_1.c (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/dhry_1.c (revision 145) @@ -0,0 +1,395 @@ +/* + **************************************************************************** + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: C, Version 2.1 + * + * File: dhry_1.c (part 2 of 3) + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * + **************************************************************************** + */ + +#include "dhry.h" + +/* Global Variables: */ + +Rec_Pointer Ptr_Glob, + Next_Ptr_Glob; +int Int_Glob; +Boolean Bool_Glob; +char Ch_1_Glob, + Ch_2_Glob; +int Arr_1_Glob [50]; +int Arr_2_Glob [50] [50]; + +extern char *malloc (); +Enumeration Func_1 (); + /* forward declaration necessary since Enumeration may not simply be int */ + +#ifndef REG + Boolean Reg = false; +#define REG + /* REG becomes defined as empty */ + /* i.e. no register variables */ +#else + Boolean Reg = true; +#endif + +/* variables for time measurement: */ + +#ifdef TIMES +struct tms time_info; +extern int times (); + /* see library function "times" */ +#define Too_Small_Time (2*HZ) + /* Measurements should last at least about 2 seconds */ +#endif +#ifdef TIME +extern long time(); + /* see library function "time" */ +#define Too_Small_Time 2 + /* Measurements should last at least 2 seconds */ +#endif +#ifdef MSC_CLOCK +extern clock_t clock(); +#define Too_Small_Time (2*HZ) +#endif + +long Begin_Time, + End_Time, + User_Time; +float Microseconds, + Dhrystones_Per_Second; + +/* end of variables for time measurement */ + + +main () +/*****/ + + /* main program, corresponds to procedures */ + /* Main and Proc_0 in the Ada version */ +{ + One_Fifty Int_1_Loc; + REG One_Fifty Int_2_Loc; + One_Fifty Int_3_Loc; + REG char Ch_Index; + Enumeration Enum_Loc; + Str_30 Str_1_Loc; + Str_30 Str_2_Loc; + REG int Run_Index; + REG int Number_Of_Runs; + + /* Initializations */ + + Next_Ptr_Glob = (Rec_Pointer) malloc (sizeof (Rec_Type)); + Ptr_Glob = (Rec_Pointer) malloc (sizeof (Rec_Type)); + + Ptr_Glob->Ptr_Comp = Next_Ptr_Glob; + Ptr_Glob->Discr = Ident_1; + Ptr_Glob->variant.var_1.Enum_Comp = Ident_3; + Ptr_Glob->variant.var_1.Int_Comp = 40; + strcpy (Ptr_Glob->variant.var_1.Str_Comp, + "DHRYSTONE PROGRAM, SOME STRING"); + strcpy (Str_1_Loc, "DHRYSTONE PROGRAM, 1'ST STRING"); + + Arr_2_Glob [8][7] = 10; + /* Was missing in published program. Without this statement, */ + /* Arr_2_Glob [8][7] would have an undefined value. */ + /* Warning: With 16-Bit processors and Number_Of_Runs > 32000, */ + /* overflow may occur for this array element. */ + + printf ("\n"); + printf ("Dhrystone Benchmark, Version 2.1 (Language: C)\n"); + printf ("\n"); + if (Reg) + { + printf ("Program compiled with 'register' attribute\n"); + printf ("\n"); + } + else + { + printf ("Program compiled without 'register' attribute\n"); + printf ("\n"); + } + printf ("Please give the number of runs through the benchmark: "); + { + int n; + scanf ("%d", &n); + Number_Of_Runs = n; + } + printf ("\n"); + + printf ("Execution starts, %d runs through Dhrystone\n", Number_Of_Runs); + + /***************/ + /* Start timer */ + /***************/ + +#ifdef TIMES + times (&time_info); + Begin_Time = (long) time_info.tms_utime; +#endif +#ifdef TIME + Begin_Time = time ( (long *) 0); +#endif +#ifdef MSC_CLOCK + Begin_Time = clock(); +#endif + + for (Run_Index = 1; Run_Index <= Number_Of_Runs; ++Run_Index) + { + + Proc_5(); + Proc_4(); + /* Ch_1_Glob == 'A', Ch_2_Glob == 'B', Bool_Glob == true */ + Int_1_Loc = 2; + Int_2_Loc = 3; + strcpy (Str_2_Loc, "DHRYSTONE PROGRAM, 2'ND STRING"); + Enum_Loc = Ident_2; + Bool_Glob = ! Func_2 (Str_1_Loc, Str_2_Loc); + /* Bool_Glob == 1 */ + while (Int_1_Loc < Int_2_Loc) /* loop body executed once */ + { + Int_3_Loc = 5 * Int_1_Loc - Int_2_Loc; + /* Int_3_Loc == 7 */ + Proc_7 (Int_1_Loc, Int_2_Loc, &Int_3_Loc); + /* Int_3_Loc == 7 */ + Int_1_Loc += 1; + } /* while */ + /* Int_1_Loc == 3, Int_2_Loc == 3, Int_3_Loc == 7 */ + Proc_8 (Arr_1_Glob, Arr_2_Glob, Int_1_Loc, Int_3_Loc); + /* Int_Glob == 5 */ + Proc_1 (Ptr_Glob); + for (Ch_Index = 'A'; Ch_Index <= Ch_2_Glob; ++Ch_Index) + /* loop body executed twice */ + { + if (Enum_Loc == Func_1 (Ch_Index, 'C')) + /* then, not executed */ + { + Proc_6 (Ident_1, &Enum_Loc); + strcpy (Str_2_Loc, "DHRYSTONE PROGRAM, 3'RD STRING"); + Int_2_Loc = Run_Index; + Int_Glob = Run_Index; + } + } + /* Int_1_Loc == 3, Int_2_Loc == 3, Int_3_Loc == 7 */ + Int_2_Loc = Int_2_Loc * Int_1_Loc; + Int_1_Loc = Int_2_Loc / Int_3_Loc; + Int_2_Loc = 7 * (Int_2_Loc - Int_3_Loc) - Int_1_Loc; + /* Int_1_Loc == 1, Int_2_Loc == 13, Int_3_Loc == 7 */ + Proc_2 (&Int_1_Loc); + /* Int_1_Loc == 5 */ + + } /* loop "for Run_Index" */ + + /**************/ + /* Stop timer */ + /**************/ + +#ifdef TIMES + times (&time_info); + End_Time = (long) time_info.tms_utime; +#endif +#ifdef TIME + End_Time = time ( (long *) 0); +#endif +#ifdef MSC_CLOCK + End_Time = clock(); +#endif + + printf ("Execution ends\n"); + printf ("\n"); + printf ("Final values of the variables used in the benchmark:\n"); + printf ("\n"); + printf ("Int_Glob: %d\n", Int_Glob); + printf (" should be: %d\n", 5); + printf ("Bool_Glob: %d\n", Bool_Glob); + printf (" should be: %d\n", 1); + printf ("Ch_1_Glob: %c\n", Ch_1_Glob); + printf (" should be: %c\n", 'A'); + printf ("Ch_2_Glob: %c\n", Ch_2_Glob); + printf (" should be: %c\n", 'B'); + printf ("Arr_1_Glob[8]: %d\n", Arr_1_Glob[8]); + printf (" should be: %d\n", 7); + printf ("Arr_2_Glob[8][7]: %d\n", Arr_2_Glob[8][7]); + printf (" should be: Number_Of_Runs + 10\n"); + printf ("Ptr_Glob->\n"); + printf (" Ptr_Comp: %d\n", (int) Ptr_Glob->Ptr_Comp); + printf (" should be: (implementation-dependent)\n"); + printf (" Discr: %d\n", Ptr_Glob->Discr); + printf (" should be: %d\n", 0); + printf (" Enum_Comp: %d\n", Ptr_Glob->variant.var_1.Enum_Comp); + printf (" should be: %d\n", 2); + printf (" Int_Comp: %d\n", Ptr_Glob->variant.var_1.Int_Comp); + printf (" should be: %d\n", 17); + printf (" Str_Comp: %s\n", Ptr_Glob->variant.var_1.Str_Comp); + printf (" should be: DHRYSTONE PROGRAM, SOME STRING\n"); + printf ("Next_Ptr_Glob->\n"); + printf (" Ptr_Comp: %d\n", (int) Next_Ptr_Glob->Ptr_Comp); + printf (" should be: (implementation-dependent), same as above\n"); + printf (" Discr: %d\n", Next_Ptr_Glob->Discr); + printf (" should be: %d\n", 0); + printf (" Enum_Comp: %d\n", Next_Ptr_Glob->variant.var_1.Enum_Comp); + printf (" should be: %d\n", 1); + printf (" Int_Comp: %d\n", Next_Ptr_Glob->variant.var_1.Int_Comp); + printf (" should be: %d\n", 18); + printf (" Str_Comp: %s\n", + Next_Ptr_Glob->variant.var_1.Str_Comp); + printf (" should be: DHRYSTONE PROGRAM, SOME STRING\n"); + printf ("Int_1_Loc: %d\n", Int_1_Loc); + printf (" should be: %d\n", 5); + printf ("Int_2_Loc: %d\n", Int_2_Loc); + printf (" should be: %d\n", 13); + printf ("Int_3_Loc: %d\n", Int_3_Loc); + printf (" should be: %d\n", 7); + printf ("Enum_Loc: %d\n", Enum_Loc); + printf (" should be: %d\n", 1); + printf ("Str_1_Loc: %s\n", Str_1_Loc); + printf (" should be: DHRYSTONE PROGRAM, 1'ST STRING\n"); + printf ("Str_2_Loc: %s\n", Str_2_Loc); + printf (" should be: DHRYSTONE PROGRAM, 2'ND STRING\n"); + printf ("\n"); + + User_Time = End_Time - Begin_Time; + + if (User_Time < Too_Small_Time) + { + printf ("Measured time too small to obtain meaningful results\n"); + printf ("Please increase number of runs\n"); + printf ("\n"); + } + else + { +#ifdef TIME + Microseconds = (float) User_Time * Mic_secs_Per_Second + / (float) Number_Of_Runs; + Dhrystones_Per_Second = (float) Number_Of_Runs / (float) User_Time; +#else + Microseconds = (float) User_Time * Mic_secs_Per_Second + / ((float) HZ * ((float) Number_Of_Runs)); + Dhrystones_Per_Second = ((float) HZ * (float) Number_Of_Runs) + / (float) User_Time; +#endif + printf ("Microseconds for one run through Dhrystone: "); + printf ("%6.1f \n", Microseconds); + printf ("Dhrystones per Second: "); + printf ("%6.1f \n", Dhrystones_Per_Second); + printf ("\n"); + } + +} + + +Proc_1 (Ptr_Val_Par) +/******************/ + +REG Rec_Pointer Ptr_Val_Par; + /* executed once */ +{ + REG Rec_Pointer Next_Record = Ptr_Val_Par->Ptr_Comp; + /* == Ptr_Glob_Next */ + /* Local variable, initialized with Ptr_Val_Par->Ptr_Comp, */ + /* corresponds to "rename" in Ada, "with" in Pascal */ + + structassign (*Ptr_Val_Par->Ptr_Comp, *Ptr_Glob); + Ptr_Val_Par->variant.var_1.Int_Comp = 5; + Next_Record->variant.var_1.Int_Comp + = Ptr_Val_Par->variant.var_1.Int_Comp; + Next_Record->Ptr_Comp = Ptr_Val_Par->Ptr_Comp; + Proc_3 (&Next_Record->Ptr_Comp); + /* Ptr_Val_Par->Ptr_Comp->Ptr_Comp + == Ptr_Glob->Ptr_Comp */ + if (Next_Record->Discr == Ident_1) + /* then, executed */ + { + Next_Record->variant.var_1.Int_Comp = 6; + Proc_6 (Ptr_Val_Par->variant.var_1.Enum_Comp, + &Next_Record->variant.var_1.Enum_Comp); + Next_Record->Ptr_Comp = Ptr_Glob->Ptr_Comp; + Proc_7 (Next_Record->variant.var_1.Int_Comp, 10, + &Next_Record->variant.var_1.Int_Comp); + } + else /* not executed */ + structassign (*Ptr_Val_Par, *Ptr_Val_Par->Ptr_Comp); +} /* Proc_1 */ + + +Proc_2 (Int_Par_Ref) +/******************/ + /* executed once */ + /* *Int_Par_Ref == 1, becomes 4 */ + +One_Fifty *Int_Par_Ref; +{ + One_Fifty Int_Loc; + Enumeration Enum_Loc; + + Int_Loc = *Int_Par_Ref + 10; + do /* executed once */ + if (Ch_1_Glob == 'A') + /* then, executed */ + { + Int_Loc -= 1; + *Int_Par_Ref = Int_Loc - Int_Glob; + Enum_Loc = Ident_1; + } /* if */ + while (Enum_Loc != Ident_1); /* true */ +} /* Proc_2 */ + + +Proc_3 (Ptr_Ref_Par) +/******************/ + /* executed once */ + /* Ptr_Ref_Par becomes Ptr_Glob */ + +Rec_Pointer *Ptr_Ref_Par; + +{ + if (Ptr_Glob != Null) + /* then, executed */ + *Ptr_Ref_Par = Ptr_Glob->Ptr_Comp; + Proc_7 (10, Int_Glob, &Ptr_Glob->variant.var_1.Int_Comp); +} /* Proc_3 */ + + +Proc_4 () /* without parameters */ +/*******/ + /* executed once */ +{ + Boolean Bool_Loc; + + Bool_Loc = Ch_1_Glob == 'A'; + Bool_Glob = Bool_Loc | Bool_Glob; + Ch_2_Glob = 'B'; +} /* Proc_4 */ + + +Proc_5 () /* without parameters */ +/*******/ + /* executed once */ +{ + Ch_1_Glob = 'A'; + Bool_Glob = false; +} /* Proc_5 */ + + + /* Procedure for the assignment of structures, */ + /* if the C compiler doesn't support this feature */ +#ifdef NOSTRUCTASSIGN +memcpy (d, s, l) +register char *d; +register char *s; +register int l; +{ + while (l--) *d++ = *s++; +} +#endif + +
rtl_sim/src-c/dhrystone_v2.1/original_files/dhry_1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/dhry_2.c =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/dhry_2.c (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/dhry_2.c (revision 145) @@ -0,0 +1,192 @@ +/* + **************************************************************************** + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: C, Version 2.1 + * + * File: dhry_2.c (part 3 of 3) + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * + **************************************************************************** + */ + +#include "dhry.h" + +#ifndef REG +#define REG + /* REG becomes defined as empty */ + /* i.e. no register variables */ +#endif + +extern int Int_Glob; +extern char Ch_1_Glob; + + +Proc_6 (Enum_Val_Par, Enum_Ref_Par) +/*********************************/ + /* executed once */ + /* Enum_Val_Par == Ident_3, Enum_Ref_Par becomes Ident_2 */ + +Enumeration Enum_Val_Par; +Enumeration *Enum_Ref_Par; +{ + *Enum_Ref_Par = Enum_Val_Par; + if (! Func_3 (Enum_Val_Par)) + /* then, not executed */ + *Enum_Ref_Par = Ident_4; + switch (Enum_Val_Par) + { + case Ident_1: + *Enum_Ref_Par = Ident_1; + break; + case Ident_2: + if (Int_Glob > 100) + /* then */ + *Enum_Ref_Par = Ident_1; + else *Enum_Ref_Par = Ident_4; + break; + case Ident_3: /* executed */ + *Enum_Ref_Par = Ident_2; + break; + case Ident_4: break; + case Ident_5: + *Enum_Ref_Par = Ident_3; + break; + } /* switch */ +} /* Proc_6 */ + + +Proc_7 (Int_1_Par_Val, Int_2_Par_Val, Int_Par_Ref) +/**********************************************/ + /* executed three times */ + /* first call: Int_1_Par_Val == 2, Int_2_Par_Val == 3, */ + /* Int_Par_Ref becomes 7 */ + /* second call: Int_1_Par_Val == 10, Int_2_Par_Val == 5, */ + /* Int_Par_Ref becomes 17 */ + /* third call: Int_1_Par_Val == 6, Int_2_Par_Val == 10, */ + /* Int_Par_Ref becomes 18 */ +One_Fifty Int_1_Par_Val; +One_Fifty Int_2_Par_Val; +One_Fifty *Int_Par_Ref; +{ + One_Fifty Int_Loc; + + Int_Loc = Int_1_Par_Val + 2; + *Int_Par_Ref = Int_2_Par_Val + Int_Loc; +} /* Proc_7 */ + + +Proc_8 (Arr_1_Par_Ref, Arr_2_Par_Ref, Int_1_Par_Val, Int_2_Par_Val) +/*********************************************************************/ + /* executed once */ + /* Int_Par_Val_1 == 3 */ + /* Int_Par_Val_2 == 7 */ +Arr_1_Dim Arr_1_Par_Ref; +Arr_2_Dim Arr_2_Par_Ref; +int Int_1_Par_Val; +int Int_2_Par_Val; +{ + REG One_Fifty Int_Index; + REG One_Fifty Int_Loc; + + Int_Loc = Int_1_Par_Val + 5; + Arr_1_Par_Ref [Int_Loc] = Int_2_Par_Val; + Arr_1_Par_Ref [Int_Loc+1] = Arr_1_Par_Ref [Int_Loc]; + Arr_1_Par_Ref [Int_Loc+30] = Int_Loc; + for (Int_Index = Int_Loc; Int_Index <= Int_Loc+1; ++Int_Index) + Arr_2_Par_Ref [Int_Loc] [Int_Index] = Int_Loc; + Arr_2_Par_Ref [Int_Loc] [Int_Loc-1] += 1; + Arr_2_Par_Ref [Int_Loc+20] [Int_Loc] = Arr_1_Par_Ref [Int_Loc]; + Int_Glob = 5; +} /* Proc_8 */ + + +Enumeration Func_1 (Ch_1_Par_Val, Ch_2_Par_Val) +/*************************************************/ + /* executed three times */ + /* first call: Ch_1_Par_Val == 'H', Ch_2_Par_Val == 'R' */ + /* second call: Ch_1_Par_Val == 'A', Ch_2_Par_Val == 'C' */ + /* third call: Ch_1_Par_Val == 'B', Ch_2_Par_Val == 'C' */ + +Capital_Letter Ch_1_Par_Val; +Capital_Letter Ch_2_Par_Val; +{ + Capital_Letter Ch_1_Loc; + Capital_Letter Ch_2_Loc; + + Ch_1_Loc = Ch_1_Par_Val; + Ch_2_Loc = Ch_1_Loc; + if (Ch_2_Loc != Ch_2_Par_Val) + /* then, executed */ + return (Ident_1); + else /* not executed */ + { + Ch_1_Glob = Ch_1_Loc; + return (Ident_2); + } +} /* Func_1 */ + + +Boolean Func_2 (Str_1_Par_Ref, Str_2_Par_Ref) +/*************************************************/ + /* executed once */ + /* Str_1_Par_Ref == "DHRYSTONE PROGRAM, 1'ST STRING" */ + /* Str_2_Par_Ref == "DHRYSTONE PROGRAM, 2'ND STRING" */ + +Str_30 Str_1_Par_Ref; +Str_30 Str_2_Par_Ref; +{ + REG One_Thirty Int_Loc; + Capital_Letter Ch_Loc; + + Int_Loc = 2; + while (Int_Loc <= 2) /* loop body executed once */ + if (Func_1 (Str_1_Par_Ref[Int_Loc], + Str_2_Par_Ref[Int_Loc+1]) == Ident_1) + /* then, executed */ + { + Ch_Loc = 'A'; + Int_Loc += 1; + } /* if, while */ + if (Ch_Loc >= 'W' && Ch_Loc < 'Z') + /* then, not executed */ + Int_Loc = 7; + if (Ch_Loc == 'R') + /* then, not executed */ + return (true); + else /* executed */ + { + if (strcmp (Str_1_Par_Ref, Str_2_Par_Ref) > 0) + /* then, not executed */ + { + Int_Loc += 7; + Int_Glob = Int_Loc; + return (true); + } + else /* executed */ + return (false); + } /* if Ch_Loc */ +} /* Func_2 */ + + +Boolean Func_3 (Enum_Par_Val) +/***************************/ + /* executed once */ + /* Enum_Par_Val == Ident_3 */ +Enumeration Enum_Par_Val; +{ + Enumeration Enum_Loc; + + Enum_Loc = Enum_Par_Val; + if (Enum_Loc == Ident_3) + /* then, executed */ + return (true); + else /* not executed */ + return (false); +} /* Func_3 */ +
rtl_sim/src-c/dhrystone_v2.1/original_files/dhry_2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/dhry_c.dif =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/dhry_c.dif (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/dhry_c.dif (revision 145) @@ -0,0 +1,141 @@ +7c7 +< * Version: C, Version 2.1 +--- +> * Version: C, Version 2.0 +9c9 +< * File: dhry.h (part 1 of 3) +--- +> * File: dhry_global.h (part 1 of 3) +11c11 +< * Date: May 25, 1988 +--- +> * Date: March 3, 1988 +30c30 +< * In addition, Berkeley UNIX system calls "times ()" or "time ()" +--- +> * In addition, UNIX system calls "times ()" or "time ()" +44c44 +< * Please send results to Rick Richardson and/or Reinhold Weicker. +--- +> * Please send results to Reinhold Weicker and/or Rick Richardson. +59c59 +< * History: This version C/2.1 has been made for two reasons: +--- +> * History: This version C/2.0 has been made for two reasons: +123,129d122 +< * Version 2.1 is identical to version 2.0 distributed via +< * the UNIX network Usenet in March 1988 except that it corrects +< * some minor deficiencies that were found by users of version 2.0. +< * The only change within the measurement loop is that a +< * non-executed "else" part was added to the "if" statement in +< * Func_3, and a non-executed "else" part removed from Proc_3. +< * +165,167c158,160 +< * -DHZ=nnn +< * In Berkeley UNIX, the function "times" returns process +< * time in 1/HZ seconds, with HZ = 60 for most systems. +--- +> * -DHZ=nnn (default: 60) +> * The function "times" returns process times in +> * 1/HZ seconds, with HZ = 60 for most systems. +169c162 +< * A VALUE. +--- +> * THE DEFAULT VALUE. +176,178c169,171 +< * - dhry.h (this file, containing global definitions and comments) +< * - dhry_1.c (containing the code corresponding to Ada package Pack_1) +< * - dhry_2.c (containing the code corresponding to Ada package Pack_2) +--- +> * - dhry_global.h (this file, containing global definitions and comments) +> * - dhry_pack_1.c (containing the code corresponding to Ada package Pack_1) +> * - dhry_pack_2.c (containing the code corresponding to Ada package Pack_2) +350a344 +> #ifndef TIMES +353,354c347,354 +< /* Use times(2) time function unless */ +< /* explicitly defined otherwise */ +--- +> #endif +> /* Use "times" function for measurement */ +> /* unless explicitly defined otherwise */ +> #ifndef HZ +> #define HZ 60 +> #endif +> /* Use HZ = 60 for "times" function */ +> /* unless explicitly defined otherwise */ +363c363 +< /* Berkeley UNIX C returns process times in seconds/HZ */ +--- +> /* UNIX C returns process times in seconds/HZ */ +7c7 +< * Version: C, Version 2.1 +--- +> * Version: C, Version 2.0 +9c9 +< * File: dhry_1.c (part 2 of 3) +--- +> * File: dhry_pack_1.c (part 2 of 3) +11c11 +< * Date: May 25, 1988 +--- +> * Date: March 3, 1988 +18c18 +< #include "dhry.h" +--- +> #include "dhry_global.h" +50,51d49 +< #define Too_Small_Time 120 +< /* Measurements should last at least about 2 seconds */ +55a54,55 +> #endif +> +58d57 +< #endif +73a73 +> +84a85 +> +99,100c100,102 +< /* Was missing in published program. Without this statement, */ +< /* Arr_2_Glob [8][7] would have an undefined value. */ +--- +> /* Was missing in published program. Without this */ +> /* initialization, Arr_2_Glob [8][7] would have an */ +> /* undefined value. */ +105c107 +< printf ("Dhrystone Benchmark, Version 2.1 (Language: C)\n"); +--- +> printf ("Dhrystone Benchmark, Version 2.0 (Language: C)\n"); +281c283 +< /******************/ +--- +> /**********************/ +338c340 +< /******************/ +--- +> /**********************/ +347a350,351 +> else /* not executed */ +> Int_Glob = 100; +349a354 +> +7c7 +< * Version: C, Version 2.1 +--- +> * Version: C, Version 2.0 +9c9 +< * File: dhry_2.c (part 3 of 3) +--- +> * File: dhry_pack_2.c (part 3 of 3) +11c11 +< * Date: May 25, 1988 +--- +> * Date: March 3, 1988 +18c18 +< #include "dhry.h" +--- +> #include "dhry_global.h" +189,190d188 +< else /* not executed */ +< return (false);
rtl_sim/src-c/dhrystone_v2.1/original_files/dhry_c.dif Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/Makefile =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/Makefile (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/Makefile (revision 145) @@ -0,0 +1,155 @@ +# +# Adjust for your system! +# +# Common options for generic UNIX and Microsoft C (under DOS) +# are listed here. You can change them by switching the order, +# placing the ones you want last. Pay particular attention to +# the HZ parameter, which may or may not be listed in some +# header file on your system, such as or +# (as CLK_TCK). Even if it is listed, it may be incorrect. +# Also, some operating systems (notably some (all?) versions +# of Microport UNIX) lie about the time. Sanity check with a +# stopwatch. +# +# For Microsoft C under DOS, you need a real make, not MSC make, +# to run this Makefile. The public domain "ndmake" will suffice. +# +CC= cl # C compiler name goes here (MSC) +CC= cc # C compiler name goes here (UNIX) +GCC= gcc + +PROGS= msc # Programs to build (MSC) +PROGS= unix # Programs to build (UNIX) + +#TIME_FUNC= -DMSC_CLOCK # Use Microsoft clock() for measurement +#TIME_FUNC= -DTIME # Use time(2) for measurement +TIME_FUNC= -DTIMES # Use times(2) for measurement +#HZ= 50 # Frequency of times(2) clock ticks +HZ= 60 # Frequency of times(2) clock ticks +#HZ= 100 # Frequency of times(2) clock ticks +#HZ= 1 # Give bogus result unless changed! + +STRUCTASSIGN= -DNOSTRUCTASSIGN # Compiler cannot assign structs +STRUCTASSIGN= # Compiler can assign structs + +ENUMS= -DNOENUMS # Compiler doesn't have enum type +ENUMS= # Compiler does have enum type + +OPTIMIZE= -Ox -G2 # Optimization Level (MSC, 80286) +OPTIMIZE= -O4 # Optimization Level (generic UNIX) +GCCOPTIM= -O + +LFLAGS= #Loader Flags + +CFLAGS= $(OPTIMIZE) $(TIME_FUNC) -DHZ=$(HZ) $(ENUMS) $(STRUCTASSIGN) $(CFL) +GCCFLAGS= $(GCCOPTIM) $(TIME_FUNC) -DHZ=$(HZ) $(ENUMS) $(STRUCTASSIGN) $(CFL) + +# +# You shouldn't need to touch the rest +# +SRC= dhry_1.c dhry_2.c +HDR= dhry.h + +UNIX_PROGS= cc_dry2 cc_dry2reg gcc_dry2 gcc_dry2reg +MSC_PROGS= sdry2.exe sdry2reg.exe mdry2.exe mdry2reg.exe \ + ldry2.exe ldry2reg.exe cdry2.exe cdry2reg.exe \ + hdry2.exe hdry2reg.exe + +# Files added by rer: +FILES1= README.RER clarify.doc Makefile submit.frm pure2_1.dif \ + dhry_c.dif +# Reinhold's files: +FILES2= README RATIONALE $(HDR) $(SRC) +FILES3= dhry.p + +all: $(PROGS) + +unix: $(UNIX_PROGS) + +msc: $(MSC_PROGS) + +cc_dry2: $(SRC) $(HDR) + $(CC) $(CFLAGS) $(SRC) $(LFLAGS) -o $@ + +cc_dry2reg: $(SRC) $(HDR) + $(CC) $(CFLAGS) -DREG=register $(SRC) $(LFLAGS) -o $@ + +gcc_dry2: $(SRC) $(HDR) + $(GCC) $(GCCFLAGS) $(SRC) $(LFLAGS) -o $@ + +gcc_dry2reg: $(SRC) $(HDR) + $(GCC) $(GCCFLAGS) -DREG=register $(SRC) $(LFLAGS) -o $@ + +sdry2.exe: $(SRC) $(HDR) + $(CC) -AS $(CFLAGS) $(SRC) $(LFLAGS) -o $@ + +sdry2reg.exe: $(SRC) $(HDR) + $(CC) -AS $(CFLAGS) -DREG=register $(SRC) $(LFLAGS) -o $@ + +mdry2.exe: $(SRC) $(HDR) + $(CC) -AM $(CFLAGS) $(SRC) $(LFLAGS) -o $@ + +mdry2reg.exe: $(SRC) $(HDR) + $(CC) -AM $(CFLAGS) -DREG=register $(SRC) $(LFLAGS) -o $@ + +ldry2.exe: $(SRC) $(HDR) + $(CC) -AL $(CFLAGS) $(SRC) $(LFLAGS) -o $@ + +ldry2reg.exe: $(SRC) $(HDR) + $(CC) -AL $(CFLAGS) -DREG=register $(SRC) $(LFLAGS) -o $@ + +cdry2.exe: $(SRC) $(HDR) + $(CC) -AC $(CFLAGS) $(SRC) $(LFLAGS) -o $@ + +cdry2reg.exe: $(SRC) $(HDR) + $(CC) -AC $(CFLAGS) -DREG=register $(SRC) $(LFLAGS) -o $@ + +hdry2.exe: $(SRC) $(HDR) + $(CC) -AH $(CFLAGS) $(SRC) $(LFLAGS) -o $@ + +hdry2reg.exe: $(SRC) $(HDR) + $(CC) -AH $(CFLAGS) -DREG=register $(SRC) $(LFLAGS) -o $@ + +shar: dry2shar.1 dry2shar.2 dry2shar.3 + +dry2.arc: $(FILES1) $(FILES2) $(FILES3) + arc a dry2.arc $(FILES1) $(FILES2) $(FILES3) + +dry2shar.1: $(FILES1) + shar -vc -p X $(FILES1) >$@ + +dry2shar.2: $(FILES2) + shar -vc -p X $(FILES2) >$@ + +dry2shar.3: $(FILES3) + shar -v -p X $(FILES3) >$@ + +clean: + -rm -f *.o *.obj + +clobber: clean + -rm -f $(UNIX_PROGS) $(MSC_PROGS) dry2shar.* dry2.arc + +post: dry2shar.1 dry2shar.2 dry2shar.3 + for i in 1 2 3;\ + do\ + cat HEADERS BOILER.$$i dry2shar.$$i |\ + inews -h -t "Dhrystone 2.1 ($$i of 3)" -n comp.arch;\ + done + +repost: dry2shar.1 dry2shar.2 dry2shar.3 + for i in 3;\ + do\ + cat HEADERS BOILER.$$i dry2shar.$$i |\ + inews -h -t "REPOST: Dhrystone 2.1 ($$i of 3)" -n comp.arch;\ + done + +mail: dry2shar.1 dry2shar.2 dry2shar.3 + for i in 1 2 3;\ + do\ + cat BOILER.$$i dry2shar.$$i |\ + mailx -s "Dhrystone 2.1 ($$i of 3)" $(ADDR);\ + done + +dos: + doscopy -a $(FILES1) $(FILES2) $(FILES3) dos!a:
rtl_sim/src-c/dhrystone_v2.1/original_files/Makefile Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/RATIONALE =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/RATIONALE (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/RATIONALE (revision 145) @@ -0,0 +1,358 @@ + + + Dhrystone Benchmark: Rationale for Version 2 and Measurement Rules + + + Reinhold P. Weicker + Siemens AG, E STE 35 + Postfach 3240 + D-8520 Erlangen + Germany (West) + + + + +1. Why a Version 2 of Dhrystone? + +The Dhrystone benchmark program [1] has become a popular benchmark for +CPU/compiler performance measurement, in particular in the area of +minicomputers, workstations, PC's and microprocesors. It apparently satisfies +a need for an easy-to-use integer benchmark; it gives a first performance +indication which is more meaningful than MIPS numbers which, in their literal +meaning (million instructions per second), cannot be used across different +instruction sets (e.g. RISC vs. CISC). With the increasing use of the +benchmark, it seems necessary to reconsider the benchmark and to check whether +it can still fulfill this function. Version 2 of Dhrystone is the result of +such a re-evaluation, it has been made for two reasons: + +o Dhrystone has been published in Ada [1], and Versions in Ada, Pascal and C + have been distributed by Reinhold Weicker via floppy disk. However, the + version that was used most often for benchmarking has been the version made + by Rick Richardson by another translation from the Ada version into the C + programming language, this has been the version distributed via the UNIX + network Usenet [2]. + + There is an obvious need for a common C version of Dhrystone, since C is at + present the most popular system programming language for the class of + systems (microcomputers, minicomputers, workstations) where Dhrystone is + used most. There should be, as far as possible, only one C version of + Dhrystone such that results can be compared without restrictions. In the + past, the C versions distributed by Rick Richardson (Version 1.1) and by + Reinhold Weicker had small (though not significant) differences. + + Together with the new C version, the Ada and Pascal versions have been + updated as well. + +o As far as it is possible without changes to the Dhrystone statistics, + optimizing compilers should be prevented from removing significant + statements. It has turned out in the past that optimizing compilers + suppressed code generation for too many statements (by "dead code removal" + or "dead variable elimination"). This has lead to the danger that + benchmarking results obtained by a naive application of Dhrystone - without + inspection of the code that was generated - could become meaningless. + +The overall policiy for version 2 has been that the distribution of +statements, operand types and operand locality described in [1] should remain +unchanged as much as possible. (Very few changes were necessary; their impact +should be negligible.) Also, the order of statements should remain unchanged. +Although I am aware of some critical remarks on the benchmark - I agree with +several of them - and know some suggestions for improvement, I didn't want to +change the benchmark into something different from what has become known as +"Dhrystone"; the confusion generated by such a change would probably outweight +the benefits. If I were to write a new benchmark program, I wouldn't give it +the name "Dhrystone" since this denotes the program published in [1]. +However, I do recognize the need for a larger number of representative +programs that can be used as benchmarks; users should always be encouraged to +use more than just one benchmark. + +The new versions (version 2.1 for C, Pascal and Ada) will be distributed as +widely as possible. (Version 2.1 differs from version 2.0 distributed via the +UNIX Network Usenet in March 1988 only in a few corrections for minor +deficiencies found by users of version 2.0.) Readers who want to use the +benchmark for their own measurements can obtain a copy in machine-readable +form on floppy disk (MS-DOS or XENIX format) from the author. + + +2. Overall Characteristics of Version 2 + +In general, version 2 follows - in the parts that are significant for +performance measurement, i.e. within the measurement loop - the published +(Ada) version and the C versions previously distributed. Where the versions +distributed by Rick Richardson [2] and Reinhold Weicker have been different, +it follows the version distributed by Reinhold Weicker. (However, the +differences have been so small that their impact on execution time in all +likelihood has been negligible.) The initialization and UNIX instrumentation +part - which had been omitted in [1] - follows mostly the ideas of Rick +Richardson [2]. However, any changes in the initialization part and in the +printing of the result have no impact on performance measurement since they +are outside the measaurement loop. As a concession to older compilers, names +have been made unique within the first 8 characters for the C version. + +The original publication of Dhrystone did not contain any statements for time +measurement since they are necessarily system-dependent. However, it turned +out that it is not enough just to inclose the main procedure of Dhrystone in a +loop and to measure the execution time. If the variables that are computed +are not used somehow, there is the danger that the compiler considers them as +"dead variables" and suppresses code generation for a part of the statements. +Therefore in version 2 all variables of "main" are printed at the end of the +program. This also permits some plausibility control for correct execution of +the benchmark. + +At several places in the benchmark, code has been added, but only in branches +that are not executed. The intention is that optimizing compilers should be +prevented from moving code out of the measurement loop, or from removing code +altogether. Statements that are executed have been changed in very few places +only. In these cases, only the role of some operands has been changed, and it +was made sure that the numbers defining the "Dhrystone distribution" +(distribution of statements, operand types and locality) still hold as much as +possible. Except for sophisticated optimizing compilers, execution times for +version 2.1 should be the same as for previous versions. + +Because of the self-imposed limitation that the order and distribution of the +executed statements should not be changed, there are still cases where +optimizing compilers may not generate code for some statements. To a certain +degree, this is unavoidable for small synthetic benchmarks. Users of the +benchmark are advised to check code listings whether code is generated for all +statements of Dhrystone. + +Contrary to the suggestion in the published paper and its realization in the +versions previously distributed, no attempt has been made to subtract the time +for the measurement loop overhead. (This calculation has proven difficult to +implement in a correct way, and its omission makes the program simpler.) +However, since the loop check is now part of the benchmark, this does have an +impact - though a very minor one - on the distribution statistics which have +been updated for this version. + + +3. Discussion of Individual Changes + +In this section, all changes are described that affect the measurement loop +and that are not just renamings of variables. All remarks refer to the C +version; the other language versions have been updated similarly. + +In addition to adding the measurement loop and the printout statements, +changes have been made at the following places: + +o In procedure "main", three statements have been added in the non-executed + "then" part of the statement + + if (Enum_Loc == Func_1 (Ch_Index, 'C')) + + they are + + strcpy (Str_2_Loc, "DHRYSTONE PROGRAM, 3'RD STRING"); + Int_2_Loc = Run_Index; + Int_Glob = Run_Index; + + The string assignment prevents movement of the preceding assignment to + Str_2_Loc (5'th statement of "main") out of the measurement loop (This + probably will not happen for the C version, but it did happen with another + language and compiler.) The assignment to Int_2_Loc prevents value + propagation for Int_2_Loc, and the assignment to Int_Glob makes the value of + Int_Glob possibly dependent from the value of Run_Index. + +o In the three arithmetic computations at the end of the measurement loop in + "main ", the role of some variables has been exchanged, to prevent the + division from just cancelling out the multiplication as it was in [1]. A + very smart compiler might have recognized this and suppressed code + generation for the division. + +o For Proc_2, no code has been changed, but the values of the actual parameter + have changed due to changes in "main". + +o In Proc_4, the second assignment has been changed from + + Bool_Loc = Bool_Loc | Bool_Glob; + + to + + Bool_Glob = Bool_Loc | Bool_Glob; + + It now assigns a value to a global variable instead of a local variable + (Bool_Loc); Bool_Loc would be a "dead variable" which is not used + afterwards. + +o In Func_1, the statement + + Ch_1_Glob = Ch_1_Loc; + + was added in the non-executed "else" part of the "if" statement, to prevent + the suppression of code generation for the assignment to Ch_1_Loc. + +o In Func_2, the second character comparison statement has been changed to + + if (Ch_Loc == 'R') + + ('R' instead of 'X') because a comparison with 'X' is implied in the + preceding "if" statement. + + Also in Func_2, the statement + + Int_Glob = Int_Loc; + + has been added in the non-executed part of the last "if" statement, in order + to prevent Int_Loc from becoming a dead variable. + +o In Func_3, a non-executed "else" part has been added to the "if" statement. + While the program would not be incorrect without this "else" part, it is + considered bad programming practice if a function can be left without a + return value. + + To compensate for this change, the (non-executed) "else" part in the "if" + statement of Proc_3 was removed. + +The distribution statistics have been changed only by the addition of the +measurement loop iteration (1 additional statement, 4 additional local integer +operands) and by the change in Proc_4 (one operand changed from local to +global). The distribution statistics in the comment headers have been updated +accordingly. + + +4. String Operations + +The string operations (string assignment and string comparison) have not been +changed, to keep the program consistent with the original version. + +There has been some concern that the string operations are over-represented in +the program, and that execution time is dominated by these operations. This +was true in particular when optimizing compilers removed too much code in the +main part of the program, this should have been mitigated in version 2. + +It should be noted that this is a language-dependent issue: Dhrystone was +first published in Ada, and with Ada or Pascal semantics, the time spent in +the string operations is, at least in all implementations known to me, +considerably smaller. In Ada and Pascal, assignment and comparison of strings +are operators defined in the language, and the upper bounds of the strings +occuring in Dhrystone are part of the type information known at compilation +time. The compilers can therefore generate efficient inline code. In C, +string assignemt and comparisons are not part of the language, so the string +operations must be expressed in terms of the C library functions "strcpy" and +"strcmp". (ANSI C allows an implementation to use inline code for these +functions.) In addition to the overhead caused by additional function calls, +these functions are defined for null-terminated strings where the length of +the strings is not known at compilation time; the function has to check every +byte for the termination condition (the null byte). + +Obviously, a C library which includes efficiently coded "strcpy" and "strcmp" +functions helps to obtain good Dhrystone results. However, I don't think that +this is unfair since string functions do occur quite frequently in real +programs (editors, command interpreters, etc.). If the strings functions are +implemented efficiently, this helps real programs as well as benchmark +programs. + +I admit that the string comparison in Dhrystone terminates later (after +scanning 20 characters) than most string comparisons in real programs. For +consistency with the original benchmark, I didn't change the program despite +this weakness. + + +5. Intended Use of Dhrystone + +When Dhrystone is used, the following "ground rules" apply: + +o Separate compilation (Ada and C versions) + + As mentioned in [1], Dhrystone was written to reflect actual programming + practice in systems programming. The division into several compilation + units (5 in the Ada version, 2 in the C version) is intended, as is the + distribution of inter-module and intra-module subprogram calls. Although on + many systems there will be no difference in execution time to a Dhrystone + version where all compilation units are merged into one file, the rule is + that separate compilation should be used. The intention is that real + programming practice, where programs consist of several independently + compiled units, should be reflected. This also has implies that the + compiler, while compiling one unit, has no information about the use of + variables, register allocation etc. occuring in other compilation units. + Although in real life compilation units will probably be larger, the + intention is that these effects of separate compilation are modeled in + Dhrystone. + + A few language systems have post-linkage optimization available (e.g., final + register allocation is performed after linkage). This is a borderline case: + Post-linkage optimization involves additional program preparation time + (although not as much as compilation in one unit) which may prevent its + general use in practical programming. I think that since it defeats the + intentions given above, it should not be used for Dhrystone. + + Unfortunately, ISO/ANSI Pascal does not contain language features for + separate compilation. Although most commercial Pascal compilers provide + separate compilation in some way, we cannot use it for Dhrystone since such + a version would not be portable. Therefore, no attempt has been made to + provide a Pascal version with several compilation units. + +o No procedure merging + + Although Dhrystone contains some very short procedures where execution would + benefit from procedure merging (inlining, macro expansion of procedures), + procedure merging is not to be used. The reason is that the percentage of + procedure and function calls is part of the "Dhrystone distribution" of + statements contained in [1]. This restriction does not hold for the string + functions of the C version since ANSI C allows an implementation to use + inline code for these functions. + +o Other optimizations are allowed, but they should be indicated + + It is often hard to draw an exact line between "normal code generation" and + "optimization" in compilers: Some compilers perform operations by default + that are invoked in other compilers only when optimization is explicitly + requested. Also, we cannot avoid that in benchmarking people try to achieve + results that look as good as possible. Therefore, optimizations performed + by compilers - other than those listed above - are not forbidden when + Dhrystone execution times are measured. Dhrystone is not intended to be + non-optimizable but is intended to be similarly optimizable as normal + programs. For example, there are several places in Dhrystone where + performance benefits from optimizations like common subexpression + elimination, value propagation etc., but normal programs usually also + benefit from these optimizations. Therefore, no effort was made to + artificially prevent such optimizations. However, measurement reports + should indicate which compiler optimization levels have been used, and + reporting results with different levels of compiler optimization for the + same hardware is encouraged. + +o Default results are those without "register" declarations (C version) + + When Dhrystone results are quoted without additional qualification, they + should be understood as results obtained without use of the "register" + attribute. Good compilers should be able to make good use of registers even + without explicit register declarations ([3], p. 193). + +Of course, for experimental purposes, post-linkage optimization, procedure +merging and/or compilation in one unit can be done to determine their effects. +However, Dhrystone numbers obtained under these conditions should be +explicitly marked as such; "normal" Dhrystone results should be understood as +results obtained following the ground rules listed above. + +In any case, for serious performance evaluation, users are advised to ask for +code listings and to check them carefully. In this way, when results for +different systems are compared, the reader can get a feeling how much +performance difference is due to compiler optimization and how much is due to +hardware speed. + + +6. Acknowledgements + +The C version 2.1 of Dhrystone has been developed in cooperation with Rick +Richardson (Tinton Falls, NJ), it incorporates many ideas from the "Version +1.1" distributed previously by him over the UNIX network Usenet. Through his +activity with Usenet, Rick Richardson has made a very valuable contribution to +the dissemination of the benchmark. I also thank Chaim Benedelac (National +Semiconductor), David Ditzel (SUN), Earl Killian and John Mashey (MIPS), Alan +Smith and Rafael Saavedra-Barrera (UC at Berkeley) for their help with +comments on earlier versions of the benchmark. + + +7. Bibliography + +[1] + Reinhold P. Weicker: Dhrystone: A Synthetic Systems Programming Benchmark. + Communications of the ACM 27, 10 (Oct. 1984), 1013-1030 + +[2] + Rick Richardson: Dhrystone 1.1 Benchmark Summary (and Program Text) + Informal Distribution via "Usenet", Last Version Known to me: Sept. 21, + 1987 + +[3] + Brian W. Kernighan and Dennis M. Ritchie: The C Programming Language. + Prentice-Hall, Englewood Cliffs (NJ) 1978 +
rtl_sim/src-c/dhrystone_v2.1/original_files/RATIONALE Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/original_files/pure2_1.dif =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/original_files/pure2_1.dif (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/original_files/pure2_1.dif (revision 145) @@ -0,0 +1,141 @@ +*** rer/dhry.h Sun Dec 4 00:08:26 1988 +--- weicker/dhry.h Sun Dec 4 00:09:00 1988 +*************** +*** 38,45 + * PC Research. Inc. + * 94 Apple Orchard Drive + * Tinton Falls, NJ 07724 +! * Phone: (201) 389-8963 (9-17 EST) +! * Usenet: ...!uunet!pcrat!rick + * + * Please send results to Rick Richardson and/or Reinhold Weicker. + * Complete information should be given on hardware and software used. + +--- 38,45 ----- + * PC Research. Inc. + * 94 Apple Orchard Drive + * Tinton Falls, NJ 07724 +! * Phone: (201) 834-1378 (9-17 EST) +! * Usenet: ...!seismo!uunet!pcrat!rick + * + * Please send results to Rick Richardson and/or Reinhold Weicker. + * Complete information should be given on hardware and software used. +*************** +*** 348,354 + /* Compiler and system dependent definitions: */ + + #ifndef TIME +- #undef TIMES + #define TIMES + #endif + /* Use times(2) time function unless */ + +--- 348,353 ----- + /* Compiler and system dependent definitions: */ + + #ifndef TIME + #define TIMES + #endif + /* Use times(2) time function unless */ +*************** +*** 353,366 + #endif + /* Use times(2) time function unless */ + /* explicitly defined otherwise */ +- +- #ifdef MSC_CLOCK +- #undef HZ +- #undef TIMES +- #include +- #define HZ CLK_TCK +- #endif +- /* Use Microsoft C hi-res clock */ + + #ifdef TIMES + #include + +--- 352,357 ----- + #endif + /* Use times(2) time function unless */ + /* explicitly defined otherwise */ + + #ifdef TIMES + #include +*** rer/dhry_1.c Sun Dec 4 00:08:36 1988 +--- weicker/dhry_1.c Sun Dec 4 00:09:09 1988 +*************** +*** 47,53 + struct tms time_info; + extern int times (); + /* see library function "times" */ +! #define Too_Small_Time (2*HZ) + /* Measurements should last at least about 2 seconds */ + #endif + #ifdef TIME + +--- 47,53 ----- + struct tms time_info; + extern int times (); + /* see library function "times" */ +! #define Too_Small_Time 120 + /* Measurements should last at least about 2 seconds */ + #endif + #ifdef TIME +*************** +*** 56,65 + #define Too_Small_Time 2 + /* Measurements should last at least 2 seconds */ + #endif +- #ifdef MSC_CLOCK +- extern clock_t clock(); +- #define Too_Small_Time (2*HZ) +- #endif + + long Begin_Time, + End_Time, + +--- 56,61 ----- + #define Too_Small_Time 2 + /* Measurements should last at least 2 seconds */ + #endif + + long Begin_Time, + End_Time, +*************** +*** 139,147 + #ifdef TIME + Begin_Time = time ( (long *) 0); + #endif +- #ifdef MSC_CLOCK +- Begin_Time = clock(); +- #endif + + for (Run_Index = 1; Run_Index <= Number_Of_Runs; ++Run_Index) + { + +--- 135,140 ----- + #ifdef TIME + Begin_Time = time ( (long *) 0); + #endif + + for (Run_Index = 1; Run_Index <= Number_Of_Runs; ++Run_Index) + { +*************** +*** 199,207 + #endif + #ifdef TIME + End_Time = time ( (long *) 0); +- #endif +- #ifdef MSC_CLOCK +- End_Time = clock(); + #endif + + printf ("Execution ends\n"); + +--- 192,197 ----- + #endif + #ifdef TIME + End_Time = time ( (long *) 0); + #endif + + printf ("Execution ends\n");
rtl_sim/src-c/dhrystone_v2.1/original_files/pure2_1.dif Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/dhry_1.c =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/dhry_1.c (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/dhry_1.c (revision 145) @@ -0,0 +1,410 @@ +/* + **************************************************************************** + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: C, Version 2.1 + * + * File: dhry_1.c (part 2 of 3) + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * + **************************************************************************** + */ + +#include "dhry.h" +#include "omsp_func.h" + +/* Global Variables: */ + +Rec_Pointer Ptr_Glob, + Next_Ptr_Glob; +int Int_Glob; +Boolean Bool_Glob; +char Ch_1_Glob, + Ch_2_Glob; +int Arr_1_Glob [50]; +int Arr_2_Glob [50] [50]; + +extern char *malloc (); +Enumeration Func_1 (); + /* forward declaration necessary since Enumeration may not simply be int */ + +#ifndef REG + Boolean Reg = false; +#define REG + /* REG becomes defined as empty */ + /* i.e. no register variables */ +#else + Boolean Reg = true; +#endif + +/* variables for time measurement: */ + +#ifdef TIMES +struct tms time_info; +extern int times (); + /* see library function "times" */ +#define Too_Small_Time (2*HZ) + /* Measurements should last at least about 2 seconds */ +#endif +#ifdef TIME +extern long time(); + /* see library function "time" */ +#define Too_Small_Time 2 + /* Measurements should last at least 2 seconds */ +#endif +#ifdef MSC_CLOCK +extern clock_t clock(); +#define Too_Small_Time (2*HZ) +#endif + +long Begin_Time, + End_Time, + User_Time; +float Microseconds, + Dhrystones_Per_Second; + +/* end of variables for time measurement */ + + +main () +/*****/ + + /* main program, corresponds to procedures */ + /* Main and Proc_0 in the Ada version */ +{ + One_Fifty Int_1_Loc; + REG One_Fifty Int_2_Loc; + One_Fifty Int_3_Loc; + REG char Ch_Index; + Enumeration Enum_Loc; + Str_30 Str_1_Loc; + Str_30 Str_2_Loc; + REG int Run_Index; + REG int Number_Of_Runs; + + /* Initializations */ + + STOP_WATCHDOG; + + Next_Ptr_Glob = (Rec_Pointer) malloc (sizeof (Rec_Type)); + Ptr_Glob = (Rec_Pointer) malloc (sizeof (Rec_Type)); + + Ptr_Glob->Ptr_Comp = Next_Ptr_Glob; + Ptr_Glob->Discr = Ident_1; + Ptr_Glob->variant.var_1.Enum_Comp = Ident_3; + Ptr_Glob->variant.var_1.Int_Comp = 40; + strcpy (Ptr_Glob->variant.var_1.Str_Comp, + "DHRYSTONE PROGRAM, SOME STRING"); + strcpy (Str_1_Loc, "DHRYSTONE PROGRAM, 1'ST STRING"); + + Arr_2_Glob [8][7] = 10; + /* Was missing in published program. Without this statement, */ + /* Arr_2_Glob [8][7] would have an undefined value. */ + /* Warning: With 16-Bit processors and Number_Of_Runs > 32000, */ + /* overflow may occur for this array element. */ + + printf ("\n"); + printf ("Dhrystone Benchmark, Version 2.1 (Language: C)\n"); + printf ("\n"); + if (Reg) + { + printf ("Program compiled with 'register' attribute\n"); + printf ("\n"); + } + else + { + printf ("Program compiled without 'register' attribute\n"); + printf ("\n"); + } + /* Replace scanf() with giving 'Number_Of_Runs' a constant value */ + /* + printf ("Please give the number of runs through the benchmark: "); + { + int n; + scanf ("%d", &n); + Number_Of_Runs = n; + } + printf ("\n"); + */ + Number_Of_Runs = 100; + + printf ("Execution starts, %d runs through Dhrystone\n", Number_Of_Runs); + + /***************/ + /* Start timer */ + /***************/ + +#ifdef TIMES + times (&time_info); + Begin_Time = (long) time_info.tms_utime; +#endif +#ifdef TIME + Begin_Time = time ( (long *) 0); +#endif +#ifdef MSC_CLOCK + Begin_Time = clock(); +#endif + START_TIME; // Set P3[0] + + for (Run_Index = 1; Run_Index <= Number_Of_Runs; ++Run_Index) + { + + Proc_5(); + Proc_4(); + /* Ch_1_Glob == 'A', Ch_2_Glob == 'B', Bool_Glob == true */ + Int_1_Loc = 2; + Int_2_Loc = 3; + strcpy (Str_2_Loc, "DHRYSTONE PROGRAM, 2'ND STRING"); + Enum_Loc = Ident_2; + Bool_Glob = ! Func_2 (Str_1_Loc, Str_2_Loc); + /* Bool_Glob == 1 */ + while (Int_1_Loc < Int_2_Loc) /* loop body executed once */ + { + Int_3_Loc = 5 * Int_1_Loc - Int_2_Loc; + /* Int_3_Loc == 7 */ + Proc_7 (Int_1_Loc, Int_2_Loc, &Int_3_Loc); + /* Int_3_Loc == 7 */ + Int_1_Loc += 1; + } /* while */ + /* Int_1_Loc == 3, Int_2_Loc == 3, Int_3_Loc == 7 */ + Proc_8 (Arr_1_Glob, Arr_2_Glob, Int_1_Loc, Int_3_Loc); + /* Int_Glob == 5 */ + Proc_1 (Ptr_Glob); + for (Ch_Index = 'A'; Ch_Index <= Ch_2_Glob; ++Ch_Index) + /* loop body executed twice */ + { + if (Enum_Loc == Func_1 (Ch_Index, 'C')) + /* then, not executed */ + { + Proc_6 (Ident_1, &Enum_Loc); + strcpy (Str_2_Loc, "DHRYSTONE PROGRAM, 3'RD STRING"); + Int_2_Loc = Run_Index; + Int_Glob = Run_Index; + } + } + /* Int_1_Loc == 3, Int_2_Loc == 3, Int_3_Loc == 7 */ + Int_2_Loc = Int_2_Loc * Int_1_Loc; + Int_1_Loc = Int_2_Loc / Int_3_Loc; + Int_2_Loc = 7 * (Int_2_Loc - Int_3_Loc) - Int_1_Loc; + /* Int_1_Loc == 1, Int_2_Loc == 13, Int_3_Loc == 7 */ + Proc_2 (&Int_1_Loc); + /* Int_1_Loc == 5 */ + + } /* loop "for Run_Index" */ + + /**************/ + /* Stop timer */ + /**************/ + END_TIME; // Clear P3[0] + +#ifdef TIMES + times (&time_info); + End_Time = (long) time_info.tms_utime; +#endif +#ifdef TIME + End_Time = time ( (long *) 0); +#endif +#ifdef MSC_CLOCK + End_Time = clock(); +#endif + + printf ("Execution ends\n"); + printf ("\n"); + printf ("Final values of the variables used in the benchmark:\n"); + printf ("\n"); + printf ("Int_Glob: %d\n", Int_Glob); + printf (" should be: %d\n", 5); + printf ("Bool_Glob: %d\n", Bool_Glob); + printf (" should be: %d\n", 1); + printf ("Ch_1_Glob: %c\n", Ch_1_Glob); + printf (" should be: %c\n", 'A'); + printf ("Ch_2_Glob: %c\n", Ch_2_Glob); + printf (" should be: %c\n", 'B'); + printf ("Arr_1_Glob[8]: %d\n", Arr_1_Glob[8]); + printf (" should be: %d\n", 7); + printf ("Arr_2_Glob[8][7]: %d\n", Arr_2_Glob[8][7]); + printf (" should be: Number_Of_Runs + 10\n"); + printf ("Ptr_Glob->\n"); + printf (" Ptr_Comp: %d\n", (int) Ptr_Glob->Ptr_Comp); + printf (" should be: (implementation-dependent)\n"); + printf (" Discr: %d\n", Ptr_Glob->Discr); + printf (" should be: %d\n", 0); + printf (" Enum_Comp: %d\n", Ptr_Glob->variant.var_1.Enum_Comp); + printf (" should be: %d\n", 2); + printf (" Int_Comp: %d\n", Ptr_Glob->variant.var_1.Int_Comp); + printf (" should be: %d\n", 17); + printf (" Str_Comp: %s\n", Ptr_Glob->variant.var_1.Str_Comp); + printf (" should be: DHRYSTONE PROGRAM, SOME STRING\n"); + printf ("Next_Ptr_Glob->\n"); + printf (" Ptr_Comp: %d\n", (int) Next_Ptr_Glob->Ptr_Comp); + printf (" should be: (implementation-dependent), same as above\n"); + printf (" Discr: %d\n", Next_Ptr_Glob->Discr); + printf (" should be: %d\n", 0); + printf (" Enum_Comp: %d\n", Next_Ptr_Glob->variant.var_1.Enum_Comp); + printf (" should be: %d\n", 1); + printf (" Int_Comp: %d\n", Next_Ptr_Glob->variant.var_1.Int_Comp); + printf (" should be: %d\n", 18); + printf (" Str_Comp: %s\n", + Next_Ptr_Glob->variant.var_1.Str_Comp); + printf (" should be: DHRYSTONE PROGRAM, SOME STRING\n"); + printf ("Int_1_Loc: %d\n", Int_1_Loc); + printf (" should be: %d\n", 5); + printf ("Int_2_Loc: %d\n", Int_2_Loc); + printf (" should be: %d\n", 13); + printf ("Int_3_Loc: %d\n", Int_3_Loc); + printf (" should be: %d\n", 7); + printf ("Enum_Loc: %d\n", Enum_Loc); + printf (" should be: %d\n", 1); + printf ("Str_1_Loc: %s\n", Str_1_Loc); + printf (" should be: DHRYSTONE PROGRAM, 1'ST STRING\n"); + printf ("Str_2_Loc: %s\n", Str_2_Loc); + printf (" should be: DHRYSTONE PROGRAM, 2'ND STRING\n"); + printf ("\n"); + + /* Comment out this section because we did not measure time with + the MCU; also the simple printf function does not support floats */ + /* + User_Time = End_Time - Begin_Time; + + if (User_Time < Too_Small_Time) + { + printf ("Measured time too small to obtain meaningful results\n"); + printf ("Please increase number of runs\n"); + printf ("\n"); + } + else + { +#ifdef TIME + Microseconds = (float) User_Time * Mic_secs_Per_Second + / (float) Number_Of_Runs; + Dhrystones_Per_Second = (float) Number_Of_Runs / (float) User_Time; +#else + Microseconds = (float) User_Time * Mic_secs_Per_Second + / ((float) HZ * ((float) Number_Of_Runs)); + Dhrystones_Per_Second = ((float) HZ * (float) Number_Of_Runs) + / (float) User_Time; +#endif + printf ("Microseconds for one run through Dhrystone: "); + printf ("%6.1f \n", Microseconds); + printf ("Dhrystones per Second: "); + printf ("%6.1f \n", Dhrystones_Per_Second); + printf ("\n"); + } + */ + + DHRYSTONE_DONE; + +} + + +Proc_1 (Ptr_Val_Par) +/******************/ + +REG Rec_Pointer Ptr_Val_Par; + /* executed once */ +{ + REG Rec_Pointer Next_Record = Ptr_Val_Par->Ptr_Comp; + /* == Ptr_Glob_Next */ + /* Local variable, initialized with Ptr_Val_Par->Ptr_Comp, */ + /* corresponds to "rename" in Ada, "with" in Pascal */ + + structassign (*Ptr_Val_Par->Ptr_Comp, *Ptr_Glob); + Ptr_Val_Par->variant.var_1.Int_Comp = 5; + Next_Record->variant.var_1.Int_Comp + = Ptr_Val_Par->variant.var_1.Int_Comp; + Next_Record->Ptr_Comp = Ptr_Val_Par->Ptr_Comp; + Proc_3 (&Next_Record->Ptr_Comp); + /* Ptr_Val_Par->Ptr_Comp->Ptr_Comp + == Ptr_Glob->Ptr_Comp */ + if (Next_Record->Discr == Ident_1) + /* then, executed */ + { + Next_Record->variant.var_1.Int_Comp = 6; + Proc_6 (Ptr_Val_Par->variant.var_1.Enum_Comp, + &Next_Record->variant.var_1.Enum_Comp); + Next_Record->Ptr_Comp = Ptr_Glob->Ptr_Comp; + Proc_7 (Next_Record->variant.var_1.Int_Comp, 10, + &Next_Record->variant.var_1.Int_Comp); + } + else /* not executed */ + structassign (*Ptr_Val_Par, *Ptr_Val_Par->Ptr_Comp); +} /* Proc_1 */ + + +Proc_2 (Int_Par_Ref) +/******************/ + /* executed once */ + /* *Int_Par_Ref == 1, becomes 4 */ + +One_Fifty *Int_Par_Ref; +{ + One_Fifty Int_Loc; + Enumeration Enum_Loc; + + Int_Loc = *Int_Par_Ref + 10; + do /* executed once */ + if (Ch_1_Glob == 'A') + /* then, executed */ + { + Int_Loc -= 1; + *Int_Par_Ref = Int_Loc - Int_Glob; + Enum_Loc = Ident_1; + } /* if */ + while (Enum_Loc != Ident_1); /* true */ +} /* Proc_2 */ + + +Proc_3 (Ptr_Ref_Par) +/******************/ + /* executed once */ + /* Ptr_Ref_Par becomes Ptr_Glob */ + +Rec_Pointer *Ptr_Ref_Par; + +{ + if (Ptr_Glob != Null) + /* then, executed */ + *Ptr_Ref_Par = Ptr_Glob->Ptr_Comp; + Proc_7 (10, Int_Glob, &Ptr_Glob->variant.var_1.Int_Comp); +} /* Proc_3 */ + + +Proc_4 () /* without parameters */ +/*******/ + /* executed once */ +{ + Boolean Bool_Loc; + + Bool_Loc = Ch_1_Glob == 'A'; + Bool_Glob = Bool_Loc | Bool_Glob; + Ch_2_Glob = 'B'; +} /* Proc_4 */ + + +Proc_5 () /* without parameters */ +/*******/ + /* executed once */ +{ + Ch_1_Glob = 'A'; + Bool_Glob = false; +} /* Proc_5 */ + + + /* Procedure for the assignment of structures, */ + /* if the C compiler doesn't support this feature */ +#ifdef NOSTRUCTASSIGN +memcpy (d, s, l) +register char *d; +register char *s; +register int l; +{ + while (l--) *d++ = *s++; +} +#endif + +
rtl_sim/src-c/dhrystone_v2.1/dhry_1.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/dhry_2.c =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/dhry_2.c (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/dhry_2.c (revision 145) @@ -0,0 +1,192 @@ +/* + **************************************************************************** + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: C, Version 2.1 + * + * File: dhry_2.c (part 3 of 3) + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * + **************************************************************************** + */ + +#include "dhry.h" + +#ifndef REG +#define REG + /* REG becomes defined as empty */ + /* i.e. no register variables */ +#endif + +extern int Int_Glob; +extern char Ch_1_Glob; + + +Proc_6 (Enum_Val_Par, Enum_Ref_Par) +/*********************************/ + /* executed once */ + /* Enum_Val_Par == Ident_3, Enum_Ref_Par becomes Ident_2 */ + +Enumeration Enum_Val_Par; +Enumeration *Enum_Ref_Par; +{ + *Enum_Ref_Par = Enum_Val_Par; + if (! Func_3 (Enum_Val_Par)) + /* then, not executed */ + *Enum_Ref_Par = Ident_4; + switch (Enum_Val_Par) + { + case Ident_1: + *Enum_Ref_Par = Ident_1; + break; + case Ident_2: + if (Int_Glob > 100) + /* then */ + *Enum_Ref_Par = Ident_1; + else *Enum_Ref_Par = Ident_4; + break; + case Ident_3: /* executed */ + *Enum_Ref_Par = Ident_2; + break; + case Ident_4: break; + case Ident_5: + *Enum_Ref_Par = Ident_3; + break; + } /* switch */ +} /* Proc_6 */ + + +Proc_7 (Int_1_Par_Val, Int_2_Par_Val, Int_Par_Ref) +/**********************************************/ + /* executed three times */ + /* first call: Int_1_Par_Val == 2, Int_2_Par_Val == 3, */ + /* Int_Par_Ref becomes 7 */ + /* second call: Int_1_Par_Val == 10, Int_2_Par_Val == 5, */ + /* Int_Par_Ref becomes 17 */ + /* third call: Int_1_Par_Val == 6, Int_2_Par_Val == 10, */ + /* Int_Par_Ref becomes 18 */ +One_Fifty Int_1_Par_Val; +One_Fifty Int_2_Par_Val; +One_Fifty *Int_Par_Ref; +{ + One_Fifty Int_Loc; + + Int_Loc = Int_1_Par_Val + 2; + *Int_Par_Ref = Int_2_Par_Val + Int_Loc; +} /* Proc_7 */ + + +Proc_8 (Arr_1_Par_Ref, Arr_2_Par_Ref, Int_1_Par_Val, Int_2_Par_Val) +/*********************************************************************/ + /* executed once */ + /* Int_Par_Val_1 == 3 */ + /* Int_Par_Val_2 == 7 */ +Arr_1_Dim Arr_1_Par_Ref; +Arr_2_Dim Arr_2_Par_Ref; +int Int_1_Par_Val; +int Int_2_Par_Val; +{ + REG One_Fifty Int_Index; + REG One_Fifty Int_Loc; + + Int_Loc = Int_1_Par_Val + 5; + Arr_1_Par_Ref [Int_Loc] = Int_2_Par_Val; + Arr_1_Par_Ref [Int_Loc+1] = Arr_1_Par_Ref [Int_Loc]; + Arr_1_Par_Ref [Int_Loc+30] = Int_Loc; + for (Int_Index = Int_Loc; Int_Index <= Int_Loc+1; ++Int_Index) + Arr_2_Par_Ref [Int_Loc] [Int_Index] = Int_Loc; + Arr_2_Par_Ref [Int_Loc] [Int_Loc-1] += 1; + Arr_2_Par_Ref [Int_Loc+20] [Int_Loc] = Arr_1_Par_Ref [Int_Loc]; + Int_Glob = 5; +} /* Proc_8 */ + + +Enumeration Func_1 (Ch_1_Par_Val, Ch_2_Par_Val) +/*************************************************/ + /* executed three times */ + /* first call: Ch_1_Par_Val == 'H', Ch_2_Par_Val == 'R' */ + /* second call: Ch_1_Par_Val == 'A', Ch_2_Par_Val == 'C' */ + /* third call: Ch_1_Par_Val == 'B', Ch_2_Par_Val == 'C' */ + +Capital_Letter Ch_1_Par_Val; +Capital_Letter Ch_2_Par_Val; +{ + Capital_Letter Ch_1_Loc; + Capital_Letter Ch_2_Loc; + + Ch_1_Loc = Ch_1_Par_Val; + Ch_2_Loc = Ch_1_Loc; + if (Ch_2_Loc != Ch_2_Par_Val) + /* then, executed */ + return (Ident_1); + else /* not executed */ + { + Ch_1_Glob = Ch_1_Loc; + return (Ident_2); + } +} /* Func_1 */ + + +Boolean Func_2 (Str_1_Par_Ref, Str_2_Par_Ref) +/*************************************************/ + /* executed once */ + /* Str_1_Par_Ref == "DHRYSTONE PROGRAM, 1'ST STRING" */ + /* Str_2_Par_Ref == "DHRYSTONE PROGRAM, 2'ND STRING" */ + +Str_30 Str_1_Par_Ref; +Str_30 Str_2_Par_Ref; +{ + REG One_Thirty Int_Loc; + Capital_Letter Ch_Loc; + + Int_Loc = 2; + while (Int_Loc <= 2) /* loop body executed once */ + if (Func_1 (Str_1_Par_Ref[Int_Loc], + Str_2_Par_Ref[Int_Loc+1]) == Ident_1) + /* then, executed */ + { + Ch_Loc = 'A'; + Int_Loc += 1; + } /* if, while */ + if (Ch_Loc >= 'W' && Ch_Loc < 'Z') + /* then, not executed */ + Int_Loc = 7; + if (Ch_Loc == 'R') + /* then, not executed */ + return (true); + else /* executed */ + { + if (strcmp (Str_1_Par_Ref, Str_2_Par_Ref) > 0) + /* then, not executed */ + { + Int_Loc += 7; + Int_Glob = Int_Loc; + return (true); + } + else /* executed */ + return (false); + } /* if Ch_Loc */ +} /* Func_2 */ + + +Boolean Func_3 (Enum_Par_Val) +/***************************/ + /* executed once */ + /* Enum_Par_Val == Ident_3 */ +Enumeration Enum_Par_Val; +{ + Enumeration Enum_Loc; + + Enum_Loc = Enum_Par_Val; + if (Enum_Loc == Ident_3) + /* then, executed */ + return (true); + else /* not executed */ + return (false); +} /* Func_3 */ +
rtl_sim/src-c/dhrystone_v2.1/dhry_2.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/dhrystone_v2.1.v =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/dhrystone_v2.1.v (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/dhrystone_v2.1.v (revision 145) @@ -0,0 +1,137 @@ +/*===========================================================================*/ +/* Copyright (C) 2001 Authors */ +/* */ +/* This source file may be used and distributed without restriction provided */ +/* that this copyright statement is not removed from the file and that any */ +/* derivative work contains the original copyright notice and the associated */ +/* disclaimer. */ +/* */ +/* This source file is free software; you can redistribute it and/or modify */ +/* it under the terms of the GNU Lesser General Public License as published */ +/* by the Free Software Foundation; either version 2.1 of the License, or */ +/* (at your option) any later version. */ +/* */ +/* This source is distributed in the hope that it will be useful, but WITHOUT*/ +/* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */ +/* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */ +/* License for more details. */ +/* */ +/* You should have received a copy of the GNU Lesser General Public License */ +/* along with this source; if not, write to the Free Software Foundation, */ +/* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ +/* */ +/*===========================================================================*/ +/* SANDBOX */ +/*---------------------------------------------------------------------------*/ +/* */ +/* Author(s): */ +/* - Olivier Girard, olgirard@gmail.com */ +/* */ +/*---------------------------------------------------------------------------*/ +/* $Rev: 19 $ */ +/* $LastChangedBy: olivier.girard $ */ +/* $LastChangedDate: 2009-08-04 23:47:15 +0200 (Tue, 04 Aug 2009) $ */ +/*===========================================================================*/ +`define NO_TIMEOUT + +time mclk_start_time, mclk_end_time; +real mclk_period, mclk_frequency; + +time dhry_start_time, dhry_end_time; +real dhry_per_sec, dhry_mips, dhry_mips_per_mhz; + +integer Number_Of_Runs; + +initial + begin + $display(" ==============================================="); + $display("| START SIMULATION |"); + $display(" ==============================================="); + repeat(5) @(posedge mclk); + stimulus_done = 0; + + //--------------------------------------- + // Check CPU configuration + //--------------------------------------- + + if ((`PMEM_SIZE !== 24576) || (`DMEM_SIZE !== 16384)) + begin + $display(" ==============================================="); + $display("| SIMULATION ERROR |"); + $display("| |"); + $display("| Core must be configured for: |"); + $display("| - 24kB program memory |"); + $display("| - 16kB data memory |"); + $display(" ==============================================="); + $finish; + end + + //--------------------------------------- + // Number of benchmark iteration + // (Must match the C-code value) + //--------------------------------------- + + Number_Of_Runs = 100; + + + //--------------------------------------- + // Measure clock period + //--------------------------------------- + repeat(100) @(posedge mclk); + $timeformat(-9, 3, " ns", 10); + @(posedge mclk); + mclk_start_time = $time; + @(posedge mclk); + mclk_end_time = $time; + @(posedge mclk); + mclk_period = mclk_end_time-mclk_start_time; + mclk_frequency = 1000/mclk_period; + $display("\nINFO-VERILOG: openMSP430 System clock frequency %f MHz\n", mclk_frequency); + + //--------------------------------------- + // Measure Dhrystone run time + //--------------------------------------- + + // Detect beginning of run + @(posedge p3_dout[0]); + dhry_start_time = $time; + $timeformat(-3, 3, " ms", 10); + $display("\nINFO-VERILOG: Dhrystone loop started at %t ", dhry_start_time); + + // Detect end of run + @(negedge p3_dout[0]); + dhry_end_time = $time; + $timeformat(-3, 3, " ms", 10); + $display("INFO-VERILOG: Dhrystone loop ended at %t ", dhry_end_time); + + // Compute results + $timeformat(-9, 3, " ns", 10); + dhry_per_sec = (Number_Of_Runs*1000000000)/(dhry_end_time - dhry_start_time); + dhry_mips = dhry_per_sec / 1757; + dhry_mips_per_mhz = dhry_mips / mclk_frequency; + + // Report results + $display("\INFO-VERILOG: Dhrystone per second : %f", dhry_per_sec); + $display("\INFO-VERILOG: DMIPS : %f", dhry_mips); + $display("\INFO-VERILOG: DMIPS/MHz : %f\n", dhry_mips_per_mhz); + + //--------------------------------------- + // Wait for the end of C-code execution + //--------------------------------------- + @(posedge p4_dout[0]); + + stimulus_done = 1; + + $display(" ==============================================="); + $display("| SIMULATION DONE |"); + $display("| (stopped through verilog stimulus) |"); + $display(" ==============================================="); + $finish; + + end + +// Display stuff from the C-program +always @(p2_dout[0]) + begin + $write("%s", p1_dout); + end
rtl_sim/src-c/dhrystone_v2.1/dhrystone_v2.1.v Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/linker.x =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/linker.x (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/linker.x (revision 145) @@ -0,0 +1,216 @@ +/* Default linker script, for normal executables */ +OUTPUT_FORMAT("elf32-msp430") +OUTPUT_ARCH("msp430") +MEMORY { + sfr : ORIGIN = 0x0000, LENGTH = 0x0010 + peripheral_8bit : ORIGIN = 0x0010, LENGTH = 0x00f0 + peripheral_16bit : ORIGIN = 0x0100, LENGTH = 0x0100 + + ram (wx) : ORIGIN = 0x0200, LENGTH = 0x4000 + rom (rx) : ORIGIN = 0xA000, LENGTH = 0x6000-0x20 + vectors : ORIGIN = 0xffe0, LENGTH = 0x0020 + + /* Remaining banks are absent */ + bsl : ORIGIN = 0x0000, LENGTH = 0x0000 + infomem : ORIGIN = 0x0000, LENGTH = 0x0000 + infob : ORIGIN = 0x0000, LENGTH = 0x0000 + infoa : ORIGIN = 0x0000, LENGTH = 0x0000 + infoc : ORIGIN = 0x0000, LENGTH = 0x0000 + infod : ORIGIN = 0x0000, LENGTH = 0x0000 + ram2 (wx) : ORIGIN = 0x0000, LENGTH = 0x0000 + ram_mirror (wx) : ORIGIN = 0x0000, LENGTH = 0x0000 + usbram (wx) : ORIGIN = 0x0000, LENGTH = 0x0000 + far_rom : ORIGIN = 0x00000000, LENGTH = 0x00000000 +} +REGION_ALIAS("REGION_TEXT", rom); +REGION_ALIAS("REGION_DATA", ram); +REGION_ALIAS("REGION_FAR_ROM", far_rom); +__WDTCTL = 0x0120; +__MPY = 0x0130; +__MPYS = 0x0132; +__MAC = 0x0134; +__MACS = 0x0136; +__OP2 = 0x0138; +__RESLO = 0x013A; +__RESHI = 0x013C; +__SUMEXT = 0x013E; + +SECTIONS +{ + /* Read-only sections, merged into text segment. */ + .hash : { *(.hash) } + .dynsym : { *(.dynsym) } + .dynstr : { *(.dynstr) } + .gnu.version : { *(.gnu.version) } + .gnu.version_d : { *(.gnu.version_d) } + .gnu.version_r : { *(.gnu.version_r) } + .rel.init : { *(.rel.init) } + .rela.init : { *(.rela.init) } + .rel.fini : { *(.rel.fini) } + .rela.fini : { *(.rela.fini) } + .rel.text : { *(.rel.text .rel.text.* .rel.gnu.linkonce.t.*) } + .rela.text : { *(.rela.text .rela.text.* .rela.gnu.linkonce.t.*) } + .rel.rodata : { *(.rel.rodata .rel.rodata.* .rel.gnu.linkonce.r.*) } + .rela.rodata : { *(.rela.rodata .rela.rodata.* .rela.gnu.linkonce.r.*) } + .rel.data : { *(.rel.data .rel.data.* .rel.gnu.linkonce.d.*) } + .rela.data : { *(.rela.data .rela.data.* .rela.gnu.linkonce.d.*) } + .rel.bss : { *(.rel.bss .rel.bss.* .rel.gnu.linkonce.b.*) } + .rela.bss : { *(.rela.bss .rela.bss.* .rela.gnu.linkonce.b.*) } + .rel.ctors : { *(.rel.ctors) } + .rela.ctors : { *(.rela.ctors) } + .rel.dtors : { *(.rel.dtors) } + .rela.dtors : { *(.rela.dtors) } + .rel.got : { *(.rel.got) } + .rela.got : { *(.rela.got) } + .rel.plt : { *(.rel.plt) } + .rela.plt : { *(.rela.plt) } + .text : + { + . = ALIGN(2); + KEEP(*(.init .init.*)) + KEEP(*(.init0)) /* Start here after reset. */ + KEEP(*(.init1)) /* User definable. */ + KEEP(*(.init2)) /* Initialize stack. */ + KEEP(*(.init3)) /* Initialize hardware, user definable. */ + KEEP(*(.init4)) /* Copy data to .data, clear bss. */ + KEEP(*(.init5)) /* User definable. */ + KEEP(*(.init6)) /* C++ constructors. */ + KEEP(*(.init7)) /* User definable. */ + KEEP(*(.init8)) /* User definable. */ + KEEP(*(.init9)) /* Call main(). */ + KEEP(*(.fini9)) /* Falls into here after main(). User definable. */ + KEEP(*(.fini8)) /* User definable. */ + KEEP(*(.fini7)) /* User definable. */ + KEEP(*(.fini6)) /* C++ destructors. */ + KEEP(*(.fini5)) /* User definable. */ + KEEP(*(.fini4)) /* User definable. */ + KEEP(*(.fini3)) /* User definable. */ + KEEP(*(.fini2)) /* User definable. */ + KEEP(*(.fini1)) /* User definable. */ + KEEP(*(.fini0)) /* Infinite loop after program termination. */ + KEEP(*(.fini .fini.*)) + . = ALIGN(2); + __ctors_start = . ; + KEEP(*(.ctors)) + __ctors_end = . ; + __dtors_start = . ; + KEEP(*(.dtors)) + __dtors_end = . ; + . = ALIGN(2); + *(.text .text.* .gnu.linkonce.t.*) + . = ALIGN(2); + } > REGION_TEXT + .rodata : + { + . = ALIGN(2); + *(.rodata .rodata.* .gnu.linkonce.r.*) + . = ALIGN(2); + } > REGION_TEXT + _etext = .; /* Past last read-only (loadable) segment */ + .data : + { + . = ALIGN(2); + PROVIDE (__data_start = .) ; + *(.data .data.* .gnu.linkonce.d.*) + . = ALIGN(2); + _edata = . ; /* Past last read-write (loadable) segment */ + } > REGION_DATA AT > REGION_TEXT + PROVIDE (__data_load_start = LOADADDR(.data) ); + PROVIDE (__data_size = SIZEOF(.data) ); + .bss : + { + PROVIDE (__bss_start = .) ; + *(.bss .bss.*) + *(COMMON) + . = ALIGN(2); + PROVIDE (__bss_end = .) ; + } > REGION_DATA + PROVIDE (__bss_size = SIZEOF(.bss) ); + .noinit : + { + PROVIDE (__noinit_start = .) ; + *(.noinit .noinit.*) + . = ALIGN(2); + PROVIDE (__noinit_end = .) ; + } > REGION_DATA + . = ALIGN(2); + _end = . ; /* Past last write (loadable) segment */ + .infomem : + { + *(.infomem) + . = ALIGN(2); + *(.infomem.*) + } > infomem + .infomemnobits : + { + *(.infomemnobits) + . = ALIGN(2); + *(.infomemnobits.*) + } > infomem + .infoa : + { + *(.infoa .infoa.*) + } > infoa + .infob : + { + *(.infob .infob.*) + } > infob + .infoc : + { + *(.infoc .infoc.*) + } > infoc + .infod : + { + *(.infod .infod.*) + } > infod + .vectors : + { + PROVIDE (__vectors_start = .) ; + KEEP(*(.vectors*)) + _vectors_end = . ; + } > vectors + .fartext : + { + . = ALIGN(2); + *(.fartext) + . = ALIGN(2); + *(.fartext.*) + _efartext = .; + } > REGION_FAR_ROM + /* Stabs for profiling information*/ + .profiler 0 : { *(.profiler) } + /* Stabs debugging sections. */ + .stab 0 : { *(.stab) } + .stabstr 0 : { *(.stabstr) } + .stab.excl 0 : { *(.stab.excl) } + .stab.exclstr 0 : { *(.stab.exclstr) } + .stab.index 0 : { *(.stab.index) } + .stab.indexstr 0 : { *(.stab.indexstr) } + .comment 0 : { *(.comment) } + /* DWARF debug sections. + Symbols in the DWARF debugging sections are relative to the beginning + of the section so we begin them at 0. */ + /* DWARF 1 */ + .debug 0 : { *(.debug) } + .line 0 : { *(.line) } + /* GNU DWARF 1 extensions */ + .debug_srcinfo 0 : { *(.debug_srcinfo) } + .debug_sfnames 0 : { *(.debug_sfnames) } + /* DWARF 1.1 and DWARF 2 */ + .debug_aranges 0 : { *(.debug_aranges) } + .debug_pubnames 0 : { *(.debug_pubnames) } + /* DWARF 2 */ + .debug_info 0 : { *(.debug_info) *(.gnu.linkonce.wi.*) } + .debug_abbrev 0 : { *(.debug_abbrev) } + .debug_line 0 : { *(.debug_line) } + .debug_frame 0 : { *(.debug_frame) } + .debug_str 0 : { *(.debug_str) } + .debug_loc 0 : { *(.debug_loc) } + .debug_macinfo 0 : { *(.debug_macinfo) } + /* DWARF 3 */ + .debug_pubtypes 0 : { *(.debug_pubtypes) } + .debug_ranges 0 : { *(.debug_ranges) } + PROVIDE (__stack = ORIGIN(ram) + LENGTH(ram)); + PROVIDE (__data_start_rom = _etext); + PROVIDE (__data_end_rom = _etext + SIZEOF (.data)); +}
rtl_sim/src-c/dhrystone_v2.1/linker.x Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/omsp_func.c =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/omsp_func.c (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/omsp_func.c (revision 145) @@ -0,0 +1,51 @@ +/*===========================================================================*/ +/* Copyright (C) 2001 Authors */ +/* */ +/* This source file may be used and distributed without restriction provided */ +/* that this copyright statement is not removed from the file and that any */ +/* derivative work contains the original copyright notice and the associated */ +/* disclaimer. */ +/* */ +/* This source file is free software; you can redistribute it and/or modify */ +/* it under the terms of the GNU Lesser General Public License as published */ +/* by the Free Software Foundation; either version 2.1 of the License, or */ +/* (at your option) any later version. */ +/* */ +/* This source is distributed in the hope that it will be useful, but WITHOUT*/ +/* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */ +/* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */ +/* License for more details. */ +/* */ +/* You should have received a copy of the GNU Lesser General Public License */ +/* along with this source; if not, write to the Free Software Foundation, */ +/* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ +/* */ +/*===========================================================================*/ +/* OMSP_FUNC C FILE */ +/*---------------------------------------------------------------------------*/ +/* */ +/* Author(s): */ +/* - Olivier Girard, olgirard@gmail.com */ +/* */ +/*---------------------------------------------------------------------------*/ +/* $Rev: 19 $ */ +/* $LastChangedBy: olivier.girard $ */ +/* $LastChangedDate: 2009-08-04 23:47:15 +0200 (Tue, 04 Aug 2009) $ */ +/*===========================================================================*/ + +#include "omsp_func.h" + +//--------------------------------------------------// +// putChar function // +// (Send a byte to the Port-1) // +//--------------------------------------------------// +int putchar (int txdata) { + + // Write the output character to the Port-1 + P1OUT = txdata; + + // Toggle Port-2[0] to signal new byte + P2OUT ^= 0x01; + + return 0; +}
rtl_sim/src-c/dhrystone_v2.1/omsp_func.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/dhry.h =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/dhry.h (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/dhry.h (revision 145) @@ -0,0 +1,433 @@ +/* + **************************************************************************** + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: C, Version 2.1 + * + * File: dhry.h (part 1 of 3) + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * Siemens AG, E STE 35 + * Postfach 3240 + * 8520 Erlangen + * Germany (West) + * Phone: [xxx-49]-9131-7-20330 + * (8-17 Central European Time) + * Usenet: ..!mcvax!unido!estevax!weicker + * + * Original Version (in Ada) published in + * "Communications of the ACM" vol. 27., no. 10 (Oct. 1984), + * pp. 1013 - 1030, together with the statistics + * on which the distribution of statements etc. is based. + * + * In this C version, the following C library functions are used: + * - strcpy, strcmp (inside the measurement loop) + * - printf, scanf (outside the measurement loop) + * In addition, Berkeley UNIX system calls "times ()" or "time ()" + * are used for execution time measurement. For measurements + * on other systems, these calls have to be changed. + * + * Collection of Results: + * Reinhold Weicker (address see above) and + * + * Rick Richardson + * PC Research. Inc. + * 94 Apple Orchard Drive + * Tinton Falls, NJ 07724 + * Phone: (201) 389-8963 (9-17 EST) + * Usenet: ...!uunet!pcrat!rick + * + * Please send results to Rick Richardson and/or Reinhold Weicker. + * Complete information should be given on hardware and software used. + * Hardware information includes: Machine type, CPU, type and size + * of caches; for microprocessors: clock frequency, memory speed + * (number of wait states). + * Software information includes: Compiler (and runtime library) + * manufacturer and version, compilation switches, OS version. + * The Operating System version may give an indication about the + * compiler; Dhrystone itself performs no OS calls in the measurement loop. + * + * The complete output generated by the program should be mailed + * such that at least some checks for correctness can be made. + * + *************************************************************************** + * + * History: This version C/2.1 has been made for two reasons: + * + * 1) There is an obvious need for a common C version of + * Dhrystone, since C is at present the most popular system + * programming language for the class of processors + * (microcomputers, minicomputers) where Dhrystone is used most. + * There should be, as far as possible, only one C version of + * Dhrystone such that results can be compared without + * restrictions. In the past, the C versions distributed + * by Rick Richardson (Version 1.1) and by Reinhold Weicker + * had small (though not significant) differences. + * + * 2) As far as it is possible without changes to the Dhrystone + * statistics, optimizing compilers should be prevented from + * removing significant statements. + * + * This C version has been developed in cooperation with + * Rick Richardson (Tinton Falls, NJ), it incorporates many + * ideas from the "Version 1.1" distributed previously by + * him over the UNIX network Usenet. + * I also thank Chaim Benedelac (National Semiconductor), + * David Ditzel (SUN), Earl Killian and John Mashey (MIPS), + * Alan Smith and Rafael Saavedra-Barrera (UC at Berkeley) + * for their help with comments on earlier versions of the + * benchmark. + * + * Changes: In the initialization part, this version follows mostly + * Rick Richardson's version distributed via Usenet, not the + * version distributed earlier via floppy disk by Reinhold Weicker. + * As a concession to older compilers, names have been made + * unique within the first 8 characters. + * Inside the measurement loop, this version follows the + * version previously distributed by Reinhold Weicker. + * + * At several places in the benchmark, code has been added, + * but within the measurement loop only in branches that + * are not executed. The intention is that optimizing compilers + * should be prevented from moving code out of the measurement + * loop, or from removing code altogether. Since the statements + * that are executed within the measurement loop have NOT been + * changed, the numbers defining the "Dhrystone distribution" + * (distribution of statements, operand types and locality) + * still hold. Except for sophisticated optimizing compilers, + * execution times for this version should be the same as + * for previous versions. + * + * Since it has proven difficult to subtract the time for the + * measurement loop overhead in a correct way, the loop check + * has been made a part of the benchmark. This does have + * an impact - though a very minor one - on the distribution + * statistics which have been updated for this version. + * + * All changes within the measurement loop are described + * and discussed in the companion paper "Rationale for + * Dhrystone version 2". + * + * Because of the self-imposed limitation that the order and + * distribution of the executed statements should not be + * changed, there are still cases where optimizing compilers + * may not generate code for some statements. To a certain + * degree, this is unavoidable for small synthetic benchmarks. + * Users of the benchmark are advised to check code listings + * whether code is generated for all statements of Dhrystone. + * + * Version 2.1 is identical to version 2.0 distributed via + * the UNIX network Usenet in March 1988 except that it corrects + * some minor deficiencies that were found by users of version 2.0. + * The only change within the measurement loop is that a + * non-executed "else" part was added to the "if" statement in + * Func_3, and a non-executed "else" part removed from Proc_3. + * + *************************************************************************** + * + * Defines: The following "Defines" are possible: + * -DREG=register (default: Not defined) + * As an approximation to what an average C programmer + * might do, the "register" storage class is applied + * (if enabled by -DREG=register) + * - for local variables, if they are used (dynamically) + * five or more times + * - for parameters if they are used (dynamically) + * six or more times + * Note that an optimal "register" strategy is + * compiler-dependent, and that "register" declarations + * do not necessarily lead to faster execution. + * -DNOSTRUCTASSIGN (default: Not defined) + * Define if the C compiler does not support + * assignment of structures. + * -DNOENUMS (default: Not defined) + * Define if the C compiler does not support + * enumeration types. + * -DTIMES (default) + * -DTIME + * The "times" function of UNIX (returning process times) + * or the "time" function (returning wallclock time) + * is used for measurement. + * For single user machines, "time ()" is adequate. For + * multi-user machines where you cannot get single-user + * access, use the "times ()" function. If you have + * neither, use a stopwatch in the dead of night. + * "printf"s are provided marking the points "Start Timer" + * and "Stop Timer". DO NOT use the UNIX "time(1)" + * command, as this will measure the total time to + * run this program, which will (erroneously) include + * the time to allocate storage (malloc) and to perform + * the initialization. + * -DHZ=nnn + * In Berkeley UNIX, the function "times" returns process + * time in 1/HZ seconds, with HZ = 60 for most systems. + * CHECK YOUR SYSTEM DESCRIPTION BEFORE YOU JUST APPLY + * A VALUE. + * + *************************************************************************** + * + * Compilation model and measurement (IMPORTANT): + * + * This C version of Dhrystone consists of three files: + * - dhry.h (this file, containing global definitions and comments) + * - dhry_1.c (containing the code corresponding to Ada package Pack_1) + * - dhry_2.c (containing the code corresponding to Ada package Pack_2) + * + * The following "ground rules" apply for measurements: + * - Separate compilation + * - No procedure merging + * - Otherwise, compiler optimizations are allowed but should be indicated + * - Default results are those without register declarations + * See the companion paper "Rationale for Dhrystone Version 2" for a more + * detailed discussion of these ground rules. + * + * For 16-Bit processors (e.g. 80186, 80286), times for all compilation + * models ("small", "medium", "large" etc.) should be given if possible, + * together with a definition of these models for the compiler system used. + * + ************************************************************************** + * + * Dhrystone (C version) statistics: + * + * [Comment from the first distribution, updated for version 2. + * Note that because of language differences, the numbers are slightly + * different from the Ada version.] + * + * The following program contains statements of a high level programming + * language (here: C) in a distribution considered representative: + * + * assignments 52 (51.0 %) + * control statements 33 (32.4 %) + * procedure, function calls 17 (16.7 %) + * + * 103 statements are dynamically executed. The program is balanced with + * respect to the three aspects: + * + * - statement type + * - operand type + * - operand locality + * operand global, local, parameter, or constant. + * + * The combination of these three aspects is balanced only approximately. + * + * 1. Statement Type: + * ----------------- number + * + * V1 = V2 9 + * (incl. V1 = F(..) + * V = Constant 12 + * Assignment, 7 + * with array element + * Assignment, 6 + * with record component + * -- + * 34 34 + * + * X = Y +|-|"&&"|"|" Z 5 + * X = Y +|-|"==" Constant 6 + * X = X +|- 1 3 + * X = Y *|/ Z 2 + * X = Expression, 1 + * two operators + * X = Expression, 1 + * three operators + * -- + * 18 18 + * + * if .... 14 + * with "else" 7 + * without "else" 7 + * executed 3 + * not executed 4 + * for ... 7 | counted every time + * while ... 4 | the loop condition + * do ... while 1 | is evaluated + * switch ... 1 + * break 1 + * declaration with 1 + * initialization + * -- + * 34 34 + * + * P (...) procedure call 11 + * user procedure 10 + * library procedure 1 + * X = F (...) + * function call 6 + * user function 5 + * library function 1 + * -- + * 17 17 + * --- + * 103 + * + * The average number of parameters in procedure or function calls + * is 1.82 (not counting the function values aX * + * + * 2. Operators + * ------------ + * number approximate + * percentage + * + * Arithmetic 32 50.8 + * + * + 21 33.3 + * - 7 11.1 + * * 3 4.8 + * / (int div) 1 1.6 + * + * Comparison 27 42.8 + * + * == 9 14.3 + * /= 4 6.3 + * > 1 1.6 + * < 3 4.8 + * >= 1 1.6 + * <= 9 14.3 + * + * Logic 4 6.3 + * + * && (AND-THEN) 1 1.6 + * | (OR) 1 1.6 + * ! (NOT) 2 3.2 + * + * -- ----- + * 63 100.1 + * + * + * 3. Operand Type (counted once per operand reference): + * --------------- + * number approximate + * percentage + * + * Integer 175 72.3 % + * Character 45 18.6 % + * Pointer 12 5.0 % + * String30 6 2.5 % + * Array 2 0.8 % + * Record 2 0.8 % + * --- ------- + * 242 100.0 % + * + * When there is an access path leading to the final operand (e.g. a record + * component), only the final data type on the access path is counted. + * + * + * 4. Operand Locality: + * ------------------- + * number approximate + * percentage + * + * local variable 114 47.1 % + * global variable 22 9.1 % + * parameter 45 18.6 % + * value 23 9.5 % + * reference 22 9.1 % + * function result 6 2.5 % + * constant 55 22.7 % + * --- ------- + * 242 100.0 % + * + * + * The program does not compute anything meaningful, but it is syntactically + * and semantically correct. All variables have a value assigned to them + * before they are used as a source operand. + * + * There has been no explicit effort to account for the effects of a + * cache, or to balance the use of long or short displacements for code or + * data. + * + *************************************************************************** + */ + +/* Compiler and system dependent definitions: */ + +/* Commented out because we do not have an OS function call to get the time */ +/* +#ifndef TIME +#undef TIMES +#define TIMES +#endif +*/ + /* Use times(2) time function unless */ + /* explicitly defined otherwise */ + +#ifdef MSC_CLOCK +#undef HZ +#undef TIMES +#include +#define HZ CLK_TCK +#endif + /* Use Microsoft C hi-res clock */ + +#ifdef TIMES +#include +#include + /* for "times" */ +#endif + +#define Mic_secs_Per_Second 1000000.0 + /* Berkeley UNIX C returns process times in seconds/HZ */ + +#ifdef NOSTRUCTASSIGN +#define structassign(d, s) memcpy(&(d), &(s), sizeof(d)) +#else +#define structassign(d, s) d = s +#endif + +#ifdef NOENUM +#define Ident_1 0 +#define Ident_2 1 +#define Ident_3 2 +#define Ident_4 3 +#define Ident_5 4 + typedef int Enumeration; +#else + typedef enum {Ident_1, Ident_2, Ident_3, Ident_4, Ident_5} + Enumeration; +#endif + /* for boolean and enumeration types in Ada, Pascal */ + +/* General definitions: */ + +#include + /* for strcpy, strcmp */ + +#define Null 0 + /* Value of a Null pointer */ +#define true 1 +#define false 0 + +typedef int One_Thirty; +typedef int One_Fifty; +typedef char Capital_Letter; +typedef int Boolean; +typedef char Str_30 [31]; +typedef int Arr_1_Dim [50]; +typedef int Arr_2_Dim [50] [50]; + +typedef struct record + { + struct record *Ptr_Comp; + Enumeration Discr; + union { + struct { + Enumeration Enum_Comp; + int Int_Comp; + char Str_Comp [31]; + } var_1; + struct { + Enumeration E_Comp_2; + char Str_2_Comp [31]; + } var_2; + struct { + char Ch_1_Comp; + char Ch_2_Comp; + } var_3; + } variant; + } Rec_Type, *Rec_Pointer; +
rtl_sim/src-c/dhrystone_v2.1/dhry.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_v2.1/makefile =================================================================== --- rtl_sim/src-c/dhrystone_v2.1/makefile (nonexistent) +++ rtl_sim/src-c/dhrystone_v2.1/makefile (revision 145) @@ -0,0 +1,61 @@ +# makfile configuration +NAME = dhrystone_v2.1 +OBJECTS = dhry_1.o dhry_2.o omsp_func.o + +# disable some warnings specific to the Dhrystone code +WARNINGS = -Wall -Wno-implicit-int -Wno-implicit-function-declaration -Wno-return-type + +#CFLAGS = -O2 ${WARNINGS} -g # Old flags +#CFLAGS = -O1 ${WARNINGS} -g -mcpu=430 -mivcnt=16 -mmpy=16 # Uniarch flags # DMIPS=0.377632 +#CFLAGS = -Os ${WARNINGS} -g -mcpu=430 -mivcnt=16 -mmpy=16 # Uniarch flags # DMIPS=0.373193 +#CFLAGS = -O2 ${WARNINGS} -g -mcpu=430 -mivcnt=16 -mmpy=16 # Uniarch flags # DMIPS=0.396044 +CFLAGS = -O3 ${WARNINGS} -g -mcpu=430 -mivcnt=16 -mmpy=16 # Uniarch flags # DMIPS=0.400228 + +#switch the compiler (for the internal make rules) +CC = msp430-gcc + + +.PHONY: all FORCE clean download download-jtag download-bsl dist + +#all should be the first target. it's built when make is runwithout args +all: ${NAME}.elf ${NAME}.a43 ${NAME}.lst + +#confgigure the next line if you want to use the serial download +download: download-uart +#download: download-jtag +#download: download-bsl + +#additional rules for files +${NAME}.elf: ${OBJECTS} + ${CC} -T linker.x -o $@ ${OBJECTS} + +${NAME}.a43: ${NAME}.elf + msp430-objcopy -O ihex $^ $@ + +${NAME}.lst: ${NAME}.elf + msp430-objdump -dSt $^ >$@ + +download-jtag: all + msp430-jtag -e ${NAME}.elf + +download-bsl: all + msp430-bsl -e ${NAME}.elf + +download-uart: all + openmsp430-loader.tcl -device /dev/ttyUSB0 -baudrate 115200 ${NAME}.elf + +clean: + rm -f ${NAME} ${NAME}.a43 ${NAME}.lst ${NAME}.elf *.o + +#backup archive +dist: + tar czf dist.tgz *.c *.h *.txt makefile + +#dummy target as dependecy if something has to be build everytime +FORCE: + +#project dependencies +dhry_1.o: dhry_1.c +dhry_2.o: dhry_2.c +omsp_func.o: omsp_func.c +
rtl_sim/src-c/dhrystone_v2.1/makefile Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/LICENSE.txt =================================================================== --- rtl_sim/src-c/coremark_v1.0/LICENSE.txt (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/LICENSE.txt (revision 145) @@ -0,0 +1,179 @@ +PLEASE READ THIS EEMBC COREMARK SOFTWARE LICENSE AGREEMENT +("LICENSE") BEFORE USING THE EEMBC COREMARK SOFTWARE. BY +USING THE EEMBC COREMARK SOFTWARE, YOU ARE AGREEING TO BE +BOUND BY THE TERMS OF THIS LICENSE. IF YOU DO NOT AGREE TO THE +TERMS OF THIS LICENSE, DO NOT DOWNLOAD OR USE THE EEMBC +COREMARK SOFTWARE. + +1. General. The software and documentation accompanying this License whether on +disk, in read only memory, on any other media or in any other form (collectively the +"Software") are licensed, not sold, to you by Embedded Microprocessor Benchmark +Consortium ("EEMBC") for use only under the terms of this License, and EEMBC +reserves all rights not expressly granted to you. The rights granted herein are limited to +EEMBC's members and its licensors' intellectual property rights in the EEMBC +COREMARK Software and do not include any other patents or intellectual property +rights. The terms of this License will govern any software upgrades provided by EEMBC +that replace and/or supplement the original EEMBC COREMARK SOFTWARE +product, unless such upgrade is accompanied by a separate license in which case the terms +of that license will govern. + +2. Permitted License Uses and Restrictions. This License allows you to download, install, +and use the EEMBC COREMARK Software only as expressly permitted under this +License. For the avoidance of doubt you may make only that number of copies of the +EEMBC COREMARK Software as are reasonably necessary in order to effectuate the +purposes for which the EEMBC COREMARK Software is intended. You may not make +the EEMBC COREMARK Software available over a network where it could be used by +multiple platforms or multiple users at the same time or for use via data hosting, time +sharing or service bureau usage. Except as and only to the extent expressly permitted in +this License or by applicable law, you may not copy or create derivative works of the +EEMBC COREMARK Software or any part thereof. The EEMBC COREMARK +SOFTWARE is not intended for any inherently dangerous use, including without +limitation for use in the operation of nuclear facilities, aircraft navigation or +communication systems, air traffic control systems, life support machines or other +equipment in which the failure of the EEMBC COREMARK SOFTWARE COULD +LEAD TO DEATH, PERSONAL INJURY, OR SEVERE PHYSICAL OR +ENVIRONMENTAL DAMAGE. + +3. Transfer. You may not rent, lease, lend, license, sublicense or otherwise transfer any +rights to use or possess the EEMBC COREMARK Software. + +4. Enhancements by EEMBC. In the event that at any time EEMBC makes any +enhancement, update, or modification to the EEMBC COREMARK Software or +becomes the owner of any new enhancement, update, or modification to the EEMBC +COREMARK Software, then upon notice to you, EEMBC may in its absolute discretion, +require that you migrate to any such enhancement, update, or modification which shall +automatically and without further action by either EEMBC or you become incorporated +into this Agreement without further consideration, and you shall have the same right and +license to use and exploit the same as it is granted hereunder with respect to the original +EEMBC COREMARK Software. You agree that all rights in and to enhancements, +updates, and modifications effected by EEMBC, if any, to the EEMBC COREMARK +Software, shall remain the sole and exclusive property of EEMBC. Nothing contained +herein shall obligate EEMBC to create any new enhancement, update or modifications to +the EEMBC COREMARK Software, to make such enhancement, update or +modifications available free of charge or to provide any maintenance and technical +support services. + +5. Enhancements by Licensee. The Licensee shall have the right, in its discretion, to +independently modify, improve, or enhance the EEMBC COREMARK Software. The +parties agree that all rights in and to the modifications, improvements, and enhancements +solely made by Licensee, if any, to the EEMBC COREMARK Software, shall remain the +sole and exclusive property of Licensee, subject to EEMBC’s ownership of the EEMBC +COREMARK Software which underlies the Licensee’s modifications, improvements, +and enhancements. + +6. Use of Trademark. You agree that you will not, without the prior written consent of +EEMBC, use in advertising, publicity, packaging, labeling, or otherwise any trade name, +trademark, service mark, symbol, or any other identification owned by EEMBC to +identify any of its products or services. + +7. Delivery. The EEMBC COREMARK Software will only be available by +downloading from EEMBC’s website, specifically at www.coremark.org, in accordance +with the current policies and procedures of EEMBC. EEMBC reserves the right to +modify such procedures in its sole and absolute discretion. + +8. Term and Termination. + a. Term. The term of this Agreement shall continue so long as you are not in +Default as set forth in Section 8(b). + + b. Termination. This Agreement and the License granted herein will +automatically terminate if you commit an act of or are subject to any Default. A Default +means you breach a term or condition of this Agreement, including, but not limited to you +assigning or purporting to assign any of the rights granted herein without the prior written +approval of EEMBC. Upon the occurrence of a Default, this Agreement shall +immediately terminate. EEMBC’s rights as set forth in this Section 8(b) are cumulative +and, except as provided herein, are in addition to any other rights EEMBC may have at +law or in equity. + + c. Effect of Termination. Upon the expiration or termination of this Agreement, +the rights granted to you hereunder shall immediately cease and discontinue, and you +shall be required to immediately return any and all materials and deliverables provided to +you under this Agreement, including without limitation, the EEMBC COREMARK +Software. The provisions contained in Sections 3, 5, 6, 8, 9, 10, 11, 12, 13, 14, 15, and +16 shall survive any such termination or expiration. + +9. No Warranty. EEMBC provides no warranty for the EEMBC COREMARK +Software. + +10. Disclaimer of Warranties. You expressly acknowledge and agree that use of the +EEMBC COREMARK SOFTWARE is at your sole risk and that the entire risk as to +satisfactory quality, performance, accuracy and effort is with you. The EEMBC +COREMARK SOFTWARE is provided "as is", with all faults and without warranty of +any kind, and EEMBC and EEMBC'S licensors (collectively referred to as "EEMBC" for +the purposes of sections 10 and 11) hereby disclaim all warranties and conditions with +respect to the EEMBC COREMARK SOFTWARE, either express, implied or statutory, +including, but not limited to, the implied warranties and/or conditions of merchantability, +of satisfactory quality, of fitness for a particular purpose, of accuracy, of quiet enjoyment, +and non-infringement of third party rights. EEMBC does not warrant against +interference with your enjoyment of the EEMBC COREMARK SOFTWARE, that the +functions contained in the EEMBC COREMARK SOFTWARE will meet your +requirements, that the operation of the EEMBC COREMARK SOFTWARE will be +uninterrupted or error-free, or that defects in the EEMBC COREMARK SOFTWARE +will be corrected. no oral or written information or advice given by EEMBC or an +EEMBC authorized representative shall create a warranty. Should the EEMBC +COREMARK SOFTWARE prove defective, you assume the entire cost of all necessary +servicing, repair or correction. Some jurisdictions do not allow the exclusion of implied +warranties or limitations on applicable statutory rights of a consumer, so the above +exclusion and limitations may not apply to you. to the extent not prohibited by law, in no +event shall EEMBC be liable for personal injury, or any incidental, special, indirect or +consequential damages whatsoever, including, without limitation, damages for loss of +profits, loss of data, business interruption or any other commercial damages or losses, +arising out of or related to your use or inability to use the EEMBC COREMARK +SOFTWARE, however caused, regardless of the theory of liability (contract, tort or +otherwise) and even if EEMBC has been advised of the possibility of such damages. +some jurisdictions do not allow the limitation of liability for personal injury, or of +incidental or consequential damages, so this limitation may not apply to you. In no event +shall EEMBC's total liability to you for all damages (other than as may be required by +applicable law in cases involving personal injury) exceed the amount of fifty dollars +($50.00). The foregoing limitations will apply even if the above stated remedy fails of its +essential purpose. + +11. POTENTIAL MISUSE OF EEMBC COREMARK SOFTWARE. you hereby +acknowledge and represent that you have been expressly warned by EEMBC that the +EEMBC COREMARK SOFTWARE may be incompatible with those microprocessors, +microcontrollers, or digital signal processors that are part of an application or end-user +product, and that such misuse of the EEMBC COREMARK SOFTWARE could result in +significant property damage and/or bodily harm. + + +12. Publication of Results. You expressly agree that this license permits you to +publicize any benchmark scores obtained using or with respect to the EEMBC +COREMARK SOFTWARE, whether for the related microprocessor, microcontroller, or +DSP platforms ONLY if you comply with the run and reporting rules as indicated in the +readme-txt file included in the EEMBC COREMARK SOFTWARE release package +available at www.coremark.org. + +13. Export Law Assurances. You may not use or otherwise export or reexport the +EEMBC COREMARK SOFTWARE except as authorized by United States law and the +laws of the jurisdiction in which the EEMBC COREMARK Software was obtained. In +particular, but without limitation, the EEMBC COREMARK SOFTWARE may not be +exported or re-exported (a) into (or to a national or resident of) any U.S. embargoed +countries (currently Cuba, Iran, Iraq, Libya, North Korea, Sudan and Syria), or (b) to +anyone on the U.S. Treasury Department's list of Specially Designated Nationals or the +U.S. Department of Commerce Denied Person's List or Entity List. By using the +EEMBC COREMARK SOFTWARE, you represent and warrant that you are not located +in, under control of, or a national or resident of any such country or on any such list. + +13. Relationship of Parties. Neither this Agreement, nor any terms and conditions +contained herein, may be construed as creating or constituting a partnership, joint venture, +or agency relationship between the parties. Neither party will have the power to bind the +other or incur obligations on the other party's behalf without the other party's prior written +consent. + +14. Waiver. No failure of either party to exercise or enforce any of its rights under this +Agreement will act as a waiver of such rights. + +15. Controlling Law and Severability. This License will be governed by and construed in +accordance with the laws of the State of California, as applied to agreements entered into +and to be performed entirely within California between California residents. This License +shall not be governed by the United Nations Convention on Contracts for the +International Sale of Goods, the application of which is expressly excluded. If for any +reason a court of competent jurisdiction finds any provision, or portion thereof, to be +unenforceable, the remainder of this License shall continue in full force and effect. + +16. Complete Agreement; Governing Language. This License constitutes the entire +agreement between the parties with respect to the use of the EEMBC COREMARK +Software licensed hereunder and supersedes all prior or contemporaneous understandings +regarding such subject matter. No amendment to or modification of this License will be +binding unless in writing and signed by EEMBC. Any translation of this License is done +for local requirements and in the event of a dispute between the English and any non- +English versions, the English version of this License shall govern.
rtl_sim/src-c/coremark_v1.0/LICENSE.txt Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/core_list_join.c =================================================================== --- rtl_sim/src-c/coremark_v1.0/core_list_join.c (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/core_list_join.c (revision 145) @@ -0,0 +1,496 @@ +/* +Author : Shay Gal-On, EEMBC + +This file is part of EEMBC(R) and CoreMark(TM), which are Copyright (C) 2009 +All rights reserved. + +EEMBC CoreMark Software is a product of EEMBC and is provided under the terms of the +CoreMark License that is distributed with the official EEMBC COREMARK Software release. +If you received this EEMBC CoreMark Software without the accompanying CoreMark License, +you must discontinue use and download the official release from www.coremark.org. + +Also, if you are publicly displaying scores generated from the EEMBC CoreMark software, +make sure that you are in compliance with Run and Reporting rules specified in the accompanying readme.txt file. + +EEMBC +4354 Town Center Blvd. Suite 114-200 +El Dorado Hills, CA, 95762 +*/ + +#include "coremark.h" +/* +Topic: Description + Benchmark using a linked list. + + Linked list is a common data structure used in many applications. + + For our purposes, this will excercise the memory units of the processor. + In particular, usage of the list pointers to find and alter data. + + We are not using Malloc since some platforms do not support this library. + + Instead, the memory block being passed in is used to create a list, + and the benchmark takes care not to add more items then can be + accomodated by the memory block. The porting layer will make sure + that we have a valid memory block. + + All operations are done in place, without using any extra memory. + + The list itself contains list pointers and pointers to data items. + Data items contain the following: + + idx - An index that captures the initial order of the list. + data - Variable data initialized based on the input parameters. The 16b are divided as follows: + o Upper 8b are backup of original data. + o Bit 7 indicates if the lower 7 bits are to be used as is or calculated. + o Bits 0-2 indicate type of operation to perform to get a 7b value. + o Bits 3-6 provide input for the operation. + +*/ + +/* local functions */ + +list_head *core_list_find(list_head *list,list_data *info); +list_head *core_list_reverse(list_head *list); +list_head *core_list_remove(list_head *item); +list_head *core_list_undo_remove(list_head *item_removed, list_head *item_modified); +list_head *core_list_insert_new(list_head *insert_point + , list_data *info, list_head **memblock, list_data **datablock + , list_head *memblock_end, list_data *datablock_end); +typedef ee_s32(*list_cmp)(list_data *a, list_data *b, core_results *res); +list_head *core_list_mergesort(list_head *list, list_cmp cmp, core_results *res); + +ee_s16 calc_func(ee_s16 *pdata, core_results *res) { + ee_s16 data=*pdata; + ee_s16 retval; + ee_u8 optype=(data>>7) & 1; /* bit 7 indicates if the function result has been cached */ + if (optype) /* if cached, use cache */ + return (data & 0x007f); + else { /* otherwise calculate and cache the result */ + ee_s16 flag=data & 0x7; /* bits 0-2 is type of function to perform */ + ee_s16 dtype=((data>>3) & 0xf); /* bits 3-6 is specific data for the operation */ + dtype |= dtype << 4; /* replicate the lower 4 bits to get an 8b value */ + switch (flag) { + case 0: + if (dtype<0x22) /* set min period for bit corruption */ + dtype=0x22; + retval=core_bench_state(res->size,res->memblock[3],res->seed1,res->seed2,dtype,res->crc); + if (res->crcstate==0) + res->crcstate=retval; + break; + case 1: + retval=core_bench_matrix(&(res->mat),dtype,res->crc); + if (res->crcmatrix==0) + res->crcmatrix=retval; + break; + default: + retval=data; + break; + } + res->crc=crcu16(retval,res->crc); + retval &= 0x007f; + *pdata = (data & 0xff00) | 0x0080 | retval; /* cache the result */ + return retval; + } +} +/* Function: cmp_complex + Compare the data item in a list cell. + + Can be used by mergesort. +*/ +ee_s32 cmp_complex(list_data *a, list_data *b, core_results *res) { + ee_s16 val1=calc_func(&(a->data16),res); + ee_s16 val2=calc_func(&(b->data16),res); + return val1 - val2; +} + +/* Function: cmp_idx + Compare the idx item in a list cell, and regen the data. + + Can be used by mergesort. +*/ +ee_s32 cmp_idx(list_data *a, list_data *b, core_results *res) { + if (res==NULL) { + a->data16 = (a->data16 & 0xff00) | (0x00ff & (a->data16>>8)); + b->data16 = (b->data16 & 0xff00) | (0x00ff & (b->data16>>8)); + } + return a->idx - b->idx; +} + +void copy_info(list_data *to,list_data *from) { + to->data16=from->data16; + to->idx=from->idx; +} + +/* Benchmark for linked list: + - Try to find multiple data items. + - List sort + - Operate on data from list (crc) + - Single remove/reinsert + * At the end of this function, the list is back to original state +*/ +ee_u16 core_bench_list(core_results *res, ee_s16 finder_idx) { + ee_u16 retval=0; + ee_u16 found=0,missed=0; + list_head *list=res->list; + ee_s16 find_num=res->seed3; + list_head *this_find; + list_head *finder, *remover; + list_data info; + ee_s16 i; + + info.idx=finder_idx; + /* find values in the list, and change the list each time (reverse and cache if value found) */ + for (i=0; inext->info->data16 >> 8) & 1; + } + else { + found++; + if (this_find->info->data16 & 0x1) /* use found value */ + retval+=(this_find->info->data16 >> 9) & 1; + /* and cache next item at the head of the list (if any) */ + if (this_find->next != NULL) { + finder = this_find->next; + this_find->next = finder->next; + finder->next=list->next; + list->next=finder; + } + } + if (info.idx>=0) + info.idx++; +#if CORE_DEBUG + ee_printf("List find %d: [%d,%d,%d]\n",i,retval,missed,found); +#endif + } + retval+=found*4-missed; + /* sort the list by data content and remove one item*/ + if (finder_idx>0) + list=core_list_mergesort(list,cmp_complex,res); + remover=core_list_remove(list->next); + /* CRC data content of list from location of index N forward, and then undo remove */ + finder=core_list_find(list,&info); + if (!finder) + finder=list->next; + while (finder) { + retval=crc16(list->info->data16,retval); + finder=finder->next; + } +#if CORE_DEBUG + ee_printf("List sort 1: %04x\n",retval); +#endif + remover=core_list_undo_remove(remover,list->next); + /* sort the list by index, in effect returning the list to original state */ + list=core_list_mergesort(list,cmp_idx,NULL); + /* CRC data content of list */ + finder=list->next; + while (finder) { + retval=crc16(list->info->data16,retval); + finder=finder->next; + } +#if CORE_DEBUG + ee_printf("List sort 2: %04x\n",retval); +#endif + return retval; +} +/* Function: core_list_init + Initialize list with data. + + Parameters: + blksize - Size of memory to be initialized. + memblock - Pointer to memory block. + seed - Actual values chosen depend on the seed parameter. + The seed parameter MUST be supplied from a source that cannot be determined at compile time + + Returns: + Pointer to the head of the list. + +*/ +list_head *core_list_init(ee_u32 blksize, list_head *memblock, ee_s16 seed) { + /* calculated pointers for the list */ + ee_u32 per_item=16+sizeof(struct list_data_s); + ee_u32 size=(blksize/per_item)-2; /* to accomodate systems with 64b pointers, and make sure same code is executed, set max list elements */ + list_head *memblock_end=memblock+size; + list_data *datablock=(list_data *)(memblock_end); + list_data *datablock_end=datablock+size; + /* some useful variables */ + ee_u32 i; + list_head *finder,*list=memblock; + list_data info; + + /* create a fake items for the list head and tail */ + list->next=NULL; + list->info=datablock; + list->info->idx=0x0000; + list->info->data16=(ee_s16)0x8080; + memblock++; + datablock++; + info.idx=0x7fff; + info.data16=(ee_s16)0xffff; + core_list_insert_new(list,&info,&memblock,&datablock,memblock_end,datablock_end); + + /* then insert size items */ + for (i=0; inext; + i=1; + while (finder->next!=NULL) { + if (iinfo->idx=i++; + else { + ee_u16 pat=(ee_u16)(i++ ^ seed); /* get a pseudo random number */ + finder->info->idx=0x3fff & (((i & 0x07) << 8) | pat); /* make sure the mixed items end up after the ones in sequence */ + } + finder=finder->next; + } + list = core_list_mergesort(list,cmp_idx,NULL); +#if CORE_DEBUG + ee_printf("Initialized list:\n"); + finder=list; + while (finder) { + ee_printf("[%04x,%04x]",finder->info->idx,(ee_u16)finder->info->data16); + finder=finder->next; + } + ee_printf("\n"); +#endif + return list; +} + +/* Function: core_list_insert + Insert an item to the list + + Parameters: + insert_point - where to insert the item. + info - data for the cell. + memblock - pointer for the list header + datablock - pointer for the list data + memblock_end - end of region for list headers + datablock_end - end of region for list data + + Returns: + Pointer to new item. +*/ +list_head *core_list_insert_new(list_head *insert_point, list_data *info, list_head **memblock, list_data **datablock + , list_head *memblock_end, list_data *datablock_end) { + list_head *newitem; + + if ((*memblock+1) >= memblock_end) + return NULL; + if ((*datablock+1) >= datablock_end) + return NULL; + + newitem=*memblock; + (*memblock)++; + newitem->next=insert_point->next; + insert_point->next=newitem; + + newitem->info=*datablock; + (*datablock)++; + copy_info(newitem->info,info); + + return newitem; +} + +/* Function: core_list_remove + Remove an item from the list. + + Operation: + For a singly linked list, remove by copying the data from the next item + over to the current cell, and unlinking the next item. + + Note: + since there is always a fake item at the end of the list, no need to check for NULL. + + Returns: + Removed item. +*/ +list_head *core_list_remove(list_head *item) { + list_data *tmp; + list_head *ret=item->next; + /* swap data pointers */ + tmp=item->info; + item->info=ret->info; + ret->info=tmp; + /* and eliminate item */ + item->next=item->next->next; + ret->next=NULL; + return ret; +} + +/* Function: core_list_undo_remove + Undo a remove operation. + + Operation: + Since we want each iteration of the benchmark to be exactly the same, + we need to be able to undo a remove. + Link the removed item back into the list, and switch the info items. + + Parameters: + item_removed - Return value from the + item_modified - List item that was modified during + + Returns: + The item that was linked back to the list. + +*/ +list_head *core_list_undo_remove(list_head *item_removed, list_head *item_modified) { + list_data *tmp; + /* swap data pointers */ + tmp=item_removed->info; + item_removed->info=item_modified->info; + item_modified->info=tmp; + /* and insert item */ + item_removed->next=item_modified->next; + item_modified->next=item_removed; + return item_removed; +} + +/* Function: core_list_find + Find an item in the list + + Operation: + Find an item by idx (if not 0) or specific data value + + Parameters: + list - list head + info - idx or data to find + + Returns: + Found item, or NULL if not found. +*/ +list_head *core_list_find(list_head *list,list_data *info) { + if (info->idx>=0) { + while (list && (list->info->idx != info->idx)) + list=list->next; + return list; + } else { + while (list && ((list->info->data16 & 0xff) != info->data16)) + list=list->next; + return list; + } +} +/* Function: core_list_reverse + Reverse a list + + Operation: + Rearrange the pointers so the list is reversed. + + Parameters: + list - list head + info - idx or data to find + + Returns: + Found item, or NULL if not found. +*/ + +list_head *core_list_reverse(list_head *list) { + list_head *next=NULL, *tmp; + while (list) { + tmp=list->next; + list->next=next; + next=list; + list=tmp; + } + return next; +} +/* Function: core_list_mergesort + Sort the list in place without recursion. + + Description: + Use mergesort, as for linked list this is a realistic solution. + Also, since this is aimed at embedded, care was taken to use iterative rather then recursive algorithm. + The sort can either return the list to original order (by idx) , + or use the data item to invoke other other algorithms and change the order of the list. + + Parameters: + list - list to be sorted. + cmp - cmp function to use + + Returns: + New head of the list. + + Note: + We have a special header for the list that will always be first, + but the algorithm could theoretically modify where the list starts. + + */ +list_head *core_list_mergesort(list_head *list, list_cmp cmp, core_results *res) { + list_head *p, *q, *e, *tail; + ee_s32 insize, nmerges, psize, qsize, i; + + insize = 1; + + while (1) { + p = list; + list = NULL; + tail = NULL; + + nmerges = 0; /* count number of merges we do in this pass */ + + while (p) { + nmerges++; /* there exists a merge to be done */ + /* step `insize' places along from p */ + q = p; + psize = 0; + for (i = 0; i < insize; i++) { + psize++; + q = q->next; + if (!q) break; + } + + /* if q hasn't fallen off end, we have two lists to merge */ + qsize = insize; + + /* now we have two lists; merge them */ + while (psize > 0 || (qsize > 0 && q)) { + + /* decide whether next element of merge comes from p or q */ + if (psize == 0) { + /* p is empty; e must come from q. */ + e = q; q = q->next; qsize--; + } else if (qsize == 0 || !q) { + /* q is empty; e must come from p. */ + e = p; p = p->next; psize--; + } else if (cmp(p->info,q->info,res) <= 0) { + /* First element of p is lower (or same); e must come from p. */ + e = p; p = p->next; psize--; + } else { + /* First element of q is lower; e must come from q. */ + e = q; q = q->next; qsize--; + } + + /* add the next element to the merged list */ + if (tail) { + tail->next = e; + } else { + list = e; + } + tail = e; + } + + /* now p has stepped `insize' places along, and q has too */ + p = q; + } + + tail->next = NULL; + + /* If we have done only one merge, we're finished. */ + if (nmerges <= 1) /* allow for nmerges==0, the empty list case */ + return list; + + /* Otherwise repeat, merging lists twice the size */ + insize *= 2; + } +#if COMPILER_REQUIRES_SORT_RETURN + return list; +#endif +}
rtl_sim/src-c/coremark_v1.0/core_list_join.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/msp430/core_portme.c =================================================================== --- rtl_sim/src-c/coremark_v1.0/msp430/core_portme.c (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/msp430/core_portme.c (revision 145) @@ -0,0 +1,148 @@ +/* + File : core_portme.c +*/ +/* + Author : Shay Gal-On, EEMBC + Legal : TODO! +*/ +#include +#include +#include "coremark.h" +#include "omsp_func.h" + +#if VALIDATION_RUN + volatile ee_s32 seed1_volatile=0x3415; + volatile ee_s32 seed2_volatile=0x3415; + volatile ee_s32 seed3_volatile=0x66; +#endif +#if PERFORMANCE_RUN + volatile ee_s32 seed1_volatile=0x0; + volatile ee_s32 seed2_volatile=0x0; + volatile ee_s32 seed3_volatile=0x66; +#endif +#if PROFILE_RUN + volatile ee_s32 seed1_volatile=0x8; + volatile ee_s32 seed2_volatile=0x8; + volatile ee_s32 seed3_volatile=0x8; +#endif + volatile ee_s32 seed4_volatile=ITERATIONS; + volatile ee_s32 seed5_volatile=0; + +/* Porting : Timing functions + How to capture time and convert to seconds must be ported to whatever is supported by the platform. + e.g. Read value from on board RTC, read value from cpu clock cycles performance counter etc. + Sample implementation for standard time.h and windows.h definitions included. +*/ +/* Define : TIMER_RES_DIVIDER + Divider to trade off timer resolution and total time that can be measured. + + Use lower values to increase resolution, but make sure that overflow does not occur. + If there are issues with the return value overflowing, increase this value. + */ + +//#define CLOCKS_PER_SEC 20000000 // Gives the time in seconds for the reporting +#define CLOCKS_PER_SEC 20000 // Gives the time in milliseconds for the reporting +#define NSECS_PER_SEC CLOCKS_PER_SEC +#define CORETIMETYPE unsigned long +#define TIMER_RES_DIVIDER 1 +#define SAMPLE_TIME_IMPLEMENTATION 1 + +#define EE_TICKS_PER_SEC (NSECS_PER_SEC / TIMER_RES_DIVIDER) + +/** Define Host specific (POSIX), or target specific global time variables. */ +static CORETIMETYPE start_time_val, stop_time_val; + +/* Function : start_time + This function will be called right before starting the timed portion of the benchmark. + + Implementation may be capturing a system timer (as implemented in the example code) + or zeroing some system parameters - e.g. setting the cpu clocks cycles to 0. +*/ +void start_time(void) { + START_TIMER; + //GETMYTIME(&start_time_val ); +} +/* Function : stop_time + This function will be called right after ending the timed portion of the benchmark. + + Implementation may be capturing a system timer (as implemented in the example code) + or other system parameters - e.g. reading the current value of cpu cycles counter. +*/ +void stop_time(void) { + STOP_TIMER; + //GETMYTIME(&stop_time_val ); +} +/* Function : get_time + Return an abstract "ticks" number that signifies time on the system. + + Actual value returned may be cpu cycles, milliseconds or any other value, + as long as it can be converted to seconds by . + This methodology is taken to accomodate any hardware or simulated platform. + The sample implementation returns millisecs by default, + and the resolution is controlled by +*/ +CORE_TICKS get_time(void) { + CORE_TICKS elapsed=read_verilog_time(); + //CORE_TICKS elapsed=(CORE_TICKS)(MYTIMEDIFF(stop_time_val, start_time_val)); + return elapsed; +} +/* Function : time_in_secs + Convert the value returned by get_time to seconds. + + The type is used to accomodate systems with no support for floating point. + Default implementation implemented by the EE_TICKS_PER_SEC macro above. +*/ +secs_ret time_in_secs(CORE_TICKS ticks) { + secs_ret retval=(secs_ret)(ticks / EE_TICKS_PER_SEC); + return retval; +} + +ee_u32 default_num_contexts=1; + +/* Function : portable_init + Target specific initialization code + Test for some common mistakes. +*/ +void portable_init(core_portable *p, int *argc, char *argv[]) +{ + STOP_WATCHDOG; + if (sizeof(ee_ptr_int) != sizeof(ee_u8 *)) { + ee_printf("ERROR! Please define ee_ptr_int to a type that holds a pointer!\n"); + } + if (sizeof(ee_u32) != 4) { + ee_printf("ERROR! Please define ee_u32 to a 32b unsigned type!\n"); + } + p->portable_id=1; +} +/* Function : portable_fini + Target specific final code +*/ +void portable_fini(core_portable *p) +{ + p->portable_id=0; + COREMARK_DONE; +} + + +#if (MEM_METHOD==MEM_MALLOC) +//#include +/* Function: portable_malloc + Provide malloc() functionality in a platform specific way. +*/ +void *portable_malloc(size_t size) { + return malloc(size); +} +/* Function: portable_free + Provide free() functionality in a platform specific way. +*/ +void portable_free(void *p) { + free(p); +} +#else +void *portable_malloc(size_t size) { + return NULL; +} +void portable_free(void *p) { + p=NULL; +} +#endif
rtl_sim/src-c/coremark_v1.0/msp430/core_portme.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/msp430/omsp_func.h =================================================================== --- rtl_sim/src-c/coremark_v1.0/msp430/omsp_func.h (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/msp430/omsp_func.h (revision 145) @@ -0,0 +1,126 @@ +/*===========================================================================*/ +/* Copyright (C) 2001 Authors */ +/* */ +/* This source file may be used and distributed without restriction provided */ +/* that this copyright statement is not removed from the file and that any */ +/* derivative work contains the original copyright notice and the associated */ +/* disclaimer. */ +/* */ +/* This source file is free software; you can redistribute it and/or modify */ +/* it under the terms of the GNU Lesser General Public License as published */ +/* by the Free Software Foundation; either version 2.1 of the License, or */ +/* (at your option) any later version. */ +/* */ +/* This source is distributed in the hope that it will be useful, but WITHOUT*/ +/* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */ +/* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */ +/* License for more details. */ +/* */ +/* You should have received a copy of the GNU Lesser General Public License */ +/* along with this source; if not, write to the Free Software Foundation, */ +/* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ +/* */ +/*===========================================================================*/ +/* OMSP_FUNC HEADER FILE */ +/*---------------------------------------------------------------------------*/ +/* */ +/* Author(s): */ +/* - Olivier Girard, olgirard@gmail.com */ +/* */ +/*---------------------------------------------------------------------------*/ +/* $Rev: 19 $ */ +/* $LastChangedBy: olivier.girard $ */ +/* $LastChangedDate: 2009-08-04 23:47:15 +0200 (Tue, 04 Aug 2009) $ */ +/*===========================================================================*/ + +//============================================================================= +// PERIPHERALS REGISTER DEFINITIONS +//============================================================================= + +//---------------------------------------------------------- +// SPECIAL FUNCTION REGISTERS +//---------------------------------------------------------- +#define IE1 (*(volatile unsigned char *) 0x0000) +#define IFG1 (*(volatile unsigned char *) 0x0002) + +#define CPU_ID_LO (*(volatile unsigned char *) 0x0004) +#define CPU_ID_HI (*(volatile unsigned char *) 0x0006) + + +//---------------------------------------------------------- +// GPIOs +//---------------------------------------------------------- +#define P1IN (*(volatile unsigned char *) 0x0020) +#define P1OUT (*(volatile unsigned char *) 0x0021) +#define P1DIR (*(volatile unsigned char *) 0x0022) +#define P1IFG (*(volatile unsigned char *) 0x0023) +#define P1IES (*(volatile unsigned char *) 0x0024) +#define P1IE (*(volatile unsigned char *) 0x0025) +#define P1SEL (*(volatile unsigned char *) 0x0026) + +#define P2IN (*(volatile unsigned char *) 0x0028) +#define P2OUT (*(volatile unsigned char *) 0x0029) +#define P2DIR (*(volatile unsigned char *) 0x002A) +#define P2IFG (*(volatile unsigned char *) 0x002B) +#define P2IES (*(volatile unsigned char *) 0x002C) +#define P2IE (*(volatile unsigned char *) 0x002D) +#define P2SEL (*(volatile unsigned char *) 0x002E) + +#define P3IN (*(volatile unsigned char *) 0x0018) +#define P3OUT (*(volatile unsigned char *) 0x0019) +#define P3DIR (*(volatile unsigned char *) 0x001A) +#define P3SEL (*(volatile unsigned char *) 0x001B) + +#define P4IN (*(volatile unsigned char *) 0x001C) +#define P4OUT (*(volatile unsigned char *) 0x001D) +#define P4DIR (*(volatile unsigned char *) 0x001E) +#define P4SEL (*(volatile unsigned char *) 0x001F) + +#define P5IN (*(volatile unsigned char *) 0x0030) +#define P5OUT (*(volatile unsigned char *) 0x0031) +#define P5DIR (*(volatile unsigned char *) 0x0032) +#define P5SEL (*(volatile unsigned char *) 0x0033) + +#define P6IN (*(volatile unsigned char *) 0x0034) +#define P6OUT (*(volatile unsigned char *) 0x0035) +#define P6DIR (*(volatile unsigned char *) 0x0036) +#define P6SEL (*(volatile unsigned char *) 0x0037) + + +//---------------------------------------------------------- +// WATCHDOG TIMER +//---------------------------------------------------------- + +// Addresses +#define WDTCTL (*(volatile unsigned int *) 0x0120) + +// Bit masks +#define WDTIS0 (0x0001) +#define WDTIS1 (0x0002) +#define WDTSSEL (0x0004) +#define WDTCNTCL (0x0008) +#define WDTTMSEL (0x0010) +#define WDTNMI (0x0020) +#define WDTNMIES (0x0040) +#define WDTHOLD (0x0080) +#define WDTPW (0x5A00) + + +//============================================================================= +// MACROS +//============================================================================= + +#define STOP_WATCHDOG WDTCTL = WDTPW | WDTHOLD + +#define START_TIMER P2OUT |= 0x02 +#define STOP_TIMER P2OUT &= 0xFD + +#define COREMARK_DONE P2OUT |= 0x80 + + +//============================================================================= +// FUNCTIONS +//============================================================================= + +int putchar (int txdata); +unsigned long read_verilog_time ();
rtl_sim/src-c/coremark_v1.0/msp430/omsp_func.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/msp430/core_portme.h =================================================================== --- rtl_sim/src-c/coremark_v1.0/msp430/core_portme.h (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/msp430/core_portme.h (revision 145) @@ -0,0 +1,187 @@ +/* File : core_portme.h */ + +/* + Author : Shay Gal-On, EEMBC + Legal : TODO! +*/ +/* Topic : Description + This file contains configuration constants required to execute on different platforms +*/ +#ifndef CORE_PORTME_H +#define CORE_PORTME_H + +#include + +/************************/ +/* Data types and settings */ +/************************/ +/* Configuration : HAS_FLOAT + Define to 1 if the platform supports floating point. +*/ +#ifndef HAS_FLOAT +#define HAS_FLOAT 0 +#endif +/* Configuration : HAS_TIME_H + Define to 1 if platform has the time.h header file, + and implementation of functions thereof. +*/ +#ifndef HAS_TIME_H +#define HAS_TIME_H 0 +#endif +/* Configuration : USE_CLOCK + Define to 1 if platform has the time.h header file, + and implementation of functions thereof. +*/ +#ifndef USE_CLOCK +#define USE_CLOCK 0 +#endif +/* Configuration : HAS_STDIO + Define to 1 if the platform has stdio.h. +*/ +#ifndef HAS_STDIO +#define HAS_STDIO 1 +#endif +/* Configuration : HAS_PRINTF + Define to 1 if the platform has stdio.h and implements the printf function. +*/ +#ifndef HAS_PRINTF +#define HAS_PRINTF 1 +#endif + +/* Configuration : CORE_TICKS + Define type of return from the timing functions. + */ +//#include +typedef unsigned long CORE_TICKS; + +/* Definitions : COMPILER_VERSION, COMPILER_FLAGS, MEM_LOCATION + Initialize these strings per platform +*/ +#ifndef COMPILER_VERSION + #ifdef __GNUC__ + #define COMPILER_VERSION "GCC"__VERSION__ + #else + #define COMPILER_VERSION "Please put compiler version here (e.g. gcc 4.1)" + #endif +#endif +#ifndef COMPILER_FLAGS + #define COMPILER_FLAGS FLAGS_STR /* "Please put compiler flags here (e.g. -o3)" */ +#endif +#ifndef MEM_LOCATION + #define MEM_LOCATION "MALLOC" +#endif + +/* Data Types : + To avoid compiler issues, define the data types that need ot be used for 8b, 16b and 32b in . + + *Imprtant* : + ee_ptr_int needs to be the data type used to hold pointers, otherwise coremark may fail!!! +*/ +typedef signed int ee_s16; +typedef unsigned int ee_u16; +typedef signed long ee_s32; +typedef double ee_f32; +typedef unsigned char ee_u8; +typedef unsigned long ee_u32; +typedef ee_u16 ee_ptr_int; +typedef size_t ee_size_t; +/* align_mem : + This macro is used to align an offset to point to a 32b value. It is used in the Matrix algorithm to initialize the input memory blocks. +*/ +#define align_mem(x) (void *)(4 + (((ee_ptr_int)(x) - 1) & ~3)) + +/* Configuration : SEED_METHOD + Defines method to get seed values that cannot be computed at compile time. + + Valid values : + SEED_ARG - from command line. + SEED_FUNC - from a system function. + SEED_VOLATILE - from volatile variables. +*/ +#ifndef SEED_METHOD +#define SEED_METHOD SEED_VOLATILE +#endif + +/* Configuration : MEM_METHOD + Defines method to get a block of memry. + + Valid values : + MEM_MALLOC - for platforms that implement malloc and have malloc.h. + MEM_STATIC - to use a static memory array. + MEM_STACK - to allocate the data block on the stack (NYI). +*/ +#ifndef MEM_METHOD +#define MEM_METHOD MEM_MALLOC +#endif + +/* Configuration : MULTITHREAD + Define for parallel execution + + Valid values : + 1 - only one context (default). + N>1 - will execute N copies in parallel. + + Note : + If this flag is defined to more then 1, an implementation for launching parallel contexts must be defined. + + Two sample implementations are provided. Use or to enable them. + + It is valid to have a different implementation of and in , + to fit a particular architecture. +*/ +#ifndef MULTITHREAD +#define MULTITHREAD 1 +#define USE_PTHREAD 0 +#define USE_FORK 0 +#define USE_SOCKET 0 +#endif + +/* Configuration : MAIN_HAS_NOARGC + Needed if platform does not support getting arguments to main. + + Valid values : + 0 - argc/argv to main is supported + 1 - argc/argv to main is not supported + + Note : + This flag only matters if MULTITHREAD has been defined to a value greater then 1. +*/ +#ifndef MAIN_HAS_NOARGC +#define MAIN_HAS_NOARGC 1 +#endif + +/* Configuration : MAIN_HAS_NORETURN + Needed if platform does not support returning a value from main. + + Valid values : + 0 - main returns an int, and return value will be 0. + 1 - platform does not support returning a value from main +*/ +#ifndef MAIN_HAS_NORETURN +#define MAIN_HAS_NORETURN 0 +#endif + +/* Variable : default_num_contexts + Not used for this simple port, must cintain the value 1. +*/ +extern ee_u32 default_num_contexts; + +typedef struct CORE_PORTABLE_S { + ee_u8 portable_id; +} core_portable; + +/* target specific init/fini */ +void portable_init(core_portable *p, int *argc, char *argv[]); +void portable_fini(core_portable *p); + +#if !defined(PROFILE_RUN) && !defined(PERFORMANCE_RUN) && !defined(VALIDATION_RUN) +#if (TOTAL_DATA_SIZE==1200) +#define PROFILE_RUN 1 +#elif (TOTAL_DATA_SIZE==2000) +#define PERFORMANCE_RUN 1 +#else +#define VALIDATION_RUN 1 +#endif +#endif + +#endif /* CORE_PORTME_H */
rtl_sim/src-c/coremark_v1.0/msp430/core_portme.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/msp430/core_portme.mak =================================================================== --- rtl_sim/src-c/coremark_v1.0/msp430/core_portme.mak (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/msp430/core_portme.mak (revision 145) @@ -0,0 +1,49 @@ +#File: core_portme.mak + +ITERATIONS = 1 +PORT_CFLAGS = -O2 + +# Flag: OUTFLAG +# Use this flag to define how to to get an executable (e.g -o) +OUTFLAG= -o +# Flag: CC +# Use this flag to define compiler to use +CC = msp430-gcc +# Flag: CFLAGS +# Use this flag to define compiler options. Note, you can add compiler options from the command line using XCFLAGS="other flags" +FLAGS_STR = "$(PORT_CFLAGS) $(XCFLAGS) $(XLFLAGS) $(LFLAGS_END)" +#CFLAGS = $(PORT_CFLAGS) -mforce-hwmul -I$(PORT_DIR) -I. -DFLAGS_STR=\"$(FLAGS_STR)\" +CFLAGS = $(PORT_CFLAGS) -mcpu=430 -mivcnt=16 -mmpy=16 -I$(PORT_DIR) -I. -DFLAGS_STR=\"$(FLAGS_STR)\" +#Flag: LFLAGS_END +# Define any libraries needed for linking or other flags that should come at the end of the link line (e.g. linker scripts). +# Note : On certain platforms, the default clock_gettime implementation is supported but requires linking of librt. +LFLAGS_END += -T$(PORT_DIR)/linker.x +# Flag : PORT_SRCS +# Port specific source files can be added here +PORT_SRCS = $(PORT_DIR)/core_portme.c $(PORT_DIR)/omsp_func.c +# Flag : LOAD +# For a simple port, we assume self hosted compile and run, no load needed. + +# Flag : RUN +# For a simple port, we assume self hosted compile and run, simple invocation of the executable + +#For native compilation and execution +LOAD = echo Loading done +RUN = echo + +OEXT = .o +EXE = .elf + + +# Target : port_pre% and port_post% +# For the purpose of this simple port, no pre or post steps needed. + +.PHONY : port_prebuild port_postbuild port_prerun port_postrun port_preload port_postload +port_pre% port_post% : + +# FLAG : OPATH +# Path to the output folder. Default - current folder. +OPATH = ./ +MKDIR = mkdir -p + +
rtl_sim/src-c/coremark_v1.0/msp430/core_portme.mak Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/msp430/linker.x =================================================================== --- rtl_sim/src-c/coremark_v1.0/msp430/linker.x (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/msp430/linker.x (revision 145) @@ -0,0 +1,217 @@ +/* Default linker script, for normal executables */ +OUTPUT_FORMAT("elf32-msp430") +OUTPUT_ARCH("msp430") +MEMORY { + sfr : ORIGIN = 0x0000, LENGTH = 0x0010 + peripheral_8bit : ORIGIN = 0x0010, LENGTH = 0x00f0 + peripheral_16bit : ORIGIN = 0x0100, LENGTH = 0x0100 + + ram (wx) : ORIGIN = 0x0200, LENGTH = 0x4000 + rom (rx) : ORIGIN = 0xA000, LENGTH = 0x6000-0x20 + vectors : ORIGIN = 0xffe0, LENGTH = 0x0020 + + /* Remaining banks are absent */ + bsl : ORIGIN = 0x0000, LENGTH = 0x0000 + infomem : ORIGIN = 0x0000, LENGTH = 0x0000 + infob : ORIGIN = 0x0000, LENGTH = 0x0000 + infoa : ORIGIN = 0x0000, LENGTH = 0x0000 + infoc : ORIGIN = 0x0000, LENGTH = 0x0000 + infod : ORIGIN = 0x0000, LENGTH = 0x0000 + ram2 (wx) : ORIGIN = 0x0000, LENGTH = 0x0000 + ram_mirror (wx) : ORIGIN = 0x0000, LENGTH = 0x0000 + usbram (wx) : ORIGIN = 0x0000, LENGTH = 0x0000 + far_rom : ORIGIN = 0x00000000, LENGTH = 0x00000000 +} +REGION_ALIAS("REGION_TEXT", rom); +REGION_ALIAS("REGION_DATA", ram); +REGION_ALIAS("REGION_FAR_ROM", far_rom); +__WDTCTL = 0x0120; +__MPY = 0x0130; +__MPYS = 0x0132; +__MAC = 0x0134; +__MACS = 0x0136; +__OP2 = 0x0138; +__RESLO = 0x013A; +__RESHI = 0x013C; +__SUMEXT = 0x013E; +__P1OUT = 0x0021; + +SECTIONS +{ + /* Read-only sections, merged into text segment. */ + .hash : { *(.hash) } + .dynsym : { *(.dynsym) } + .dynstr : { *(.dynstr) } + .gnu.version : { *(.gnu.version) } + .gnu.version_d : { *(.gnu.version_d) } + .gnu.version_r : { *(.gnu.version_r) } + .rel.init : { *(.rel.init) } + .rela.init : { *(.rela.init) } + .rel.fini : { *(.rel.fini) } + .rela.fini : { *(.rela.fini) } + .rel.text : { *(.rel.text .rel.text.* .rel.gnu.linkonce.t.*) } + .rela.text : { *(.rela.text .rela.text.* .rela.gnu.linkonce.t.*) } + .rel.rodata : { *(.rel.rodata .rel.rodata.* .rel.gnu.linkonce.r.*) } + .rela.rodata : { *(.rela.rodata .rela.rodata.* .rela.gnu.linkonce.r.*) } + .rel.data : { *(.rel.data .rel.data.* .rel.gnu.linkonce.d.*) } + .rela.data : { *(.rela.data .rela.data.* .rela.gnu.linkonce.d.*) } + .rel.bss : { *(.rel.bss .rel.bss.* .rel.gnu.linkonce.b.*) } + .rela.bss : { *(.rela.bss .rela.bss.* .rela.gnu.linkonce.b.*) } + .rel.ctors : { *(.rel.ctors) } + .rela.ctors : { *(.rela.ctors) } + .rel.dtors : { *(.rel.dtors) } + .rela.dtors : { *(.rela.dtors) } + .rel.got : { *(.rel.got) } + .rela.got : { *(.rela.got) } + .rel.plt : { *(.rel.plt) } + .rela.plt : { *(.rela.plt) } + .text : + { + . = ALIGN(2); + KEEP(*(.init .init.*)) + KEEP(*(.init0)) /* Start here after reset. */ + KEEP(*(.init1)) /* User definable. */ + KEEP(*(.init2)) /* Initialize stack. */ + KEEP(*(.init3)) /* Initialize hardware, user definable. */ + KEEP(*(.init4)) /* Copy data to .data, clear bss. */ + KEEP(*(.init5)) /* User definable. */ + KEEP(*(.init6)) /* C++ constructors. */ + KEEP(*(.init7)) /* User definable. */ + KEEP(*(.init8)) /* User definable. */ + KEEP(*(.init9)) /* Call main(). */ + KEEP(*(.fini9)) /* Falls into here after main(). User definable. */ + KEEP(*(.fini8)) /* User definable. */ + KEEP(*(.fini7)) /* User definable. */ + KEEP(*(.fini6)) /* C++ destructors. */ + KEEP(*(.fini5)) /* User definable. */ + KEEP(*(.fini4)) /* User definable. */ + KEEP(*(.fini3)) /* User definable. */ + KEEP(*(.fini2)) /* User definable. */ + KEEP(*(.fini1)) /* User definable. */ + KEEP(*(.fini0)) /* Infinite loop after program termination. */ + KEEP(*(.fini .fini.*)) + . = ALIGN(2); + __ctors_start = . ; + KEEP(*(.ctors)) + __ctors_end = . ; + __dtors_start = . ; + KEEP(*(.dtors)) + __dtors_end = . ; + . = ALIGN(2); + *(.text .text.* .gnu.linkonce.t.*) + . = ALIGN(2); + } > REGION_TEXT + .rodata : + { + . = ALIGN(2); + *(.rodata .rodata.* .gnu.linkonce.r.*) + . = ALIGN(2); + } > REGION_TEXT + _etext = .; /* Past last read-only (loadable) segment */ + .data : + { + . = ALIGN(2); + PROVIDE (__data_start = .) ; + *(.data .data.* .gnu.linkonce.d.*) + . = ALIGN(2); + _edata = . ; /* Past last read-write (loadable) segment */ + } > REGION_DATA AT > REGION_TEXT + PROVIDE (__data_load_start = LOADADDR(.data) ); + PROVIDE (__data_size = SIZEOF(.data) ); + .bss : + { + PROVIDE (__bss_start = .) ; + *(.bss .bss.*) + *(COMMON) + . = ALIGN(2); + PROVIDE (__bss_end = .) ; + } > REGION_DATA + PROVIDE (__bss_size = SIZEOF(.bss) ); + .noinit : + { + PROVIDE (__noinit_start = .) ; + *(.noinit .noinit.*) + . = ALIGN(2); + PROVIDE (__noinit_end = .) ; + } > REGION_DATA + . = ALIGN(2); + _end = . ; /* Past last write (loadable) segment */ + .infomem : + { + *(.infomem) + . = ALIGN(2); + *(.infomem.*) + } > infomem + .infomemnobits : + { + *(.infomemnobits) + . = ALIGN(2); + *(.infomemnobits.*) + } > infomem + .infoa : + { + *(.infoa .infoa.*) + } > infoa + .infob : + { + *(.infob .infob.*) + } > infob + .infoc : + { + *(.infoc .infoc.*) + } > infoc + .infod : + { + *(.infod .infod.*) + } > infod + .vectors : + { + PROVIDE (__vectors_start = .) ; + KEEP(*(.vectors*)) + _vectors_end = . ; + } > vectors + .fartext : + { + . = ALIGN(2); + *(.fartext) + . = ALIGN(2); + *(.fartext.*) + _efartext = .; + } > REGION_FAR_ROM + /* Stabs for profiling information*/ + .profiler 0 : { *(.profiler) } + /* Stabs debugging sections. */ + .stab 0 : { *(.stab) } + .stabstr 0 : { *(.stabstr) } + .stab.excl 0 : { *(.stab.excl) } + .stab.exclstr 0 : { *(.stab.exclstr) } + .stab.index 0 : { *(.stab.index) } + .stab.indexstr 0 : { *(.stab.indexstr) } + .comment 0 : { *(.comment) } + /* DWARF debug sections. + Symbols in the DWARF debugging sections are relative to the beginning + of the section so we begin them at 0. */ + /* DWARF 1 */ + .debug 0 : { *(.debug) } + .line 0 : { *(.line) } + /* GNU DWARF 1 extensions */ + .debug_srcinfo 0 : { *(.debug_srcinfo) } + .debug_sfnames 0 : { *(.debug_sfnames) } + /* DWARF 1.1 and DWARF 2 */ + .debug_aranges 0 : { *(.debug_aranges) } + .debug_pubnames 0 : { *(.debug_pubnames) } + /* DWARF 2 */ + .debug_info 0 : { *(.debug_info) *(.gnu.linkonce.wi.*) } + .debug_abbrev 0 : { *(.debug_abbrev) } + .debug_line 0 : { *(.debug_line) } + .debug_frame 0 : { *(.debug_frame) } + .debug_str 0 : { *(.debug_str) } + .debug_loc 0 : { *(.debug_loc) } + .debug_macinfo 0 : { *(.debug_macinfo) } + /* DWARF 3 */ + .debug_pubtypes 0 : { *(.debug_pubtypes) } + .debug_ranges 0 : { *(.debug_ranges) } + PROVIDE (__stack = ORIGIN(ram) + LENGTH(ram)); + PROVIDE (__data_start_rom = _etext); + PROVIDE (__data_end_rom = _etext + SIZEOF (.data)); +}
rtl_sim/src-c/coremark_v1.0/msp430/linker.x Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/msp430/omsp_func.c =================================================================== --- rtl_sim/src-c/coremark_v1.0/msp430/omsp_func.c (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/msp430/omsp_func.c (revision 145) @@ -0,0 +1,67 @@ +/*===========================================================================*/ +/* Copyright (C) 2001 Authors */ +/* */ +/* This source file may be used and distributed without restriction provided */ +/* that this copyright statement is not removed from the file and that any */ +/* derivative work contains the original copyright notice and the associated */ +/* disclaimer. */ +/* */ +/* This source file is free software; you can redistribute it and/or modify */ +/* it under the terms of the GNU Lesser General Public License as published */ +/* by the Free Software Foundation; either version 2.1 of the License, or */ +/* (at your option) any later version. */ +/* */ +/* This source is distributed in the hope that it will be useful, but WITHOUT*/ +/* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */ +/* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */ +/* License for more details. */ +/* */ +/* You should have received a copy of the GNU Lesser General Public License */ +/* along with this source; if not, write to the Free Software Foundation, */ +/* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ +/* */ +/*===========================================================================*/ +/* OMSP_FUNC C FILE */ +/*---------------------------------------------------------------------------*/ +/* */ +/* Author(s): */ +/* - Olivier Girard, olgirard@gmail.com */ +/* */ +/*---------------------------------------------------------------------------*/ +/* $Rev: 19 $ */ +/* $LastChangedBy: olivier.girard $ */ +/* $LastChangedDate: 2009-08-04 23:47:15 +0200 (Tue, 04 Aug 2009) $ */ +/*===========================================================================*/ + +#include "omsp_func.h" + +//--------------------------------------------------// +// putChar function // +// (Send a byte to the Port-1) // +//--------------------------------------------------// +int putchar (int txdata) { + + // Write the output character to the Port-1 + P1OUT = txdata; + + // Toggle Port-2[0] to signal new byte + P2OUT ^= 0x01; + + return 0; +} + +//--------------------------------------------------// +// Read time from the // +// verilog stimulus // +//--------------------------------------------------// +unsigned long read_verilog_time () { + + unsigned long tick_time; + + tick_time = P6IN; + tick_time = ((tick_time<<8) + P5IN); + tick_time = ((tick_time<<8) + P4IN); + tick_time = ((tick_time<<8) + P3IN); + + return tick_time; +}
rtl_sim/src-c/coremark_v1.0/msp430/omsp_func.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/core_util.c =================================================================== --- rtl_sim/src-c/coremark_v1.0/core_util.c (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/core_util.c (revision 145) @@ -0,0 +1,210 @@ +/* +Author : Shay Gal-On, EEMBC + +This file is part of EEMBC(R) and CoreMark(TM), which are Copyright (C) 2009 +All rights reserved. + +EEMBC CoreMark Software is a product of EEMBC and is provided under the terms of the +CoreMark License that is distributed with the official EEMBC COREMARK Software release. +If you received this EEMBC CoreMark Software without the accompanying CoreMark License, +you must discontinue use and download the official release from www.coremark.org. + +Also, if you are publicly displaying scores generated from the EEMBC CoreMark software, +make sure that you are in compliance with Run and Reporting rules specified in the accompanying readme.txt file. + +EEMBC +4354 Town Center Blvd. Suite 114-200 +El Dorado Hills, CA, 95762 +*/ +#include "coremark.h" +/* Function: get_seed + Get a values that cannot be determined at compile time. + + Since different embedded systems and compilers are used, 3 different methods are provided: + 1 - Using a volatile variable. This method is only valid if the compiler is forced to generate code that + reads the value of a volatile variable from memory at run time. + Please note, if using this method, you would need to modify core_portme.c to generate training profile. + 2 - Command line arguments. This is the preferred method if command line arguments are supported. + 3 - System function. If none of the first 2 methods is available on the platform, + a system function which is not a stub can be used. + + e.g. read the value on GPIO pins connected to switches, or invoke special simulator functions. +*/ +#if (SEED_METHOD==SEED_VOLATILE) + extern volatile ee_s32 seed1_volatile; + extern volatile ee_s32 seed2_volatile; + extern volatile ee_s32 seed3_volatile; + extern volatile ee_s32 seed4_volatile; + extern volatile ee_s32 seed5_volatile; + ee_s32 get_seed_32(int i) { + ee_s32 retval; + switch (i) { + case 1: + retval=seed1_volatile; + break; + case 2: + retval=seed2_volatile; + break; + case 3: + retval=seed3_volatile; + break; + case 4: + retval=seed4_volatile; + break; + case 5: + retval=seed5_volatile; + break; + default: + retval=0; + break; + } + return retval; + } +#elif (SEED_METHOD==SEED_ARG) +ee_s32 parseval(char *valstring) { + ee_s32 retval=0; + ee_s32 neg=1; + int hexmode=0; + if (*valstring == '-') { + neg=-1; + valstring++; + } + if ((valstring[0] == '0') && (valstring[1] == 'x')) { + hexmode=1; + valstring+=2; + } + /* first look for digits */ + if (hexmode) { + while (((*valstring >= '0') && (*valstring <= '9')) || ((*valstring >= 'a') && (*valstring <= 'f'))) { + ee_s32 digit=*valstring-'0'; + if (digit>9) + digit=10+*valstring-'a'; + retval*=16; + retval+=digit; + valstring++; + } + } else { + while ((*valstring >= '0') && (*valstring <= '9')) { + ee_s32 digit=*valstring-'0'; + retval*=10; + retval+=digit; + valstring++; + } + } + /* now add qualifiers */ + if (*valstring=='K') + retval*=1024; + if (*valstring=='M') + retval*=1024*1024; + + retval*=neg; + return retval; +} + +ee_s32 get_seed_args(int i, int argc, char *argv[]) { + if (argc>i) + return parseval(argv[i]); + return 0; +} + +#elif (SEED_METHOD==SEED_FUNC) +/* If using OS based function, you must define and implement the functions below in core_portme.h and core_portme.c ! */ +ee_s32 get_seed_32(int i) { + ee_s32 retval; + switch (i) { + case 1: + retval=portme_sys1(); + break; + case 2: + retval=portme_sys2(); + break; + case 3: + retval=portme_sys3(); + break; + case 4: + retval=portme_sys4(); + break; + case 5: + retval=portme_sys5(); + break; + default: + retval=0; + break; + } + return retval; +} +#endif + +/* Function: crc* + Service functions to calculate 16b CRC code. + +*/ +ee_u16 crcu8(ee_u8 data, ee_u16 crc ) +{ + ee_u8 i=0,x16=0,carry=0; + + for (i = 0; i < 8; i++) + { + x16 = (ee_u8)((data & 1) ^ ((ee_u8)crc & 1)); + data >>= 1; + + if (x16 == 1) + { + crc ^= 0x4002; + carry = 1; + } + else + carry = 0; + crc >>= 1; + if (carry) + crc |= 0x8000; + else + crc &= 0x7fff; + } + return crc; +} +ee_u16 crcu16(ee_u16 newval, ee_u16 crc) { + crc=crcu8( (ee_u8) (newval) ,crc); + crc=crcu8( (ee_u8) ((newval)>>8) ,crc); + return crc; +} +ee_u16 crcu32(ee_u32 newval, ee_u16 crc) { + crc=crc16((ee_s16) newval ,crc); + crc=crc16((ee_s16) (newval>>16) ,crc); + return crc; +} +ee_u16 crc16(ee_s16 newval, ee_u16 crc) { + return crcu16((ee_u16)newval, crc); +} + +ee_u8 check_data_types() { + ee_u8 retval=0; + if (sizeof(ee_u8) != 1) { + ee_printf("ERROR: ee_u8 is not an 8b datatype!\n"); + retval++; + } + if (sizeof(ee_u16) != 2) { + ee_printf("ERROR: ee_u16 is not a 16b datatype!\n"); + retval++; + } + if (sizeof(ee_s16) != 2) { + ee_printf("ERROR: ee_s16 is not a 16b datatype!\n"); + retval++; + } + if (sizeof(ee_s32) != 4) { + ee_printf("ERROR: ee_s32 is not a 32b datatype!\n"); + retval++; + } + if (sizeof(ee_u32) != 4) { + ee_printf("ERROR: ee_u32 is not a 32b datatype!\n"); + retval++; + } + if (sizeof(ee_ptr_int) != sizeof(int *)) { + ee_printf("ERROR: ee_ptr_int is not a datatype that holds an int pointer!\n"); + retval++; + } + if (retval>0) { + ee_printf("ERROR: Please modify the datatypes in core_portme.h!\n"); + } + return retval; +}
rtl_sim/src-c/coremark_v1.0/core_util.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/release_notes.txt =================================================================== --- rtl_sim/src-c/coremark_v1.0/release_notes.txt (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/release_notes.txt (revision 145) @@ -0,0 +1,59 @@ +File: Release Notes + Version: 1.01 + +History: + Version 1.01 + - Added validation testing the sizes of datatypes. + + Version 1.00 + - First public version. + +Validation: + This release was tested on the following platforms + o x86 cygwin and gcc 3.4 (Quad, dual and single core systems) + o x86 linux (Ubuntu/Fedora) and gcc (4.2/4.1) (Quad and single core systems) + o MIPS64 BE linux and gcc 3.4 16 cores system + o MIPS32 BE linux with CodeSourcery compiler 4.2-177 on Malta/Linux with a 1004K 3-core system + o PPC simulator with gcc 4.2.2 (No OS) + o PPC 64b BE linux (yellowdog) with gcc 3.4 and 4.1 (Dual core system) + o BF533 with VDSP50 + o Renesas R8C/H8 MCU with HEW 4.05 + o NXP LPC1700 armcc v4.0.0.524 + o NEC 78K with IAR v4.61 + o ARM simulator with armcc v4 + + Coverage: + GCOV results can be found on SVN under cover. + + Memory analysis: + Valgrind 3.4.0 used and no errors reported. + + Balance analysis: + Number of instructions executed for each function tested with cachegrind and found balanced with gcc and -O0. + +Statistics: + +Lines: +(start table) +Lines Blank Cmnts Source AESL +===== ===== ===== ===== ========== ======================================= + 469 66 170 251 627.5 core_list_join.c (C) + 330 18 54 268 670.0 core_main.c (C) + 256 32 80 146 365.0 core_matrix.c (C) + 240 16 51 186 465.0 core_state.c (C) + 165 11 20 134 335.0 core_util.c (C) + 150 23 36 98 245.0 coremark.h (C) + 1610 166 411 1083 2707.5 ----- Benchmark ----- (6 files) + 293 15 74 212 530.0 linux/core_portme.c (C) + 235 30 104 104 260.0 linux/core_portme.h (C) + 528 45 178 316 790.0 ----- Porting ----- (2 files) + + +* For comparison, here are the stats for Dhrystone +Lines Blank Cmnts Source AESL +===== ===== ===== ===== ========== ======================================= + 311 15 242 54 135.0 dhry.h (C) + 789 132 119 553 1382.5 dhry_1.c (C) + 186 26 68 107 267.5 dhry_2.c (C) + 1286 173 429 714 1785.0 ----- C ----- (3 files) +(end table)
rtl_sim/src-c/coremark_v1.0/release_notes.txt Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/coremark.md5 =================================================================== --- rtl_sim/src-c/coremark_v1.0/coremark.md5 (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/coremark.md5 (revision 145) @@ -0,0 +1,6 @@ +ef848e21d3268820c4830c8332708c1e *core_list_join.c +7631bd852cf622ee2c3f58d30d5a6a92 *core_main.c +aba83b72d1179503e17d182cf809a2f1 *core_matrix.c +e494356cd3a4adc07f12d330b25a2d72 *core_state.c +f37e364b4f4123722066218707cc476e *core_util.c +e8eac57239af0eedf934f9e8b62d8ec6 *coremark.h
rtl_sim/src-c/coremark_v1.0/coremark.md5 Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/docs/r01an0757eu_rx.pdf =================================================================== Cannot display: file marked as a binary type. svn:mime-type = application/octet-stream Index: rtl_sim/src-c/coremark_v1.0/docs/r01an0757eu_rx.pdf =================================================================== --- rtl_sim/src-c/coremark_v1.0/docs/r01an0757eu_rx.pdf (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/docs/r01an0757eu_rx.pdf (revision 145)
rtl_sim/src-c/coremark_v1.0/docs/r01an0757eu_rx.pdf Property changes : Added: svn:mime-type ## -0,0 +1 ## +application/octet-stream \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/docs/LICENSE.DOC =================================================================== Cannot display: file marked as a binary type. svn:mime-type = application/octet-stream Index: rtl_sim/src-c/coremark_v1.0/docs/LICENSE.DOC =================================================================== --- rtl_sim/src-c/coremark_v1.0/docs/LICENSE.DOC (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/docs/LICENSE.DOC (revision 145)
rtl_sim/src-c/coremark_v1.0/docs/LICENSE.DOC Property changes : Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +application/octet-stream \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/docs/Coremark-requirements.doc =================================================================== Cannot display: file marked as a binary type. svn:mime-type = application/octet-stream Index: rtl_sim/src-c/coremark_v1.0/docs/Coremark-requirements.doc =================================================================== --- rtl_sim/src-c/coremark_v1.0/docs/Coremark-requirements.doc (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/docs/Coremark-requirements.doc (revision 145)
rtl_sim/src-c/coremark_v1.0/docs/Coremark-requirements.doc Property changes : Added: svn:executable ## -0,0 +1 ## +* \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +application/octet-stream \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/core_state.c =================================================================== --- rtl_sim/src-c/coremark_v1.0/core_state.c (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/core_state.c (revision 145) @@ -0,0 +1,277 @@ +/* +Author : Shay Gal-On, EEMBC + +This file is part of EEMBC(R) and CoreMark(TM), which are Copyright (C) 2009 +All rights reserved. + +EEMBC CoreMark Software is a product of EEMBC and is provided under the terms of the +CoreMark License that is distributed with the official EEMBC COREMARK Software release. +If you received this EEMBC CoreMark Software without the accompanying CoreMark License, +you must discontinue use and download the official release from www.coremark.org. + +Also, if you are publicly displaying scores generated from the EEMBC CoreMark software, +make sure that you are in compliance with Run and Reporting rules specified in the accompanying readme.txt file. + +EEMBC +4354 Town Center Blvd. Suite 114-200 +El Dorado Hills, CA, 95762 +*/ +#include "coremark.h" +/* local functions */ +enum CORE_STATE core_state_transition( ee_u8 **instr , ee_u32 *transition_count); + +/* +Topic: Description + Simple state machines like this one are used in many embedded products. + + For more complex state machines, sometimes a state transition table implementation is used instead, + trading speed of direct coding for ease of maintenance. + + Since the main goal of using a state machine in CoreMark is to excercise the switch/if behaviour, + we are using a small moore machine. + + In particular, this machine tests type of string input, + trying to determine whether the input is a number or something else. + (see core_state.png). +*/ + +/* Function: core_bench_state + Benchmark function + + Go over the input twice, once direct, and once after introducing some corruption. +*/ +ee_u16 core_bench_state(ee_u32 blksize, ee_u8 *memblock, + ee_s16 seed1, ee_s16 seed2, ee_s16 step, ee_u16 crc) +{ + ee_u32 final_counts[NUM_CORE_STATES]; + ee_u32 track_counts[NUM_CORE_STATES]; + ee_u8 *p=memblock; + ee_u32 i; + + +#if CORE_DEBUG + ee_printf("State Bench: %d,%d,%d,%04x\n",seed1,seed2,step,crc); +#endif + for (i=0; i0) { + for(i=0;i>3) & 0x3]; + next=4; + break; + case 3: /* float */ + case 4: /* float */ + buf=floatpat[(seed>>3) & 0x3]; + next=8; + break; + case 5: /* scientific */ + case 6: /* scientific */ + buf=scipat[(seed>>3) & 0x3]; + next=8; + break; + case 7: /* invalid */ + buf=errpat[(seed>>3) & 0x3]; + next=8; + break; + default: /* Never happen, just to make some compilers happy */ + break; + } + } + size++; + while (total='0') & (c<='9')) ? 1 : 0; + return retval; +} + +/* Function: core_state_transition + Actual state machine. + + The state machine will continue scanning until either: + 1 - an invalid input is detcted. + 2 - a valid number has been detected. + + The input pointer is updated to point to the end of the token, and the end state is returned (either specific format determined or invalid). +*/ + +enum CORE_STATE core_state_transition( ee_u8 **instr , ee_u32 *transition_count) { + ee_u8 *str=*instr; + ee_u8 NEXT_SYMBOL; + enum CORE_STATE state=CORE_START; + for( ; *str && state != CORE_INVALID; str++ ) { + NEXT_SYMBOL = *str; + if (NEXT_SYMBOL==',') /* end of this input */ { + str++; + break; + } + switch(state) { + case CORE_START: + if(ee_isdigit(NEXT_SYMBOL)) { + state = CORE_INT; + } + else if( NEXT_SYMBOL == '+' || NEXT_SYMBOL == '-' ) { + state = CORE_S1; + } + else if( NEXT_SYMBOL == '.' ) { + state = CORE_FLOAT; + } + else { + state = CORE_INVALID; + transition_count[CORE_INVALID]++; + } + transition_count[CORE_START]++; + break; + case CORE_S1: + if(ee_isdigit(NEXT_SYMBOL)) { + state = CORE_INT; + transition_count[CORE_S1]++; + } + else if( NEXT_SYMBOL == '.' ) { + state = CORE_FLOAT; + transition_count[CORE_S1]++; + } + else { + state = CORE_INVALID; + transition_count[CORE_S1]++; + } + break; + case CORE_INT: + if( NEXT_SYMBOL == '.' ) { + state = CORE_FLOAT; + transition_count[CORE_INT]++; + } + else if(!ee_isdigit(NEXT_SYMBOL)) { + state = CORE_INVALID; + transition_count[CORE_INT]++; + } + break; + case CORE_FLOAT: + if( NEXT_SYMBOL == 'E' || NEXT_SYMBOL == 'e' ) { + state = CORE_S2; + transition_count[CORE_FLOAT]++; + } + else if(!ee_isdigit(NEXT_SYMBOL)) { + state = CORE_INVALID; + transition_count[CORE_FLOAT]++; + } + break; + case CORE_S2: + if( NEXT_SYMBOL == '+' || NEXT_SYMBOL == '-' ) { + state = CORE_EXPONENT; + transition_count[CORE_S2]++; + } + else { + state = CORE_INVALID; + transition_count[CORE_S2]++; + } + break; + case CORE_EXPONENT: + if(ee_isdigit(NEXT_SYMBOL)) { + state = CORE_SCIENTIFIC; + transition_count[CORE_EXPONENT]++; + } + else { + state = CORE_INVALID; + transition_count[CORE_EXPONENT]++; + } + break; + case CORE_SCIENTIFIC: + if(!ee_isdigit(NEXT_SYMBOL)) { + state = CORE_INVALID; + transition_count[CORE_INVALID]++; + } + break; + default: + break; + } + } + *instr=str; + return state; +}
rtl_sim/src-c/coremark_v1.0/core_state.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/coremark.h =================================================================== --- rtl_sim/src-c/coremark_v1.0/coremark.h (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/coremark.h (revision 145) @@ -0,0 +1,174 @@ +/* +Author : Shay Gal-On, EEMBC + +This file is part of EEMBC(R) and CoreMark(TM), which are Copyright (C) 2009 +All rights reserved. + +EEMBC CoreMark Software is a product of EEMBC and is provided under the terms of the +CoreMark License that is distributed with the official EEMBC COREMARK Software release. +If you received this EEMBC CoreMark Software without the accompanying CoreMark License, +you must discontinue use and download the official release from www.coremark.org. + +Also, if you are publicly displaying scores generated from the EEMBC CoreMark software, +make sure that you are in compliance with Run and Reporting rules specified in the accompanying readme.txt file. + +EEMBC +4354 Town Center Blvd. Suite 114-200 +El Dorado Hills, CA, 95762 +*/ +/* Topic: Description + This file contains declarations of the various benchmark functions. +*/ + +/* Configuration: TOTAL_DATA_SIZE + Define total size for data algorithms will operate on +*/ +#ifndef TOTAL_DATA_SIZE +#define TOTAL_DATA_SIZE 2*1000 +#endif + +#define SEED_ARG 0 +#define SEED_FUNC 1 +#define SEED_VOLATILE 2 + +#define MEM_STATIC 0 +#define MEM_MALLOC 1 +#define MEM_STACK 2 + +#include "core_portme.h" + +#if HAS_STDIO +#include +#endif +#if HAS_PRINTF +#define ee_printf printf +#endif + +/* Actual benchmark execution in iterate */ +void *iterate(void *pres); + +/* Typedef: secs_ret + For machines that have floating point support, get number of seconds as a double. + Otherwise an unsigned int. +*/ +#if HAS_FLOAT +typedef double secs_ret; +#else +typedef ee_u32 secs_ret; +#endif + +#if MAIN_HAS_NORETURN +#define MAIN_RETURN_VAL +#define MAIN_RETURN_TYPE void +#else +#define MAIN_RETURN_VAL 0 +#define MAIN_RETURN_TYPE int +#endif + +void start_time(void); +void stop_time(void); +CORE_TICKS get_time(void); +secs_ret time_in_secs(CORE_TICKS ticks); + +/* Misc useful functions */ +ee_u16 crcu8(ee_u8 data, ee_u16 crc); +ee_u16 crc16(ee_s16 newval, ee_u16 crc); +ee_u16 crcu16(ee_u16 newval, ee_u16 crc); +ee_u16 crcu32(ee_u32 newval, ee_u16 crc); +ee_u8 check_data_types(); +void *portable_malloc(ee_size_t size); +void portable_free(void *p); +ee_s32 parseval(char *valstring); + +/* Algorithm IDS */ +#define ID_LIST (1<<0) +#define ID_MATRIX (1<<1) +#define ID_STATE (1<<2) +#define ALL_ALGORITHMS_MASK (ID_LIST|ID_MATRIX|ID_STATE) +#define NUM_ALGORITHMS 3 + +/* list data structures */ +typedef struct list_data_s { + ee_s16 data16; + ee_s16 idx; +} list_data; + +typedef struct list_head_s { + struct list_head_s *next; + struct list_data_s *info; +} list_head; + + +/*matrix benchmark related stuff */ +#define MATDAT_INT 1 +#if MATDAT_INT +typedef ee_s16 MATDAT; +typedef ee_s32 MATRES; +#else +typedef ee_f16 MATDAT; +typedef ee_f32 MATRES; +#endif + +typedef struct MAT_PARAMS_S { + int N; + MATDAT *A; + MATDAT *B; + MATRES *C; +} mat_params; + +/* state machine related stuff */ +/* List of all the possible states for the FSM */ +typedef enum CORE_STATE { + CORE_START=0, + CORE_INVALID, + CORE_S1, + CORE_S2, + CORE_INT, + CORE_FLOAT, + CORE_EXPONENT, + CORE_SCIENTIFIC, + NUM_CORE_STATES +} core_state_e ; + + +/* Helper structure to hold results */ +typedef struct RESULTS_S { + /* inputs */ + ee_s16 seed1; /* Initializing seed */ + ee_s16 seed2; /* Initializing seed */ + ee_s16 seed3; /* Initializing seed */ + void *memblock[4]; /* Pointer to safe memory location */ + ee_u32 size; /* Size of the data */ + ee_u32 iterations; /* Number of iterations to execute */ + ee_u32 execs; /* Bitmask of operations to execute */ + struct list_head_s *list; + mat_params mat; + /* outputs */ + ee_u16 crc; + ee_u16 crclist; + ee_u16 crcmatrix; + ee_u16 crcstate; + ee_s16 err; + /* ultithread specific */ + core_portable port; +} core_results; + +/* Multicore execution handling */ +#if (MULTITHREAD>1) +ee_u8 core_start_parallel(core_results *res); +ee_u8 core_stop_parallel(core_results *res); +#endif + +/* list benchmark functions */ +list_head *core_list_init(ee_u32 blksize, list_head *memblock, ee_s16 seed); +ee_u16 core_bench_list(core_results *res, ee_s16 finder_idx); + +/* state benchmark functions */ +void core_init_state(ee_u32 size, ee_s16 seed, ee_u8 *p); +ee_u16 core_bench_state(ee_u32 blksize, ee_u8 *memblock, + ee_s16 seed1, ee_s16 seed2, ee_s16 step, ee_u16 crc); + +/* matrix benchmark functions */ +ee_u32 core_init_matrix(ee_u32 blksize, void *memblk, ee_s32 seed, mat_params *p); +ee_u16 core_bench_matrix(mat_params *p, ee_s16 seed, ee_u16 crc); +
rtl_sim/src-c/coremark_v1.0/coremark.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/coremark_v1.0.v =================================================================== --- rtl_sim/src-c/coremark_v1.0/coremark_v1.0.v (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/coremark_v1.0.v (revision 145) @@ -0,0 +1,145 @@ +/*===========================================================================*/ +/* Copyright (C) 2001 Authors */ +/* */ +/* This source file may be used and distributed without restriction provided */ +/* that this copyright statement is not removed from the file and that any */ +/* derivative work contains the original copyright notice and the associated */ +/* disclaimer. */ +/* */ +/* This source file is free software; you can redistribute it and/or modify */ +/* it under the terms of the GNU Lesser General Public License as published */ +/* by the Free Software Foundation; either version 2.1 of the License, or */ +/* (at your option) any later version. */ +/* */ +/* This source is distributed in the hope that it will be useful, but WITHOUT*/ +/* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */ +/* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */ +/* License for more details. */ +/* */ +/* You should have received a copy of the GNU Lesser General Public License */ +/* along with this source; if not, write to the Free Software Foundation, */ +/* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ +/* */ +/*===========================================================================*/ +/* SANDBOX */ +/*---------------------------------------------------------------------------*/ +/* */ +/* Author(s): */ +/* - Olivier Girard, olgirard@gmail.com */ +/* */ +/*---------------------------------------------------------------------------*/ +/* $Rev: 19 $ */ +/* $LastChangedBy: olivier.girard $ */ +/* $LastChangedDate: 2009-08-04 23:47:15 +0200 (Tue, 04 Aug 2009) $ */ +/*===========================================================================*/ +`define NO_TIMEOUT + +time mclk_start_time, mclk_end_time; +real mclk_period, mclk_frequency; + +time coremark_start_time, coremark_end_time; +real coremark_per_sec; +real coremark_per_mhz; + +integer Number_Of_Iterations; + +initial + begin + $display(" ==============================================="); + $display("| START SIMULATION |"); + $display(" ==============================================="); + repeat(5) @(posedge mclk); + stimulus_done = 0; + + //--------------------------------------- + // Check CPU configuration + //--------------------------------------- + + if ((`PMEM_SIZE !== 24576) || (`DMEM_SIZE !== 16384)) + begin + $display(" ==============================================="); + $display("| SIMULATION ERROR |"); + $display("| |"); + $display("| Core must be configured for: |"); + $display("| - 24kB program memory |"); + $display("| - 16kB data memory |"); + $display(" ==============================================="); + $finish; + end + + //--------------------------------------- + // Number of benchmark iteration + // (Must match the C-code value) + //--------------------------------------- + + Number_Of_Iterations = 1; + + + //--------------------------------------- + // Measure clock period + //--------------------------------------- + repeat(100) @(posedge mclk); + $timeformat(-9, 3, " ns", 10); + @(posedge mclk); + mclk_start_time = $time; + @(posedge mclk); + mclk_end_time = $time; + @(posedge mclk); + mclk_period = mclk_end_time-mclk_start_time; + mclk_frequency = 1000/mclk_period; + $display("\nINFO-VERILOG: openMSP430 System clock frequency %f MHz", mclk_frequency); + + //--------------------------------------- + // Measure Dhrystone run time + //--------------------------------------- + + // Detect beginning of run + @(posedge p2_dout[1]); + coremark_start_time = $time; + $timeformat(-3, 3, " ms", 10); + $display("INFO-VERILOG: CoreMark loop started at %t ", coremark_start_time); + + // Detect end of run + @(negedge p2_dout[1]); + coremark_end_time = $time; + $timeformat(-3, 3, " ms", 10); + $display("INFO-VERILOG: Coremark loop ended at %t ", coremark_end_time); + + // Compute results + $timeformat(-9, 3, " ns", 10); + coremark_per_sec = coremark_end_time - coremark_start_time; + coremark_per_sec = 1000000000 / coremark_per_sec; + coremark_per_sec = Number_Of_Iterations*coremark_per_sec; + coremark_per_mhz = coremark_per_sec / mclk_frequency; + + // Report results + $display("\INFO-VERILOG: CoreMark ticks : %d", {p6_din, p5_din, p4_din, p3_din}); + $display("\INFO-VERILOG: CoreMark per second : %f", coremark_per_sec); + $display("\INFO-VERILOG: CoreMark per MHz : %f\n\n", coremark_per_mhz); + + //--------------------------------------- + // Wait for the end of C-code execution + //--------------------------------------- + @(posedge p2_dout[7]); + + stimulus_done = 1; + + $display(" ==============================================="); + $display("| SIMULATION DONE |"); + $display("| (stopped through verilog stimulus) |"); + $display(" ==============================================="); + $finish; + + end + +// Display stuff from the C-program +always @(p2_dout[0]) + begin + $write("%s", p1_dout); + end + + +// Time tick counter +always @(negedge mclk or posedge puc_rst) + if (puc_rst) {p6_din, p5_din, p4_din, p3_din} <= 32'h0000_0000; + else if (p2_dout[1]) {p6_din, p5_din, p4_din, p3_din} <= {p6_din, p5_din, p4_din, p3_din} + 32'h1;
rtl_sim/src-c/coremark_v1.0/coremark_v1.0.v Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/readme.txt =================================================================== --- rtl_sim/src-c/coremark_v1.0/readme.txt (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/readme.txt (revision 145) @@ -0,0 +1,227 @@ +File: CoreMark + +Topic: Welcome +Copyright © 2009 EEMBC All rights reserved. +CoreMark is a trademark of EEMBC and EEMBC is a registered trademark of the Embedded Microprocessor Benchmark Consortium. + +CoreMark’s primary goals are simplicity and providing a method for testing only a processor’s core features. + +For more information about EEMBC's comprehensive embedded benchmark suites, please see www.eembc.org. + +Topic: Building and running + Download the release files from the www.coremark.org. + You can verify the download using the coremark_.md5 file + > md5sum -c coremark_.md5 + + Unpack the distribution (tar -vzxf coremark_.tgz && tar -vzxf coremark__docs.tgz) + then change to the coremark_ folder. + + To build and run the benchmark, type + > make + Full results are available in the files run1.log and run2.log. + CoreMark result can be found in run1.log. + + For self hosted Linux or Cygwin platforms, a simple make should work. + + Cross Compile: + For cross compile platforms please adjust , (and possibly ) + according to the specific platform used. + When porting to a new platform, it is recommended to copy one of the default port folders + (e.g. mkdir && cp linux/* ), adjust the porting files, and run + > make PORT_DIR= + + Systems without make: + The following files need to be compiled: + - + - + - + - + - + - / + + For example + > gcc -O2 -o coremark.exe core_list_join.c core_main.c core_matrix.c core_state.c core_util.c simple/core_portme.c -DPERFORMANCE_RUN=1 -DITERATIONS=1000 + > ./coremark.exe > run1.log + The above will compile the benchmark for a performance run and 1000 iterations. Output is redirected to run1.log. + + Make targets: + run - Default target, creates run1.log and run2.log. + run1.log - Run the benchmark with performance parameters, and output to run1.log + run2.log - Run the benchmark with validation parameters, and output to run2.log + run3.log - Run the benchmark with profile generation parameters, and output to run3.log + compile - compile the benchmark executable + link - link the benchmark executable + check - test MD5 of sources that may not be modified + clean - clean temporary files + + ITERATIONS: + By default, the benchmark will run between 10-100 seconds. + To override, use ITERATIONS=N + > make ITERATIONS=10 + Will run the benchmark for 10 iterations. + It is recommended to set a specific number of iterations in certain situations e.g.: + - Running with a simulator + - Measuring power/energy + - Timing cannot be restarted + + Minimum required run time: + Results are only valid for reporting if the benchmark ran for at least 10 secs! + + XCFLAGS: + To add compiler flags from the command line, use XCFLAGS e.g. + > make XCFLAGS="-g -DMULTITHREAD=4 -DUSE_FORK=1" + + o CORE_DEBUG + + Define to compile for a debug run if you get incorrect CRC. + > make XCFLAGS="-DCORE_DEBUG=1" + + o Parallel Execution + + Use XCFLAGS=-DMULTITHREAD=N where N is number of threads to run in parallel. + Several implementations are available to execute in multiple contexts, + or you can implement your own in . + > make XCFLAGS="-DMULTITHREAD=4 -DUSE_PTHREAD" + Above will compile the benchmark for execution on 4 cores, using POSIX Threads API. + + REBUILD: + To force rebuild, add the flag REBUILD to the command line + > make REBUILD=1 + + Check core_portme.mak for more important options. + + Run parameters for the benchmark executable: + Coremark executable takes several parameters as follows (if main accepts arguments). + 1st - A seed value used for initialization of data. + 2nd - A seed value used for initialization of data. + 3rd - A seed value used for initialization of data. + 4th - Number of iterations (0 for auto : default value) + 5th - Reserved for internal use. + 6th - Reserved for internal use. + 7th - For malloc users only, ovreride the size of the input data buffer. + + The run target from make will run coremark with 2 different data initialization seeds. + + Alternative parameters: + If not using malloc or command line arguments are not supported, the buffer size + for the algorithms must be defined via the compiler define TOTAL_DATA_SIZE. + TOTAL_DATA_SIZE must be set to 2000 bytes (default) for standard runs. + The default for such a target when testing different configurations could be ... + > make XCFLAGS="-DTOTAL_DATA_SIZE=6000 -DMAIN_HAS_NOARGC=1" + +Topic: Documentation + When you unpack the documentation (tar -vzxf coremark__docs.tgz) a docs folder will be created. + Check the file docs/html/index.html and the website http://www.coremark.org for more info. + +Topic: Submitting results + CoreMark results can be submitted on the web. + + Open a web browser and go to http://www.coremark.org/benchmark/index.php?pg=benchmark + Select the link to add a new score and follow the instructions. + +Topic: Run rules + What is and is not allowed. + + Required: + 1 - The benchmark needs to run for at least 10 seconds. + 2 - All validation must succeed for seeds 0,0,0x66 and 0x3415,0x3415,0x66, + buffer size of 2000 bytes total. + o If not using command line arguments to main: + > make XCFLAGS="-DPERFORMANCE_RUN=1" REBUILD=1 run1.log + > make XCFLAGS="-DVALIDATION_RUN=1" REBUILD=1 run2.log + 3 - If using profile guided optimization, profile must be generated using seeds of 8,8,8, + and buffer size of 1200 bytes total. + > make XCFLAGS="-DTOTAL_DATA_SIZE=1200 -DPROFILE_RUN=1" REBUILD=1 run3.log + 4 - All source files must be compiled with the same flags. + 5 - All data type sizes must match size in bits such that: + o ee_u8 is an 8 bits datatype. + o ee_s16 is an 16 bits datatype. + o ee_u16 is an 16 bits datatype. + o ee_s32 is an 32 bits datatype. + o ee_u32 is an 32 bits datatype. + + Allowed: + - Changing number of iterations + - Changing toolchain and build/load/run options + - Changing method of acquiring a data memory block + - Changing the method of acquiring seed values + - Changing implementation in core_portme.c + - Changing configuration values in core_portme.h + - Changing core_portme.mak + + Not allowed: + - Changing of source file other then core_portme* (use make check to validate) + +Topic: Reporting rules + How to report results on a data sheet? + + CoreMark 1.0 : N / C [/ P] [/ M] + + N - Number of iterations per second with seeds 0,0,0x66,size=2000) + C - Compiler version and flags + P - Parameters such as data and code allocation specifics + - This parameter *may* be omitted if all data was allocated on the heap in RAM. + - This parameter *may not* be omitted when reporting CoreMark/MHz + M - Type of parallel execution (if used) and number of contexts + This parameter may be omitted if parallel execution was not used. + + e.g. + > CoreMark 1.0 : 128 / GCC 4.1.2 -O2 -fprofile-use / Heap in TCRAM / FORK:2 + or + > CoreMark 1.0 : 1400 / GCC 3.4 -O4 + + If reporting scaling results, the results must be reported as follows: + + CoreMark/MHz 1.0 : N / C / P [/ M] + + P - When reporting scaling results, memory parameter must also indicate memory frequency:core frequency ratio. + - If the core has cache and cache frequency to core frequency ratio is configurable, that must also be included. + + e.g. + > CoreMark/MHz 1.0 : 1.47 / GCC 4.1.2 -O2 / DDR3(Heap) 30:1 Memory 1:1 Cache + + +Topic: Log File Format + The log files have the following format +(start example) +2K performance run parameters for coremark. (Run type) +CoreMark Size : 666 (Buffer size) +Total ticks : 25875 (platform dependent value) +Total time (secs) : 25.875000 (actual time in seconds) +Iterations/Sec : 3864.734300 (Performance value to report) +Iterations : 100000 (number of iterations used) +Compiler version : GCC3.4.4 (Compiler and version) +Compiler flags : -O2 (Compiler and linker flags) +Memory location : Code in flash, data in on chip RAM +seedcrc : 0xe9f5 (identifier for the input seeds) +[0]crclist : 0xe714 (validation for list part) +[0]crcmatrix : 0x1fd7 (validation for matrix part) +[0]crcstate : 0x8e3a (validation for state part) +[0]crcfinal : 0x33ff (iteration dependent output) +Correct operation validated. See readme.txt for run and reporting rules. (*Only when run is successful*) +CoreMark 1.0 : 6508.490622 / GCC3.4.4 -O2 / Heap (*Only on a successful performance run*) +(end example) + +Topic: Legal +See LICENSE.txt or the word document file under docs/LICENSE.doc. +For more information on your legal rights to use this benchmark, please see +http://www.coremark.org/download/register.php?pg=register + +Topic: Credits +Many thanks to all of the individuals who helped with the development or testing of CoreMark including (Sorted by company name) +o Alan Anderson, ADI +o Adhikary Rajiv, ADI +o Elena Stohr, ARM +o Ian Rickards, ARM +o Andrew Pickard, ARM +o Trent Parker, CAVIUM +o Shay Gal-On, EEMBC +o Markus Levy, EEMBC +o Ron Olson, IBM +o Eyal Barzilay, MIPS +o Jens Eltze, NEC +o Hirohiko Ono, NEC +o Ulrich Drees, NEC +o Frank Roscheda, NEC +o Rob Cosaro, NXP +o Shumpei Kawasaki, RENESAS
rtl_sim/src-c/coremark_v1.0/readme.txt Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/Makefile =================================================================== --- rtl_sim/src-c/coremark_v1.0/Makefile (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/Makefile (revision 145) @@ -0,0 +1,142 @@ +#Author : Shay Gal-On, EEMBC +# +#This file is part of EEMBC(R) and CoreMark(TM), which are Copyright (C) 2009 +#All rights reserved. +# +#EEMBC CoreMark Software is a product of EEMBC and is provided under the terms of the +#CoreMark License that is distributed with the official EEMBC COREMARK Software release. +#If you received this EEMBC CoreMark Software without the accompanying CoreMark License, +#you must discontinue use and download the official release from www.coremark.org. +# +#Also, if you are publicly displaying scores generated from the EEMBC CoreMark software, +#make sure that you are in compliance with Run and Reporting rules specified in the accompanying readme.txt file. +# +#EEMBC +#4354 Town Center Blvd. Suite 114-200 +#El Dorado Hills, CA, 95762 + +PORT_DIR=msp430 + +# Make sure the default target is to simply build and run the benchmark. +RSTAMP = v1.0 + +.PHONY: run score +run: $(OUTFILE) rerun score + +score: + @echo "Check run1.log and run2.log for results." + @echo "See readme.txt for run and reporting rules." + +ifndef PORT_DIR +# Ports for a couple of common self hosted platforms +UNAME=$(shell if [[ `uname 2> /dev/null` ]] ; then uname ; fi) +ifneq (,$(findstring CYGWIN,$(UNAME))) +PORT_DIR=cygwin +endif +ifneq (,$(findstring Linux,$(UNAME))) +MACHINE=$(shell uname -m) +ifneq (,$(findstring 64,$(MACHINE))) +PORT_DIR=linux64 +else +PORT_DIR=linux +endif +endif +endif +ifndef PORT_DIR +$(error PLEASE define PORT_DIR! (e.g. make PORT_DIR=simple)) +endif +vpath %.c $(PORT_DIR) +vpath %.h $(PORT_DIR) +vpath %.mak $(PORT_DIR) +include $(PORT_DIR)/core_portme.mak + +ifndef ITERATIONS +ITERATIONS=0 +endif +ifdef REBUILD +FORCE_REBUILD=force_rebuild +endif + +CFLAGS += -DITERATIONS=$(ITERATIONS) + +CORE_FILES = core_list_join core_main core_matrix core_state core_util +ORIG_SRCS = $(addsuffix .c,$(CORE_FILES)) +SRCS = $(ORIG_SRCS) $(PORT_SRCS) +OBJS = $(addprefix $(OPATH),$(addsuffix $(OEXT),$(CORE_FILES)) $(PORT_OBJS)) +OUTNAME = coremark_v1.0$(EXE) +OUTFILE = $(OPATH)$(OUTNAME) +LOUTCMD = $(OFLAG) $(OUTFILE) $(LFLAGS_END) +OUTCMD = $(OUTFLAG) $(OUTFILE) $(LFLAGS_END) + +HEADERS = coremark.h +CHECK_FILES = $(ORIG_SRCS) $(HEADERS) + +$(OPATH): + $(MKDIR) $(OPATH) + +.PHONY: compile link +ifdef SEPARATE_COMPILE +$(OPATH)$(PORT_DIR): + $(MKDIR) $(OPATH)$(PORT_DIR) + +compile: $(OPATH) $(OPATH)$(PORT_DIR) $(OBJS) $(HEADERS) +link: compile + $(LD) $(LFLAGS) $(XLFLAGS) $(OBJS) $(LOUTCMD) + +else + +compile: $(OPATH) $(SRCS) $(HEADERS) + $(CC) $(CFLAGS) $(XCFLAGS) $(SRCS) $(OUTCMD) +link: compile + @echo "Link performed along with compile" + +endif + +$(OUTFILE): $(SRCS) $(HEADERS) Makefile core_portme.mak $(FORCE_REBUILD) + $(MAKE) port_prebuild + $(MAKE) link + $(MAKE) port_postbuild + +.PHONY: rerun +rerun: + $(MAKE) XCFLAGS="$(XCFLAGS) -DPERFORMANCE_RUN=1" load run1.log +# $(MAKE) XCFLAGS="$(XCFLAGS) -DVALIDATION_RUN=1" load run2.log + +PARAM1=$(PORT_PARAMS) 0x0 0x0 0x66 $(ITERATIONS) +PARAM2=$(PORT_PARAMS) 0x3415 0x3415 0x66 $(ITERATIONS) +PARAM3=$(PORT_PARAMS) 8 8 8 $(ITERATIONS) + +run1.log-PARAM=$(PARAM1) 7 1 2000 +run2.log-PARAM=$(PARAM2) 7 1 2000 +run3.log-PARAM=$(PARAM3) 7 1 1200 + +run1.log run2.log run3.log: load + $(MAKE) port_prerun + $(RUN) $(OUTFILE) $($(@)-PARAM) > $(OPATH)$@ + $(MAKE) port_postrun + +.PHONY: gen_pgo_data +gen_pgo_data: run3.log + +.PHONY: load +load: $(OUTFILE) + $(MAKE) port_preload + $(LOAD) $(OUTFILE) + $(MAKE) port_postload + +.PHONY: clean +clean: + rm -f $(OUTFILE) $(OPATH)*.log *.info $(OPATH)index.html $(PORT_CLEAN) + +.PHONY: force_rebuild +force_rebuild: + echo "Forcing Rebuild" + +.PHONY: check +check: + md5sum -c coremark.md5 + +ifdef ETC +# Targets related to testing and releasing CoreMark. Not part of the general release! +include Makefile.internal +endif
rtl_sim/src-c/coremark_v1.0/Makefile Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/core_main.c =================================================================== --- rtl_sim/src-c/coremark_v1.0/core_main.c (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/core_main.c (revision 145) @@ -0,0 +1,356 @@ +/* +Author : Shay Gal-On, EEMBC + +This file is part of EEMBC(R) and CoreMark(TM), which are Copyright (C) 2009 +All rights reserved. + +EEMBC CoreMark Software is a product of EEMBC and is provided under the terms of the +CoreMark License that is distributed with the official EEMBC COREMARK Software release. +If you received this EEMBC CoreMark Software without the accompanying CoreMark License, +you must discontinue use and download the official release from www.coremark.org. + +Also, if you are publicly displaying scores generated from the EEMBC CoreMark software, +make sure that you are in compliance with Run and Reporting rules specified in the accompanying readme.txt file. + +EEMBC +4354 Town Center Blvd. Suite 114-200 +El Dorado Hills, CA, 95762 +*/ +/* File: core_main.c + This file contains the framework to acquire a block of memory, seed initial parameters, tun t he benchmark and report the results. +*/ +#include "coremark.h" + +/* Function: iterate + Run the benchmark for a specified number of iterations. + + Operation: + For each type of benchmarked algorithm: + a - Initialize the data block for the algorithm. + b - Execute the algorithm N times. + + Returns: + NULL. +*/ +static ee_u16 list_known_crc[] = {(ee_u16)0xd4b0,(ee_u16)0x3340,(ee_u16)0x6a79,(ee_u16)0xe714,(ee_u16)0xe3c1}; +static ee_u16 matrix_known_crc[] = {(ee_u16)0xbe52,(ee_u16)0x1199,(ee_u16)0x5608,(ee_u16)0x1fd7,(ee_u16)0x0747}; +static ee_u16 state_known_crc[] = {(ee_u16)0x5e47,(ee_u16)0x39bf,(ee_u16)0xe5a4,(ee_u16)0x8e3a,(ee_u16)0x8d84}; +void *iterate(void *pres) { + ee_u32 i; + ee_u16 crc; + core_results *res=(core_results *)pres; + ee_u32 iterations=res->iterations; + res->crc=0; + res->crclist=0; + res->crcmatrix=0; + res->crcstate=0; + + for (i=0; icrc=crcu16(crc,res->crc); + crc=core_bench_list(res,-1); + res->crc=crcu16(crc,res->crc); + if (i==0) res->crclist=res->crc; + } + return NULL; +} + +#if (SEED_METHOD==SEED_ARG) +ee_s32 get_seed_args(int i, int argc, char *argv[]); +#define get_seed(x) (ee_s16)get_seed_args(x,argc,argv) +#define get_seed_32(x) get_seed_args(x,argc,argv) +#else /* via function or volatile */ +ee_s32 get_seed_32(int i); +#define get_seed(x) (ee_s16)get_seed_32(x) +#endif + +#if (MEM_METHOD==MEM_STATIC) +ee_u8 static_memblk[TOTAL_DATA_SIZE]; +#endif +char *mem_name[3] = {"Static","Heap","Stack"}; +/* Function: main + Main entry routine for the benchmark. + This function is responsible for the following steps: + + 1 - Initialize input seeds from a source that cannot be determined at compile time. + 2 - Initialize memory block for use. + 3 - Run and time the benchmark. + 4 - Report results, testing the validity of the output if the seeds are known. + + Arguments: + 1 - first seed : Any value + 2 - second seed : Must be identical to first for iterations to be identical + 3 - third seed : Any value, should be at least an order of magnitude less then the input size, but bigger then 32. + 4 - Iterations : Special, if set to 0, iterations will be automatically determined such that the benchmark will run between 10 to 100 secs + +*/ + +#if MAIN_HAS_NOARGC +MAIN_RETURN_TYPE main(void) { + int argc=0; + char *argv[1]; +#else +MAIN_RETURN_TYPE main(int argc, char *argv[]) { +#endif + ee_u16 i,j=0,num_algorithms=0; + ee_s16 known_id=-1,total_errors=0; + ee_u16 seedcrc=0; + CORE_TICKS total_time; + core_results results[MULTITHREAD]; +#if (MEM_METHOD==MEM_STACK) + ee_u8 stack_memblock[TOTAL_DATA_SIZE*MULTITHREAD]; +#endif + /* first call any initializations needed */ + portable_init(&(results[0].port), &argc, argv); + /* First some checks to make sure benchmark will run ok */ + if (sizeof(struct list_head_s)>128) { + ee_printf("list_head structure too big for comparable data!\n"); + return MAIN_RETURN_VAL; + } + results[0].seed1=get_seed(1); + results[0].seed2=get_seed(2); + results[0].seed3=get_seed(3); + results[0].iterations=get_seed_32(4); +#if CORE_DEBUG + results[0].iterations=1; +#endif + results[0].execs=get_seed_32(5); + if (results[0].execs==0) { /* if not supplied, execute all algorithms */ + results[0].execs=ALL_ALGORITHMS_MASK; + } + /* put in some default values based on one seed only for easy testing */ + if ((results[0].seed1==0) && (results[0].seed2==0) && (results[0].seed3==0)) { /* validation run */ + results[0].seed1=0; + results[0].seed2=0; + results[0].seed3=0x66; + } + if ((results[0].seed1==1) && (results[0].seed2==0) && (results[0].seed3==0)) { /* perfromance run */ + results[0].seed1=0x3415; + results[0].seed2=0x3415; + results[0].seed3=0x66; + } +#if (MEM_METHOD==MEM_STATIC) + results[0].memblock[0]=(void *)static_memblk; + results[0].size=TOTAL_DATA_SIZE; + results[0].err=0; + #if (MULTITHREAD>1) + #error "Cannot use a static data area with multiple contexts!" + #endif +#elif (MEM_METHOD==MEM_MALLOC) + for (i=0 ; i1) + if (default_num_contexts>MULTITHREAD) { + default_num_contexts=MULTITHREAD; + } + for (i=0 ; i=0) { + for (i=0 ; i 0) + ee_printf("Iterations/Sec : %f\n",default_num_contexts*results[0].iterations/time_in_secs(total_time)); +#else + ee_printf("Total time (secs): %d\n",time_in_secs(total_time)); + if (time_in_secs(total_time) > 0) + ee_printf("Iterations/Sec : %d\n",default_num_contexts*results[0].iterations/time_in_secs(total_time)); +#endif + if (time_in_secs(total_time) < 10) { + ee_printf("ERROR! Must execute for at least 10 secs for a valid result!\n"); + total_errors++; + } + + ee_printf("Iterations : %lu\n",(ee_u32)default_num_contexts*results[0].iterations); + ee_printf("Compiler version : %s\n",COMPILER_VERSION); + ee_printf("Compiler flags : %s\n",COMPILER_FLAGS); +#if (MULTITHREAD>1) + ee_printf("Parallel %s : %d\n",PARALLEL_METHOD,default_num_contexts); +#endif + ee_printf("Memory location : %s\n",MEM_LOCATION); + /* output for verification */ + ee_printf("seedcrc : 0x%04x\n",seedcrc); + if (results[0].execs & ID_LIST) + for (i=0 ; i1) + ee_printf(" / %d:%s",default_num_contexts,PARALLEL_METHOD); +#endif + ee_printf("\n"); + } +#endif + } + if (total_errors>0) + ee_printf("Errors detected\n"); + if (total_errors<0) + ee_printf("Cannot validate operation for these seed values, please compare with results on a known platform.\n"); + +#if (MEM_METHOD==MEM_MALLOC) + for (i=0 ; i
rtl_sim/src-c/coremark_v1.0/core_main.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/coremark_v1.0/core_matrix.c =================================================================== --- rtl_sim/src-c/coremark_v1.0/core_matrix.c (nonexistent) +++ rtl_sim/src-c/coremark_v1.0/core_matrix.c (revision 145) @@ -0,0 +1,308 @@ +/* +Author : Shay Gal-On, EEMBC + +This file is part of EEMBC(R) and CoreMark(TM), which are Copyright (C) 2009 +All rights reserved. + +EEMBC CoreMark Software is a product of EEMBC and is provided under the terms of the +CoreMark License that is distributed with the official EEMBC COREMARK Software release. +If you received this EEMBC CoreMark Software without the accompanying CoreMark License, +you must discontinue use and download the official release from www.coremark.org. + +Also, if you are publicly displaying scores generated from the EEMBC CoreMark software, +make sure that you are in compliance with Run and Reporting rules specified in the accompanying readme.txt file. + +EEMBC +4354 Town Center Blvd. Suite 114-200 +El Dorado Hills, CA, 95762 +*/ +#include "coremark.h" +/* +Topic: Description + Matrix manipulation benchmark + + This very simple algorithm forms the basis of many more complex algorithms. + + The tight inner loop is the focus of many optimizations (compiler as well as hardware based) + and is thus relevant for embedded processing. + + The total available data space will be divided to 3 parts: + NxN Matrix A - initialized with small values (upper 3/4 of the bits all zero). + NxN Matrix B - initialized with medium values (upper half of the bits all zero). + NxN Matrix C - used for the result. + + The actual values for A and B must be derived based on input that is not available at compile time. +*/ +ee_s16 matrix_test(ee_u32 N, MATRES *C, MATDAT *A, MATDAT *B, MATDAT val); +ee_s16 matrix_sum(ee_u32 N, MATRES *C, MATDAT clipval); +void matrix_mul_const(ee_u32 N, MATRES *C, MATDAT *A, MATDAT val); +void matrix_mul_vect(ee_u32 N, MATRES *C, MATDAT *A, MATDAT *B); +void matrix_mul_matrix(ee_u32 N, MATRES *C, MATDAT *A, MATDAT *B); +void matrix_mul_matrix_bitextract(ee_u32 N, MATRES *C, MATDAT *A, MATDAT *B); +void matrix_add_const(ee_u32 N, MATDAT *A, MATDAT val); + +#define matrix_test_next(x) (x+1) +#define matrix_clip(x,y) ((y) ? (x) & 0x0ff : (x) & 0x0ffff) +#define matrix_big(x) (0xf000 | (x)) +#define bit_extract(x,from,to) (((x)>>(from)) & (~(0xffffffff << (to)))) + +#if CORE_DEBUG +void printmat(MATDAT *A, ee_u32 N, char *name) { + ee_u32 i,j; + ee_printf("Matrix %s [%dx%d]:\n",name,N,N); + for (i=0; i N times, + changing the matrix values slightly by a constant amount each time. +*/ +ee_u16 core_bench_matrix(mat_params *p, ee_s16 seed, ee_u16 crc) { + ee_u32 N=p->N; + MATRES *C=p->C; + MATDAT *A=p->A; + MATDAT *B=p->B; + MATDAT val=(MATDAT)seed; + + crc=crc16(matrix_test(N,C,A,B,val),crc); + + return crc; +} + +/* Function: matrix_test + Perform matrix manipulation. + + Parameters: + N - Dimensions of the matrix. + C - memory for result matrix. + A - input matrix + B - operator matrix (not changed during operations) + + Returns: + A CRC value that captures all results calculated in the function. + In particular, crc of the value calculated on the result matrix + after each step by . + + Operation: + + 1 - Add a constant value to all elements of a matrix. + 2 - Multiply a matrix by a constant. + 3 - Multiply a matrix by a vector. + 4 - Multiply a matrix by a matrix. + 5 - Add a constant value to all elements of a matrix. + + After the last step, matrix A is back to original contents. +*/ +ee_s16 matrix_test(ee_u32 N, MATRES *C, MATDAT *A, MATDAT *B, MATDAT val) { + ee_u16 crc=0; + MATDAT clipval=matrix_big(val); + + matrix_add_const(N,A,val); /* make sure data changes */ +#if CORE_DEBUG + printmat(A,N,"matrix_add_const"); +#endif + matrix_mul_const(N,C,A,val); + crc=crc16(matrix_sum(N,C,clipval),crc); +#if CORE_DEBUG + printmatC(C,N,"matrix_mul_const"); +#endif + matrix_mul_vect(N,C,A,B); + crc=crc16(matrix_sum(N,C,clipval),crc); +#if CORE_DEBUG + printmatC(C,N,"matrix_mul_vect"); +#endif + matrix_mul_matrix(N,C,A,B); + crc=crc16(matrix_sum(N,C,clipval),crc); +#if CORE_DEBUG + printmatC(C,N,"matrix_mul_matrix"); +#endif + matrix_mul_matrix_bitextract(N,C,A,B); + crc=crc16(matrix_sum(N,C,clipval),crc); +#if CORE_DEBUG + printmatC(C,N,"matrix_mul_matrix_bitextract"); +#endif + + matrix_add_const(N,A,-val); /* return matrix to initial value */ + return crc; +} + +/* Function : matrix_init + Initialize the memory block for matrix benchmarking. + + Parameters: + blksize - Size of memory to be initialized. + memblk - Pointer to memory block. + seed - Actual values chosen depend on the seed parameter. + p - pointers to containing initialized matrixes. + + Returns: + Matrix dimensions. + + Note: + The seed parameter MUST be supplied from a source that cannot be determined at compile time +*/ +ee_u32 core_init_matrix(ee_u32 blksize, void *memblk, ee_s32 seed, mat_params *p) { + ee_u32 N=0; + MATDAT *A; + MATDAT *B; + ee_s32 order=1; + MATDAT val; + ee_u32 i=0,j=0; + if (seed==0) + seed=1; + while (jA=A; + p->B=B; + p->C=(MATRES *)align_mem(B+N*N); + p->N=N; +#if CORE_DEBUG + printmat(A,N,"A"); + printmat(B,N,"B"); +#endif + return N; +} + +/* Function: matrix_sum + Calculate a function that depends on the values of elements in the matrix. + + For each element, accumulate into a temporary variable. + + As long as this value is under the parameter clipval, + add 1 to the result if the element is bigger then the previous. + + Otherwise, reset the accumulator and add 10 to the result. +*/ +ee_s16 matrix_sum(ee_u32 N, MATRES *C, MATDAT clipval) { + MATRES tmp=0,prev=0,cur=0; + ee_s16 ret=0; + ee_u32 i,j; + for (i=0; iclipval) { + ret+=10; + tmp=0; + } else { + ret += (cur>prev) ? 1 : 0; + } + prev=cur; + } + } + return ret; +} + +/* Function: matrix_mul_const + Multiply a matrix by a constant. + This could be used as a scaler for instance. +*/ +void matrix_mul_const(ee_u32 N, MATRES *C, MATDAT *A, MATDAT val) { + ee_u32 i,j; + for (i=0; i
rtl_sim/src-c/coremark_v1.0/core_matrix.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/omsp_func.h =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/omsp_func.h (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/omsp_func.h (revision 145) @@ -0,0 +1,124 @@ +/*===========================================================================*/ +/* Copyright (C) 2001 Authors */ +/* */ +/* This source file may be used and distributed without restriction provided */ +/* that this copyright statement is not removed from the file and that any */ +/* derivative work contains the original copyright notice and the associated */ +/* disclaimer. */ +/* */ +/* This source file is free software; you can redistribute it and/or modify */ +/* it under the terms of the GNU Lesser General Public License as published */ +/* by the Free Software Foundation; either version 2.1 of the License, or */ +/* (at your option) any later version. */ +/* */ +/* This source is distributed in the hope that it will be useful, but WITHOUT*/ +/* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */ +/* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */ +/* License for more details. */ +/* */ +/* You should have received a copy of the GNU Lesser General Public License */ +/* along with this source; if not, write to the Free Software Foundation, */ +/* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ +/* */ +/*===========================================================================*/ +/* OMSP_FUNC HEADER FILE */ +/*---------------------------------------------------------------------------*/ +/* */ +/* Author(s): */ +/* - Olivier Girard, olgirard@gmail.com */ +/* */ +/*---------------------------------------------------------------------------*/ +/* $Rev: 19 $ */ +/* $LastChangedBy: olivier.girard $ */ +/* $LastChangedDate: 2009-08-04 23:47:15 +0200 (Tue, 04 Aug 2009) $ */ +/*===========================================================================*/ + +//============================================================================= +// PERIPHERALS REGISTER DEFINITIONS +//============================================================================= + +//---------------------------------------------------------- +// SPECIAL FUNCTION REGISTERS +//---------------------------------------------------------- +#define IE1 (*(volatile unsigned char *) 0x0000) +#define IFG1 (*(volatile unsigned char *) 0x0002) + +#define CPU_ID_LO (*(volatile unsigned char *) 0x0004) +#define CPU_ID_HI (*(volatile unsigned char *) 0x0006) + + +//---------------------------------------------------------- +// GPIOs +//---------------------------------------------------------- +#define P1IN (*(volatile unsigned char *) 0x0020) +#define P1OUT (*(volatile unsigned char *) 0x0021) +#define P1DIR (*(volatile unsigned char *) 0x0022) +#define P1IFG (*(volatile unsigned char *) 0x0023) +#define P1IES (*(volatile unsigned char *) 0x0024) +#define P1IE (*(volatile unsigned char *) 0x0025) +#define P1SEL (*(volatile unsigned char *) 0x0026) + +#define P2IN (*(volatile unsigned char *) 0x0028) +#define P2OUT (*(volatile unsigned char *) 0x0029) +#define P2DIR (*(volatile unsigned char *) 0x002A) +#define P2IFG (*(volatile unsigned char *) 0x002B) +#define P2IES (*(volatile unsigned char *) 0x002C) +#define P2IE (*(volatile unsigned char *) 0x002D) +#define P2SEL (*(volatile unsigned char *) 0x002E) + +#define P3IN (*(volatile unsigned char *) 0x0018) +#define P3OUT (*(volatile unsigned char *) 0x0019) +#define P3DIR (*(volatile unsigned char *) 0x001A) +#define P3SEL (*(volatile unsigned char *) 0x001B) + +#define P4IN (*(volatile unsigned char *) 0x001C) +#define P4OUT (*(volatile unsigned char *) 0x001D) +#define P4DIR (*(volatile unsigned char *) 0x001E) +#define P4SEL (*(volatile unsigned char *) 0x001F) + +#define P5IN (*(volatile unsigned char *) 0x0030) +#define P5OUT (*(volatile unsigned char *) 0x0031) +#define P5DIR (*(volatile unsigned char *) 0x0032) +#define P5SEL (*(volatile unsigned char *) 0x0033) + +#define P6IN (*(volatile unsigned char *) 0x0034) +#define P6OUT (*(volatile unsigned char *) 0x0035) +#define P6DIR (*(volatile unsigned char *) 0x0036) +#define P6SEL (*(volatile unsigned char *) 0x0037) + + +//---------------------------------------------------------- +// WATCHDOG TIMER +//---------------------------------------------------------- + +// Addresses +#define WDTCTL (*(volatile unsigned int *) 0x0120) + +// Bit masks +#define WDTIS0 (0x0001) +#define WDTIS1 (0x0002) +#define WDTSSEL (0x0004) +#define WDTCNTCL (0x0008) +#define WDTTMSEL (0x0010) +#define WDTNMI (0x0020) +#define WDTNMIES (0x0040) +#define WDTHOLD (0x0080) +#define WDTPW (0x5A00) + + +//============================================================================= +// MACROS +//============================================================================= + +#define STOP_WATCHDOG WDTCTL = WDTPW | WDTHOLD + +#define START_TIME P3OUT = 0x01 +#define END_TIME P3OUT = 0x00 + +#define DHRYSTONE_DONE P4OUT = 0x01 + +//============================================================================= +// FUNCTIONS +//============================================================================= + +int putchar (int txdata);
rtl_sim/src-c/dhrystone_4mcu/omsp_func.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/original_files/timers_b.c =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/original_files/timers_b.c (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/original_files/timers_b.c (revision 145) @@ -0,0 +1,479 @@ +/*****************************************************/ +/* Various timer routines. */ +/* Al Aburto, aburto@nosc.mil, 18 Feb 1997 */ +/* */ +/* t = dtime() outputs the current time in seconds. */ +/* Use CAUTION as some of these routines will mess */ +/* up when timing across the hour mark!!! */ +/* */ +/* For timing I use the 'user' time whenever */ +/* possible. Using 'user+sys' time is a separate */ +/* issue. */ +/* */ +/* Example Usage: */ +/* [timer options added here] */ +/* main() */ +/* { */ +/* double starttime,benchtime,dtime(); */ +/* */ +/* starttime = dtime(); */ +/* [routine to time] */ +/* benchtime = dtime() - starttime; */ +/* } */ +/* */ +/* [timer code below added here] */ +/*****************************************************/ + +/*************************************************************************** + * Adapted for embedded microcontrollers by Graham Davies, ECROS Technology. + **************************************************************************/ + +/***************************************************************/ +/* Timer options. You MUST uncomment one of the options below */ +/* or compile, for example, with the '-DUNIX' option. */ +/***************************************************************/ +/* #define Amiga */ +/* #define UNIX */ +/* #define UNIX_Old */ +/* #define VMS */ +/* #define BORLAND_C */ +/* #define MSC */ +/* #define MAC */ +/* #define IPSC */ +/* #define FORTRAN_SEC */ +/* #define GTODay */ +/* #define CTimer */ +/* #define UXPM */ +/* #define MAC_TMgr */ +/* #define PARIX */ +/* #define POSIX */ +/* #define WIN32 */ +/* #define POSIX1 */ +/***********************/ + +/*********************************/ +/* Timer code. */ +/*********************************/ + +/************************************/ +/* Embedded microcontroller dtime() */ +/************************************/ +#if defined( __AVR_ARCH__ ) || defined( __ENCORE__ ) +double dtime( void ) +{ + return 0.0; +} +#endif + +/*******************/ +/* Amiga dtime() */ +/*******************/ +#ifdef Amiga +#include +#define HZ 50 + +double dtime() +{ + double q; + + struct tt + { + long days; + long minutes; + long ticks; + } tt; + + DateStamp(&tt); + + q = ((double)(tt.ticks + (tt.minutes * 60L * 50L))) / (double)HZ; + + return q; +} +#endif + +/*****************************************************/ +/* UNIX dtime(). This is the preferred UNIX timer. */ +/* Provided by: Markku Kolkka, mk59200@cc.tut.fi */ +/* HP-UX Addition by: Bo Thide', bt@irfu.se */ +/*****************************************************/ +#ifdef UNIX +#include +#include + +#ifdef hpux +#include +#define getrusage(a,b) syscall(SYS_getrusage,a,b) +#endif + +struct rusage rusage; + +double dtime() +{ + double q; + + getrusage(RUSAGE_SELF,&rusage); + + q = (double)(rusage.ru_utime.tv_sec); + q = q + (double)(rusage.ru_utime.tv_usec) * 1.0e-06; + + return q; +} +#endif + +/***************************************************/ +/* UNIX_Old dtime(). This is the old UNIX timer. */ +/* Make sure HZ is properly defined in param.h !! */ +/***************************************************/ +#ifdef UNIX_Old +#include +#include +#include + +#ifndef HZ +#define HZ 60 +#endif + +struct tms tms; + +double dtime() +{ + double q; + + times(&tms); + + q = (double)(tms.tms_utime) / (double)HZ; + + return q; +} +#endif + +/*********************************************************/ +/* VMS dtime() for VMS systems. */ +/* Provided by: RAMO@uvphys.phys.UVic.CA */ +/* Some people have run into problems with this timer. */ +/*********************************************************/ +#ifdef VMS +#include time + +#ifndef HZ +#define HZ 100 +#endif + +struct tbuffer_t + { + int proc_user_time; + int proc_system_time; + int child_user_time; + int child_system_time; + }; + +struct tbuffer_t tms; + +double dtime() +{ + double q; + + times(&tms); + + q = (double)(tms.proc_user_time) / (double)HZ; + + return q; +} +#endif + +/******************************/ +/* BORLAND C dtime() for DOS */ +/******************************/ +#ifdef BORLAND_C +#include +#include +#include + +#define HZ 100 +struct time tnow; + +double dtime() +{ + double q; + + gettime(&tnow); + + q = 60.0 * (double)(tnow.ti_min); + q = q + (double)(tnow.ti_sec); + q = q + (double)(tnow.ti_hund)/(double)HZ; + + return q; +} +#endif + +/**************************************/ +/* Microsoft C (MSC) dtime() for DOS */ +/**************************************/ +#ifdef MSC +#include +#include + +#define HZ CLOCKS_PER_SEC +clock_t tnow; + +double dtime() +{ + double q; + + tnow = clock(); + + q = (double)tnow / (double)HZ; + + return q; +} +#endif + +/*************************************/ +/* Macintosh (MAC) Think C dtime() */ +/*************************************/ +#ifdef MAC +#include + +#define HZ 60 + +double dtime() +{ + double q; + + q = (double)clock() / (double)HZ; + + return q; +} +#endif + +/************************************************************/ +/* iPSC/860 (IPSC) dtime() for i860. */ +/* Provided by: Dan Yergeau, yergeau@gloworm.Stanford.EDU */ +/************************************************************/ +#ifdef IPSC +extern double dclock(); + +double dtime() +{ + double q; + + q = dclock(); + + return q; +} +#endif + +/**************************************************/ +/* FORTRAN dtime() for Cray type systems. */ +/* This is the preferred timer for Cray systems. */ +/**************************************************/ +#ifdef FORTRAN_SEC + +fortran double second(); + +double dtime() +{ + double q; + + second(&q); + + return q; +} +#endif + +/***********************************************************/ +/* UNICOS C dtime() for Cray UNICOS systems. Don't use */ +/* unless absolutely necessary as returned time includes */ +/* 'user+system' time. Provided by: R. Mike Dority, */ +/* dority@craysea.cray.com */ +/***********************************************************/ +#ifdef CTimer +#include + +double dtime() +{ + double q; + clock_t clock(void); + + q = (double)clock() / (double)CLOCKS_PER_SEC; + + return q; +} +#endif + +/********************************************/ +/* Another UNIX timer using gettimeofday(). */ +/* However, getrusage() is preferred. */ +/********************************************/ +#ifdef GTODay +#include + +struct timeval tnow; + +double dtime() +{ + double q; + + gettimeofday(&tnow,NULL); + q = (double)tnow.tv_sec + (double)tnow.tv_usec * 1.0e-6; + + return q; +} +#endif + +/*****************************************************/ +/* Fujitsu UXP/M timer. */ +/* Provided by: Mathew Lim, ANUSF, M.Lim@anu.edu.au */ +/*****************************************************/ +#ifdef UXPM +#include +#include +struct tmsu rusage; + +double dtime() +{ + double q; + + timesu(&rusage); + + q = (double)(rusage.tms_utime) * 1.0e-06; + + return q; +} +#endif + +/**********************************************/ +/* Macintosh (MAC_TMgr) Think C dtime() */ +/* requires Think C Language Extensions or */ +/* #include in the prefix */ +/* provided by Francis H Schiffer 3rd (fhs) */ +/* skipschiffer@genie.geis.com */ +/**********************************************/ +#ifdef MAC_TMgr +#include +#include + +static TMTask mgrTimer; +static Boolean mgrInited = false; +static double mgrClock; + +#define RMV_TIMER RmvTime( (QElemPtr)&mgrTimer ) +#define MAX_TIME 1800000000L +/* MAX_TIME limits time between calls to */ +/* dtime( ) to no more than 30 minutes */ +/* this limitation could be removed by */ +/* creating a completion routine to sum */ +/* 30 minute segments (fhs 1994 feb 9) */ + +static void Remove_timer( ) +{ + RMV_TIMER; + mgrInited = false; +} + +double dtime( ) +{ + if( mgrInited ) { + RMV_TIMER; + mgrClock += (MAX_TIME + mgrTimer.tmCount)*1.0e-6; + } else { + if( _atexit( &Remove_timer ) == 0 ) mgrInited = true; + mgrClock = 0.0; + } + + if ( mgrInited ) + { + mgrTimer.tmAddr = NULL; + mgrTimer.tmCount = 0; + mgrTimer.tmWakeUp = 0; + mgrTimer.tmReserved = 0; + InsTime( (QElemPtr)&mgrTimer ); + PrimeTime( (QElemPtr)&mgrTimer, -MAX_TIME ); + } + return( mgrClock ); +} +#endif + +/***********************************************************/ +/* Parsytec GCel timer. */ +/* Provided by: Georg Wambach, gw@informatik.uni-koeln.de */ +/***********************************************************/ +#ifdef PARIX +#include + +double dtime() +{ + double q; + + q = (double) (TimeNowHigh()) / (double) CLK_TCK_HIGH; + + return q; +} +#endif + +/************************************************/ +/* Sun Solaris POSIX dtime() routine */ +/* Provided by: Case Larsen, CTLarsen.lbl.gov */ +/************************************************/ +#ifdef POSIX +#include +#include +#include + +#ifdef __hpux +#include +#endif + +struct rusage rusage; + +double dtime() +{ + double q; + + getrusage(RUSAGE_SELF,&rusage); + + q = (double)(rusage.ru_utime.tv_sec); + q = q + (double)(rusage.ru_utime.tv_nsec) * 1.0e-09; + + return q; +} +#endif + + +/****************************************************/ +/* Windows NT (32 bit) dtime() routine */ +/* Provided by: Piers Haken, piersh@microsoft.com */ +/****************************************************/ +#ifdef WIN32 +#include + +double dtime(void) +{ + double q; + + q = (double)GetTickCount() * 1.0e-03; + + return q; +} +#endif + +/*****************************************************/ +/* Time according to POSIX.1 - */ +/* Ref: "POSIX Programmer's Guide" O'Reilly & Assoc.*/ +/*****************************************************/ +#ifdef POSIX1 +#define _POSIX_SOURCE 1 +#include +#include +#include + +struct tms tms; + +double dtime() +{ + double q; + times(&tms); + q = (double)tms.tms_utime / (double)CLK_TCK; + return q; +} +#endif
rtl_sim/src-c/dhrystone_4mcu/original_files/timers_b.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/original_files/Dhrystone.pnproj =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/original_files/Dhrystone.pnproj (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/original_files/Dhrystone.pnproj (revision 145) @@ -0,0 +1,9 @@ + + + + + + + + + \ No newline at end of file
rtl_sim/src-c/dhrystone_4mcu/original_files/Dhrystone.pnproj Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/original_files/estubs.c =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/original_files/estubs.c (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/original_files/estubs.c (revision 145) @@ -0,0 +1,84 @@ +/******************************************************************************* + * Copyright (c) 2004 by Graham Davies, ECROS Technology. This work is * + * released into the Public Domain on condition that the forgoing copyright * + * notice is preserved in this and all derived files. * + ******************************************************************************/ + +/******************************************************************************* + * File: estubs.c - embedded stubs used to adapt the Dhrystone benchmark for + * small (4 Kbyte RAM) microcontrollers. + * + * Last edited on $Date: Wednesday, June 09, 2004 1:05:22 PM $ by + * $Author: Graham $ saved as $Revision: 1.5 $ $Version: NONE $ + ******************************************************************************/ + +#include +#include +#include "dhry.h" + +/******************************************************************************* + * Function emalloc() - provides a dynamic memory allocation service sufficient + * for two allocations of 50 bytes each or less. + */ +void * emalloc( size_t nbytes ) +{ + static char space[100]; + static char * ptr = space; + static char * result; + + result = ptr; + nbytes = (nbytes & 0xFFFC) + 4; + ptr += nbytes; + + return ( result ); + +} /* end of function emalloc() */ + +/******************************************************************************* + * Function fopen() - initialize an output port bit. + */ +FILE * fopen( const char * filename, const char * mode ) +{ +#if defined( __AVR_ARCH__ ) + DDRB = 0x01; /* bit 0 output */ + PORTB = 0x00; /* start low (zero) */ +#elif defined( __ENCORE__ ) + PAADDR = 4; + PACTL = 0x01; /* bit 0 high drive */ + PAADDR = 1; + PACTL = 0xFE; /* bit 0 output */ + PAADDR = 0; + PAOUT = 0x00; /* start low (zero) */ +#endif + + return ( (FILE *)1 ); + +} /* end of function fopen() */ + +/******************************************************************************* + * Function fclose() - stub; does nothing. + */ +int fclose( FILE * stream ) +{ + return ( 0 ); + +} /* end of function fclose() */ + +/******************************************************************************* + * Function scanf() - fake a value typed by the user. + */ +int scanf( const char * format, ... ) +{ + va_list args; + int * ptr; + + va_start( args, format ); + ptr = va_arg( args, int * ); + *ptr = 30000; + va_end( args ); + + return ( 0 ); + +} /* end of function scanf() */ + +/* end of file estubs.c */
rtl_sim/src-c/dhrystone_4mcu/original_files/estubs.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/original_files/ReadMe.txt =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/original_files/ReadMe.txt (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/original_files/ReadMe.txt (revision 145) @@ -0,0 +1,23 @@ +Adapted Dhrystone source files: + + dhry.h + dhry21a.c + dhry21b.c + timers_b.c + estubs.c + +ZDS II 4.8.0 project file: + + dhrystone.pro + +Programmer's Notepad project file: + + dhrystone.pnproj + +AVR-GCC Makefile: + + Makefile + +This file: + + ReadMe.txt
rtl_sim/src-c/dhrystone_4mcu/original_files/ReadMe.txt Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/original_files/dhry21a.c =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/original_files/dhry21a.c (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/original_files/dhry21a.c (revision 145) @@ -0,0 +1,389 @@ +/* + ************************************************************************* + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: C, Version 2.1 + * + * File: dhry_1.c (part 2 of 3) + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * + ************************************************************************* + */ + +/*************************************************************************** + * Adapted for embedded microcontrollers by Graham Davies, ECROS Technology. + **************************************************************************/ + +#include "dhry.h" +#include +#include +#include + +/* Global Variables: */ + +Rec_Pointer Ptr_Glob, + Next_Ptr_Glob; +int Int_Glob; +Boolean Bool_Glob; +char Ch_1_Glob, + Ch_2_Glob; +int Arr_1_Glob [25]; /* <-- changed from 50 */ +int Arr_2_Glob [25] [25]; /* <-- changed from 50 */ + +char Reg_Define[] = "Register option selected."; + +#ifndef ROPT +#define REG + /* REG becomes defined as empty */ + /* i.e. no register variables */ +#else +#define REG register +#endif + + +/* variables for time measurement: */ + +#define Too_Small_Time 2 + /* Measurements should last at least 2 seconds */ + +double Begin_Time, + End_Time, + User_Time; + +double Microseconds, + Dhrystones_Per_Second, + Vax_Mips; + +/* end of variables for time measurement */ + +void Proc_1( REG Rec_Pointer Ptr_Val_Par ); +void Proc_2( One_Fifty * Int_Par_Ref ); +void Proc_3( Rec_Pointer * Ptr_Ref_Par ); +void Proc_4( void ); +void Proc_5( void ); + +int main( void ) +/*****/ + + /* main program, corresponds to procedures */ + /* Main and Proc_0 in the Ada version */ +{ + double dtime( void ); + + One_Fifty Int_1_Loc; + REG One_Fifty Int_2_Loc; + One_Fifty Int_3_Loc; + REG char Ch_Index; + Enumeration Enum_Loc; + Str_30 Str_1_Loc; + Str_30 Str_2_Loc; + REG int Run_Index; + REG int Number_Of_Runs; + + FILE *Ap; + + /* Initializations */ + + if ((Ap = fopen("dhry.res","a+")) == NULL) + { + printf("Can not open dhry.res\n\n"); + exit(1); + } + + Next_Ptr_Glob = (Rec_Pointer)emalloc (sizeof (Rec_Type)); + Ptr_Glob = (Rec_Pointer)emalloc (sizeof (Rec_Type)); + + Ptr_Glob->Ptr_Comp = Next_Ptr_Glob; + Ptr_Glob->Discr = Ident_1; + Ptr_Glob->variant.var_1.Enum_Comp = Ident_3; + Ptr_Glob->variant.var_1.Int_Comp = 40; + strcpy (Ptr_Glob->variant.var_1.Str_Comp, + "DHRYSTONE PROGRAM, SOME STRING"); + strcpy (Str_1_Loc, "DHRYSTONE PROGRAM, 1'ST STRING"); + + Arr_2_Glob [8][7] = 10; + /* Was missing in published program. Without this statement, */ + /* Arr_2_Glob [8][7] would have an undefined value. */ + /* Warning: With 16-Bit processors and Number_Of_Runs > 32000, */ + /* overflow may occur for this array element. */ + + printf ("\n"); + printf ("Dhrystone Benchmark, Version 2.1 (Language: C)\n"); + printf ("\n"); +/* + if (Reg) + { + printf ("Program compiled with 'register' attribute\n"); + printf ("\n"); + } + else + { + printf ("Program compiled without 'register' attribute\n"); + printf ("\n"); + } +*/ + printf ("Please give the number of runs through the benchmark: "); + { + int n; + scanf ("%d", &n); + Number_Of_Runs = n; + } + printf ("\n"); + + printf ("Execution starts, %d runs through Dhrystone\n",Number_Of_Runs); + + /***************/ + /* Start timer */ + /***************/ + + Begin_Time = dtime(); + + for (Run_Index = 1; Run_Index <= Number_Of_Runs; /* ++Run_Index */ ) + { + + SetPort( 1 ); /* <-- added; set port high */ + Proc_5(); + Proc_4(); + /* Ch_1_Glob == 'A', Ch_2_Glob == 'B', Bool_Glob == true */ + Int_1_Loc = 2; + Int_2_Loc = 3; + strcpy (Str_2_Loc, "DHRYSTONE PROGRAM, 2'ND STRING"); + Enum_Loc = Ident_2; + Bool_Glob = ! Func_2 (Str_1_Loc, Str_2_Loc); + /* Bool_Glob == 1 */ + while (Int_1_Loc < Int_2_Loc) /* loop body executed once */ + { + Int_3_Loc = 5 * Int_1_Loc - Int_2_Loc; + /* Int_3_Loc == 7 */ + Proc_7 (Int_1_Loc, Int_2_Loc, &Int_3_Loc); + /* Int_3_Loc == 7 */ + Int_1_Loc += 1; + } /* while */ + SetPort( 0 ); /* <-- added; set port low */ + /* Int_1_Loc == 3, Int_2_Loc == 3, Int_3_Loc == 7 */ + Proc_8 (Arr_1_Glob, Arr_2_Glob, Int_1_Loc, Int_3_Loc); + /* Int_Glob == 5 */ + Proc_1 (Ptr_Glob); + for (Ch_Index = 'A'; Ch_Index <= Ch_2_Glob; ++Ch_Index) + /* loop body executed twice */ + { + if (Enum_Loc == Func_1 (Ch_Index, 'C')) + /* then, not executed */ + { + Proc_6 (Ident_1, &Enum_Loc); + strcpy (Str_2_Loc, "DHRYSTONE PROGRAM, 3'RD STRING"); + Int_2_Loc = Run_Index; + Int_Glob = Run_Index; + } + } + /* Int_1_Loc == 3, Int_2_Loc == 3, Int_3_Loc == 7 */ + Int_2_Loc = Int_2_Loc * Int_1_Loc; + Int_1_Loc = Int_2_Loc / Int_3_Loc; + Int_2_Loc = 7 * (Int_2_Loc - Int_3_Loc) - Int_1_Loc; + /* Int_1_Loc == 1, Int_2_Loc == 13, Int_3_Loc == 7 */ + Proc_2 (&Int_1_Loc); + /* Int_1_Loc == 5 */ + + } /* loop "for Run_Index" */ + + /**************/ + /* Stop timer */ + /**************/ + + End_Time = dtime(); + + printf ("Execution ends\n"); + printf ("\n"); + printf ("Final values of the variables used in the benchmark:\n"); + printf ("\n"); + printf ("Int_Glob: %d\n", Int_Glob); + printf (" should be: %d\n", 5); + printf ("Bool_Glob: %d\n", Bool_Glob); + printf (" should be: %d\n", 1); + printf ("Ch_1_Glob: %c\n", Ch_1_Glob); + printf (" should be: %c\n", 'A'); + printf ("Ch_2_Glob: %c\n", Ch_2_Glob); + printf (" should be: %c\n", 'B'); + printf ("Arr_1_Glob[8]: %d\n", Arr_1_Glob[8]); + printf (" should be: %d\n", 7); + printf ("Arr_2_Glob[8][7]: %d\n", Arr_2_Glob[8][7]); + printf (" should be: Number_Of_Runs + 10\n"); + printf ("Ptr_Glob->\n"); + printf (" Ptr_Comp: %d\n", (int) Ptr_Glob->Ptr_Comp); + printf (" should be: (implementation-dependent)\n"); + printf (" Discr: %d\n", Ptr_Glob->Discr); + printf (" should be: %d\n", 0); + printf (" Enum_Comp: %d\n", Ptr_Glob->variant.var_1.Enum_Comp); + printf (" should be: %d\n", 2); + printf (" Int_Comp: %d\n", Ptr_Glob->variant.var_1.Int_Comp); + printf (" should be: %d\n", 17); + printf (" Str_Comp: %s\n", Ptr_Glob->variant.var_1.Str_Comp); + printf (" should be: DHRYSTONE PROGRAM, SOME STRING\n"); + printf ("Next_Ptr_Glob->\n"); + printf (" Ptr_Comp: %d\n", (int) Next_Ptr_Glob->Ptr_Comp); + printf (" should be: (implementation-dependent), same as above\n"); + printf (" Discr: %d\n", Next_Ptr_Glob->Discr); + printf (" should be: %d\n", 0); + printf (" Enum_Comp: %d\n", Next_Ptr_Glob->variant.var_1.Enum_Comp); + printf (" should be: %d\n", 1); + printf (" Int_Comp: %d\n", Next_Ptr_Glob->variant.var_1.Int_Comp); + printf (" should be: %d\n", 18); + printf (" Str_Comp: %s\n", Next_Ptr_Glob->variant.var_1.Str_Comp); + printf (" should be: DHRYSTONE PROGRAM, SOME STRING\n"); + printf ("Int_1_Loc: %d\n", Int_1_Loc); + printf (" should be: %d\n", 5); + printf ("Int_2_Loc: %d\n", Int_2_Loc); + printf (" should be: %d\n", 13); + printf ("Int_3_Loc: %d\n", Int_3_Loc); + printf (" should be: %d\n", 7); + printf ("Enum_Loc: %d\n", Enum_Loc); + printf (" should be: %d\n", 1); + printf ("Str_1_Loc: %s\n", Str_1_Loc); + printf (" should be: DHRYSTONE PROGRAM, 1'ST STRING\n"); + printf ("Str_2_Loc: %s\n", Str_2_Loc); + printf (" should be: DHRYSTONE PROGRAM, 2'ND STRING\n"); + printf ("\n"); + + User_Time = End_Time - Begin_Time; + + if (User_Time < Too_Small_Time) + { + printf ("Measured time too small to obtain meaningful results\n"); + printf ("Please increase number of runs\n"); + printf ("\n"); + } + else + { + Microseconds = User_Time * Mic_secs_Per_Second + / (double) Number_Of_Runs; + Dhrystones_Per_Second = (double) Number_Of_Runs / User_Time; + Vax_Mips = Dhrystones_Per_Second / 1757.0; + +#ifdef ROPT + printf ("Register option selected? YES\n"); +#else + printf ("Register option selected? NO\n"); + strcpy(Reg_Define, "Register option not selected."); +#endif + printf ("Microseconds for one run through Dhrystone: "); + printf ("%7.1lf \n", Microseconds); + printf ("Dhrystones per Second: "); + printf ("%10.1lf \n", Dhrystones_Per_Second); + printf ("VAX MIPS rating = %10.3lf \n",Vax_Mips); + printf ("\n"); + + fprintf(Ap,"\n"); + fprintf(Ap,"Dhrystone Benchmark, Version 2.1 (Language: C)\n"); + fprintf(Ap,"%s\n",Reg_Define); + fprintf(Ap,"Microseconds for one loop: %7.1lf\n",Microseconds); + fprintf(Ap,"Dhrystones per second: %10.1lf\n",Dhrystones_Per_Second); + fprintf(Ap,"VAX MIPS rating: %10.3lf\n",Vax_Mips); + fclose(Ap); + + } + return ( 0 ); +} + + +void Proc_1( REG Rec_Pointer Ptr_Val_Par ) +/******************/ + /* executed once */ +{ + REG Rec_Pointer Next_Record = Ptr_Val_Par->Ptr_Comp; + /* == Ptr_Glob_Next */ + /* Local variable, initialized with Ptr_Val_Par->Ptr_Comp, */ + /* corresponds to "rename" in Ada, "with" in Pascal */ + + structassign (*Ptr_Val_Par->Ptr_Comp, *Ptr_Glob); + Ptr_Val_Par->variant.var_1.Int_Comp = 5; + Next_Record->variant.var_1.Int_Comp + = Ptr_Val_Par->variant.var_1.Int_Comp; + Next_Record->Ptr_Comp = Ptr_Val_Par->Ptr_Comp; + Proc_3 (&Next_Record->Ptr_Comp); + /* Ptr_Val_Par->Ptr_Comp->Ptr_Comp + == Ptr_Glob->Ptr_Comp */ + if (Next_Record->Discr == Ident_1) + /* then, executed */ + { + Next_Record->variant.var_1.Int_Comp = 6; + Proc_6 (Ptr_Val_Par->variant.var_1.Enum_Comp, + &Next_Record->variant.var_1.Enum_Comp); + Next_Record->Ptr_Comp = Ptr_Glob->Ptr_Comp; + Proc_7 (Next_Record->variant.var_1.Int_Comp, 10, + &Next_Record->variant.var_1.Int_Comp); + } + else /* not executed */ + structassign (*Ptr_Val_Par, *Ptr_Val_Par->Ptr_Comp); +} /* Proc_1 */ + + +void Proc_2( One_Fifty * Int_Par_Ref ) +/******************/ + /* executed once */ + /* *Int_Par_Ref == 1, becomes 4 */ +{ + One_Fifty Int_Loc; + Enumeration Enum_Loc; + + Int_Loc = *Int_Par_Ref + 10; + do /* executed once */ + if (Ch_1_Glob == 'A') + /* then, executed */ + { + Int_Loc -= 1; + *Int_Par_Ref = Int_Loc - Int_Glob; + Enum_Loc = Ident_1; + } /* if */ + while (Enum_Loc != Ident_1); /* true */ +} /* Proc_2 */ + + +void Proc_3( Rec_Pointer * Ptr_Ref_Par ) +/******************/ + /* executed once */ + /* Ptr_Ref_Par becomes Ptr_Glob */ +{ + if (Ptr_Glob != Null) + /* then, executed */ + *Ptr_Ref_Par = Ptr_Glob->Ptr_Comp; + Proc_7 (10, Int_Glob, &Ptr_Glob->variant.var_1.Int_Comp); +} /* Proc_3 */ + + +void Proc_4( void ) /* without parameters */ +/*******/ + /* executed once */ +{ + Boolean Bool_Loc; + + Bool_Loc = Ch_1_Glob == 'A'; + Bool_Glob = Bool_Loc | Bool_Glob; + Ch_2_Glob = 'B'; +} /* Proc_4 */ + + +void Proc_5( void ) /* without parameters */ +/*******/ + /* executed once */ +{ + Ch_1_Glob = 'A'; + Bool_Glob = false; +} /* Proc_5 */ + + + /* Procedure for the assignment of structures, */ + /* if the C compiler doesn't support this feature */ +#ifdef NOSTRUCTASSIGN +memcpy (d, s, l) +register char *d; +register char *s; +register int l; +{ + while (l--) *d++ = *s++; +} +#endif
rtl_sim/src-c/dhrystone_4mcu/original_files/dhry21a.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/original_files/dhry.h =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/original_files/dhry.h (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/original_files/dhry.h (revision 145) @@ -0,0 +1,440 @@ +/* + ************************************************************************* + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: C, Version 2.1 + * + * File: dhry.h (part 1 of 3) + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * Siemens Nixdorf Inf. Syst. + * STM OS 32 + * Otto-Hahn-Ring 6 + * W-8000 Muenchen 83 + * Germany + * Phone: [+49]-89-636-42436 + * (8-17 Central European Time) + * UUCP: weicker@ztivax.uucp@unido.uucp + * Internet: weicker@ztivax.siemens.com + * + * Original Version (in Ada) published in + * "Communications of the ACM" vol. 27., no. 10 (Oct. 1984), + * pp. 1013 - 1030, together with the statistics + * on which the distribution of statements etc. is based. + * + * In this C version, the following C library functions are + * used: + * - strcpy, strcmp (inside the measurement loop) + * - printf, scanf (outside the measurement loop) + * + * Collection of Results: + * Reinhold Weicker (address see above) and + * + * Rick Richardson + * PC Research. Inc. + * 94 Apple Orchard Drive + * Tinton Falls, NJ 07724 + * Phone: (201) 834-1378 (9-17 EST) + * UUCP: ...!uunet!pcrat!rick + * + * Please send results to Rick Richardson and/or Reinhold Weicker. + * Complete information should be given on hardware and software + * used. Hardware information includes: Machine type, CPU, type and + * size of caches; for microprocessors: clock frequency, memory speed + * (number of wait states). Software information includes: Compiler + * (and runtime library) manufacturer and version, compilation + * switches, OS version. The Operating System version may give an + * indication about the compiler; Dhrystone itself performs no OS + * calls in the measurement loop. + * + * The complete output generated by the program should be mailed + * such that at least some checks for correctness can be made. + * + ************************************************************************* + * + * History: This version C/2.1 has been made for two reasons: + * + * 1) There is an obvious need for a common C version of + * Dhrystone, since C is at present the most popular system + * programming language for the class of processors + * (microcomputers, minicomputers) where Dhrystone is used + * most. There should be, as far as possible, only one C + * version of Dhrystone such that results can be compared + * without restrictions. In the past, the C versions + * distributed by Rick Richardson (Version 1.1) and by + * Reinhold Weicker had small (though not significant) + * differences. + * + * 2) As far as it is possible without changes to the + * Dhrystone statistics, optimizing compilers should be + * prevented from removing significant statements. + * + * This C version has been developed in cooperation with + * Rick Richardson (Tinton Falls, NJ), it incorporates many + * ideas from the "Version 1.1" distributed previously by + * him over the UNIX network Usenet. + * I also thank Chaim Benedelac (National Semiconductor), + * David Ditzel (SUN), Earl Killian and John Mashey (MIPS), + * Alan Smith and Rafael Saavedra-Barrera (UC at Berkeley) + * for their help with comments on earlier versions of the + * benchmark. + * + * Changes: In the initialization part, this version follows mostly + * Rick Richardson's version distributed via Usenet, not the + * version distributed earlier via floppy disk by Reinhold + * Weicker. As a concession to older compilers, names have + * been made unique within the first 8 characters. Inside the + * measurement loop, this version follows the version + * previously distributed by Reinhold Weicker. + * + * At several places in the benchmark, code has been added, + * but within the measurement loop only in branches that + * are not executed. The intention is that optimizing + * compilers should be prevented from moving code out of the + * measurement loop, or from removing code altogether. Since + * the statements that are executed within the measurement + * loop have NOT been changed, the numbers defining the + * "Dhrystone distribution" (distribution of statements, + * operand types and locality) still hold. Except for + * sophisticated optimizing compilers, execution times for + * this version should be the same as for previous versions. + * + * Since it has proven difficult to subtract the time for the + * measurement loop overhead in a correct way, the loop check + * has been made a part of the benchmark. This does have + * an impact - though a very minor one - on the distribution + * statistics which have been updated for this version. + * + * All changes within the measurement loop are described + * and discussed in the companion paper "Rationale for + * Dhrystone version 2". + * + * Because of the self-imposed limitation that the order and + * distribution of the executed statements should not be + * changed, there are still cases where optimizing compilers + * may not generate code for some statements. To a certain + * degree, this is unavoidable for small synthetic + * benchmarks. Users of the benchmark are advised to check + * code listings whether code is generated for all statements + * of Dhrystone. + * + * Version 2.1 is identical to version 2.0 distributed via + * the UNIX network Usenet in March 1988 except that it + * corrects some minor deficiencies that were found by users + * of version 2.0. The only change within the measurement + * loop is that a non-executed "else" part was added to the + * "if" statement in Func_3, and a non-executed "else" part + * removed from Proc_3. + * + ************************************************************************* + * + * Defines: The following "Defines" are possible: + * -DROPT (default: Not defined) + * As an approximation to what an average C + * programmer might do, the "register" storage class + * is applied (if enabled by -DROPT) + * - for local variables, if they are used + * (dynamically) five or more times + * - for parameters if they are used (dynamically) + * six or more times + * Note that an optimal "register" strategy is + * compiler-dependent, and that "register" + * declarations do not necessarily lead to faster + * execution. + * -DNOSTRUCTASSIGN (default: Not defined) + * Define if the C compiler does not support + * assignment of structures. + * -DNOENUMS (default: Not defined) + * Define if the C compiler does not support + * enumeration types. + * + ************************************************************************* + * + * Compilation model and measurement (IMPORTANT): + * + * This C version of Dhrystone consists of three files: + * - dhry.h (this file, containing global definitions and comments) + * - dhry_1.c (containing the code corresponding to Ada package Pack_1) + * - dhry_2.c (containing the code corresponding to Ada package Pack_2) + * + * The following "ground rules" apply for measurements: + * - Separate compilation + * - No procedure merging + * - Otherwise, compiler optimizations are allowed but should be + * indicated + * - Default results are those without register declarations + * See the companion paper "Rationale for Dhrystone Version 2" for a more + * detailed discussion of these ground rules. + * + * For 16-Bit processors (e.g. 80186, 80286), times for all compilation + * models ("small", "medium", "large" etc.) should be given if possible, + * together with a definition of these models for the compiler system + * used. + * + ************************************************************************* + * + * Dhrystone (C version) statistics: + * + * [Comment from the first distribution, updated for version 2. + * Note that because of language differences, the numbers are slightly + * different from the Ada version.] + * + * The following program contains statements of a high level programming + * language (here: C) in a distribution considered representative: + * + * assignments 52 (51.0 %) + * control statements 33 (32.4 %) + * procedure, function calls 17 (16.7 %) + * + * 103 statements are dynamically executed. The program is balanced with + * respect to the three aspects: + * + * - statement type + * - operand type + * - operand locality + * operand global, local, parameter, or constant. + * + * The combination of these three aspects is balanced only approximately. + * + * 1. Statement Type: + * ----------------- number + * + * V1 = V2 9 + * (incl. V1 = F(..) + * V = Constant 12 + * Assignment, 7 + * with array element + * Assignment, 6 + * with record component + * -- + * 34 34 + * + * X = Y +|-|"&&"|"|" Z 5 + * X = Y +|-|"==" Constant 6 + * X = X +|- 1 3 + * X = Y *|/ Z 2 + * X = Expression, 1 + * two operators + * X = Expression, 1 + * three operators + * -- + * 18 18 + * + * if .... 14 + * with "else" 7 + * without "else" 7 + * executed 3 + * not executed 4 + * for ... 7 | counted every time + * while ... 4 | the loop condition + * do ... while 1 | is evaluated + * switch ... 1 + * break 1 + * declaration with 1 + * initialization + * -- + * 34 34 + * + * P (...) procedure call 11 + * user procedure 10 + * library procedure 1 + * X = F (...) + * function call 6 + * user function 5 + * library function 1 + * -- + * 17 17 + * --- + * 103 + * + * The average number of parameters in procedure or function calls + * is 1.82 (not counting the function values as implicit parameters). + * + * + * 2. Operators + * ------------ + * number approximate + * percentage + * + * Arithmetic 32 50.8 + * + * + 21 33.3 + * - 7 11.1 + * * 3 4.8 + * / (int div) 1 1.6 + * + * Comparison 27 42.8 + * + * == 9 14.3 + * /= 4 6.3 + * > 1 1.6 + * < 3 4.8 + * >= 1 1.6 + * <= 9 14.3 + * + * Logic 4 6.3 + * + * && (AND-THEN) 1 1.6 + * | (OR) 1 1.6 + * ! (NOT) 2 3.2 + * + * -- ----- + * 63 100.1 + * + * + * 3. Operand Type (counted once per operand reference): + * --------------- + * number approximate + * percentage + * + * Integer 175 72.3 % + * Character 45 18.6 % + * Pointer 12 5.0 % + * String30 6 2.5 % + * Array 2 0.8 % + * Record 2 0.8 % + * --- ------- + * 242 100.0 % + * + * When there is an access path leading to the final operand (e.g. a + * record component), only the final data type on the access path is + * counted. + * + * + * 4. Operand Locality: + * ------------------- + * number approximate + * percentage + * + * local variable 114 47.1 % + * global variable 22 9.1 % + * parameter 45 18.6 % + * value 23 9.5 % + * reference 22 9.1 % + * function result 6 2.5 % + * constant 55 22.7 % + * --- ------- + * 242 100.0 % + * + * + * The program does not compute anything meaningful, but it is + * syntactically and semantically correct. All variables have a value + * assigned to them before they are used as a source operand. + * + * There has been no explicit effort to account for the effects of a + * cache, or to balance the use of long or short displacements for code + * or data. + * + ************************************************************************* + */ + +/******************************************************************************* + * Adapted for embedded microcontrollers by Graham Davies, ECROS Technology. * + ******************************************************************************/ + +/* Compiler and system dependent definitions: */ + +#define Mic_secs_Per_Second 1000000.0 + /* Berkeley UNIX C returns process times in seconds/HZ */ + +#ifdef NOSTRUCTASSIGN +#define structassign(d, s) memcpy(&(d), &(s), sizeof(d)) +#else +#define structassign(d, s) d = s +#endif + +#ifdef NOENUM +#define Ident_1 0 +#define Ident_2 1 +#define Ident_3 2 +#define Ident_4 3 +#define Ident_5 4 + typedef int Enumeration; +#else + typedef enum {Ident_1, Ident_2, Ident_3, Ident_4, Ident_5} + Enumeration; +#endif + /* for boolean and enumeration types in Ada, Pascal */ + +/* General definitions: */ + +#include + /* for strcpy, strcmp */ + +#define Null 0 + /* Value of a Null pointer */ +#define true 1 +#define false 0 + +typedef int One_Thirty; +typedef int One_Fifty; +typedef char Capital_Letter; +typedef int Boolean; +typedef char Str_30 [31]; +typedef int Arr_1_Dim [25]; /* <-- changed from 50 */ +typedef int Arr_2_Dim [25] [25]; /* <-- changed from 50 */ + +typedef struct record + { + struct record *Ptr_Comp; + Enumeration Discr; + union { + struct { + Enumeration Enum_Comp; + int Int_Comp; + char Str_Comp [31]; + } var_1; + struct { + Enumeration E_Comp_2; + char Str_2_Comp [31]; + } var_2; + struct { + char Ch_1_Comp; + char Ch_2_Comp; + } var_3; + } variant; + } Rec_Type, *Rec_Pointer; + +/* Prototypes of function defined in dhry21b.c and called from dhry21a.c. + */ +void Proc_6( Enumeration Enum_Val_Par, Enumeration * Enum_Ref_Par ); +void Proc_7( One_Fifty Int_1_Par_Val, One_Fifty Int_2_Par_Val, + One_Fifty * Int_Par_Ref ); +void Proc_8( Arr_1_Dim Arr_1_Par_Ref, Arr_2_Dim Arr_2_Par_Ref, + int Int_1_Par_Val, int Int_2_Par_Val ); +Enumeration Func_1( Capital_Letter Ch_1_Par_Val, Capital_Letter Ch_2_Par_Val ); +Boolean Func_2( Str_30 Str_1_Par_Ref, Str_30 Str_2_Par_Ref ); + +/******************************************************************************* + * Additions for embedded microcontrollers follow ... + */ +#ifdef printf +#undef printf +#endif +#define printf // +#ifdef fprintf +#undef fprintf +#endif +#define fprintf // + +extern void * emalloc( size_t nbytes ); + +#if defined( __AVR_ARCH__ ) /* Atmel AVR */ + +#include +#define SetPort( state ) PORTB = (state) +extern FILE * fopen( const char * filename, const char * mode ); + +#elif defined( __ENCORE__ ) /* ZiLOG Z8 Encore! */ + +#include +#define SetPort( state ) PAOUT = (state) +typedef int FILE; +extern FILE * fopen( const char * filename, const char * mode ); +extern int fclose( FILE * stream ); + +#endif
rtl_sim/src-c/dhrystone_4mcu/original_files/dhry.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/original_files/dhry21b.c =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/original_files/dhry21b.c (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/original_files/dhry21b.c (revision 145) @@ -0,0 +1,184 @@ +/* + ************************************************************************* + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: C, Version 2.1 + * + * File: dhry_2.c (part 3 of 3) + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * + ************************************************************************* + */ + +/*************************************************************************** + * Adapted for embedded microcontrollers by Graham Davies, ECROS Technology. + **************************************************************************/ + +#include "dhry.h" +#include + +#ifndef REG +#define REG + /* REG becomes defined as empty */ + /* i.e. no register variables */ +#else +#define REG register +#endif + +extern int Int_Glob; +extern char Ch_1_Glob; + +Boolean Func_3( Enumeration Enum_Par_Val ); + +void Proc_6( Enumeration Enum_Val_Par, Enumeration * Enum_Ref_Par ) +/*********************************/ + /* executed once */ + /* Enum_Val_Par == Ident_3, Enum_Ref_Par becomes Ident_2 */ +{ + *Enum_Ref_Par = Enum_Val_Par; + if (! Func_3 (Enum_Val_Par)) + /* then, not executed */ + *Enum_Ref_Par = Ident_4; + switch (Enum_Val_Par) + { + case Ident_1: + *Enum_Ref_Par = Ident_1; + break; + case Ident_2: + if (Int_Glob > 100) + /* then */ + *Enum_Ref_Par = Ident_1; + else *Enum_Ref_Par = Ident_4; + break; + case Ident_3: /* executed */ + *Enum_Ref_Par = Ident_2; + break; + case Ident_4: break; + case Ident_5: + *Enum_Ref_Par = Ident_3; + break; + } /* switch */ +} /* Proc_6 */ + + +void Proc_7( One_Fifty Int_1_Par_Val, One_Fifty Int_2_Par_Val, + One_Fifty * Int_Par_Ref ) +/**********************************************/ + /* executed three times */ + /* first call: Int_1_Par_Val == 2, Int_2_Par_Val == 3, */ + /* Int_Par_Ref becomes 7 */ + /* second call: Int_1_Par_Val == 10, Int_2_Par_Val == 5, */ + /* Int_Par_Ref becomes 17 */ + /* third call: Int_1_Par_Val == 6, Int_2_Par_Val == 10, */ + /* Int_Par_Ref becomes 18 */ +{ + One_Fifty Int_Loc; + + Int_Loc = Int_1_Par_Val + 2; + *Int_Par_Ref = Int_2_Par_Val + Int_Loc; +} /* Proc_7 */ + + +void Proc_8( Arr_1_Dim Arr_1_Par_Ref, Arr_2_Dim Arr_2_Par_Ref, + int Int_1_Par_Val, int Int_2_Par_Val ) +/*********************************************************************/ + /* executed once */ + /* Int_Par_Val_1 == 3 */ + /* Int_Par_Val_2 == 7 */ +{ + REG One_Fifty Int_Index; + REG One_Fifty Int_Loc; + + Int_Loc = Int_1_Par_Val + 5; + Arr_1_Par_Ref [Int_Loc] = Int_2_Par_Val; + Arr_1_Par_Ref [Int_Loc+1] = Arr_1_Par_Ref [Int_Loc]; + Arr_1_Par_Ref [Int_Loc+15] = Int_Loc; + for (Int_Index = Int_Loc; Int_Index <= Int_Loc+1; ++Int_Index) + Arr_2_Par_Ref [Int_Loc] [Int_Index] = Int_Loc; + Arr_2_Par_Ref [Int_Loc] [Int_Loc-1] += 1; + Arr_2_Par_Ref [Int_Loc+10] [Int_Loc] = Arr_1_Par_Ref [Int_Loc]; + Int_Glob = 5; +} /* Proc_8 */ + + +Enumeration Func_1 ( Capital_Letter Ch_1_Par_Val, Capital_Letter Ch_2_Par_Val ) +/*************************************************/ + /* executed three times */ + /* first call: Ch_1_Par_Val == 'H', Ch_2_Par_Val == 'R' */ + /* second call: Ch_1_Par_Val == 'A', Ch_2_Par_Val == 'C' */ + /* third call: Ch_1_Par_Val == 'B', Ch_2_Par_Val == 'C' */ +{ + Capital_Letter Ch_1_Loc; + Capital_Letter Ch_2_Loc; + + Ch_1_Loc = Ch_1_Par_Val; + Ch_2_Loc = Ch_1_Loc; + if (Ch_2_Loc != Ch_2_Par_Val) + /* then, executed */ + return (Ident_1); + else /* not executed */ + { + Ch_1_Glob = Ch_1_Loc; + return (Ident_2); + } +} /* Func_1 */ + + +Boolean Func_2( Str_30 Str_1_Par_Ref, Str_30 Str_2_Par_Ref ) +/*************************************************/ + /* executed once */ + /* Str_1_Par_Ref == "DHRYSTONE PROGRAM, 1'ST STRING" */ + /* Str_2_Par_Ref == "DHRYSTONE PROGRAM, 2'ND STRING" */ +{ + REG One_Thirty Int_Loc; + Capital_Letter Ch_Loc; + + Int_Loc = 2; + while (Int_Loc <= 2) /* loop body executed once */ + if (Func_1 (Str_1_Par_Ref[Int_Loc], + Str_2_Par_Ref[Int_Loc+1]) == Ident_1) + /* then, executed */ + { + Ch_Loc = 'A'; + Int_Loc += 1; + } /* if, while */ + if (Ch_Loc >= 'W' && Ch_Loc < 'Z') + /* then, not executed */ + Int_Loc = 7; + if (Ch_Loc == 'R') + /* then, not executed */ + return (true); + else /* executed */ + { + if (strcmp (Str_1_Par_Ref, Str_2_Par_Ref) > 0) + /* then, not executed */ + { + Int_Loc += 7; + Int_Glob = Int_Loc; + return (true); + } + else /* executed */ + return (false); + } /* if Ch_Loc */ +} /* Func_2 */ + + +Boolean Func_3( Enumeration Enum_Par_Val ) +/***************************/ + /* executed once */ + /* Enum_Par_Val == Ident_3 */ +{ + Enumeration Enum_Loc; + + Enum_Loc = Enum_Par_Val; + if (Enum_Loc == Ident_3) + /* then, executed */ + return (true); + else /* not executed */ + return (false); +} /* Func_3 */
rtl_sim/src-c/dhrystone_4mcu/original_files/dhry21b.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/original_files/Makefile =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/original_files/Makefile (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/original_files/Makefile (revision 145) @@ -0,0 +1,394 @@ +# WinAVR Sample makefile written by Eric B. Weddington, Jörg Wunsch, et al. +# Released to the Public Domain +# Please read the make user manual! +# +# Additional material for this makefile was submitted by: +# Tim Henigan +# Peter Fleury +# Reiner Patommel +# Sander Pool +# Frederik Rouleau +# Markus Pfaff +# +# On command line: +# +# make all = Make software. +# +# make clean = Clean out built project files. +# +# make coff = Convert ELF to AVR COFF (for use with AVR Studio 3.x or VMLAB). +# +# make extcoff = Convert ELF to AVR Extended COFF (for use with AVR Studio +# 4.07 or greater). +# +# make program = Download the hex file to the device, using avrdude. Please +# customize the avrdude settings below first! +# +# make filename.s = Just compile filename.c into the assembler code only +# +# To rebuild project do "make clean" then "make all". +# + + +# MCU name +MCU = atmega64 + +# Output format. (can be srec, ihex, binary) +FORMAT = ihex + +# Target file name (without extension). +TARGET = Dhrystone + + +# List C source files here. (C dependencies are automatically generated.) +SRC = dhry21a.c dhry21b.c timers_b.c estubs.c + + +# List Assembler source files here. +# Make them always end in a capital .S. Files ending in a lowercase .s +# will not be considered source files but generated files (assembler +# output from the compiler), and will be deleted upon "make clean"! +# Even though the DOS/Win* filesystem matches both .s and .S the same, +# it will preserve the spelling of the filenames, and gcc itself does +# care about how the name is spelled on its command-line. +ASRC = + + +# Optimization level, can be [0, 1, 2, 3, s]. +# 0 = turn off optimization. s = optimize for size. +# (Note: 3 is not always the best optimization level. See avr-libc FAQ.) +OPT = s + + +# List any extra directories to look for include files here. +# Each directory must be seperated by a space. +EXTRAINCDIRS = + + +# Compiler flag to set the C Standard level. +CSTANDARD_C89 = c89 +CSTANDARD_GNU89 = gnu89 +CSTANDARD_C99 = c99 +CSTANDARD_GNU99 = gnu99 +CSTANDARD = -std=$(CSTANDARD_GNU99) + + + +# Compiler flags. +# -g: generate debugging information +# -O*: optimization level +# -f...: tuning, see GCC manual and avr-libc documentation +# -Wall...: warning level +# -Wa,...: tell GCC to pass this to the assembler. +# -adhlns...: create assembler listing +CFLAGS = -g +CFLAGS += -O$(OPT) +CFLAGS += -funsigned-char -funsigned-bitfields -fpack-struct +CFLAGS += -Wall -Wstrict-prototypes +CFLAGS += -Wa,-adhlns=$(<:.c=.lst) +CFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS)) +CFLAGS += $(CSTANDARD) + + + +# Assembler flags. +# -Wa,...: tell GCC to pass this to the assembler. +# -ahlms: create listing +# -gstabs: have the assembler create line number information; note that +# for use in COFF files, additional information about filenames +# and function names needs to be present in the assembler source +# files -- see avr-libc docs [FIXME: not yet described there] +ASFLAGS = -Wa,-adhlns=$(<:.S=.lst),-gstabs + + + +#Additional libraries. + +PRINTF_LIB_NONE = + +# Minimalistic printf version +PRINTF_LIB_MIN = -Wl,-u,vfprintf -lprintf_min + +# Floating point printf version (requires MATH_LIB = -lm below) +PRINTF_LIB_FLOAT = -Wl,-u,vfprintf -lprintf_flt + +PRINTF_LIB = $(PRINTF_LIB_NONE) + +MATH_LIB = -lm + + + +# Linker flags. +# -Wl,...: tell GCC to pass this to linker. +# -Map: create map file +# --cref: add cross reference to map file +LDFLAGS = -Wl,-Map=$(TARGET).map,--cref $(PRINTF_LIB) $(MATH_LIB) + + + + +# Programming support using avrdude. Settings and variables. + +# Programming hardware: alf avr910 avrisp bascom bsd +# dt006 pavr picoweb pony-stk200 sp12 stk200 stk500 +# +# Type: avrdude -c ? +# to get a full listing. +# +AVRDUDE_PROGRAMMER = stk500 + +# com1 = serial port. Use lpt1 to connect to parallel port. +AVRDUDE_PORT = com1 # programmer connected to serial device + +AVRDUDE_WRITE_FLASH = -U flash:w:$(TARGET).hex +#AVRDUDE_WRITE_EEPROM = -U eeprom:w:$(TARGET).eep + + +# Uncomment the following if you want avrdude's erase cycle counter. +# Note that this counter needs to be initialized first using -Yn, +# see avrdude manual. +#AVRDUDE_ERASE_COUNTER = -y + +# Uncomment the following if you do /not/ wish a verification to be +# performed after programming the device. +#AVRDUDE_NO_VERIFY = -V + +# Increase verbosity level. Please use this when submitting bug +# reports about avrdude. See +# to submit bug reports. +#AVRDUDE_VERBOSE = -v -v + +AVRDUDE_FLAGS = -p $(MCU) -P $(AVRDUDE_PORT) -c $(AVRDUDE_PROGRAMMER) +AVRDUDE_FLAGS += $(AVRDUDE_NO_VERIFY) +AVRDUDE_FLAGS += $(AVRDUDE_VERBOSE) +AVRDUDE_FLAGS += $(AVRDUDE_ERASE_COUNTER) + + + +# --------------------------------------------------------------------------- + +# Define directories, if needed. +DIRAVR = C:/CygWin/WinAVR +DIRAVRBIN = $(DIRAVR)/bin +DIRAVRUTILS = $(DIRAVR)/utils/bin +DIRINC = . +DIRLIB = $(DIRAVR)/avr/lib + + +# Define programs and commands. +SHELL = sh +CC = avr-gcc +OBJCOPY = avr-objcopy +OBJDUMP = avr-objdump +SIZE = avr-size +NM = avr-nm +AVRDUDE = avrdude +REMOVE = rm -f +COPY = cp + + + + +# Define Messages +# English +MSG_ERRORS_NONE = Errors: none +MSG_BEGIN = -------- begin -------- +MSG_END = -------- end -------- +MSG_SIZE_BEFORE = Size before: +MSG_SIZE_AFTER = Size after: +MSG_COFF = Converting to AVR COFF: +MSG_EXTENDED_COFF = Converting to AVR Extended COFF: +MSG_FLASH = Creating load file for Flash: +MSG_EEPROM = Creating load file for EEPROM: +MSG_EXTENDED_LISTING = Creating Extended Listing: +MSG_SYMBOL_TABLE = Creating Symbol Table: +MSG_LINKING = Linking: +MSG_COMPILING = Compiling: +MSG_ASSEMBLING = Assembling: +MSG_CLEANING = Cleaning project: + + + + +# Define all object files. +OBJ = $(SRC:.c=.o) $(ASRC:.S=.o) + +# Define all listing files. +LST = $(ASRC:.S=.lst) $(SRC:.c=.lst) + + +# Compiler flags to generate dependency files. +GENDEPFLAGS = -Wp,-M,-MP,-MT,$(*F).o,-MF,.dep/$(@F).d + + +# Combine all necessary flags and optional flags. +# Add target processor to flags. +ALL_CFLAGS = -mmcu=$(MCU) -I. $(CFLAGS) $(GENDEPFLAGS) +ALL_ASFLAGS = -mmcu=$(MCU) -I. -x assembler-with-cpp $(ASFLAGS) + + + + + +# Default target. +all: begin gccversion sizebefore build sizeafter finished end + +build: elf hex eep lss sym + +elf: $(TARGET).elf +hex: $(TARGET).hex +eep: $(TARGET).eep +lss: $(TARGET).lss +sym: $(TARGET).sym + + + +# Eye candy. +# AVR Studio 3.x does not check make's exit code but relies on +# the following magic strings to be generated by the compile job. +begin: + @echo + @echo $(MSG_BEGIN) + +finished: + @echo $(MSG_ERRORS_NONE) + +end: + @echo $(MSG_END) + @echo + + +# Display size of file. +HEXSIZE = $(SIZE) --target=$(FORMAT) $(TARGET).hex +ELFSIZE = $(SIZE) -A $(TARGET).elf +sizebefore: + @if [ -f $(TARGET).elf ]; then echo; echo $(MSG_SIZE_BEFORE); $(ELFSIZE); echo; fi + +sizeafter: + @if [ -f $(TARGET).elf ]; then echo; echo $(MSG_SIZE_AFTER); $(ELFSIZE); echo; fi + + + +# Display compiler version information. +gccversion : + @$(CC) --version + + + +# Program the device. +program: $(TARGET).hex $(TARGET).eep + $(AVRDUDE) $(AVRDUDE_FLAGS) $(AVRDUDE_WRITE_FLASH) $(AVRDUDE_WRITE_EEPROM) + + + + +# Convert ELF to COFF for use in debugging / simulating in AVR Studio or VMLAB. +COFFCONVERT=$(OBJCOPY) --debugging \ +--change-section-address .data-0x800000 \ +--change-section-address .bss-0x800000 \ +--change-section-address .noinit-0x800000 \ +--change-section-address .eeprom-0x810000 + + +coff: $(TARGET).elf + @echo + @echo $(MSG_COFF) $(TARGET).cof + $(COFFCONVERT) -O coff-avr $< $(TARGET).cof + + +extcoff: $(TARGET).elf + @echo + @echo $(MSG_EXTENDED_COFF) $(TARGET).cof + $(COFFCONVERT) -O coff-ext-avr $< $(TARGET).cof + + + +# Create final output files (.hex, .eep) from ELF output file. +%.hex: %.elf + @echo + @echo $(MSG_FLASH) $@ + $(OBJCOPY) -O $(FORMAT) -R .eeprom $< $@ + +%.eep: %.elf + @echo + @echo $(MSG_EEPROM) $@ + -$(OBJCOPY) -j .eeprom --set-section-flags=.eeprom="alloc,load" \ + --change-section-lma .eeprom=0 -O $(FORMAT) $< $@ + +# Create extended listing file from ELF output file. +%.lss: %.elf + @echo + @echo $(MSG_EXTENDED_LISTING) $@ + $(OBJDUMP) -h -S $< > $@ + +# Create a symbol table from ELF output file. +%.sym: %.elf + @echo + @echo $(MSG_SYMBOL_TABLE) $@ + $(NM) -n $< > $@ + + + +# Link: create ELF output file from object files. +.SECONDARY : $(TARGET).elf +.PRECIOUS : $(OBJ) +%.elf: $(OBJ) + @echo + @echo $(MSG_LINKING) $@ + $(CC) $(ALL_CFLAGS) $(OBJ) --output $@ $(LDFLAGS) + + +# Compile: create object files from C source files. +%.o : %.c + @echo + @echo $(MSG_COMPILING) $< + $(CC) -c $(ALL_CFLAGS) $< -o $@ + + +# Compile: create assembler files from C source files. +%.s : %.c + $(CC) -S $(ALL_CFLAGS) $< -o $@ + + +# Assemble: create object files from assembler source files. +%.o : %.S + @echo + @echo $(MSG_ASSEMBLING) $< + $(CC) -c $(ALL_ASFLAGS) $< -o $@ + + + +# Target: clean project. +clean: begin clean_list finished end + +clean_list : + @echo + @echo $(MSG_CLEANING) + $(REMOVE) $(TARGET).hex + $(REMOVE) $(TARGET).eep + $(REMOVE) $(TARGET).obj + $(REMOVE) $(TARGET).cof + $(REMOVE) $(TARGET).elf + $(REMOVE) $(TARGET).map + $(REMOVE) $(TARGET).obj + $(REMOVE) $(TARGET).a90 + $(REMOVE) $(TARGET).sym + $(REMOVE) $(TARGET).lnk + $(REMOVE) $(TARGET).lss + $(REMOVE) $(OBJ) + $(REMOVE) $(LST) + $(REMOVE) $(SRC:.c=.s) + $(REMOVE) $(SRC:.c=.d) + $(REMOVE) .dep/* + + + +# Include the dependency files. +-include $(shell mkdir .dep 2>/dev/null) $(wildcard .dep/*) + + +# Listing of phony targets. +.PHONY : all begin finish end sizebefore sizeafter gccversion \ +build elf hex eep lss sym coff extcoff \ +clean clean_list program +
rtl_sim/src-c/dhrystone_4mcu/original_files/Makefile Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/original_files/dhyrstone.pro =================================================================== Cannot display: file marked as a binary type. svn:mime-type = application/octet-stream Index: rtl_sim/src-c/dhrystone_4mcu/original_files/dhyrstone.pro =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/original_files/dhyrstone.pro (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/original_files/dhyrstone.pro (revision 145)
rtl_sim/src-c/dhrystone_4mcu/original_files/dhyrstone.pro Property changes : Added: svn:mime-type ## -0,0 +1 ## +application/octet-stream \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/linker.x =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/linker.x (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/linker.x (revision 145) @@ -0,0 +1,216 @@ +/* Default linker script, for normal executables */ +OUTPUT_FORMAT("elf32-msp430") +OUTPUT_ARCH("msp430") +MEMORY { + sfr : ORIGIN = 0x0000, LENGTH = 0x0010 + peripheral_8bit : ORIGIN = 0x0010, LENGTH = 0x00f0 + peripheral_16bit : ORIGIN = 0x0100, LENGTH = 0x0100 + + ram (wx) : ORIGIN = 0x0200, LENGTH = 0x4000 + rom (rx) : ORIGIN = 0xA000, LENGTH = 0x6000-0x20 + vectors : ORIGIN = 0xffe0, LENGTH = 0x0020 + + /* Remaining banks are absent */ + bsl : ORIGIN = 0x0000, LENGTH = 0x0000 + infomem : ORIGIN = 0x0000, LENGTH = 0x0000 + infob : ORIGIN = 0x0000, LENGTH = 0x0000 + infoa : ORIGIN = 0x0000, LENGTH = 0x0000 + infoc : ORIGIN = 0x0000, LENGTH = 0x0000 + infod : ORIGIN = 0x0000, LENGTH = 0x0000 + ram2 (wx) : ORIGIN = 0x0000, LENGTH = 0x0000 + ram_mirror (wx) : ORIGIN = 0x0000, LENGTH = 0x0000 + usbram (wx) : ORIGIN = 0x0000, LENGTH = 0x0000 + far_rom : ORIGIN = 0x00000000, LENGTH = 0x00000000 +} +REGION_ALIAS("REGION_TEXT", rom); +REGION_ALIAS("REGION_DATA", ram); +REGION_ALIAS("REGION_FAR_ROM", far_rom); +__WDTCTL = 0x0120; +__MPY = 0x0130; +__MPYS = 0x0132; +__MAC = 0x0134; +__MACS = 0x0136; +__OP2 = 0x0138; +__RESLO = 0x013A; +__RESHI = 0x013C; +__SUMEXT = 0x013E; + +SECTIONS +{ + /* Read-only sections, merged into text segment. */ + .hash : { *(.hash) } + .dynsym : { *(.dynsym) } + .dynstr : { *(.dynstr) } + .gnu.version : { *(.gnu.version) } + .gnu.version_d : { *(.gnu.version_d) } + .gnu.version_r : { *(.gnu.version_r) } + .rel.init : { *(.rel.init) } + .rela.init : { *(.rela.init) } + .rel.fini : { *(.rel.fini) } + .rela.fini : { *(.rela.fini) } + .rel.text : { *(.rel.text .rel.text.* .rel.gnu.linkonce.t.*) } + .rela.text : { *(.rela.text .rela.text.* .rela.gnu.linkonce.t.*) } + .rel.rodata : { *(.rel.rodata .rel.rodata.* .rel.gnu.linkonce.r.*) } + .rela.rodata : { *(.rela.rodata .rela.rodata.* .rela.gnu.linkonce.r.*) } + .rel.data : { *(.rel.data .rel.data.* .rel.gnu.linkonce.d.*) } + .rela.data : { *(.rela.data .rela.data.* .rela.gnu.linkonce.d.*) } + .rel.bss : { *(.rel.bss .rel.bss.* .rel.gnu.linkonce.b.*) } + .rela.bss : { *(.rela.bss .rela.bss.* .rela.gnu.linkonce.b.*) } + .rel.ctors : { *(.rel.ctors) } + .rela.ctors : { *(.rela.ctors) } + .rel.dtors : { *(.rel.dtors) } + .rela.dtors : { *(.rela.dtors) } + .rel.got : { *(.rel.got) } + .rela.got : { *(.rela.got) } + .rel.plt : { *(.rel.plt) } + .rela.plt : { *(.rela.plt) } + .text : + { + . = ALIGN(2); + KEEP(*(.init .init.*)) + KEEP(*(.init0)) /* Start here after reset. */ + KEEP(*(.init1)) /* User definable. */ + KEEP(*(.init2)) /* Initialize stack. */ + KEEP(*(.init3)) /* Initialize hardware, user definable. */ + KEEP(*(.init4)) /* Copy data to .data, clear bss. */ + KEEP(*(.init5)) /* User definable. */ + KEEP(*(.init6)) /* C++ constructors. */ + KEEP(*(.init7)) /* User definable. */ + KEEP(*(.init8)) /* User definable. */ + KEEP(*(.init9)) /* Call main(). */ + KEEP(*(.fini9)) /* Falls into here after main(). User definable. */ + KEEP(*(.fini8)) /* User definable. */ + KEEP(*(.fini7)) /* User definable. */ + KEEP(*(.fini6)) /* C++ destructors. */ + KEEP(*(.fini5)) /* User definable. */ + KEEP(*(.fini4)) /* User definable. */ + KEEP(*(.fini3)) /* User definable. */ + KEEP(*(.fini2)) /* User definable. */ + KEEP(*(.fini1)) /* User definable. */ + KEEP(*(.fini0)) /* Infinite loop after program termination. */ + KEEP(*(.fini .fini.*)) + . = ALIGN(2); + __ctors_start = . ; + KEEP(*(.ctors)) + __ctors_end = . ; + __dtors_start = . ; + KEEP(*(.dtors)) + __dtors_end = . ; + . = ALIGN(2); + *(.text .text.* .gnu.linkonce.t.*) + . = ALIGN(2); + } > REGION_TEXT + .rodata : + { + . = ALIGN(2); + *(.rodata .rodata.* .gnu.linkonce.r.*) + . = ALIGN(2); + } > REGION_TEXT + _etext = .; /* Past last read-only (loadable) segment */ + .data : + { + . = ALIGN(2); + PROVIDE (__data_start = .) ; + *(.data .data.* .gnu.linkonce.d.*) + . = ALIGN(2); + _edata = . ; /* Past last read-write (loadable) segment */ + } > REGION_DATA AT > REGION_TEXT + PROVIDE (__data_load_start = LOADADDR(.data) ); + PROVIDE (__data_size = SIZEOF(.data) ); + .bss : + { + PROVIDE (__bss_start = .) ; + *(.bss .bss.*) + *(COMMON) + . = ALIGN(2); + PROVIDE (__bss_end = .) ; + } > REGION_DATA + PROVIDE (__bss_size = SIZEOF(.bss) ); + .noinit : + { + PROVIDE (__noinit_start = .) ; + *(.noinit .noinit.*) + . = ALIGN(2); + PROVIDE (__noinit_end = .) ; + } > REGION_DATA + . = ALIGN(2); + _end = . ; /* Past last write (loadable) segment */ + .infomem : + { + *(.infomem) + . = ALIGN(2); + *(.infomem.*) + } > infomem + .infomemnobits : + { + *(.infomemnobits) + . = ALIGN(2); + *(.infomemnobits.*) + } > infomem + .infoa : + { + *(.infoa .infoa.*) + } > infoa + .infob : + { + *(.infob .infob.*) + } > infob + .infoc : + { + *(.infoc .infoc.*) + } > infoc + .infod : + { + *(.infod .infod.*) + } > infod + .vectors : + { + PROVIDE (__vectors_start = .) ; + KEEP(*(.vectors*)) + _vectors_end = . ; + } > vectors + .fartext : + { + . = ALIGN(2); + *(.fartext) + . = ALIGN(2); + *(.fartext.*) + _efartext = .; + } > REGION_FAR_ROM + /* Stabs for profiling information*/ + .profiler 0 : { *(.profiler) } + /* Stabs debugging sections. */ + .stab 0 : { *(.stab) } + .stabstr 0 : { *(.stabstr) } + .stab.excl 0 : { *(.stab.excl) } + .stab.exclstr 0 : { *(.stab.exclstr) } + .stab.index 0 : { *(.stab.index) } + .stab.indexstr 0 : { *(.stab.indexstr) } + .comment 0 : { *(.comment) } + /* DWARF debug sections. + Symbols in the DWARF debugging sections are relative to the beginning + of the section so we begin them at 0. */ + /* DWARF 1 */ + .debug 0 : { *(.debug) } + .line 0 : { *(.line) } + /* GNU DWARF 1 extensions */ + .debug_srcinfo 0 : { *(.debug_srcinfo) } + .debug_sfnames 0 : { *(.debug_sfnames) } + /* DWARF 1.1 and DWARF 2 */ + .debug_aranges 0 : { *(.debug_aranges) } + .debug_pubnames 0 : { *(.debug_pubnames) } + /* DWARF 2 */ + .debug_info 0 : { *(.debug_info) *(.gnu.linkonce.wi.*) } + .debug_abbrev 0 : { *(.debug_abbrev) } + .debug_line 0 : { *(.debug_line) } + .debug_frame 0 : { *(.debug_frame) } + .debug_str 0 : { *(.debug_str) } + .debug_loc 0 : { *(.debug_loc) } + .debug_macinfo 0 : { *(.debug_macinfo) } + /* DWARF 3 */ + .debug_pubtypes 0 : { *(.debug_pubtypes) } + .debug_ranges 0 : { *(.debug_ranges) } + PROVIDE (__stack = ORIGIN(ram) + LENGTH(ram)); + PROVIDE (__data_start_rom = _etext); + PROVIDE (__data_end_rom = _etext + SIZEOF (.data)); +}
rtl_sim/src-c/dhrystone_4mcu/linker.x Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/omsp_func.c =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/omsp_func.c (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/omsp_func.c (revision 145) @@ -0,0 +1,51 @@ +/*===========================================================================*/ +/* Copyright (C) 2001 Authors */ +/* */ +/* This source file may be used and distributed without restriction provided */ +/* that this copyright statement is not removed from the file and that any */ +/* derivative work contains the original copyright notice and the associated */ +/* disclaimer. */ +/* */ +/* This source file is free software; you can redistribute it and/or modify */ +/* it under the terms of the GNU Lesser General Public License as published */ +/* by the Free Software Foundation; either version 2.1 of the License, or */ +/* (at your option) any later version. */ +/* */ +/* This source is distributed in the hope that it will be useful, but WITHOUT*/ +/* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */ +/* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */ +/* License for more details. */ +/* */ +/* You should have received a copy of the GNU Lesser General Public License */ +/* along with this source; if not, write to the Free Software Foundation, */ +/* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ +/* */ +/*===========================================================================*/ +/* OMSP_FUNC C FILE */ +/*---------------------------------------------------------------------------*/ +/* */ +/* Author(s): */ +/* - Olivier Girard, olgirard@gmail.com */ +/* */ +/*---------------------------------------------------------------------------*/ +/* $Rev: 19 $ */ +/* $LastChangedBy: olivier.girard $ */ +/* $LastChangedDate: 2009-08-04 23:47:15 +0200 (Tue, 04 Aug 2009) $ */ +/*===========================================================================*/ + +#include "omsp_func.h" + +//--------------------------------------------------// +// putChar function // +// (Send a byte to the Port-1) // +//--------------------------------------------------// +int putchar (int txdata) { + + // Write the output character to the Port-1 + P1OUT = txdata; + + // Toggle Port-2[0] to signal new byte + P2OUT ^= 0x01; + + return 0; +}
rtl_sim/src-c/dhrystone_4mcu/omsp_func.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/dhry21a.c =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/dhry21a.c (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/dhry21a.c (revision 145) @@ -0,0 +1,402 @@ +/* + ************************************************************************* + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: C, Version 2.1 + * + * File: dhry_1.c (part 2 of 3) + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * + ************************************************************************* + */ + +/*************************************************************************** + * Adapted for embedded microcontrollers by Graham Davies, ECROS Technology. + **************************************************************************/ + +#include "dhry.h" +#include +#include +#include +#include "omsp_func.h" + +/* Global Variables: */ + +Rec_Pointer Ptr_Glob, + Next_Ptr_Glob; +int Int_Glob; +Boolean Bool_Glob; +char Ch_1_Glob, + Ch_2_Glob; +int Arr_1_Glob [25]; /* <-- changed from 50 */ +int Arr_2_Glob [25] [25]; /* <-- changed from 50 */ + +char Reg_Define[] = "Register option selected."; + +#ifndef ROPT +#define REG + /* REG becomes defined as empty */ + /* i.e. no register variables */ +#else +#define REG register +#endif + + +/* variables for time measurement: */ + +#define Too_Small_Time 2 + /* Measurements should last at least 2 seconds */ + +double Begin_Time, + End_Time, + User_Time; + +double Microseconds, + Dhrystones_Per_Second, + Vax_Mips; + +/* end of variables for time measurement */ + +void Proc_1( REG Rec_Pointer Ptr_Val_Par ); +void Proc_2( One_Fifty * Int_Par_Ref ); +void Proc_3( Rec_Pointer * Ptr_Ref_Par ); +void Proc_4( void ); +void Proc_5( void ); + +int main( void ) +/*****/ + + /* main program, corresponds to procedures */ + /* Main and Proc_0 in the Ada version */ +{ + // double dtime( void ); + + One_Fifty Int_1_Loc; + REG One_Fifty Int_2_Loc; + One_Fifty Int_3_Loc; + REG char Ch_Index; + Enumeration Enum_Loc; + Str_30 Str_1_Loc; + Str_30 Str_2_Loc; + REG int Run_Index; + REG int Number_Of_Runs; + + // FILE *Ap; + + /* Initializations */ + + STOP_WATCHDOG; + + /* + if ((Ap = fopen("dhry.res","a+")) == NULL) + { + printf("Can not open dhry.res\n\n"); + exit(1); + } + */ + + Next_Ptr_Glob = (Rec_Pointer)malloc (sizeof (Rec_Type)); + Ptr_Glob = (Rec_Pointer)malloc (sizeof (Rec_Type)); + + Ptr_Glob->Ptr_Comp = Next_Ptr_Glob; + Ptr_Glob->Discr = Ident_1; + Ptr_Glob->variant.var_1.Enum_Comp = Ident_3; + Ptr_Glob->variant.var_1.Int_Comp = 40; + strcpy (Ptr_Glob->variant.var_1.Str_Comp, + "DHRYSTONE PROGRAM, SOME STRING"); + strcpy (Str_1_Loc, "DHRYSTONE PROGRAM, 1'ST STRING"); + + Arr_2_Glob [8][7] = 10; + /* Was missing in published program. Without this statement, */ + /* Arr_2_Glob [8][7] would have an undefined value. */ + /* Warning: With 16-Bit processors and Number_Of_Runs > 32000, */ + /* overflow may occur for this array element. */ + + printf ("\n"); + printf ("Dhrystone Benchmark, Version 2.1 (Language: C)\n"); + printf ("\n"); +/* + if (Reg) + { + printf ("Program compiled with 'register' attribute\n"); + printf ("\n"); + } + else + { + printf ("Program compiled without 'register' attribute\n"); + printf ("\n"); + } +*/ +/* + printf ("Please give the number of runs through the benchmark: "); + { + int n; + scanf ("%d", &n); + Number_Of_Runs = n; + } + printf ("\n"); +*/ + Number_Of_Runs = 100; + + printf ("Execution starts, %d runs through Dhrystone\n",Number_Of_Runs); + + /***************/ + /* Start timer */ + /***************/ + + Begin_Time = 1;//dtime(); + START_TIME; // Set P3[0] + + for (Run_Index = 1; Run_Index <= Number_Of_Runs; ++Run_Index ) + { + + //SetPort( 1 ); /* <-- added; set port high */ + Proc_5(); + Proc_4(); + /* Ch_1_Glob == 'A', Ch_2_Glob == 'B', Bool_Glob == true */ + Int_1_Loc = 2; + Int_2_Loc = 3; + strcpy (Str_2_Loc, "DHRYSTONE PROGRAM, 2'ND STRING"); + Enum_Loc = Ident_2; + Bool_Glob = ! Func_2 (Str_1_Loc, Str_2_Loc); + /* Bool_Glob == 1 */ + while (Int_1_Loc < Int_2_Loc) /* loop body executed once */ + { + Int_3_Loc = 5 * Int_1_Loc - Int_2_Loc; + /* Int_3_Loc == 7 */ + Proc_7 (Int_1_Loc, Int_2_Loc, &Int_3_Loc); + /* Int_3_Loc == 7 */ + Int_1_Loc += 1; + } /* while */ + //SetPort( 0 ); /* <-- added; set port low */ + /* Int_1_Loc == 3, Int_2_Loc == 3, Int_3_Loc == 7 */ + Proc_8 (Arr_1_Glob, Arr_2_Glob, Int_1_Loc, Int_3_Loc); + /* Int_Glob == 5 */ + Proc_1 (Ptr_Glob); + for (Ch_Index = 'A'; Ch_Index <= Ch_2_Glob; ++Ch_Index) + /* loop body executed twice */ + { + if (Enum_Loc == Func_1 (Ch_Index, 'C')) + /* then, not executed */ + { + Proc_6 (Ident_1, &Enum_Loc); + strcpy (Str_2_Loc, "DHRYSTONE PROGRAM, 3'RD STRING"); + Int_2_Loc = Run_Index; + Int_Glob = Run_Index; + } + } + /* Int_1_Loc == 3, Int_2_Loc == 3, Int_3_Loc == 7 */ + Int_2_Loc = Int_2_Loc * Int_1_Loc; + Int_1_Loc = Int_2_Loc / Int_3_Loc; + Int_2_Loc = 7 * (Int_2_Loc - Int_3_Loc) - Int_1_Loc; + /* Int_1_Loc == 1, Int_2_Loc == 13, Int_3_Loc == 7 */ + Proc_2 (&Int_1_Loc); + /* Int_1_Loc == 5 */ + + } /* loop "for Run_Index" */ + + /**************/ + /* Stop timer */ + /**************/ + + END_TIME; // Clear P3[0] + End_Time = 2;//dtime(); + + printf ("Execution ends\n"); + printf ("\n"); + printf ("Final values of the variables used in the benchmark:\n"); + printf ("\n"); + printf ("Int_Glob: %d\n", Int_Glob); + printf (" should be: %d\n", 5); + printf ("Bool_Glob: %d\n", Bool_Glob); + printf (" should be: %d\n", 1); + printf ("Ch_1_Glob: %c\n", Ch_1_Glob); + printf (" should be: %c\n", 'A'); + printf ("Ch_2_Glob: %c\n", Ch_2_Glob); + printf (" should be: %c\n", 'B'); + printf ("Arr_1_Glob[8]: %d\n", Arr_1_Glob[8]); + printf (" should be: %d\n", 7); + printf ("Arr_2_Glob[8][7]: %d\n", Arr_2_Glob[8][7]); + printf (" should be: Number_Of_Runs + 10\n"); + printf ("Ptr_Glob->\n"); + printf (" Ptr_Comp: %d\n", (int) Ptr_Glob->Ptr_Comp); + printf (" should be: (implementation-dependent)\n"); + printf (" Discr: %d\n", Ptr_Glob->Discr); + printf (" should be: %d\n", 0); + printf (" Enum_Comp: %d\n", Ptr_Glob->variant.var_1.Enum_Comp); + printf (" should be: %d\n", 2); + printf (" Int_Comp: %d\n", Ptr_Glob->variant.var_1.Int_Comp); + printf (" should be: %d\n", 17); + printf (" Str_Comp: %s\n", Ptr_Glob->variant.var_1.Str_Comp); + printf (" should be: DHRYSTONE PROGRAM, SOME STRING\n"); + printf ("Next_Ptr_Glob->\n"); + printf (" Ptr_Comp: %d\n", (int) Next_Ptr_Glob->Ptr_Comp); + printf (" should be: (implementation-dependent), same as above\n"); + printf (" Discr: %d\n", Next_Ptr_Glob->Discr); + printf (" should be: %d\n", 0); + printf (" Enum_Comp: %d\n", Next_Ptr_Glob->variant.var_1.Enum_Comp); + printf (" should be: %d\n", 1); + printf (" Int_Comp: %d\n", Next_Ptr_Glob->variant.var_1.Int_Comp); + printf (" should be: %d\n", 18); + printf (" Str_Comp: %s\n", Next_Ptr_Glob->variant.var_1.Str_Comp); + printf (" should be: DHRYSTONE PROGRAM, SOME STRING\n"); + printf ("Int_1_Loc: %d\n", Int_1_Loc); + printf (" should be: %d\n", 5); + printf ("Int_2_Loc: %d\n", Int_2_Loc); + printf (" should be: %d\n", 13); + printf ("Int_3_Loc: %d\n", Int_3_Loc); + printf (" should be: %d\n", 7); + printf ("Enum_Loc: %d\n", Enum_Loc); + printf (" should be: %d\n", 1); + printf ("Str_1_Loc: %s\n", Str_1_Loc); + printf (" should be: DHRYSTONE PROGRAM, 1'ST STRING\n"); + printf ("Str_2_Loc: %s\n", Str_2_Loc); + printf (" should be: DHRYSTONE PROGRAM, 2'ND STRING\n"); + printf ("\n"); + + /* + User_Time = End_Time - Begin_Time; + + if (User_Time < Too_Small_Time) + { + printf ("Measured time too small to obtain meaningful results\n"); + printf ("Please increase number of runs\n"); + printf ("\n"); + } + else + { + Microseconds = User_Time * Mic_secs_Per_Second + / (double) Number_Of_Runs; + Dhrystones_Per_Second = (double) Number_Of_Runs / User_Time; + Vax_Mips = Dhrystones_Per_Second / 1757.0; + +#ifdef ROPT + printf ("Register option selected? YES\n"); +#else + printf ("Register option selected? NO\n"); + strcpy(Reg_Define, "Register option not selected."); +#endif + printf ("Microseconds for one run through Dhrystone: "); + printf ("%7.1lf \n", Microseconds); + printf ("Dhrystones per Second: "); + printf ("%10.1lf \n", Dhrystones_Per_Second); + printf ("VAX MIPS rating = %10.3lf \n",Vax_Mips); + printf ("\n"); + + fprintf(Ap,"\n"); + fprintf(Ap,"Dhrystone Benchmark, Version 2.1 (Language: C)\n"); + fprintf(Ap,"%s\n",Reg_Define); + fprintf(Ap,"Microseconds for one loop: %7.1lf\n",Microseconds); + fprintf(Ap,"Dhrystones per second: %10.1lf\n",Dhrystones_Per_Second); + fprintf(Ap,"VAX MIPS rating: %10.3lf\n",Vax_Mips); + fclose(Ap); + + } + */ + DHRYSTONE_DONE; + return ( 0 ); +} + + +void Proc_1( REG Rec_Pointer Ptr_Val_Par ) +/******************/ + /* executed once */ +{ + REG Rec_Pointer Next_Record = Ptr_Val_Par->Ptr_Comp; + /* == Ptr_Glob_Next */ + /* Local variable, initialized with Ptr_Val_Par->Ptr_Comp, */ + /* corresponds to "rename" in Ada, "with" in Pascal */ + + structassign (*Ptr_Val_Par->Ptr_Comp, *Ptr_Glob); + Ptr_Val_Par->variant.var_1.Int_Comp = 5; + Next_Record->variant.var_1.Int_Comp + = Ptr_Val_Par->variant.var_1.Int_Comp; + Next_Record->Ptr_Comp = Ptr_Val_Par->Ptr_Comp; + Proc_3 (&Next_Record->Ptr_Comp); + /* Ptr_Val_Par->Ptr_Comp->Ptr_Comp + == Ptr_Glob->Ptr_Comp */ + if (Next_Record->Discr == Ident_1) + /* then, executed */ + { + Next_Record->variant.var_1.Int_Comp = 6; + Proc_6 (Ptr_Val_Par->variant.var_1.Enum_Comp, + &Next_Record->variant.var_1.Enum_Comp); + Next_Record->Ptr_Comp = Ptr_Glob->Ptr_Comp; + Proc_7 (Next_Record->variant.var_1.Int_Comp, 10, + &Next_Record->variant.var_1.Int_Comp); + } + else /* not executed */ + structassign (*Ptr_Val_Par, *Ptr_Val_Par->Ptr_Comp); +} /* Proc_1 */ + + +void Proc_2( One_Fifty * Int_Par_Ref ) +/******************/ + /* executed once */ + /* *Int_Par_Ref == 1, becomes 4 */ +{ + One_Fifty Int_Loc; + Enumeration Enum_Loc; + + Int_Loc = *Int_Par_Ref + 10; + do /* executed once */ + if (Ch_1_Glob == 'A') + /* then, executed */ + { + Int_Loc -= 1; + *Int_Par_Ref = Int_Loc - Int_Glob; + Enum_Loc = Ident_1; + } /* if */ + while (Enum_Loc != Ident_1); /* true */ +} /* Proc_2 */ + + +void Proc_3( Rec_Pointer * Ptr_Ref_Par ) +/******************/ + /* executed once */ + /* Ptr_Ref_Par becomes Ptr_Glob */ +{ + if (Ptr_Glob != Null) + /* then, executed */ + *Ptr_Ref_Par = Ptr_Glob->Ptr_Comp; + Proc_7 (10, Int_Glob, &Ptr_Glob->variant.var_1.Int_Comp); +} /* Proc_3 */ + + +void Proc_4( void ) /* without parameters */ +/*******/ + /* executed once */ +{ + Boolean Bool_Loc; + + Bool_Loc = Ch_1_Glob == 'A'; + Bool_Glob = Bool_Loc | Bool_Glob; + Ch_2_Glob = 'B'; +} /* Proc_4 */ + + +void Proc_5( void ) /* without parameters */ +/*******/ + /* executed once */ +{ + Ch_1_Glob = 'A'; + Bool_Glob = false; +} /* Proc_5 */ + + + /* Procedure for the assignment of structures, */ + /* if the C compiler doesn't support this feature */ +#ifdef NOSTRUCTASSIGN +memcpy (d, s, l) +register char *d; +register char *s; +register int l; +{ + while (l--) *d++ = *s++; +} +#endif
rtl_sim/src-c/dhrystone_4mcu/dhry21a.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/dhrystone_4mcu.v =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/dhrystone_4mcu.v (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/dhrystone_4mcu.v (revision 145) @@ -0,0 +1,137 @@ +/*===========================================================================*/ +/* Copyright (C) 2001 Authors */ +/* */ +/* This source file may be used and distributed without restriction provided */ +/* that this copyright statement is not removed from the file and that any */ +/* derivative work contains the original copyright notice and the associated */ +/* disclaimer. */ +/* */ +/* This source file is free software; you can redistribute it and/or modify */ +/* it under the terms of the GNU Lesser General Public License as published */ +/* by the Free Software Foundation; either version 2.1 of the License, or */ +/* (at your option) any later version. */ +/* */ +/* This source is distributed in the hope that it will be useful, but WITHOUT*/ +/* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */ +/* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */ +/* License for more details. */ +/* */ +/* You should have received a copy of the GNU Lesser General Public License */ +/* along with this source; if not, write to the Free Software Foundation, */ +/* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ +/* */ +/*===========================================================================*/ +/* SANDBOX */ +/*---------------------------------------------------------------------------*/ +/* */ +/* Author(s): */ +/* - Olivier Girard, olgirard@gmail.com */ +/* */ +/*---------------------------------------------------------------------------*/ +/* $Rev: 19 $ */ +/* $LastChangedBy: olivier.girard $ */ +/* $LastChangedDate: 2009-08-04 23:47:15 +0200 (Tue, 04 Aug 2009) $ */ +/*===========================================================================*/ +`define NO_TIMEOUT + +time mclk_start_time, mclk_end_time; +real mclk_period, mclk_frequency; + +time dhry_start_time, dhry_end_time; +real dhry_per_sec, dhry_mips, dhry_mips_per_mhz; + +integer Number_Of_Runs; + +initial + begin + $display(" ==============================================="); + $display("| START SIMULATION |"); + $display(" ==============================================="); + repeat(5) @(posedge mclk); + stimulus_done = 0; + + //--------------------------------------- + // Check CPU configuration + //--------------------------------------- + + if ((`PMEM_SIZE !== 24576) || (`DMEM_SIZE !== 16384)) + begin + $display(" ==============================================="); + $display("| SIMULATION ERROR |"); + $display("| |"); + $display("| Core must be configured for: |"); + $display("| - 24kB program memory |"); + $display("| - 16kB data memory |"); + $display(" ==============================================="); + $finish; + end + + //--------------------------------------- + // Number of benchmark iteration + // (Must match the C-code value) + //--------------------------------------- + + Number_Of_Runs = 100; + + + //--------------------------------------- + // Measure clock period + //--------------------------------------- + repeat(100) @(posedge mclk); + $timeformat(-9, 3, " ns", 10); + @(posedge mclk); + mclk_start_time = $time; + @(posedge mclk); + mclk_end_time = $time; + @(posedge mclk); + mclk_period = mclk_end_time-mclk_start_time; + mclk_frequency = 1000/mclk_period; + $display("\nINFO-VERILOG: openMSP430 System clock frequency %f MHz\n", mclk_frequency); + + //--------------------------------------- + // Measure Dhrystone run time + //--------------------------------------- + + // Detect beginning of run + @(posedge p3_dout[0]); + dhry_start_time = $time; + $timeformat(-3, 3, " ms", 10); + $display("\nINFO-VERILOG: Dhrystone loop started at %t ", dhry_start_time); + + // Detect end of run + @(negedge p3_dout[0]); + dhry_end_time = $time; + $timeformat(-3, 3, " ms", 10); + $display("INFO-VERILOG: Dhrystone loop ended at %t ", dhry_end_time); + + // Compute results + $timeformat(-9, 3, " ns", 10); + dhry_per_sec = (Number_Of_Runs*1000000000)/(dhry_end_time - dhry_start_time); + dhry_mips = dhry_per_sec / 1757; + dhry_mips_per_mhz = dhry_mips / mclk_frequency; + + // Report results + $display("\INFO-VERILOG: Dhrystone per second : %f", dhry_per_sec); + $display("\INFO-VERILOG: DMIPS : %f", dhry_mips); + $display("\INFO-VERILOG: DMIPS/MHz : %f\n", dhry_mips_per_mhz); + + //--------------------------------------- + // Wait for the end of C-code execution + //--------------------------------------- + @(posedge p4_dout[0]); + + stimulus_done = 1; + + $display(" ==============================================="); + $display("| SIMULATION DONE |"); + $display("| (stopped through verilog stimulus) |"); + $display(" ==============================================="); + $finish; + + end + +// Display stuff from the C-program +always @(p2_dout[0]) + begin + $write("%s", p1_dout); + end
rtl_sim/src-c/dhrystone_4mcu/dhrystone_4mcu.v Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/dhry.h =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/dhry.h (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/dhry.h (revision 145) @@ -0,0 +1,448 @@ +/* + ************************************************************************* + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: C, Version 2.1 + * + * File: dhry.h (part 1 of 3) + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * Siemens Nixdorf Inf. Syst. + * STM OS 32 + * Otto-Hahn-Ring 6 + * W-8000 Muenchen 83 + * Germany + * Phone: [+49]-89-636-42436 + * (8-17 Central European Time) + * UUCP: weicker@ztivax.uucp@unido.uucp + * Internet: weicker@ztivax.siemens.com + * + * Original Version (in Ada) published in + * "Communications of the ACM" vol. 27., no. 10 (Oct. 1984), + * pp. 1013 - 1030, together with the statistics + * on which the distribution of statements etc. is based. + * + * In this C version, the following C library functions are + * used: + * - strcpy, strcmp (inside the measurement loop) + * - printf, scanf (outside the measurement loop) + * + * Collection of Results: + * Reinhold Weicker (address see above) and + * + * Rick Richardson + * PC Research. Inc. + * 94 Apple Orchard Drive + * Tinton Falls, NJ 07724 + * Phone: (201) 834-1378 (9-17 EST) + * UUCP: ...!uunet!pcrat!rick + * + * Please send results to Rick Richardson and/or Reinhold Weicker. + * Complete information should be given on hardware and software + * used. Hardware information includes: Machine type, CPU, type and + * size of caches; for microprocessors: clock frequency, memory speed + * (number of wait states). Software information includes: Compiler + * (and runtime library) manufacturer and version, compilation + * switches, OS version. The Operating System version may give an + * indication about the compiler; Dhrystone itself performs no OS + * calls in the measurement loop. + * + * The complete output generated by the program should be mailed + * such that at least some checks for correctness can be made. + * + ************************************************************************* + * + * History: This version C/2.1 has been made for two reasons: + * + * 1) There is an obvious need for a common C version of + * Dhrystone, since C is at present the most popular system + * programming language for the class of processors + * (microcomputers, minicomputers) where Dhrystone is used + * most. There should be, as far as possible, only one C + * version of Dhrystone such that results can be compared + * without restrictions. In the past, the C versions + * distributed by Rick Richardson (Version 1.1) and by + * Reinhold Weicker had small (though not significant) + * differences. + * + * 2) As far as it is possible without changes to the + * Dhrystone statistics, optimizing compilers should be + * prevented from removing significant statements. + * + * This C version has been developed in cooperation with + * Rick Richardson (Tinton Falls, NJ), it incorporates many + * ideas from the "Version 1.1" distributed previously by + * him over the UNIX network Usenet. + * I also thank Chaim Benedelac (National Semiconductor), + * David Ditzel (SUN), Earl Killian and John Mashey (MIPS), + * Alan Smith and Rafael Saavedra-Barrera (UC at Berkeley) + * for their help with comments on earlier versions of the + * benchmark. + * + * Changes: In the initialization part, this version follows mostly + * Rick Richardson's version distributed via Usenet, not the + * version distributed earlier via floppy disk by Reinhold + * Weicker. As a concession to older compilers, names have + * been made unique within the first 8 characters. Inside the + * measurement loop, this version follows the version + * previously distributed by Reinhold Weicker. + * + * At several places in the benchmark, code has been added, + * but within the measurement loop only in branches that + * are not executed. The intention is that optimizing + * compilers should be prevented from moving code out of the + * measurement loop, or from removing code altogether. Since + * the statements that are executed within the measurement + * loop have NOT been changed, the numbers defining the + * "Dhrystone distribution" (distribution of statements, + * operand types and locality) still hold. Except for + * sophisticated optimizing compilers, execution times for + * this version should be the same as for previous versions. + * + * Since it has proven difficult to subtract the time for the + * measurement loop overhead in a correct way, the loop check + * has been made a part of the benchmark. This does have + * an impact - though a very minor one - on the distribution + * statistics which have been updated for this version. + * + * All changes within the measurement loop are described + * and discussed in the companion paper "Rationale for + * Dhrystone version 2". + * + * Because of the self-imposed limitation that the order and + * distribution of the executed statements should not be + * changed, there are still cases where optimizing compilers + * may not generate code for some statements. To a certain + * degree, this is unavoidable for small synthetic + * benchmarks. Users of the benchmark are advised to check + * code listings whether code is generated for all statements + * of Dhrystone. + * + * Version 2.1 is identical to version 2.0 distributed via + * the UNIX network Usenet in March 1988 except that it + * corrects some minor deficiencies that were found by users + * of version 2.0. The only change within the measurement + * loop is that a non-executed "else" part was added to the + * "if" statement in Func_3, and a non-executed "else" part + * removed from Proc_3. + * + ************************************************************************* + * + * Defines: The following "Defines" are possible: + * -DROPT (default: Not defined) + * As an approximation to what an average C + * programmer might do, the "register" storage class + * is applied (if enabled by -DROPT) + * - for local variables, if they are used + * (dynamically) five or more times + * - for parameters if they are used (dynamically) + * six or more times + * Note that an optimal "register" strategy is + * compiler-dependent, and that "register" + * declarations do not necessarily lead to faster + * execution. + * -DNOSTRUCTASSIGN (default: Not defined) + * Define if the C compiler does not support + * assignment of structures. + * -DNOENUMS (default: Not defined) + * Define if the C compiler does not support + * enumeration types. + * + ************************************************************************* + * + * Compilation model and measurement (IMPORTANT): + * + * This C version of Dhrystone consists of three files: + * - dhry.h (this file, containing global definitions and comments) + * - dhry_1.c (containing the code corresponding to Ada package Pack_1) + * - dhry_2.c (containing the code corresponding to Ada package Pack_2) + * + * The following "ground rules" apply for measurements: + * - Separate compilation + * - No procedure merging + * - Otherwise, compiler optimizations are allowed but should be + * indicated + * - Default results are those without register declarations + * See the companion paper "Rationale for Dhrystone Version 2" for a more + * detailed discussion of these ground rules. + * + * For 16-Bit processors (e.g. 80186, 80286), times for all compilation + * models ("small", "medium", "large" etc.) should be given if possible, + * together with a definition of these models for the compiler system + * used. + * + ************************************************************************* + * + * Dhrystone (C version) statistics: + * + * [Comment from the first distribution, updated for version 2. + * Note that because of language differences, the numbers are slightly + * different from the Ada version.] + * + * The following program contains statements of a high level programming + * language (here: C) in a distribution considered representative: + * + * assignments 52 (51.0 %) + * control statements 33 (32.4 %) + * procedure, function calls 17 (16.7 %) + * + * 103 statements are dynamically executed. The program is balanced with + * respect to the three aspects: + * + * - statement type + * - operand type + * - operand locality + * operand global, local, parameter, or constant. + * + * The combination of these three aspects is balanced only approximately. + * + * 1. Statement Type: + * ----------------- number + * + * V1 = V2 9 + * (incl. V1 = F(..) + * V = Constant 12 + * Assignment, 7 + * with array element + * Assignment, 6 + * with record component + * -- + * 34 34 + * + * X = Y +|-|"&&"|"|" Z 5 + * X = Y +|-|"==" Constant 6 + * X = X +|- 1 3 + * X = Y *|/ Z 2 + * X = Expression, 1 + * two operators + * X = Expression, 1 + * three operators + * -- + * 18 18 + * + * if .... 14 + * with "else" 7 + * without "else" 7 + * executed 3 + * not executed 4 + * for ... 7 | counted every time + * while ... 4 | the loop condition + * do ... while 1 | is evaluated + * switch ... 1 + * break 1 + * declaration with 1 + * initialization + * -- + * 34 34 + * + * P (...) procedure call 11 + * user procedure 10 + * library procedure 1 + * X = F (...) + * function call 6 + * user function 5 + * library function 1 + * -- + * 17 17 + * --- + * 103 + * + * The average number of parameters in procedure or function calls + * is 1.82 (not counting the function values as implicit parameters). + * + * + * 2. Operators + * ------------ + * number approximate + * percentage + * + * Arithmetic 32 50.8 + * + * + 21 33.3 + * - 7 11.1 + * * 3 4.8 + * / (int div) 1 1.6 + * + * Comparison 27 42.8 + * + * == 9 14.3 + * /= 4 6.3 + * > 1 1.6 + * < 3 4.8 + * >= 1 1.6 + * <= 9 14.3 + * + * Logic 4 6.3 + * + * && (AND-THEN) 1 1.6 + * | (OR) 1 1.6 + * ! (NOT) 2 3.2 + * + * -- ----- + * 63 100.1 + * + * + * 3. Operand Type (counted once per operand reference): + * --------------- + * number approximate + * percentage + * + * Integer 175 72.3 % + * Character 45 18.6 % + * Pointer 12 5.0 % + * String30 6 2.5 % + * Array 2 0.8 % + * Record 2 0.8 % + * --- ------- + * 242 100.0 % + * + * When there is an access path leading to the final operand (e.g. a + * record component), only the final data type on the access path is + * counted. + * + * + * 4. Operand Locality: + * ------------------- + * number approximate + * percentage + * + * local variable 114 47.1 % + * global variable 22 9.1 % + * parameter 45 18.6 % + * value 23 9.5 % + * reference 22 9.1 % + * function result 6 2.5 % + * constant 55 22.7 % + * --- ------- + * 242 100.0 % + * + * + * The program does not compute anything meaningful, but it is + * syntactically and semantically correct. All variables have a value + * assigned to them before they are used as a source operand. + * + * There has been no explicit effort to account for the effects of a + * cache, or to balance the use of long or short displacements for code + * or data. + * + ************************************************************************* + */ +#ifndef __MSP430__ +#define __MSP430__ +#endif + +/******************************************************************************* + * Adapted for embedded microcontrollers by Graham Davies, ECROS Technology. * + ******************************************************************************/ + +/* Compiler and system dependent definitions: */ + +#define Mic_secs_Per_Second 1000000.0 + /* Berkeley UNIX C returns process times in seconds/HZ */ + +#ifdef NOSTRUCTASSIGN +#define structassign(d, s) memcpy(&(d), &(s), sizeof(d)) +#else +#define structassign(d, s) d = s +#endif + +#ifdef NOENUM +#define Ident_1 0 +#define Ident_2 1 +#define Ident_3 2 +#define Ident_4 3 +#define Ident_5 4 + typedef int Enumeration; +#else + typedef enum {Ident_1, Ident_2, Ident_3, Ident_4, Ident_5} + Enumeration; +#endif + /* for boolean and enumeration types in Ada, Pascal */ + +/* General definitions: */ + +#include + /* for strcpy, strcmp */ + +#define Null 0 + /* Value of a Null pointer */ +#define true 1 +#define false 0 + +typedef int One_Thirty; +typedef int One_Fifty; +typedef char Capital_Letter; +typedef int Boolean; +typedef char Str_30 [31]; +typedef int Arr_1_Dim [25]; /* <-- changed from 50 */ +typedef int Arr_2_Dim [25] [25]; /* <-- changed from 50 */ + +typedef struct record + { + struct record *Ptr_Comp; + Enumeration Discr; + union { + struct { + Enumeration Enum_Comp; + int Int_Comp; + char Str_Comp [31]; + } var_1; + struct { + Enumeration E_Comp_2; + char Str_2_Comp [31]; + } var_2; + struct { + char Ch_1_Comp; + char Ch_2_Comp; + } var_3; + } variant; + } Rec_Type, *Rec_Pointer; + +/* Prototypes of function defined in dhry21b.c and called from dhry21a.c. + */ +void Proc_6( Enumeration Enum_Val_Par, Enumeration * Enum_Ref_Par ); +void Proc_7( One_Fifty Int_1_Par_Val, One_Fifty Int_2_Par_Val, + One_Fifty * Int_Par_Ref ); +void Proc_8( Arr_1_Dim Arr_1_Par_Ref, Arr_2_Dim Arr_2_Par_Ref, + int Int_1_Par_Val, int Int_2_Par_Val ); +Enumeration Func_1( Capital_Letter Ch_1_Par_Val, Capital_Letter Ch_2_Par_Val ); +Boolean Func_2( Str_30 Str_1_Par_Ref, Str_30 Str_2_Par_Ref ); + +/******************************************************************************* + * Additions for embedded microcontrollers follow ... + +#ifdef printf +#undef printf +#endif +#define printf // +#ifdef fprintf +#undef fprintf +#endif +#define fprintf // + */ + +extern void * emalloc( size_t nbytes ); + +#if defined( __AVR_ARCH__ ) /* Atmel AVR */ + +#include +#define SetPort( state ) PORTB = (state) +extern FILE * fopen( const char * filename, const char * mode ); + +#elif defined( __ENCORE__ ) /* ZiLOG Z8 Encore! */ + +#include +#define SetPort( state ) PAOUT = (state) +typedef int FILE; +extern FILE * fopen( const char * filename, const char * mode ); +extern int fclose( FILE * stream ); + +#elif defined( __MSP430__ ) /* MSP430 */ + +typedef int FILE; + +#endif
rtl_sim/src-c/dhrystone_4mcu/dhry.h Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/dhry21b.c =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/dhry21b.c (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/dhry21b.c (revision 145) @@ -0,0 +1,184 @@ +/* + ************************************************************************* + * + * "DHRYSTONE" Benchmark Program + * ----------------------------- + * + * Version: C, Version 2.1 + * + * File: dhry_2.c (part 3 of 3) + * + * Date: May 25, 1988 + * + * Author: Reinhold P. Weicker + * + ************************************************************************* + */ + +/*************************************************************************** + * Adapted for embedded microcontrollers by Graham Davies, ECROS Technology. + **************************************************************************/ + +#include "dhry.h" +#include + +#ifndef REG +#define REG + /* REG becomes defined as empty */ + /* i.e. no register variables */ +#else +#define REG register +#endif + +extern int Int_Glob; +extern char Ch_1_Glob; + +Boolean Func_3( Enumeration Enum_Par_Val ); + +void Proc_6( Enumeration Enum_Val_Par, Enumeration * Enum_Ref_Par ) +/*********************************/ + /* executed once */ + /* Enum_Val_Par == Ident_3, Enum_Ref_Par becomes Ident_2 */ +{ + *Enum_Ref_Par = Enum_Val_Par; + if (! Func_3 (Enum_Val_Par)) + /* then, not executed */ + *Enum_Ref_Par = Ident_4; + switch (Enum_Val_Par) + { + case Ident_1: + *Enum_Ref_Par = Ident_1; + break; + case Ident_2: + if (Int_Glob > 100) + /* then */ + *Enum_Ref_Par = Ident_1; + else *Enum_Ref_Par = Ident_4; + break; + case Ident_3: /* executed */ + *Enum_Ref_Par = Ident_2; + break; + case Ident_4: break; + case Ident_5: + *Enum_Ref_Par = Ident_3; + break; + } /* switch */ +} /* Proc_6 */ + + +void Proc_7( One_Fifty Int_1_Par_Val, One_Fifty Int_2_Par_Val, + One_Fifty * Int_Par_Ref ) +/**********************************************/ + /* executed three times */ + /* first call: Int_1_Par_Val == 2, Int_2_Par_Val == 3, */ + /* Int_Par_Ref becomes 7 */ + /* second call: Int_1_Par_Val == 10, Int_2_Par_Val == 5, */ + /* Int_Par_Ref becomes 17 */ + /* third call: Int_1_Par_Val == 6, Int_2_Par_Val == 10, */ + /* Int_Par_Ref becomes 18 */ +{ + One_Fifty Int_Loc; + + Int_Loc = Int_1_Par_Val + 2; + *Int_Par_Ref = Int_2_Par_Val + Int_Loc; +} /* Proc_7 */ + + +void Proc_8( Arr_1_Dim Arr_1_Par_Ref, Arr_2_Dim Arr_2_Par_Ref, + int Int_1_Par_Val, int Int_2_Par_Val ) +/*********************************************************************/ + /* executed once */ + /* Int_Par_Val_1 == 3 */ + /* Int_Par_Val_2 == 7 */ +{ + REG One_Fifty Int_Index; + REG One_Fifty Int_Loc; + + Int_Loc = Int_1_Par_Val + 5; + Arr_1_Par_Ref [Int_Loc] = Int_2_Par_Val; + Arr_1_Par_Ref [Int_Loc+1] = Arr_1_Par_Ref [Int_Loc]; + Arr_1_Par_Ref [Int_Loc+15] = Int_Loc; + for (Int_Index = Int_Loc; Int_Index <= Int_Loc+1; ++Int_Index) + Arr_2_Par_Ref [Int_Loc] [Int_Index] = Int_Loc; + Arr_2_Par_Ref [Int_Loc] [Int_Loc-1] += 1; + Arr_2_Par_Ref [Int_Loc+10] [Int_Loc] = Arr_1_Par_Ref [Int_Loc]; + Int_Glob = 5; +} /* Proc_8 */ + + +Enumeration Func_1 ( Capital_Letter Ch_1_Par_Val, Capital_Letter Ch_2_Par_Val ) +/*************************************************/ + /* executed three times */ + /* first call: Ch_1_Par_Val == 'H', Ch_2_Par_Val == 'R' */ + /* second call: Ch_1_Par_Val == 'A', Ch_2_Par_Val == 'C' */ + /* third call: Ch_1_Par_Val == 'B', Ch_2_Par_Val == 'C' */ +{ + Capital_Letter Ch_1_Loc; + Capital_Letter Ch_2_Loc; + + Ch_1_Loc = Ch_1_Par_Val; + Ch_2_Loc = Ch_1_Loc; + if (Ch_2_Loc != Ch_2_Par_Val) + /* then, executed */ + return (Ident_1); + else /* not executed */ + { + Ch_1_Glob = Ch_1_Loc; + return (Ident_2); + } +} /* Func_1 */ + + +Boolean Func_2( Str_30 Str_1_Par_Ref, Str_30 Str_2_Par_Ref ) +/*************************************************/ + /* executed once */ + /* Str_1_Par_Ref == "DHRYSTONE PROGRAM, 1'ST STRING" */ + /* Str_2_Par_Ref == "DHRYSTONE PROGRAM, 2'ND STRING" */ +{ + REG One_Thirty Int_Loc; + Capital_Letter Ch_Loc; + + Int_Loc = 2; + while (Int_Loc <= 2) /* loop body executed once */ + if (Func_1 (Str_1_Par_Ref[Int_Loc], + Str_2_Par_Ref[Int_Loc+1]) == Ident_1) + /* then, executed */ + { + Ch_Loc = 'A'; + Int_Loc += 1; + } /* if, while */ + if (Ch_Loc >= 'W' && Ch_Loc < 'Z') + /* then, not executed */ + Int_Loc = 7; + if (Ch_Loc == 'R') + /* then, not executed */ + return (true); + else /* executed */ + { + if (strcmp (Str_1_Par_Ref, Str_2_Par_Ref) > 0) + /* then, not executed */ + { + Int_Loc += 7; + Int_Glob = Int_Loc; + return (true); + } + else /* executed */ + return (false); + } /* if Ch_Loc */ +} /* Func_2 */ + + +Boolean Func_3( Enumeration Enum_Par_Val ) +/***************************/ + /* executed once */ + /* Enum_Par_Val == Ident_3 */ +{ + Enumeration Enum_Loc; + + Enum_Loc = Enum_Par_Val; + if (Enum_Loc == Ident_3) + /* then, executed */ + return (true); + else /* not executed */ + return (false); +} /* Func_3 */
rtl_sim/src-c/dhrystone_4mcu/dhry21b.c Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/dhrystone_4mcu/makefile =================================================================== --- rtl_sim/src-c/dhrystone_4mcu/makefile (nonexistent) +++ rtl_sim/src-c/dhrystone_4mcu/makefile (revision 145) @@ -0,0 +1,58 @@ +# makfile configuration +NAME = dhrystone_4mcu +OBJECTS = dhry21a.o dhry21b.o omsp_func.o + +# disable some warnings specific to the Dhrystone code +WARNINGS = -Wall + +#CFLAGS = -O2 ${WARNINGS} -g # Old flags +CFLAGS = -O2 ${WARNINGS} -g -mcpu=430 -mivcnt=16 -mmpy=16 # Uniarch flags + +#switch the compiler (for the internal make rules) +CC = msp430-gcc + + +.PHONY: all FORCE clean download download-jtag download-bsl dist + +#all should be the first target. it's built when make is runwithout args +all: ${NAME}.elf ${NAME}.a43 ${NAME}.lst + +#confgigure the next line if you want to use the serial download +download: download-uart +#download: download-jtag +#download: download-bsl + +#additional rules for files +${NAME}.elf: ${OBJECTS} + ${CC} -T linker.x -o $@ ${OBJECTS} + +${NAME}.a43: ${NAME}.elf + msp430-objcopy -O ihex $^ $@ + +${NAME}.lst: ${NAME}.elf + msp430-objdump -dSt $^ >$@ + +download-jtag: all + msp430-jtag -e ${NAME}.elf + +download-bsl: all + msp430-bsl -e ${NAME}.elf + +download-uart: all + openmsp430-loader.tcl -device /dev/ttyUSB0 -baudrate 115200 ${NAME}.elf + +clean: + rm -f ${NAME} ${NAME}.a43 ${NAME}.lst ${NAME}.elf *.o + +#backup archive +dist: + tar czf dist.tgz *.c *.h *.txt makefile + +#dummy target as dependecy if something has to be build everytime +FORCE: + +#project dependencies +dhry_1.o: dhry_1.c +dhry_2.o: dhry_2.c +omsp_func.o: omsp_func.c +
rtl_sim/src-c/dhrystone_4mcu/makefile Property changes : Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Index: rtl_sim/src-c/sandbox/sandbox.v =================================================================== --- rtl_sim/src-c/sandbox/sandbox.v (revision 142) +++ rtl_sim/src-c/sandbox/sandbox.v (revision 145) @@ -41,6 +41,26 @@ repeat(5) @(posedge mclk); stimulus_done = 0; + //--------------------------------------- + // Check CPU configuration + //--------------------------------------- + if ((`PMEM_SIZE !== 24576) || (`DMEM_SIZE !== 16384)) + begin + $display(" ==============================================="); + $display("| SIMULATION ERROR |"); + $display("| |"); + $display("| Core must be configured for: |"); + $display("| - 24kB program memory |"); + $display("| - 16kB data memory |"); + $display(" ==============================================="); + $finish; + end + + + //--------------------------------------- + // Generate stimulus + //--------------------------------------- + repeat(1000) @(posedge mclk); p1_din = 8'h01; repeat(10) @(posedge mclk);
/rtl_sim/src-c/sandbox/linker.x
1,149 → 1,184
/* Default linker script, for normal executables */
OUTPUT_FORMAT("elf32-msp430","elf32-msp430","elf32-msp430")
OUTPUT_FORMAT("elf32-msp430")
OUTPUT_ARCH("msp430")
MEMORY
{
text (rx) : ORIGIN = 0xF800, LENGTH = 0x800
data (rwx) : ORIGIN = 0x0200, LENGTH = 0x080
vectors (rw) : ORIGIN = 0xffe0, LENGTH = 0x20
MEMORY {
sfr : ORIGIN = 0x0000, LENGTH = 0x0010
peripheral_8bit : ORIGIN = 0x0010, LENGTH = 0x00f0
peripheral_16bit : ORIGIN = 0x0100, LENGTH = 0x0100
 
ram (wx) : ORIGIN = 0x0200, LENGTH = 0x4000
rom (rx) : ORIGIN = 0xA000, LENGTH = 0x6000-0x20
vectors : ORIGIN = 0xffe0, LENGTH = 0x0020
 
/* Remaining banks are absent */
bsl : ORIGIN = 0x0000, LENGTH = 0x0000
infomem : ORIGIN = 0x0000, LENGTH = 0x0000
infob : ORIGIN = 0x0000, LENGTH = 0x0000
infoa : ORIGIN = 0x0000, LENGTH = 0x0000
infoc : ORIGIN = 0x0000, LENGTH = 0x0000
infod : ORIGIN = 0x0000, LENGTH = 0x0000
ram2 (wx) : ORIGIN = 0x0000, LENGTH = 0x0000
ram_mirror (wx) : ORIGIN = 0x0000, LENGTH = 0x0000
usbram (wx) : ORIGIN = 0x0000, LENGTH = 0x0000
far_rom : ORIGIN = 0x00000000, LENGTH = 0x00000000
}
REGION_ALIAS("REGION_TEXT", rom);
REGION_ALIAS("REGION_DATA", ram);
REGION_ALIAS("REGION_FAR_ROM", far_rom);
__WDTCTL = 0x0120;
__MPY = 0x0130;
__MPYS = 0x0132;
__MAC = 0x0134;
__MACS = 0x0136;
__OP2 = 0x0138;
__RESLO = 0x013A;
__RESHI = 0x013C;
__SUMEXT = 0x013E;
 
SECTIONS
{
PROVIDE (__stack = 0x280) ;
 
/* Read-only sections, merged into text segment. */
.hash : { *(.hash) }
.dynsym : { *(.dynsym) }
.dynstr : { *(.dynstr) }
.gnu.version : { *(.gnu.version) }
.gnu.version_d : { *(.gnu.version_d) }
.gnu.version_r : { *(.gnu.version_r) }
.rel.init : { *(.rel.init) }
.hash : { *(.hash) }
.dynsym : { *(.dynsym) }
.dynstr : { *(.dynstr) }
.gnu.version : { *(.gnu.version) }
.gnu.version_d : { *(.gnu.version_d) }
.gnu.version_r : { *(.gnu.version_r) }
.rel.init : { *(.rel.init) }
.rela.init : { *(.rela.init) }
.rel.text :
{
*(.rel.text)
*(.rel.text.*)
*(.rel.gnu.linkonce.t*)
}
.rela.text :
{
*(.rela.text)
*(.rela.text.*)
*(.rela.gnu.linkonce.t*)
}
.rel.fini : { *(.rel.fini) }
.rel.fini : { *(.rel.fini) }
.rela.fini : { *(.rela.fini) }
.rel.rodata :
{
*(.rel.rodata)
*(.rel.rodata.*)
*(.rel.gnu.linkonce.r*)
}
.rela.rodata :
{
*(.rela.rodata)
*(.rela.rodata.*)
*(.rela.gnu.linkonce.r*)
}
.rel.data :
{
*(.rel.data)
*(.rel.data.*)
*(.rel.gnu.linkonce.d*)
}
.rela.data :
{
*(.rela.data)
*(.rela.data.*)
*(.rela.gnu.linkonce.d*)
}
.rel.ctors : { *(.rel.ctors) }
.rela.ctors : { *(.rela.ctors) }
.rel.dtors : { *(.rel.dtors) }
.rela.dtors : { *(.rela.dtors) }
.rel.got : { *(.rel.got) }
.rela.got : { *(.rela.got) }
.rel.bss : { *(.rel.bss) }
.rela.bss : { *(.rela.bss) }
.rel.plt : { *(.rel.plt) }
.rela.plt : { *(.rela.plt) }
/* Internal text space. */
.rel.text : { *(.rel.text .rel.text.* .rel.gnu.linkonce.t.*) }
.rela.text : { *(.rela.text .rela.text.* .rela.gnu.linkonce.t.*) }
.rel.rodata : { *(.rel.rodata .rel.rodata.* .rel.gnu.linkonce.r.*) }
.rela.rodata : { *(.rela.rodata .rela.rodata.* .rela.gnu.linkonce.r.*) }
.rel.data : { *(.rel.data .rel.data.* .rel.gnu.linkonce.d.*) }
.rela.data : { *(.rela.data .rela.data.* .rela.gnu.linkonce.d.*) }
.rel.bss : { *(.rel.bss .rel.bss.* .rel.gnu.linkonce.b.*) }
.rela.bss : { *(.rela.bss .rela.bss.* .rela.gnu.linkonce.b.*) }
.rel.ctors : { *(.rel.ctors) }
.rela.ctors : { *(.rela.ctors) }
.rel.dtors : { *(.rel.dtors) }
.rela.dtors : { *(.rela.dtors) }
.rel.got : { *(.rel.got) }
.rela.got : { *(.rela.got) }
.rel.plt : { *(.rel.plt) }
.rela.plt : { *(.rela.plt) }
.text :
{
. = ALIGN(2);
*(.init)
*(.init0) /* Start here after reset. */
*(.init1)
*(.init2) /* Copy data loop */
*(.init3)
*(.init4) /* Clear bss */
*(.init5)
*(.init6) /* C++ constructors. */
*(.init7)
*(.init8)
*(.init9) /* Call main(). */
. = ALIGN(2);
KEEP(*(.init .init.*))
KEEP(*(.init0)) /* Start here after reset. */
KEEP(*(.init1)) /* User definable. */
KEEP(*(.init2)) /* Initialize stack. */
KEEP(*(.init3)) /* Initialize hardware, user definable. */
KEEP(*(.init4)) /* Copy data to .data, clear bss. */
KEEP(*(.init5)) /* User definable. */
KEEP(*(.init6)) /* C++ constructors. */
KEEP(*(.init7)) /* User definable. */
KEEP(*(.init8)) /* User definable. */
KEEP(*(.init9)) /* Call main(). */
KEEP(*(.fini9)) /* Falls into here after main(). User definable. */
KEEP(*(.fini8)) /* User definable. */
KEEP(*(.fini7)) /* User definable. */
KEEP(*(.fini6)) /* C++ destructors. */
KEEP(*(.fini5)) /* User definable. */
KEEP(*(.fini4)) /* User definable. */
KEEP(*(.fini3)) /* User definable. */
KEEP(*(.fini2)) /* User definable. */
KEEP(*(.fini1)) /* User definable. */
KEEP(*(.fini0)) /* Infinite loop after program termination. */
KEEP(*(.fini .fini.*))
. = ALIGN(2);
__ctors_start = . ;
*(.ctors)
KEEP(*(.ctors))
__ctors_end = . ;
__dtors_start = . ;
*(.dtors)
KEEP(*(.dtors))
__dtors_end = . ;
. = ALIGN(2);
*(.text)
. = ALIGN(2);
*(.text.*)
. = ALIGN(2);
*(.fini9) /* */
*(.fini8)
*(.fini7)
*(.fini6) /* C++ destructors. */
*(.fini5)
*(.fini4)
*(.fini3)
*(.fini2)
*(.fini1)
*(.fini0) /* Infinite loop after program termination. */
*(.fini)
_etext = . ;
} > text
.data : AT (ADDR (.text) + SIZEOF (.text))
. = ALIGN(2);
*(.text .text.* .gnu.linkonce.t.*)
. = ALIGN(2);
} > REGION_TEXT
.rodata :
{
. = ALIGN(2);
*(.rodata .rodata.* .gnu.linkonce.r.*)
. = ALIGN(2);
} > REGION_TEXT
_etext = .; /* Past last read-only (loadable) segment */
.data :
{
. = ALIGN(2);
PROVIDE (__data_start = .) ;
. = ALIGN(2);
*(.data)
. = ALIGN(2);
*(.gnu.linkonce.d*)
. = ALIGN(2);
_edata = . ;
} > data
PROVIDE (__data_load_start = LOADADDR(.data) );
PROVIDE (__data_size = SIZEOF(.data) );
.bss SIZEOF(.data) + ADDR(.data) :
*(.data .data.* .gnu.linkonce.d.*)
. = ALIGN(2);
_edata = . ; /* Past last read-write (loadable) segment */
} > REGION_DATA AT > REGION_TEXT
PROVIDE (__data_load_start = LOADADDR(.data) );
PROVIDE (__data_size = SIZEOF(.data) );
.bss :
{
PROVIDE (__bss_start = .) ;
*(.bss)
*(.bss .bss.*)
*(COMMON)
. = ALIGN(2);
PROVIDE (__bss_end = .) ;
_end = . ;
} > data
PROVIDE (__bss_size = SIZEOF(.bss) );
.noinit SIZEOF(.bss) + ADDR(.bss) :
} > REGION_DATA
PROVIDE (__bss_size = SIZEOF(.bss) );
.noinit :
{
PROVIDE (__noinit_start = .) ;
*(.noinit)
*(COMMON)
*(.noinit .noinit.*)
. = ALIGN(2);
PROVIDE (__noinit_end = .) ;
_end = . ;
} > data
} > REGION_DATA
. = ALIGN(2);
_end = . ; /* Past last write (loadable) segment */
.infomem :
{
*(.infomem)
. = ALIGN(2);
*(.infomem.*)
} > infomem
.infomemnobits :
{
*(.infomemnobits)
. = ALIGN(2);
*(.infomemnobits.*)
} > infomem
.infoa :
{
*(.infoa .infoa.*)
} > infoa
.infob :
{
*(.infob .infob.*)
} > infob
.infoc :
{
*(.infoc .infoc.*)
} > infoc
.infod :
{
*(.infod .infod.*)
} > infod
.vectors :
{
PROVIDE (__vectors_start = .) ;
*(.vectors*)
KEEP(*(.vectors*))
_vectors_end = . ;
} > vectors
.fartext :
{
. = ALIGN(2);
*(.fartext)
. = ALIGN(2);
*(.fartext.*)
_efartext = .;
} > REGION_FAR_ROM
/* Stabs for profiling information*/
.profiler 0 : { *(.profiler) }
/* Stabs debugging sections. */
.stab 0 : { *(.stab) }
.stabstr 0 : { *(.stabstr) }
172,8 → 207,10
.debug_str 0 : { *(.debug_str) }
.debug_loc 0 : { *(.debug_loc) }
.debug_macinfo 0 : { *(.debug_macinfo) }
PROVIDE (__data_start_rom = _etext) ;
PROVIDE (__data_end_rom = _etext + SIZEOF (.data)) ;
PROVIDE (__noinit_start_rom = _etext + SIZEOF (.data)) ;
PROVIDE (__noinit_end_rom = _etext + SIZEOF (.data) + SIZEOF (.noinit)) ;
/* DWARF 3 */
.debug_pubtypes 0 : { *(.debug_pubtypes) }
.debug_ranges 0 : { *(.debug_ranges) }
PROVIDE (__stack = ORIGIN(ram) + LENGTH(ram));
PROVIDE (__data_start_rom = _etext);
PROVIDE (__data_end_rom = _etext + SIZEOF (.data));
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.