14
SOFTWARE RELEASE NOTICE 01. SRN Number: PA-SRN-013 02. Project Title: Project No. Volcano - A Module for Simulation of Magmatic Scenario. 03. SRN Title: VOLCANO Version 1.1 04. Originator/Requester: | Date: Thomas J. Ratchford 02/01/94 05. Summary of Actions * Release of new code admitted to CM System ° Release of modified code: o Enhancements made o Corrections made o Change of access code 06. Persons Authorized Access Name | RO/RW [ A/C/D 07. Element Manager Approval: Date: 08. Remarks: CNWRA Form TOP-6 (08/93)

SOFTWARE RELEASE NOTICE 01. SRN Number: PA-SRN-013 · 2012. 11. 19. · [2] Fortran 77 Analyzer User's Manual, National Bureau of Standards, NBS GCR 81-359, 1981 [3] FORWARN User's

  • Upload
    others

  • View
    3

  • Download
    0

Embed Size (px)

Citation preview

  • SOFTWARE RELEASE NOTICE

    01. SRN Number: PA-SRN-013

    02. Project Title: Project No.

    Volcano - A Module for Simulation of Magmatic Scenario.

    03. SRN Title: VOLCANO Version 1.1

    04. Originator/Requester: | Date:

    Thomas J. Ratchford 02/01/94

    05. Summary of Actions

    * Release of new code admitted to CM System

    ° Release of modified code:

    o Enhancements made

    o Corrections made

    o Change of access code

    06. Persons Authorized Access

    Name | RO/RW [ A/C/D

    07. Element Manager Approval: Date:

    08. Remarks:

    CNWRA Form TOP-6 (08/93)

  • SOFTWARE RELEASE NOTICE

    01. SRN Number: PA-SRN-013

    02. Project Title: Project No.

    Volcano - A Module for Simulation of Magmatic Scenario.

    03. SRN Title: VOLCANO Version 1.1

    04. Originator/Requester: Date:

    Thomas J. Ratchford 02/1/94

    05. Summary of Actions

    * Release of new code admitted to CM System

    ° Release of modified code:

    ° Enhancements made

    o Corrections made

    * Change of access code

    06. Persons Authorized Access

    Name I RO/RW TAC/D

    07. Element Manager Approval: Date:

    08. Remarks:

    CNWRA Form TOP-6 (08/93)

  • SOFTWARE SUMMARY FORM

    01 .Summary Date: 02. Summary prepared by(Name and Phone) 03 Summ ry Action:

    02/01/94 TJ. Ratchford 522-3083

    04. Software Date: 05. Short Title: e

    8/15/93 VOLCANO

    06. Software Tide: Volcano -A module for simulation of magmatic scenario. 07 InteMral Software ID:

    NONE

    08. Software Type: 09Processing Mode: 10. APPLICATION AREA

    A. General:

    ° Automated Data System ° Interactive 0 Scientific/Engineering ° Auxiliary Analyses

    0 Total System PA

    * Computer Program 0 Batch U Subsystem PA ° Other

    o Subroutine/Module * Combination b. Specific:

    II. Submitting Organization and Address: 12. Technical Contact(s) and Phone:

    CNWRA, SwRI, San Antonio, Texas B. Baca, (210) 522-3805

    13. Narrative:The Volcano code is used by the Total Perfomnance Assessment Code to simulate the magma scenarios in the Yucca Mountain region arround the potential

    repository.

    14. Computer Platform 15. Computer Operating System: 16. Programming Language(s): 17. Number of Source ProgramStatements:

    CRAY/XMP UNDX FORTRAN 15,639 lines of code

    18. Computer Memory 19. Tape Drives: 20. Disk/Drum Units: 21. Oraphics:Requirements:

    UNKNOWN NONE N/A UNKNOWN

    22. Other Operational Requirements

    NONE

    23. Software Availability: 24. Documentation Availability:* Available 0 Limited a In-House ONLY * Available 0 Inadequate ° In-House ONLY

    25. Submission Package Status:

    Acceptance Criteria: Me Not Met E are QA Assessment: Successful * Unsuccessful 0

    Code Custodian: 19/ P 1 , Date: Dste

    CNWRA Form TOP-4-1 (08/93)

  • Volcano Cray Directory Listing

    -rwxrwx----rwxrwx----rw-r------rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx ----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx ----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx ----rwxrwx----rwxrwx----rwxrwx ----rwxrwx ----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx----rwxrwx ----rwxrwx----rwxrwx----rwxrwx----rwxrwx ----rwxrwx----rwxrwx---

    tjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrl

    tjrltirlt rltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjr1tjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrltjrl

    22092385

    043754731763216690

    1264129112533193150

    2151295

    32721836502514821651106519481390969631482372937570

    34425089624221863900

    187815963921190917072892260

    406210142592309

    1874452

    1727198329757662502

    787691701209

    5011287287

    JanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJanJan

    313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131

    08:5008:5009:0908:5008:5008:5008:5008:5008:5008:5008: 5008:5008:5008: 5008:5008:5008:5008:5008:5008:5008:5008:5008: 5008: 5008:5008:5008: 5008: 5008:5008: 5008: 5008:5008: 5008: 5008:5008:5008: 5008:5008: 5008: 5008: 5008:5008:5008:5008: 5008:5008: 5008:5008:5008:5008:5008:5008:5008:5008: 5008:5008:50

    Makefile*TPA VOL.VGD*VALCANO.DIRairout.F*betwn.F*cdamag.F*ceil.F*chkele.F*cirint.F*coin.F*ddamag.F*decay.F*dist.F*ditout.F*dot.F*echol.F*echo2.F*echo3.F*getara.F*getbrk.F*getdc.F*getlen.F*gettb.F*inside.F*intl.F*int2.F*int3.F*intr.F*left.F*lhsoooo.out*opnfil.F*order.F*params.H*ranl.F*ranc.F*rand.F*rdelem.F*rdenv.F*rdmap.F*rdrun.F*remove.F*setup.F*solve.F*sotcom.H*split.F*testlS.nuc*valid.F*vlcano.F*vlcano.f*volcano.cpp*volcano. in*volcano.pre*volcom.H*volmap.dat*wrel.F*x.volcano.co*x.volcano.te*

    Directory from -/tpa/VOLCANO/WKDIR1/31/94 T.J. Ryhford

  • VOLCANO Fortran ProgramStatic and Dynamic Analysis

    June 29, 1993

    Earl S. MarwilJohn E. Tolli

    Scientific Computing UnitIdaho National Engineering Laboratory

    1. Introduction

    This analysis was performed on the Cray version of the software as provided bySouthwest Research Institute (SwRI).

    One sample problem was supplied along with the source code. The program wasanalyzed using the Craft (Cross Reference Analysis of Fortran) tool, FORWARN, theFortran 77 analyzer, and PC-Metric. These tools provide static analysis, coverageanalysis, and complexity analysis.

    2. References

    [1] N.H. Marshall and ES. Marwil, Cross Reference Analysis of Fortran (CRAFT), EG&G-CATT-9198, EG&G Idaho, Inc., July 1991.[2] Fortran 77 Analyzer User's Manual, National Bureau of Standards, NBS GCR 81-359,1981[3] FORWARN User's Guide, Quibus Enterprises, Inc., July 1991.[4] PC-Metric User's Guide, SET Laboratories, Inc., 1987.

    3. Functions

    The VOLCANO program contains 42 Fortran routines.

    VOLCANO has no alternate entry points and no unreferenced subroutines orfunctions.

    4. Common Block Irregularities

    There are 9 common blocks in the VOLCANO program.

    All common block declarations are consistent, except for the declaration of commonblock "envpar" in subroutine "setup" where the variables "seed" and "cmeth" aretyped real. These variables are typed integer everywhere else "envpar" is declared.

    There are many instances of a common block being declared in a routine in whichnone of its elements are otherwise referenced.

  • VOLCANO Analysis June 29, 1993

    Of the 27 elements in common block "cnucl6", 23 are never defined or used anywherein the VOLCANO program.

    5. Interface Irregularities

    Argument number 6 to "opnfil" should be a 64-character string, but is typed real incalls from "airout", "ditout", "rdenv", "rdrun", "rdelem", and "rdmap".

    Argument number 2 in "split" is an 8-character string, but "wrel" passes a 6-character string to "split" in this argument.

    Routines "ditout", "intl", and "wrel" each have dummy arguments which are unused.

    Subroutine "rdrun" calls function "ranl" several times. The first call passes theexpression "-seed" to "ran1" as an argument. This argument is assigned a value of 1by "ran 1" before returning to "rdrun". While no harm is done by this argumentusage, owing to the fact that the expression is never used again, it may be better tochange the statement

    ul-RAN1( -seed)

    to

    idum - -seedul - ranl (idum)

    to avoid confusion.

    6. Local Variable Irregularities

    Parameter usage is consistent.

    There are several instances of a parameter not being used in a module in which it isdeclared.

    The proper functioning of "ranl" depends upon the local variables "r", "iff", "ixil","ix2", and "ix3" retaining their assigned values from the previous call to "ranl".These variables should therefore be placed in a common block.

    7. Fortran Extensions

    All routines except "ran 1" contain some lower case alphabetic characters in theiractive Fortran.

    Several routines have entity names which are longer than 6 characters.

    Routines "echol", "echo2", and "echo3" all have format statements containing the "x"descriptor without a repeat count.

    Routine "rdelem" has 2 instances of overlap in character assignment statements.

    - 2 -

  • VOLCANO Analysis June 29, 1993

    8. OptimizationThe following table summarizes the performance data gathered from execution of thesample problem. Only those routines exercised by the sample problem are shown(see "Coverage Analysis" for a list of routines not exercised by the sample problem,i.e., coverage = 0%). The table lists all program modules in descending orderaccording to CPU time. To optimize code execution time, emphasis should be placed onthose modules which appear highest in the listing.

    In order to obtain meaningful statistics for performance evaluation, the programshould execute for a reasonable amount of time. Note that the execution time for thissample problem is short ( 1).

    A detailed optimization analysis effort should focus on these 2 areas.

    - 3 -

  • VOLCANO Analysis June 29, 1993

    PERFORMANCE DATA FOR VOLCANO

    ROUTINE NAME

    RDMAPOPNFILRDELEMAIROUTRDENVECH01WRELECH03ECH02RDRUNDITOUTDECAYSETUPINTRGETLENINSIDELEFTDISTCHKELESOLVEVLCANOSPLITDDAMAGDOTCEILRANDGETDC

    Time %ExTime %AccumT

    0.0220.0060.0060.0060.0050.0050.0040.0040.0010.0010.0010.0010.0000.0000.0000.0000.0000.0000.0000.0000.0000.0000.0000.0000.0000.0000.000

    34.1249.6639.5759.1148.3428.1226.1796.1751.7951.0340.9310.8650.6340.6090.5760.5440.3180.2960.2890.2170.2160. 1120.1060.0760.0540.0190.013

    34.12443.78653.36162.47670.81778.93985.11891.29493.08894.12395.05495.91996.55497.16397.73898.28398.60098.89699.18599.40399.61999.73199.83799.91499.96899.987

    100.000

    %Vf lops

    0.000000.000000.000000.000000.000000.00000

    47.4487580.141850.000000.000000.00000

    71.0344837.883010.000000.000000.000000.000000.000000.000000.000000.000000.000000.000000.000000.000000.000000.00000

    IFact

    0.000.000.000.000.000.000.000.000.000.000.000.000.000.100.010.030.400.200.020.280.000.060.000.200.190.000.00

    MC/MR

    0.1160.3710.0960.4570.2040.2730.0970.2000.2670.1750.3010.0700.1500.2540.2850.0200.4821.3000.4330.7290.7930.4640.0900.4840.1380.0000.395

    IBFR

    0.7570.5471.0761.0271.1180.9101.0720.8970.9910.7861.0930.4301.3081.3841.6151.2070.9520.7090.6610.9661.0911.3451.3210.0000.0000.4120.930

    --- w----=------w------- ------ -------- mm --- =

    Totals (All Traced Routines)0.065 100.000 100.000 30.15386 0.03 0.216 0.884

    Key:%AccumT - accumulated percentage of total CPU time%ExTime - percentage of total CPU time%Vflops - percentage of floating point operations due

    to vector floating point operationsIBFR - Instruction Buffer Fetch Rate (megafetches/sec)IFact - Inline Factor (total calls to routine /

    average time spent in routine for each call)MC - number of memory conflictsMR - number of memory referencesTime - total CPU time (sec)

    -4-

  • VOLCANO Analysis June 29, 1993

    9. Coverage AnalysisOne sample problem was supplied. The sample problem aborted while trying to raisea negative number to a real power. The trouble was traced to function "dist" inwhich the following statement appears:

    dist-SQRT((x2-x1)**2. + (y2-yl)**2.)

    When the program is compiled without optimization, this statement will causeexecution failure any time one of the base numbers is negative or zero due to theexponents being specified as floating point numbers (2.). Failure does not occur withcompiler optimization because the optimizer replaces the real-to-real function callwith a real-to-integer function call.

    A similar problem exists with several other statements in the program. The troublewas rectified by eliminating the "." after the whole number exponent in each suchinstance.

    A coverage analysis shows that the supplied sample problem yielded a 56% segmentcoverage of VOLCANO. Sample problems provided with simulation programs typicallyachieve 35% to 50% coverage. A statement of software quality cannot be made forroutines that have low coverage, i.e., large portions of the code are untested.

    Note that 15 routines have 0% coverage. These routines are not tested with thesupplied sample problem.

    One routine achieves 1%-19% coverage, 2 routines achieve 4096-59% coverage, 6routines achieve 60%-79% coverage, 7 routines achieve 80%-99% coverage, and 11routines achieve 100% coverage.

    The following table shows the percent coverage for each routine.

    -5-

  • VOLCANO Analysis June 29, 1993

    Module Number ofName Segments

    in moduleVLCANO 11AIROUT 19BETWN 3CDAMAG 13CEIL 4CHKELE 10CIRINT 13COIN 21DDAMAG 7DECAY 20DIST 1DITOUT 6DOT 1ECHO1 5ECH02 3ECH03 18GETARA 17GETBRK 15GETDC 4GETLEN 22GETTB 11INSIDE 6INT1 1INT2 4INT3 1INTR 7LEFT 13OPNFIL 28ORDER 7RAN1 7RANC 4RAND 1RDELEM 14RDENV 7RDMAP 28RDRUN 6REMOVE 3SETUP 30SOLVE 18SPLIT 3VALID 3WREL 22

    Number ofSegmentsExecuted

    914003

    1000620

    1415316003

    10050005718000114726502533022

    246

    PercentSegmentCoverage

    81.873.70.00.075.0

    100.00.00.0

    85.7100.0100.066.7

    100.0100.0100.088.9

    0.00.075.045.50.0

    83.30.00.00.0

    71.453.864.30.00.00.0

    100.0100.0100.092.983.30.0

    83.316.7

    100.00.0

    100.0

    56.3Totals 437

    - 6 -

  • VOLCANO Analysis June 29, 1993

    VLCANOAIROUTBETWNCDAMAGCEILCHKELECIRINTCOINDDAMAGDECAYDISTDITOUTDOTECHO1ECH02ECH03GETARAGETBRKGETDCGETLENGETTBINSIDEINT1INT2INT3INTRLEFTOPNFILORDERRAN1RANCRANDRDELEMRDENVRDMAPRDRUNREMOVESETUPSOLVESPLITVALIDWREL

    0.20 0.40 0.60 0.80 1.00

    + I** *+** *I** *+**I** *+** *I** * + II*****************************************

    I************************************** I IIl**************************************************

    I ************************************************

    I **************************************************I ********************************* I II **************************************************I **************************************************I **************************************************I******************************************** I

    I **********1*********1*********1******** I II***********************IIII I I I I II******************************************I

    I*************************** IIII********************************II

    Il**************************************************

    I **********************************I *******************************************************************************I**********************************************

    - 7 -

  • VOLCANO Analysis June 29, 1993

    coverage - 0.

    0.01

  • VOLCANO AnalysisJue9,13 June 29, 1993

    Complexity Report by Subprogram for VOLCANO

    ncomt/s 1oc

    v g2/s 1oc

    cgotocgoto /sloc

    UgotoUgoto /sloc

    bifbIF /sloc

    lhf1IF /sloc BhatName

    vIcanoa irOutbetwnCd ama gcell1c hkel1ecirlntcoinDdamagdecaydi stdi tOutdotechol1echo2echo3getAragetBrkgetDCgeti-engetTBin sidei ntl1i nt2i nt3i ntrl eftopnf i11orderRANI1r anCr anDrdel1emrdEnvrdmaprdRun

    loc sloc cmnt ncomt

    14320518

    10311294343881514

    11511

    12496

    2175511076111100852620153622

    208222910696162112103184

    28355287182529142931832614433036940311514951418591024171028314235

    50108103936151038781

    5973142

    1002037253532321077156

    13281474485373179

    3188527129S

    2762147

    319308510211722201942282

    11931312873231860

    110.7251.4100.096.414.311.136.017.2

    192.9213.833.3

    261.1100.073. 1

    214.3197.733.358.3188.955.064.5126.728.622.240.057.111.1

    201.730.04.2

    182.4280.0260.774.242.9

    171.4

    21.428.6100.017.928.622.224.031.021.434.533.327.833.311.514.318.626.719.422.227.522.620.07.1

    22.220.042.938.927.140.025.011.810.025.012.931.08.6

    000000000000000000000000000000000000

    0.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.0

    000001000000000000000000000000000010

    0.00.00.00.00.05.60.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.00.02.40.0

    320212351101010252133101022811102021

    10.75.70.07.114.311.112.017.27. 13.40.05.60.03.80.04.7

    16.75.6

    11.17.59.76.7o.o

    11.10.014.311.113.610.04.25.90.07.10.04.82.9

    001000210100000101030000004001000090

    0.00.0

    20.00.00.00.08.03.40.03.40.00.00.00.00.02.30.02.80.07.50.00.00.00.00.00.0

    22.20.00.04.20.00.00.00.0

    21.40.0

    010000000000000110010000000000000110

    9 -

  • VOLCANO Analysis June 29, 1993

    ncomt vg2 cgoto ugoto bif lifName loc sloc cmnt ncomt /sloc /sloc cgoto /sloc ugoto /sloc bIF /sloc 1IF /sloc Bhat

    remove 14 4 7 2 50.0 50.0 0 0.0 0 0.0 0 0.0 0 0.0 0setup 162 64 45 28 43.8 23.4 0 0.0 0 0.0 6 9.4 4 6.3 1solve 48 28 17 9 32.1 21.4 0 0.0 0 0.0 5 17.9 0 0.0 0split 11 6 3 1 16.7 33.3 0 0.0 0 0.0 1 16.7 0 0.0 0valid 17 8 8 4 50.0 37.5 0 0.0 0 0.0 1 12.5 0 0.0 0Wrel 221 55 98 85 154.5 21.8 0 0.0 0 0.0 1 1.8 0 0.0 1

    Legend of Metrics in Report

    loc -- lines of codesloc -- number of executable statementscmnt -- total number of commntsncomt -- number of non-blank COMMENT statements100*ncomt/sloc -- percent, nonblank comments to number of executable statements100*vg2/sloc -- percent, extended complexity of number of executable statementscgoto -- number of COMPUTED GO TO statements100*cgoto/sloc -- percent, computed GOTO's to number of executable statementsugoto -- number of UNCONDITIONAL GO TO statements100*ugoto/sloc -- percent, unconditional GOTO's to number of executable statementsbIF -- number of BLOCK IF statements100*bif/sloc -- percent, Block IF statements to number of executable statementslIF -- number of LOGICAL IF statements100*lif/sloc -- percent, logical IF statements to number of executable statementsBhat -- Halstead's predicted number of errors in writing code

    - 10-