avro-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vivek Nadkarni (Updated) (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (AVRO-1038) Avro-C: Header file calls out GCC atomic intrinsics, which are missing in some GCC versions older than 4.5.0
Date Wed, 29 Feb 2012 08:49:58 GMT

     [ https://issues.apache.org/jira/browse/AVRO-1038?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Vivek Nadkarni updated AVRO-1038:
---------------------------------

    Attachment: AVRO-1038.patch

Attaching the (trivial) patch increasing the required version number
before using GCC atomic intrinsics to be > 4.5.0 instead of > 4.1.0

Doug mentioned an alternate option of detecting the presence or
absence of GCC atomic intrinsics via the cmake build scripts, in a
comment in AVRO-1033. This would certainly make the build more robust
than just a version number check. However, I also like the fact that a
simple version number check is independent of the build scripts, and
makes the code easier to port to non-cmake build environments.

I suggest applying this simple patch for Avro Version 1.6.3, since
1.6.3 is about to be released, and deciding later whether to add the
more sophisticated checks in the cmake build scripts.


                
> Avro-C: Header file calls out GCC atomic intrinsics, which are missing in some GCC versions
older than 4.5.0
> ------------------------------------------------------------------------------------------------------------
>
>                 Key: AVRO-1038
>                 URL: https://issues.apache.org/jira/browse/AVRO-1038
>             Project: Avro
>          Issue Type: Bug
>          Components: c
>    Affects Versions: 1.6.2
>         Environment: Linux on an x86 or x86-64 platform with GCC versions between 4.1.0
and 4.5.0. 
> Two platforms we tested were:
> 1. GCC 4.1.2 20080704 (Red Hat 4.1.2-48)
> 2. GCC 4.4.3 on Mandriva for an i586 target
>            Reporter: Vivek Nadkarni
>             Fix For: 1.6.3
>
>         Attachments: AVRO-1038.patch
>
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> This issue was described as Item 2 in AVRO-1033. Splitting it out into a 
> separate JIRA ticket per Doug's request.
> While compiling Avro across several flavors of
> Linux, we noticed that the GCC atomic intrinsics
> __sync_add_and_fetch() and __sync_sub_and_fetch() were not implemented
> for all versions of GCC greater than 4.1.0, causing compile errors.
> Specifically, the following two versions of GCC don't appear to
> support the GCC atomic intrinsics:
> 1. GCC 4.1.2 20080704 (Red Hat 4.1.2-48)
> 2. GCC 4.4.3 on Mandriva for an i586 target
> In our local code we have updated the GCC version test in refcount.h
> to require versions of GCC greater than 4.5.0, before including the
> GCC intrinsics. We might want to do the same in the global Avro
> repository.
> Cheers,
> Vivek Nadkarni

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message