[asterisk-bugs] [Asterisk 0012886]: crash asterisk.c compiled for i486sx with out fpu

noreply at bugs.digium.com noreply at bugs.digium.com
Thu Jun 19 11:00:41 CDT 2008


The following issue has been RESOLVED. 
====================================================================== 
http://bugs.digium.com/view.php?id=12886 
====================================================================== 
Reported By:                tecnoxarxa
Assigned To:                svnbot
====================================================================== 
Project:                    Asterisk
Issue ID:                   12886
Category:                   General
Reproducibility:            always
Severity:                   crash
Priority:                   normal
Status:                     resolved
Asterisk Version:           1.4.21-rc1 
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Disclaimer on File?:        N/A 
Request Review:              
Resolution:                 fixed
Fixed in Version:           
====================================================================== 
Date Submitted:             06-18-2008 19:03 CDT
Last Modified:              06-19-2008 11:00 CDT
====================================================================== 
Summary:                    crash asterisk.c compiled for i486sx with out fpu
Description: 
Crash:

http://bugs.digium.com/view.php?id=0  0x08069847 in rdtsc () at asterisk.c:433
No locals.
http://bugs.digium.com/view.php?id=1  0x08069659 in ast_mark (i=0, startstop=1)
at asterisk.c:442
No locals.
http://bugs.digium.com/view.php?id=2  0x080b8a04 in extension_match_core
(pattern=0x817f4d8 "200",
data=0xb7c71bc4 "69", mode=E_MATCH) at pbx.c:878
        i = 135787688
        prof_id = 0



File: asterisk.c

---- Start Line 416 --------

#if defined ( __i386__) && (defined(__FreeBSD__) || defined(linux))
#if defined(__FreeBSD__)
#include <machine/cpufunc.h>
#elif defined(linux)
static __inline uint64_t
rdtsc(void)
{
        uint64_t rv;

        __asm __volatile(".byte 0x0f, 0x31" : "=A" (rv));
        return (rv);
}
#endif
#else   /* supply a dummy function on other platforms */
static __inline uint64_t
rdtsc(void)
{
        return 0;
}
#endif

int64_t ast_mark(int i, int startstop)
{
        if (!prof_data || i < 0 || i > prof_data->entries) /* invalid
index */
                return 0;
        if (startstop == 1)
                prof_data->e[i].mark = rdtsc();
        else {
                prof_data->e[i].mark = (rdtsc() - prof_data->e[i].mark);
                if (prof_data->e[i].scale > 1)
                        prof_data->e[i].mark /= prof_data->e[i].scale;
                prof_data->e[i].value += prof_data->e[i].mark;
                prof_data->e[i].events++;
        }
        return prof_data->e[i].mark;
}

---- end ----
====================================================================== 

Issue History 
Date Modified   Username       Field                    Change               
====================================================================== 
06-19-08 11:00  svnbot         Status                   new => resolved     
06-19-08 11:00  svnbot         Resolution               open => fixed       
06-19-08 11:00  svnbot         Assigned To               => svnbot          
======================================================================




More information about the asterisk-bugs mailing list