HP.com home PA-RISC Procedure Calling Conventions Reference Manual > Appendix A Standard Procedure Calls

A.3 FORTRAN Source Code

MPE documents

Complete PDF
Table of Contents


  call one
  end

  subroutine one
  integer*4 a,b,c,d,e,f
  a = 5
  b = 10
  call proca(a,b,c,d,e,f) --> Note: In FORTRAN, all parameters are
                                    passed by reference, so it is
  e = c + d                         impossible to simulate the
  f = e                             difference between Pascal's
  return                            VAR and Value parameters.
  end

  subroutine proca(a,b,c,d,e,f)
  integer*4 a,b,c,d,e,f
  c = a + b
  d = mul(a,b)
  return
  end

  function mul(a,b)
  integer*4 a,b
  mul = a*b
  return
  end




A.2 ANSI C Source Code


A.4 Assembly Listing