Re: [Boost-bugs] [Boost C++ Libraries] #9912: shared_ptr SEGV in Android debug builds

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #9912: shared_ptr SEGV in Android debug builds
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2014-04-18 21:44:33

#9912: shared_ptr SEGV in Android debug builds
  Reporter: ian@… | Owner: pdimov
      Type: Bugs | Status: new
 Milestone: To Be Determined | Component: smart_ptr
   Version: Boost 1.55.0 | Severity: Problem
Resolution: | Keywords:

Comment (by ian@…):

 The Android NDK supports compiling for two different arm abis. The default
 is ARMv5TE and it also supports ARMv7-A. These are configured through the
 armeabi and armeabi-v7a values, respectively.

 It is my understanding that armeabi is a subset of armeabi-v7a so that a
 binary compiled for armeabi should work on all arm android devices.

 I did a quick test to answer your question. I grabbed all the ARM_ARCH
 macros checked in smart_ptr/detail/spinlock_gcc_arm.hpp (these where the
 only references I could find in the sample app I posted) and created the
 following function:

 void arm_arch() {
     #if defined(__ARM_ARCH_7__)
         const char* arch="defined(__ARM_ARCH_7__)";
     #if defined(__ARM_ARCH_7A__)
         const char* arch="defined(__ARM_ARCH_7A__)";
     #if defined(__ARM_ARCH_7R__)
         const char* arch="defined(__ARM_ARCH_7R__)";
     #if defined(__ARM_ARCH_7M__)
         const char* arch="defined(__ARM_ARCH_7M__)";
     #if defined(__ARM_ARCH_7EM__)
         const char* arch="defined(__ARM_ARCH_7EM__)";
     #if defined(__ARM_ARCH_7S__)
         const char* arch="defined(__ARM_ARCH_7S__)";
     #if defined(__ARM_ARCH_6__)
         const char* arch="defined(__ARM_ARCH_6__)";
     #if defined(__ARM_ARCH_6J__)
         const char* arch="defined(__ARM_ARCH_6J__)";
     #if defined(__ARM_ARCH_6K__)
         const char* arch="defined(__ARM_ARCH_6K__)";
     #if defined(__ARM_ARCH_6Z__)
         const char* arch="defined(__ARM_ARCH_6Z__)";
     #if defined(__ARM_ARCH_6ZK__)
         const char* arch="defined(__ARM_ARCH_6ZK__)";
     #if defined(__ARM_ARCH_6T2__)
         const char* arch="defined(__ARM_ARCH_6T2__)";

 As you might expect, none are defined when compiled for armeabi. When
 compiled for armeabi-v7a, __ARM_ARCH_7A__ is defined.

 Also, the armeabi binary exhibits the crash on the Nexus 7, while the
 armeabi-v7a does not.

Ticket URL: <>
Boost C++ Libraries <>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:16 UTC