The R Project SVN R

Rev

Rev 63431 | Rev 63481 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 63431 Rev 63454
Line 106... Line 106...
106
{
106
{
107
    int dummy;
107
    int dummy;
108
    intptr_t usage = R_CStackDir * (R_CStackStart - (uintptr_t)&dummy);
108
    intptr_t usage = R_CStackDir * (R_CStackStart - (uintptr_t)&dummy);
109
 
109
 
110
    /* printf("usage %ld\n", usage); */
110
    /* printf("usage %ld\n", usage); */
111
    if(R_CStackLimit != -1 && usage > /*0.95 * */R_CStackLimit) 
111
    if(R_CStackLimit != -1 && usage > ((intptr_t) R_CStackLimit))
112
	R_SignalCStackOverflow();
112
	R_SignalCStackOverflow();
113
}
113
}
114
 
114
 
115
void R_CheckStack2(size_t extra)
115
void R_CheckStack2(size_t extra)
116
{
116
{
Line 118... Line 118...
118
    intptr_t usage = R_CStackDir * (R_CStackStart - (uintptr_t)&dummy);
118
    intptr_t usage = R_CStackDir * (R_CStackStart - (uintptr_t)&dummy);
119
 
119
 
120
    /* do it this way, as some compilers do usage + extra 
120
    /* do it this way, as some compilers do usage + extra 
121
       in unsigned arithmetic */
121
       in unsigned arithmetic */
122
    usage += extra;
122
    usage += extra;
123
    if(R_CStackLimit != -1 && usage > /*0.95 * */R_CStackLimit)
123
    if(R_CStackLimit != -1 && usage > ((intptr_t) R_CStackLimit))
124
	R_SignalCStackOverflow();
124
	R_SignalCStackOverflow();
125
 
125
 
126
}
126
}
127
 
127
 
128
void R_CheckUserInterrupt(void)
128
void R_CheckUserInterrupt(void)