1d4e76214Sopenharmony_ci/* libunwind - a platform-independent unwind library
2d4e76214Sopenharmony_ci   Copyright (C) 2006-2007 IBM
3d4e76214Sopenharmony_ci   Contributed by
4d4e76214Sopenharmony_ci     Corey Ashford <cjashfor@us.ibm.com>
5d4e76214Sopenharmony_ci     Jose Flavio Aguilar Paulino <jflavio@br.ibm.com> <joseflavio@gmail.com>
6d4e76214Sopenharmony_ci
7d4e76214Sopenharmony_ci   Copied from libunwind-x86_64.h, modified slightly for building
8d4e76214Sopenharmony_ci   frysk successfully on ppc64, by Wu Zhou <woodzltc@cn.ibm.com>
9d4e76214Sopenharmony_ci   Will be replaced when libunwind is ready on ppc64 platform.
10d4e76214Sopenharmony_ci
11d4e76214Sopenharmony_ciThis file is part of libunwind.
12d4e76214Sopenharmony_ci
13d4e76214Sopenharmony_ciPermission is hereby granted, free of charge, to any person obtaining
14d4e76214Sopenharmony_cia copy of this software and associated documentation files (the
15d4e76214Sopenharmony_ci"Software"), to deal in the Software without restriction, including
16d4e76214Sopenharmony_ciwithout limitation the rights to use, copy, modify, merge, publish,
17d4e76214Sopenharmony_cidistribute, sublicense, and/or sell copies of the Software, and to
18d4e76214Sopenharmony_cipermit persons to whom the Software is furnished to do so, subject to
19d4e76214Sopenharmony_cithe following conditions:
20d4e76214Sopenharmony_ci
21d4e76214Sopenharmony_ciThe above copyright notice and this permission notice shall be
22d4e76214Sopenharmony_ciincluded in all copies or substantial portions of the Software.
23d4e76214Sopenharmony_ci
24d4e76214Sopenharmony_ciTHE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
25d4e76214Sopenharmony_ciEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
26d4e76214Sopenharmony_ciMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
27d4e76214Sopenharmony_ciNONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
28d4e76214Sopenharmony_ciLIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
29d4e76214Sopenharmony_ciOF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
30d4e76214Sopenharmony_ciWITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.  */
31d4e76214Sopenharmony_ci
32d4e76214Sopenharmony_ci#ifndef dwarf_config_h
33d4e76214Sopenharmony_ci#define dwarf_config_h
34d4e76214Sopenharmony_ci
35d4e76214Sopenharmony_ci/* For PPC64, 48 GPRs + 33 FPRs + 33 AltiVec + 1 SPE  */
36d4e76214Sopenharmony_ci#define DWARF_NUM_PRESERVED_REGS        115
37d4e76214Sopenharmony_ci
38d4e76214Sopenharmony_ci#define DWARF_REGNUM_MAP_LENGTH         115
39d4e76214Sopenharmony_ci
40d4e76214Sopenharmony_ci/* Return TRUE if the ADDR_SPACE uses big-endian byte-order.  */
41d4e76214Sopenharmony_ci#define dwarf_is_big_endian(addr_space) 1
42d4e76214Sopenharmony_ci
43d4e76214Sopenharmony_ci/* Convert a pointer to a dwarf_cursor structure to a pointer to
44d4e76214Sopenharmony_ci   unw_cursor_t.  */
45d4e76214Sopenharmony_ci#define dwarf_to_cursor(c)      ((unw_cursor_t *) (c))
46d4e76214Sopenharmony_ci
47d4e76214Sopenharmony_citypedef struct dwarf_loc
48d4e76214Sopenharmony_ci  {
49d4e76214Sopenharmony_ci    unw_word_t val;
50d4e76214Sopenharmony_ci#ifndef UNW_LOCAL_ONLY
51d4e76214Sopenharmony_ci    unw_word_t type;            /* see X86_LOC_TYPE_* macros.  */
52d4e76214Sopenharmony_ci#endif
53d4e76214Sopenharmony_ci  }
54d4e76214Sopenharmony_cidwarf_loc_t;
55d4e76214Sopenharmony_ci
56d4e76214Sopenharmony_ci#endif /* dwarf_config_h */
57