stdcxx-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Liviu Nicoara (JIRA)" <j...@apache.org>
Subject [jira] [Assigned] (STDCXX-1072) [Oracle Solaris/SPARCV8] stricter mutex alignment requirements
Date Wed, 10 Oct 2012 11:53:02 GMT

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

Liviu Nicoara reassigned STDCXX-1072:
-------------------------------------

    Assignee: Liviu Nicoara
    
> [Oracle Solaris/SPARCV8] stricter mutex alignment requirements
> --------------------------------------------------------------
>
>                 Key: STDCXX-1072
>                 URL: https://issues.apache.org/jira/browse/STDCXX-1072
>             Project: C++ Standard Library
>          Issue Type: Bug
>          Components: Thread Safety
>    Affects Versions: 4.2.1, 4.2.x, 4.3.x, 5.0.0
>         Environment: Oracle Solaris on SPARC V8 (or V9 emulation?) hardware.
>            Reporter: Liviu Nicoara
>            Assignee: Liviu Nicoara
>              Labels: SPARC, Solaris, V8, alignment, mutex
>             Fix For: 4.2.x, 4.3.x, 5.0.0
>
>         Attachments: patch.2.diff, patch.diff
>
>   Original Estimate: 4h
>  Remaining Estimate: 4h
>
> The issue has been reported in STDCXX-1040, then STDCXX-1066. The originator was apparently
an improvement (as a response to CR 6296770: http://tinyurl.com/8ohjsgl) shipped with KU 137111-01
(http://tinyurl.com/ceet6ec) which requires stricter alignment than the machine word for userland
mutexes. 
> Quoting here the Fujitsu patch notes (in case it goes away):
> {quote}
> {noformat}
> 2) When an application using the mutex lock or rw lock in the way shown below is executed.
(*1, *2) ...
>       *2) ... example of programming that causes the ... problem.
>         <In the case where the problem occurs>
>           ----------------------------------------------------------------
>           int       *ip;
>           mutex_t   *mp;
>           ip = (int *) malloc(sizeof (int) + sizeof (mutex_t));
>           mp = (mutex_t *) (ip + 1);
>                              /* The address is used with a modification */
>           ----------------------------------------------------------------
>         <In the case where the problem does not occur -1>
>           ----------------------------------------------------------------
>           mutex_t   mp;                          /* Obtained statically */
>           ----------------------------------------------------------------
>         <In the case where the problem does not occur -2>
>           ----------------------------------------------------------------
>           mutex_t   *mp;
>           mp = (mutex_t *) malloc(sizeof (mutex_t));
>                        /* The address is used without any modifications */
>           ----------------------------------------------------------------
> {noformat}
> {quote}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message