Parameter-Induced Aliasing in Ada

  • Authors:
  • Wolfgang Gellerich;Erhard Plödereder

  • Affiliations:
  • -;-

  • Venue:
  • Ada Europe '01 Proceedings of the 6th Ade-Europe International Conference Leuven on Reliable Software Technologies
  • Year:
  • 2001

Quantified Score

Hi-index 0.00

Visualization

Abstract

Parameter-induced aliasing means that overlapping areas of memory are associated with different identifiers causing assignments to one of them to have the unexpected effect of also changing the other's value. The disadvantages of aliasing for most aspects of programming languages have been known for decades and it is reported that aliasing occurs quite often when programming in languages like C or Fortran. In contrast, our examination of 173 MB real-world Ada code with a total of 93690 subprogram calls revealed less than one alias pair per 10000 lines of code. Further code inspection showed that most alias pairs could have been avoided. The rare occurrence of aliasing may be one reason for the low error rate frequently reported for Ada programs. This paper presents the methods and results of our analysis. Further, it discusses two approaches to forbid aliasing by language rules and evaluates the usability of our alias-free "named container" model suggested earlier.