184d9c625SLionel Sambuc /* This file is automatically generated. DO NOT EDIT! */ 2*0a6a1f1dSLionel Sambuc /* Generated from: NetBSD: mknative-gcc,v 1.70 2013/05/05 07:11:34 skrll Exp */ 3*0a6a1f1dSLionel Sambuc /* Generated from: NetBSD: mknative.common,v 1.8 2006/05/26 19:17:21 mrg Exp */ 484d9c625SLionel Sambuc 584d9c625SLionel Sambuc // Control various target specific ABI tweaks. ARM version. 684d9c625SLionel Sambuc 7*0a6a1f1dSLionel Sambuc // Copyright (C) 2004-2013 Free Software Foundation, Inc. 884d9c625SLionel Sambuc // 984d9c625SLionel Sambuc // This file is part of the GNU ISO C++ Library. This library is free 1084d9c625SLionel Sambuc // software; you can redistribute it and/or modify it under the 1184d9c625SLionel Sambuc // terms of the GNU General Public License as published by the 1284d9c625SLionel Sambuc // Free Software Foundation; either version 3, or (at your option) 1384d9c625SLionel Sambuc // any later version. 1484d9c625SLionel Sambuc 1584d9c625SLionel Sambuc // This library is distributed in the hope that it will be useful, 1684d9c625SLionel Sambuc // but WITHOUT ANY WARRANTY; without even the implied warranty of 1784d9c625SLionel Sambuc // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 1884d9c625SLionel Sambuc // GNU General Public License for more details. 1984d9c625SLionel Sambuc 2084d9c625SLionel Sambuc // Under Section 7 of GPL version 3, you are granted additional 2184d9c625SLionel Sambuc // permissions described in the GCC Runtime Library Exception, version 2284d9c625SLionel Sambuc // 3.1, as published by the Free Software Foundation. 2384d9c625SLionel Sambuc 2484d9c625SLionel Sambuc // You should have received a copy of the GNU General Public License and 2584d9c625SLionel Sambuc // a copy of the GCC Runtime Library Exception along with this program; 2684d9c625SLionel Sambuc // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see 2784d9c625SLionel Sambuc // <http://www.gnu.org/licenses/>. 2884d9c625SLionel Sambuc 29*0a6a1f1dSLionel Sambuc /** @file bits/cxxabi_tweaks.h 30*0a6a1f1dSLionel Sambuc * This is an internal header file, included by other library headers. 31*0a6a1f1dSLionel Sambuc * Do not attempt to use it directly. @headername{cxxabi.h} 3284d9c625SLionel Sambuc */ 3384d9c625SLionel Sambuc 3484d9c625SLionel Sambuc #ifndef _CXXABI_TWEAKS_H 3584d9c625SLionel Sambuc #define _CXXABI_TWEAKS_H 1 3684d9c625SLionel Sambuc 3784d9c625SLionel Sambuc #ifdef __cplusplus 3884d9c625SLionel Sambuc namespace __cxxabiv1 3984d9c625SLionel Sambuc { 4084d9c625SLionel Sambuc extern "C" 4184d9c625SLionel Sambuc { 4284d9c625SLionel Sambuc #endif 4384d9c625SLionel Sambuc 4484d9c625SLionel Sambuc #ifdef __ARM_EABI__ 4584d9c625SLionel Sambuc // The ARM EABI uses the least significant bit of a 32-bit 4684d9c625SLionel Sambuc // guard variable. */ 4784d9c625SLionel Sambuc #define _GLIBCXX_GUARD_TEST(x) ((*(x) & 1) != 0) 4884d9c625SLionel Sambuc #define _GLIBCXX_GUARD_SET(x) *(x) = 1 4984d9c625SLionel Sambuc #define _GLIBCXX_GUARD_BIT 1 5084d9c625SLionel Sambuc #define _GLIBCXX_GUARD_PENDING_BIT __guard_test_bit (1, 1) 5184d9c625SLionel Sambuc #define _GLIBCXX_GUARD_WAITING_BIT __guard_test_bit (2, 1) 5284d9c625SLionel Sambuc typedef int __guard; 5384d9c625SLionel Sambuc 5484d9c625SLionel Sambuc // We also want the element size in array cookies. 5584d9c625SLionel Sambuc #define _GLIBCXX_ELTSIZE_IN_COOKIE 1 5684d9c625SLionel Sambuc 5784d9c625SLionel Sambuc // __cxa_vec_ctor should return a pointer to the array. 5884d9c625SLionel Sambuc typedef void * __cxa_vec_ctor_return_type; 5984d9c625SLionel Sambuc #define _GLIBCXX_CXA_VEC_CTOR_RETURN(x) return x 6084d9c625SLionel Sambuc // Constructors and destructors return the "this" pointer. 6184d9c625SLionel Sambuc typedef void * __cxa_cdtor_return_type; 6284d9c625SLionel Sambuc 6384d9c625SLionel Sambuc #else // __ARM_EABI__ 6484d9c625SLionel Sambuc 6584d9c625SLionel Sambuc // The generic ABI uses the first byte of a 64-bit guard variable. 6684d9c625SLionel Sambuc #define _GLIBCXX_GUARD_TEST(x) (*(char *) (x) != 0) 6784d9c625SLionel Sambuc #define _GLIBCXX_GUARD_SET(x) *(char *) (x) = 1 6884d9c625SLionel Sambuc #define _GLIBCXX_GUARD_BIT __guard_test_bit (0, 1) 6984d9c625SLionel Sambuc #define _GLIBCXX_GUARD_PENDING_BIT __guard_test_bit (1, 1) 7084d9c625SLionel Sambuc #define _GLIBCXX_GUARD_WAITING_BIT __guard_test_bit (2, 1) 7184d9c625SLionel Sambuc __extension__ typedef int __guard __attribute__((mode (__DI__))); 7284d9c625SLionel Sambuc 7384d9c625SLionel Sambuc // __cxa_vec_ctor has void return type. 7484d9c625SLionel Sambuc typedef void __cxa_vec_ctor_return_type; 7584d9c625SLionel Sambuc #define _GLIBCXX_CXA_VEC_CTOR_RETURN(x) return 7684d9c625SLionel Sambuc // Constructors and destructors do not return a value. 7784d9c625SLionel Sambuc typedef void __cxa_cdtor_return_type; 7884d9c625SLionel Sambuc 7984d9c625SLionel Sambuc #endif //!__ARM_EABI__ 8084d9c625SLionel Sambuc 8184d9c625SLionel Sambuc #ifdef __cplusplus 8284d9c625SLionel Sambuc } 8384d9c625SLionel Sambuc } // namespace __cxxabiv1 8484d9c625SLionel Sambuc #endif 8584d9c625SLionel Sambuc 8684d9c625SLionel Sambuc #endif 87