File : s-tracon.ads


   1 ------------------------------------------------------------------------------
   2 --                                                                          --
   3 --                         GNAT COMPILER COMPONENTS                         --
   4 --                                                                          --
   5 --             S Y S T E M . T R A C E B A C K _ C O N T R O L              --
   6 --                                                                          --
   7 --                                 S p e c                                  --
   8 --                                                                          --
   9 --                                                                          --
  10 --             Copyright (C) 2012, Free Software Foundation, Inc.           --
  11 --                                                                          --
  12 -- GNAT is free software;  you can  redistribute it  and/or modify it under --
  13 -- terms of the  GNU General Public License as published  by the Free Soft- --
  14 -- ware  Foundation;  either version 3,  or (at your option) any later ver- --
  15 -- sion.  GNAT is distributed in the hope that it will be useful, but WITH- --
  16 -- OUT ANY WARRANTY;  without even the  implied warranty of MERCHANTABILITY --
  17 -- or FITNESS FOR A PARTICULAR PURPOSE.                                     --
  18 --                                                                          --
  19 --                                                                          --
  20 --                                                                          --
  21 --                                                                          --
  22 --                                                                          --
  23 -- You should have received a copy of the GNU General Public License and    --
  24 -- a copy of the GCC Runtime Library Exception along with this program;     --
  25 -- see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see    --
  26 -- <http://www.gnu.org/licenses/>.                                          --
  27 --                                                                          --
  28 -- GNAT was originally developed  by the GNAT team at  New York University. --
  29 -- It is now maintained by Ada Core Technologies Inc (http://www.gnat.com). --
  30 --                                                                          --
  31 ------------------------------------------------------------------------------
  32 
  33 --  This is the spec of the System.Traceback_Control helper for the PPC/cert
  34 --  version of System.Traceback. See comments in the System.Traceback body for
  35 --  explanations on what we are providing here.
  36 
  37 package System.Traceback_Control is
  38 
  39    function Return_Address_Offset return System.Address;
  40    --  Relative to a given frame pointer, the constant offset at which the
  41    --  return address for this frame is stored.
  42 
  43    --  Return_Address_Offset is declared as a function instead of as named
  44    --  constant to allow exposing a single spec for all the supported targets,
  45    --  as the constant value varies across ABIs. Request inlining to minimize
  46    --  the cost of this extra abstraction layer:
  47 
  48    pragma Inline (Return_Address_Offset);
  49 
  50    function Is_Topframe_Retaddr (Retaddr : System.Address) return Boolean;
  51    --  Whether the provided Retaddr signals a top-of-stack frame.
  52 
  53 end System.Traceback_Control;