Saturday, June 24, 2023

NASA : The Ten Rules that Guide You in Writing Space-Grade Software

 Authored by the developer of the SPIN model checker, Gerald Holzmann


#

Rule of

Description

1

Ten

Aim for no more than 10 modules in a software system. This rule emphasizes the importance of keeping software systems modular and manageable.

2

Call Tree

Aim for no more than 10 levels in the call tree. The call tree represents the hierarchical structure of function calls in a software system. This rule suggests limiting the depth of the call tree to ensure code clarity and maintainability.

3

Decentralization

Aim for no more than 10 tasks per software system. This rule advocates for breaking down complex systems into smaller, manageable tasks to improve efficiency and reduce the risk of errors.

4

Data Coupling

Aim for no more than 10 data structures. Data coupling refers to the interdependencies between different data structures. This rule encourages limiting the number of data structures to simplify the software and minimize potential issues.

5

Control Coupling

Aim for no more than 10 control coupling connections. Control coupling refers to the interdependencies between different control flows in a software system. This rule promotes minimizing control coupling to enhance code readability and maintainability.

6

Global Data

Aim for no more than 10 global data structures. Global data refers to data that can be accessed by multiple modules or functions. This rule suggests limiting the use of global data to reduce complexity and potential conflicts.

7

Portability

Aim for a minimum of 10 compilers and hosts. This rule encourages designing software systems that are portable and can be compiled and run on multiple platforms and architectures.

8

Bounds

Aim to minimize loops with bounds greater than 10. Loops with large bounds can increase the risk of errors and performance issues. This rule advises minimizing loops with high bounds to improve efficiency and reduce potential problems.

9

Asserts

Aim for no more than 10 assertions per module. Assertions are statements that validate certain conditions in code. This rule suggests limiting the number of assertions to maintain code clarity and avoid excessive complexity.

10

Paths

Aim for a maximum of 10 paths through a software system. The number of paths through a software system refers to the various execution routes that can be taken. This rule encourages keeping the number of paths manageable to simplify testing and reduce potential issues.

 


No comments: