Published on

  • Be the first to comment

  • Be the first to like this

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide


  1. 1. Software Development Processes in CSED: The Future? Chris Greenough & David Worth Software Engineering Group Computational Science & Engineering Rutherford Appleton Laboratory [email_address]
  2. 2. Contents <ul><li>Background & Motivation </li></ul><ul><li>The Process </li></ul><ul><li>Some Definitions </li></ul><ul><li>Software Quality </li></ul><ul><li>What is a software process? </li></ul><ul><li>Review of CSED software development </li></ul><ul><li>Process models & their shortcomings </li></ul><ul><li>Similar exercises & their outcomes </li></ul><ul><li>CSED Best Practice </li></ul><ul><li>Classifying CSED Software </li></ul><ul><li>Current and future SESP Tools </li></ul><ul><li>Challenges & Difficulties </li></ul><ul><li>An Example </li></ul><ul><li>Next Steps </li></ul><ul><li>Conclusions </li></ul>
  3. 3. Background <ul><li>Over the past year we have been making and critical study of the development processes within CSED in response to one of the recommendation from the EPSRC SLA Review Panel. </li></ul><ul><li>The recommendation was - CSED should consider implementing minimum standards of design, documentation and testing to ensure that software distributed by Daresbury (and Rutherford Appleton) and used by the scientific community acquires a reputation of being of the highest quality. </li></ul><ul><li>A draft document has been written, discussed and modified by a small working group within CSED. </li></ul><ul><li>This presentation will outline the study process and described the current content of the draft Software Development Best Practice document. It is an opportunity to add your comments to the process as a prelude to starting to develop an implementation plan. </li></ul>
  4. 4. Plan of Action <ul><li>In response to the SLA Review CSED has started a process to address this recommendation. The process has had three main strands: </li></ul><ul><ul><li>A review of current software development practice within CSED. </li></ul></ul><ul><ul><li>A review of current best practice in software development taking into account software development initiatives in similar scientific areas. </li></ul></ul><ul><ul><li>The development of a CSED software development best practice. </li></ul></ul><ul><li>The goal of this activity is to promote an incremental improvement of the current practices within CSED using a set of appropriate best practices supported by a selection of suitable software engineering methods and tools. </li></ul>
  5. 5. Definition: Software Engineering <ul><li>Software engineering is an engineering discipline that is concerned with all aspects of software production. </li></ul><ul><li>Software engineers should adopt a systematic and organised approach to their work and use appropriate tools and techniques depending on the problem to be solved, the development constraints and the resources available. </li></ul><ul><li>Sommerville, Software Engineering, 8 th Edition </li></ul>
  6. 6. Software engineering and computer science? <ul><li>Computer science is concerned with theory and fundamentals; software engineering is concerned with the practicalities of developing and delivering useful software. </li></ul><ul><li>Computer science theories are still insufficient to act as a complete underpinning for software engineering (unlike e.g. physics and electrical engineering). </li></ul><ul><li>Sommerville, Software Engineering, 8 th Edition </li></ul>
  7. 7. What is software quality <ul><li>Software quality is a very difficult term to define! </li></ul><ul><li>The IEEE definition: Software quality is: </li></ul><ul><ul><li>The degree to which a system, components, or process meets specified requirements. </li></ul></ul><ul><ul><li>The degree to which a system, components, or process meets customer or use needs or expectations </li></ul></ul><ul><li>The Pressman definitions: </li></ul><ul><ul><li>Conformance to explicitly stated functional and performance requirements, explicit documented development standards, and implicit characteristics that are expect of al professionally developed software. </li></ul></ul><ul><li>These are very different: one focusing on the users the other focusing on the process. </li></ul><ul><li>Both definition agree that quality comes through conformance to a requirement specification. </li></ul><ul><li>Not particularly useful! </li></ul>
  8. 8. …software quality continued… <ul><li>Quality criteria include but are not limited to: </li></ul><ul><ul><li>Economy Correctness Resilience Integrity </li></ul></ul><ul><ul><li>Reliability Usability Documentation Modifiability </li></ul></ul><ul><ul><li>Clarity Understandability Validity Maintainability </li></ul></ul><ul><ul><li>Flexibility Generality Portability Interoperability </li></ul></ul><ul><ul><li>Testability Efficiency Modularity Resuability </li></ul></ul><ul><li>Because there are so many criteria, we can not use them all for measuring software quality. </li></ul><ul><li>Some of the desired characteristics can be used in software product standards as guiding actual development work. </li></ul><ul><li>To be a high quality software, software must be able to run correctly and consistently, have few defects (if there are), handle abnormal situation nicely, and need little installation effort. </li></ul>
  9. 9. What is a software process? <ul><li>A set of activities whose goal is the development or evolution of software. </li></ul><ul><li>Generic activities in all software processes are: </li></ul><ul><ul><li>Specification - what the system should do and its development constraints </li></ul></ul><ul><ul><li>Development - production of the software system </li></ul></ul><ul><ul><li>Validation - checking that the software is what the customer wants </li></ul></ul><ul><ul><li>Evolution - changing the software in response to changing demands. </li></ul></ul><ul><li>Sommerville, Software Engineering, 8 th Edition </li></ul>
  10. 10. Review of CSED Software Development <ul><li>Requirements </li></ul><ul><li>Design </li></ul><ul><li>Formal Methods </li></ul><ul><li>Languages </li></ul><ul><li>Graphics </li></ul><ul><li>Integrated Design Environments </li></ul><ul><li>Component Systems </li></ul><ul><li>Parallel/Distributed Technology </li></ul><ul><li>Data/Web Technology </li></ul><ul><li>Version Control </li></ul><ul><li>Software Processes </li></ul><ul><li>Process Tools </li></ul><ul><li>Performance </li></ul><ul><li>Software Quality </li></ul><ul><li>Testing </li></ul><ul><li>Distribution </li></ul><ul><li>Bug Tracing </li></ul><ul><li>Documentation </li></ul>The questionnaire was based on that used by the Harrison CCP Scoping Study with a few minor additions. The intension was to gather information on all elements of software development.
  11. 11. Current Practice within CSED (1) <ul><li>Requirements: Requirements gathering is done in an informal way if performed at all. Some documentation is written but not in general. There was only one instance of a detailed requirements document being written. </li></ul><ul><li>Design: This was not broken down into architectural and detailed design but the responses indicate only informal design is performed. There is no mention of the designs being documented. </li></ul><ul><li>Formal Methods: Only Object Orientation was mentioned as a formal method. </li></ul><ul><li>Languages: The dominant language is Fortran in some form: 77, 90 and 95 are mentioned. Some mention of C, C++, Java, perl and python. </li></ul><ul><li>Graphics: With one exception, DLV, generally only simple graphical systems are currently being used by most Groups. Those developing GUIs and visualisation tools are using OpenGL and Tcl/Tk. </li></ul>
  12. 12. Current Practice within CSED (2) <ul><li>Integrated Design Environments: Only Visual Studio on Windows systems is being used. </li></ul><ul><li>Component Systems: No group is using component style technology in their developments. </li></ul><ul><li>Parallel/Distributed: MPI is the dominant software harness and SPMD the most common paradigm of parallelism. Also Global Arrays (GA), OpenMP and Shmem are mentioned. </li></ul><ul><li>Data/Web Technology: Only use is in the CCPForge project and the HSL Archive. </li></ul><ul><li>Version Control: CVS and Subversion are used with a variety of GUI front ends. </li></ul><ul><li>Software Processes: In general no formal/documented SDP are used. </li></ul><ul><li>Process Tools: A general array of compilers, editors (emacs, vi) and debuggers (DDT, Totalview) are used. No group uses software quality tools in general development. </li></ul>
  13. 13. Current Practice within CSED (3) <ul><li>Performance: This is an issue for most groups. Tools such as Vampir, xprofile, VTune and gprof are used. </li></ul><ul><li>Software Quality: Compile options are the main tool for software quality where considered. In general no software quality planning and processes. </li></ul><ul><li>Testing: In general no testing plans. Some unit testing and testing through the use of data sets as part of regression testing. Some in house tools to monitor and control regression testing. </li></ul><ul><li>Distribution: Most distribution is performed using tar files and CVS repositories. Web sites and SourceForge are also used. It is unclear whether tools such as automake or auto config are used and the level of documentation was unspecified. </li></ul><ul><li>Bug Tracking: Bugzilla and forums are in use. </li></ul><ul><li>Documentation: Very few documentation tools are in use. LaTeX and html appear to be the most common mark up languages. Some user documentation is evident but other documentation is unclear. </li></ul>
  14. 14. Elements of Software Development <ul><li>User Requirements </li></ul><ul><li>Software Requirements: target systems, languages </li></ul><ul><li>Architectural Design: target systems </li></ul><ul><li>Detailed Software Design: language, structure, libraries </li></ul><ul><li>Implementation: languages, quality, version control </li></ul><ul><li>Unit Testing </li></ul><ul><li>Integration Testing </li></ul><ul><li>System Testing </li></ul><ul><li>Deployment and Acceptance Testing </li></ul><ul><li>Maintenance: regression testing, quality control, bug tracking, version control </li></ul><ul><li>Documentation: paper, online (HTML/PDF), system, user </li></ul>
  15. 15. The software process <ul><li>A structured set of activities required to develop a software system </li></ul><ul><ul><li>Specification; </li></ul></ul><ul><ul><li>Design; </li></ul></ul><ul><ul><li>Validation; </li></ul></ul><ul><ul><li>Evolution. </li></ul></ul><ul><li>A software process model is an abstract representation of a process. It presents a description of a process from some particular perspective. </li></ul>
  16. 16. The Waterfall Model Requirements Design Implementation Testing Deployment Maintenance The requirements define the required functionality and operation of the final package. These are driven by what the end-user expects the system to provide. Given a set of user and system requirements design often takes two steps: an overall system architecture followed by a detailed design of the system’s modules and interfaces. Program units are developed according to the detailed design. These are often functionally tested as a unit before integration into the complete system. Testing is one of the most important phases of a system’s development. It takes the form of testing the functionality of each component and then testing the complete integrated system. Deployment and maintenance of the system are the final steps in the process but often two of the hardest. A badly designed and implemented system can be very difficult to maintain.
  17. 17. Problems with the Waterfall model <ul><li>The main drawback of the waterfall model is the difficulty of accommodating change after the process is underway. </li></ul><ul><li>One phase has to be complete before moving onto the next phase </li></ul><ul><li>Inflexible partitioning of the project into distinct stages makes it difficult to respond to changing customer requirements. </li></ul><ul><li>Therefore, this model is only appropriate when the requirements are well-understood and changes will be fairly limited during the design process. </li></ul><ul><li>Few business systems have stable requirements. </li></ul><ul><li>The waterfall model is mostly used for large systems engineering projects where a system is developed at several sites. </li></ul>
  18. 18. Evolutionary development <ul><li>Exploratory development </li></ul><ul><ul><li>Objective is to work with customers and to Evolutionary development evolve a final system from an initial outline specification. Should start with well-understood requirements and add new features as proposed by the customer. </li></ul></ul><ul><li>Throw-away prototyping </li></ul><ul><ul><li>Objective is to understand the system requirements. Should start with poorly understood requirements to clarify what is really needed. </li></ul></ul>
  19. 19. Evolutionary development Outline Description Outline Description Outline Description Intermediate versions Initial Version Final Version Validation Design & Implementation Specification
  20. 20. Problems with Evolutionary development <ul><li>Problems </li></ul><ul><ul><li>Lack of process visibility; </li></ul></ul><ul><ul><li>Systems are often poorly structured; </li></ul></ul><ul><ul><li>Special skills (e.g. in languages for rapid prototyping) may be required. </li></ul></ul><ul><li>Applicability </li></ul><ul><ul><li>For small or medium-size interactive systems; </li></ul></ul><ul><ul><li>For parts of large systems (e.g. the user interface); </li></ul></ul><ul><ul><li>For short-lifetime systems. </li></ul></ul>
  21. 21. Spiral development <ul><li>Process is represented as a spiral rather than as a sequence of activities with backtracking. </li></ul><ul><li>Each loop in the spiral represents a phase in the process. </li></ul><ul><li>No fixed phases such as specification or design - loops in the spiral are chosen depending on what is required. </li></ul><ul><li>Risks are explicitly assessed and resolved throughout the process. </li></ul><ul><li>Proposed by Boehm (1988) </li></ul>
  22. 22. Boehm Spiral Development Model
  23. 23. Spiral Process Activities <ul><li>Objective setting </li></ul><ul><ul><li>Specific objectives for the phase are identified. </li></ul></ul><ul><li>Risk assessment and reduction </li></ul><ul><ul><li>Risks are assessed and activities put in place to reduce the key risks. </li></ul></ul><ul><li>Development and validation </li></ul><ul><ul><li>A development model for the system is chosen which can be any of the generic models. </li></ul></ul><ul><li>Planning </li></ul><ul><ul><li>The project is reviewed and the next phase of the spiral is planned. </li></ul></ul>
  24. 24. Post’s thoughts of software development
  25. 25. Some Model Conclusions <ul><li>Software development in a complex task </li></ul><ul><li>No one model is sufficient to represent the process </li></ul><ul><li>What is required is a recognition of the important processes and outputs to ensure quality software </li></ul>
  26. 26. Software Development – What Others Tried <ul><li>Reviewed current practice in similar activities: </li></ul><ul><ul><li>ASC Programme in general </li></ul></ul><ul><ul><li>Software Modernisation Program </li></ul></ul><ul><ul><li>Lawrence Livermore National Lab </li></ul></ul><ul><ul><li>Sandia National Lab </li></ul></ul><ul><ul><li>Los Alamos National Lab </li></ul></ul><ul><ul><li>SEI Carnegie Mellon </li></ul></ul><ul><li>Review some of the many standards available (IEEE, ISO, CMM..) </li></ul>
  27. 27. ASCI Lessons Learned – Post & Kendall (LANL) <ul><li>Build on successful code development history and prototypes </li></ul><ul><li>Highly competent and motivated people in a good team are essential </li></ul><ul><li>Risk identification, management and mitigation are essential </li></ul><ul><li>Software Project Management: Run the code project like a project </li></ul><ul><li>Schedule and resources are determined by the requirements </li></ul><ul><li>Customer focus is essential </li></ul><ul><ul><li>For code teams and for stakeholder support </li></ul></ul><ul><li>Better physics is much more important than better computer science </li></ul><ul><li>Use modern but proven Computer Science techniques, </li></ul><ul><ul><li>Don’t make the code project a Computer Science research project </li></ul></ul><ul><li>Provide training for the team </li></ul><ul><li>Software Quality Engineering: Best Practices rather than Processes </li></ul><ul><li>Validation and Verification are essential </li></ul>
  28. 28. Elements of Software Development <ul><li>User Requirements </li></ul><ul><li>Software Requirements: target systems, languages </li></ul><ul><li>Architectural Design: target systems </li></ul><ul><li>Detailed Software Design: language, structure, libraries </li></ul><ul><li>Implementation: languages, quality, version control </li></ul><ul><li>Unit Testing </li></ul><ul><li>Integration Testing </li></ul><ul><li>System Testing </li></ul><ul><li>Deployment and Acceptance Testing </li></ul><ul><li>Maintenance: regression testing, quality control, bug tracking, version control </li></ul><ul><li>Documentation: paper, online (HTML/PDF), system, user </li></ul>
  29. 29. Steps in CSED Best Practice (1) <ul><li>User and System Requirements: The user requirements of a system should describe the functional and non-functional requirements and expand these in terms that software engineers/implementers have a starting point for the system design. Output: User and System Requirements Document. </li></ul><ul><li>Management Planning: will contain details of the methods and techniques to be developed with (where necessary) task breakdowns, time scales and dependencies, It should also contain details on any standards being adopted by the project and details of any specific methods/techniques being used in the project. Choice of licence. Also includes document storage etc… Output: Management Plan </li></ul>
  30. 30. Steps in CSED Best Practice (2) <ul><li>Quality Assurance Planning: Decide how the quality of the development will be monitored, measured and maintained throughout the project. This could contain detailed processes and use of software tools where thought appropriate. It details how the quality of the system will be audited (measured and demonstrated, verified). Should also define roles and responsibilities. Output: Quality Assurance Plan </li></ul><ul><li>Software Design: Work out the overall architecture of the system and its components. Draft global data structures and their access methods. For larger projects, design each routine/module in relation to the architecture. Sort out languages, libraries and system constraints. Specify language standards and quality metrics to be applied and describe reasons for any exceptions/extensions used. Define project-specific coding conventions. Output: Software Design Document </li></ul>
  31. 31. Steps in CSED Best Practice (3) <ul><li>Test Planning: Develop test methodology and test cases to exercise the software. Must include deployment and acceptance testing and should consider other approaches including unit testing, coverage analysis and black and white box approaches. </li></ul><ul><ul><li>Unit Testing: Test each unit using methods agreed – API testing if necessary to cover all possible input values – coverage testing the exercise the code fully. </li></ul></ul><ul><ul><li>Integration Testing: Combine units within the call tree and test their interaction and interfaces. </li></ul></ul><ul><ul><li>Coverage Analysis: Examine whether test suite executes all statements and redesign test suite as necessary. </li></ul></ul><ul><ul><li>Deployment and Acceptance Testing: Run sample of representative user test cases test and distribute system using agreed mechanism. </li></ul></ul><ul><li>Output: Test Plan </li></ul>
  32. 32. Steps in CSED Best Practice (4) <ul><li>Implementation: Use the Software Design to do the development according to the agreed processes. Apply any software quality tests and ensure compliance. Includes writing documentation in-line. Output: The Software </li></ul><ul><li>System Documentation: will contain a very detailed description of all elements of the system. It will bring together how the user and system requirements have been implemented architecture and detailed design. It will include details of the software architectural, call trees, external dependencies, the algorithms used together with a detailed description of the implementation. It should contain everything a trainee developer would need to engage in a new development. Output: The System Documentation </li></ul>
  33. 33. Steps in CSED Best Practice (5) <ul><li>Testing: Test software in accordance with agreed Test Plan. Output: Test Report </li></ul><ul><li>User Documentation to include: User Manual - a complete description of the purpose and functionality of the system together with detailed instructions on how users can use the program. It should have not only a reference section giving details on each option available to the user but also some form of walk through tutorial covering the main elements of the systems usage. It should also contain suitable information on the algorithms being used and their implementation. (essential for non-prototype) Installation Guide - details on how the system is installed and tested on the systems. </li></ul>
  34. 34. Steps in CSED Best Practice (6) <ul><li>Project Web Site: The Web is now the main method of informing the scientific community about software and scientific results. The majority of CCPs and major CSED activities have a web presence. As part of the documentation of a software system information should be posted on the Web in a variety of formats. HTML, PDF and PostScript are the three most commonly used formats in the scientific community. The web pages should contain information on bug reporting and release developments as well as contact points. </li></ul><ul><li>Maintenance: Manage bug reports and fixes together with regression testing and re-distribution. </li></ul>
  35. 35. Classes of CSED Software Projects - Scope <ul><li>Production package: Software is being well used by the community and is either under development and/or being supported with bug fixes and support. Regular releases are made and it is available to the wider community through a distribution mechanism. </li></ul><ul><li>Project software: Software that is only being used and/or developed within a specific project for CSED or their project partners. There is no general release to the wider community. </li></ul><ul><li>Prototype software: Software developed in-house to test specific modelling or algorithmic ideas. Not intended to be used outside a specific group. </li></ul>
  36. 36. CSED Software Development Standard - Summary
  37. 37. Classes of CSED Software Projects - Age <ul><li>Legacy: Software that has been around for a long time and is a mixture of programming styles and language dialects. This class of software may not have most of the basic documentation. Action: Audit and apply remedial activities – transformation, standardisation, documentation… </li></ul><ul><li>Mature: Recent software that is developed and maintained that may have been designed and developed according to some standards and for which the majority of documentation exists. Action: Audit and update current status </li></ul><ul><li>New: A completely new development. This software will be developed according the requirements of the project and proposed target community (production, project or prototype). Action: Define and follow best practice </li></ul>
  38. 38. Software tools – acquired or licensed <ul><li>After a survey of the available tools for the Fortran language the following tools have been selected: </li></ul><ul><ul><li>ftnchek ( public domain) </li></ul></ul><ul><ul><li>FORCHECK ( FORCHECK) </li></ul></ul><ul><ul><li>NAGWare Tools ( Numerical Algorithms Group Ltd) </li></ul></ul><ul><ul><li>plusFORT suite ( Polyhedron Software Ltd) </li></ul></ul><ul><ul><li>Understand for Fortran ( Scientific Toolworks Inc.) </li></ul></ul><ul><ul><li>a range of different compilers (g77, gfortran, lf95, f95, fort..) </li></ul></ul><ul><ul><li>additional polish and metrics tools under development </li></ul></ul><ul><ul><li>test generation and management tools to follow </li></ul></ul><ul><li>These tools provide a basic working set to aid the developer produce and maintain a good language quality during the implementation, testing and maintenance phases. </li></ul>
  39. 39. Challenges and Difficulties <ul><li>Provision of Software Tools </li></ul><ul><ul><li>there are a limited number Fortran 95 based tools </li></ul></ul><ul><ul><li>many tools are particularly tolerant for mixed code </li></ul></ul><ul><ul><li>tools generally do not recognise pre-processors </li></ul></ul><ul><ul><li>language conformance is generally covered </li></ul></ul><ul><ul><li>transformations are limit </li></ul></ul><ul><ul><li>The available tools often create too much output which is difficult to navigate and interpret </li></ul></ul><ul><ul><li>license issues </li></ul></ul><ul><li>People and Processes </li></ul><ul><ul><li>Changing any development process is long term – years not months </li></ul></ul><ul><ul><li>There are very few short term gains to be seen </li></ul></ul><ul><ul><li>Using addition methods and process takes addition time and effort </li></ul></ul><ul><ul><li>Author recognition is a serious problem </li></ul></ul><ul><ul><li>The benefits of using these additional processes are often not immediately obvious </li></ul></ul>
  40. 40. An Example: The HSL Subroutine Library <ul><li>HSL is the main software product of the Numerical Algorithms Group </li></ul><ul><li>HSL is a library of portable, fully documented and tested Fortran packages for large-scale scientific computations </li></ul><ul><li>O - Input and output aids </li></ul><ul><li>P - Polynomial and rational functions Q - Numerical integration </li></ul><ul><li>S - Statistics </li></ul><ul><li>T - Interpolation and approximation </li></ul><ul><li>V - Optimization and nonlinear data fitting </li></ul><ul><li>Y - Test program generators </li></ul><ul><li>Z - Fortran system facilities </li></ul><ul><li>A - Computer algebra </li></ul><ul><li>D - Differential equations </li></ul><ul><li>E - Eigenvalues and eigenvectors </li></ul><ul><li>F - Mathematical functions </li></ul><ul><li>G - Geometrical problems </li></ul><ul><li>I - Integer valued functions </li></ul><ul><li>K – Sorting </li></ul><ul><li>L - Linear programming </li></ul><ul><li>M - Matrices and linear algebra </li></ul><ul><li>N - Nonlinear equations </li></ul>
  41. 41. HSL Software Development Documentation <ul><li>HSL is a product which has legacy, mature and new elements </li></ul><ul><li>HSL has been develop over many years </li></ul><ul><li>The motivation: </li></ul><ul><ul><li>new staff working on the project </li></ul></ul><ul><ul><li>external collaborator wishing to contribute </li></ul></ul><ul><ul><li>the realisation that there too many undocumented rules </li></ul></ul><ul><ul><li>the requirement to maintain quality standards </li></ul></ul><ul><ul><li>the need to reduce the time taken in preparing and polishing the software for new releases </li></ul></ul>
  42. 42. The HSL Software Development Document <ul><li>The document addresses new developments </li></ul><ul><li>The document contains 21 pages (plus two check lists) </li></ul><ul><li>The aim of the report is to provide clear and comprehensive guidelines for those involved in the </li></ul><ul><ul><li>design </li></ul></ul><ul><ul><li>development and </li></ul></ul><ul><ul><li>maintenance </li></ul></ul><ul><li>of software for HSL. </li></ul><ul><li>It explains the organisation of HSL, including: </li></ul><ul><ul><li>the use of version numbers </li></ul></ul><ul><ul><li>naming conventions </li></ul></ul><ul><ul><li>the aims and format of the user documentation </li></ul></ul><ul><ul><li>the programming language standards and style and </li></ul></ul><ul><ul><li>the verification and testing procedures </li></ul></ul>
  43. 43. Guidelines for the development of HSL software <ul><li>Introduction </li></ul><ul><li>Organisation of HSL </li></ul><ul><ul><li>Versions </li></ul></ul><ul><ul><li>Naming conventions </li></ul></ul><ul><ul><li>File naming conventions </li></ul></ul><ul><li>Documentation </li></ul><ul><ul><li>HSL specification documents </li></ul></ul><ul><ul><ul><li>Summary </li></ul></ul></ul><ul><ul><ul><li>How to use the package </li></ul></ul></ul><ul><ul><ul><li>General information </li></ul></ul></ul><ul><ul><ul><li>Method </li></ul></ul></ul><ul><ul><ul><li>Example of Use </li></ul></ul></ul><ul><ul><ul><li>Accompanying reports </li></ul></ul></ul><ul><li>HSL catalogue </li></ul><ul><li>Programming language and style </li></ul><ul><ul><li>Use of Fortran 95 </li></ul></ul><ul><ul><li>HSL rules and conventions </li></ul></ul><ul><ul><li>Use of control parameters </li></ul></ul><ul><ul><li>Checking of the user's data </li></ul></ul><ul><ul><li>The role of information parameters </li></ul></ul><ul><ul><li>Communication between procedures </li></ul></ul><ul><ul><li>Use of other library routines </li></ul></ul><ul><li>Verification and testing </li></ul><ul><ul><li>Simple examples </li></ul></ul><ul><ul><li>Comprehensive test </li></ul></ul><ul><ul><li>Independent testing </li></ul></ul><ul><li>Use of compilers </li></ul><ul><li>Role of the Librarian </li></ul><ul><ul><li>Check lists </li></ul></ul><ul><li>Licence issues </li></ul><ul><li>Acknowledgements </li></ul><ul><li>Appendices </li></ul><ul><ul><li>Profiling with g95 </li></ul></ul><ul><ul><li>Profiling with nag coverage95 </li></ul></ul><ul><ul><li>Checking line lengths </li></ul></ul><ul><ul><li>Debugging and checking conformance with standards </li></ul></ul><ul><ul><li>Polishing Fortran 95 code </li></ul></ul><ul><ul><li>Polishing Fortran 77 code </li></ul></ul><ul><ul><li>Other tools </li></ul></ul><ul><ul><li>Check list for new packages </li></ul></ul><ul><ul><li>Check list for revised packages </li></ul></ul>
  44. 44. Some examples <ul><li>Programming language and style </li></ul><ul><ul><li>… Packages must adhere to the Fortran 95 standard except that, from September 2006, we allow the use of allocatable structure components and dummy arguments. These are part of the official extension that is defined by Technical Report TR 15581(E) and is included in Fortran 2003. It allows arrays to be of dynamic size without the computing overheads and memory-leakage dangers of pointers…. </li></ul></ul><ul><li>Verification and testing </li></ul><ul><ul><li>… It should exercise all the modes that the user is permitted to employ (including testing of different settings for the control parameters, errors and warnings, and the different levels of printing). Ideally, it would exercise all possible execution sequences, but we recognize that this would usually not be practicable. Instead, we aim to exercise every statement at least once. Even this is often not practicable; for example, it is desirable to test the stat= variable of a deallocate statement, but it is probably impossible to provoke the statement to fail…. </li></ul></ul>
  45. 45. …some more examples <ul><li>Use of compilers </li></ul><ul><ul><li>… having access to a range of up-to-date Fortran compilers (currently, Nag, g95, lf95, ifort). The developer should test his or her software using each of these compilers…. </li></ul></ul><ul><li>Debugging and check for conformance with standards </li></ul><ul><ul><li>For debugging and checking conformance with standards, it is important to run several compilers. Our experience is that different compilers can find different problems. The following command lines may be used </li></ul></ul><ul><ul><ul><li>Nag compiler: f95 -C=all -gline </li></ul></ul></ul><ul><ul><ul><li>Lahey-Fujitsu compiler: lf95 --chk aesux </li></ul></ul></ul><ul><ul><ul><li>Gnu g95 compiler, allowing allocatable components and dummy arguments: </li></ul></ul></ul><ul><ul><ul><li>g95 -std=f95 -ftr15581 -Wall -Wimplicit-none -fbounds-check -ftrace=full </li></ul></ul></ul><ul><ul><ul><li>Intel compiler: ifort -C -u </li></ul></ul></ul><ul><ul><ul><li>Forchk syntax analysis for Fortran 77: forchk -f77 -nwarn –ninf </li></ul></ul></ul><ul><ul><li>Since each of these find different problems, they should all be used. </li></ul></ul>
  46. 46. Check List for a Revision <ul><li>Package name: . . . . . . . . . . . . . . . </li></ul><ul><li>Start date: . . . . . . . . . . . . . . . </li></ul><ul><li>Version: . . . . . . . . . . . . . . . </li></ul><ul><li>Start with the latest HSL version </li></ul><ul><li>of codes and documentation: YES/NO </li></ul><ul><li>Update documentation: </li></ul><ul><ul><li>Version number: YES/NO </li></ul></ul><ul><ul><li>Comments on changes: YES/NO </li></ul></ul><ul><ul><li>Changes: YES/NO </li></ul></ul><ul><li>Add comments to start of code: YES/NO </li></ul><ul><li>Simple tests: YES/NO </li></ul><ul><li>Comprehensive tests: </li></ul><ul><li>Profile: Coverage: YES/NO </li></ul><ul><li>Different modes: YES/NO </li></ul><ul><li>Compilers: g95: YES/NO Nag: YES/NO </li></ul><ul><li>ifort: YES/NO lf95: YES/NO </li></ul><ul><li>xlf95: YES/NO </li></ul><ul><li>Use source BLAS/LAPACK: YES/NO </li></ul><ul><li>Output portability: YES/NO </li></ul><ul><li>Independent testing (optional): Tested by . . . . . . . . . . . . . . . </li></ul><ul><li>Generate other versions (e.g. single): YES/NO </li></ul><ul><li>Simple tests: YES/NO </li></ul><ul><li>Comprehensive testing: YES/NO </li></ul>
  47. 47. Comparison with CSED Best Practice
  48. 48. Next Steps <ul><li>Classify the current software systems currently active within CSED: Product, Project or Prototype – Legacy, Mature or New. </li></ul><ul><li>A review of all documentation against documentation check list appropriate to the class. </li></ul><ul><li>A review of all development practice against development phases - to include quality controls, testing processes and change control appropriate to the class. </li></ul><ul><li>Development and execution of a remedial plan to bring the system up to the required level of conformance with tasks and times scales. </li></ul><ul><li>Monitor progress against the plan depending on the complexity and scale of the plan (monthly reviews would be recommended). </li></ul><ul><li>Define specific software metrics and acceptable ranges for conformance – use of tools such as compilers or other tools such as FORCHECK and nag_metrics. </li></ul><ul><li>Put in place a process of regular audits </li></ul>
  49. 49. Things we need to do <ul><li>Development and maintenance processes our software portfolio </li></ul><ul><li>Establish good software development practices </li></ul><ul><li>Capture/rescue important legacy software </li></ul><ul><li>Improve the quality of our software base: </li></ul><ul><ul><li>language conformance (not just Fortran) </li></ul></ul><ul><ul><li>portability (over many platforms and architectures) </li></ul></ul><ul><ul><li>design and structure </li></ul></ul><ul><ul><li>testing </li></ul></ul><ul><ul><li>maintenance </li></ul></ul><ul><ul><li>improve software quality </li></ul></ul><ul><li>Where possible use tools to automate, to make the process easier and more measurable </li></ul><ul><li>Ensure our developers adopt some good practices and develop their own process of improvement! </li></ul>
  50. 50. Conclusions <ul><li>Much of Best Practice is common sense – however is it formalised common sense </li></ul><ul><li>The essence of Best Practice is in definition and documentation </li></ul><ul><li>Software development should be managed like any project </li></ul><ul><li>The Best Practice outlined is a framework in which to work </li></ul><ul><li>The process steps have not been defined – these are the remit of the project to defined, implement and audit </li></ul><ul><li>There are some tools that can aid a process step </li></ul><ul><li>There is no magic bullet – software and development process improvement is a long term activity </li></ul>