[X-tt-list:50] Re: Xのクラッシュに悩まされてます

Zurück zum Archiv-Index

Chisato Yamauchi cyama****@plamo*****
2003年 6月 29日 (日) 00:44:28 JST


From: Chisato Yamauchi <cyama****@plamo*****>
Subject: [X-tt-list:49] Re: Xのクラッシュに悩まされてます
Date: Sat, 28 Jun 2003 14:07:46 +0900
Message-ID: <20030****@plamo*****>

>   ところで,PolyGlyphBltAsSingleBitmap(); 内に,
> 
>     block = (CARD32*)ALLOCATE_LOCAL(size);
> 
> という部分がありますが,ここを試しに
> 
>     block = (CARD32*)ALLOCATE_LOCAL(2*size);
> 
> なんて事をするとどうなるでしょうか?

  このテストをした後,添付のパッチで libxaa.a をつくって
ログをとっていただけませんか.

  よろしくお願いします.

#PPCの方,クラッシュが再現できなくて困ってます.G4とか
#速いマシンでないとダメなのかなぁ...
==  Chisato Yamauchi  =================================
    URL: http://phe.phyas.aichi-edu.ac.jp/~cyamauch/ 
-------------- next part --------------
*** xaaNonTEText.c.orig	2003-06-28 13:44:09.000000000 +0900
--- xaaNonTEText.c	2003-06-29 00:39:14.000000000 +0900
***************
*** 238,243 ****
--- 238,244 ----
  ){
     int i, w = 0;
     
+    fprintf(stderr,"[CollectCharacterInfo]\n");
     for(i = 0; i < nglyph; i++, ppci++, glyphs++) {
  	glyphs->bits = (unsigned char*)((*ppci)->bits);
  	glyphs->start = w + (*ppci)->metrics.leftSideBearing;
***************
*** 246,251 ****
--- 247,258 ----
  	glyphs->height = glyphs->yoff + (*ppci)->metrics.descent;
  	glyphs->srcwidth = PADGLYPHWIDTHBYTES(glyphs->end - glyphs->start);
  	w += (*ppci)->metrics.characterWidth;
+ 	fprintf(stderr, "*%d*", i);
+ 	fprintf(stderr," ascent:%d descent:%d cWidth:%d lsb:%d rsb:%d\n",
+ 		(*ppci)->metrics.ascent,(*ppci)->metrics.descent,
+ 		(*ppci)->metrics.characterWidth,
+ 		(*ppci)->metrics.leftSideBearing,
+ 		(*ppci)->metrics.rightSideBearing);
     }
     return w;
  }
***************
*** 278,283 ****
--- 285,294 ----
      Top = yInit - FONTMAXBOUNDS(font,ascent);
      Bottom = yInit + FONTMAXBOUNDS(font,descent);
  
+     fprintf(stderr,"[PolyGlyphBltAsSingleBitmap] nglyph=%d nbox=%d xInit=%d yInit=%d\n",
+ 	    nglyph,nbox,xInit,yInit);
+     fprintf(stderr,"Left=%d Right=%d Top=%d Bottom=%d\n",Left,Right,Top,Bottom);
+ 
      /* get into the first band that may contain part of our string */
      while(nbox && (Top >= pbox->y2)) {
  	pbox++; nbox--;
***************
*** 285,297 ****
--- 296,320 ----
  
      if(!nbox) return;
  
+     fprintf(stderr,"-1- nbox=%d\n",nbox);
+ 
      pitch = (Right - Left + 31) >> 5;
      size = (pitch << 2) * (Bottom - Top);
      block = (CARD32*)ALLOCATE_LOCAL(size);
      bzero(block, size);
  
+     fprintf(stderr,"pitch=%d size=%d\n",pitch,size);
+ 
      topLine = 10000; botLine = -10000;
  
+     fprintf(stderr,"*MAXBOUNDS*");
+     fprintf(stderr," ascent:%d descent:%d cWidth:%d lsb:%d rsb:%d\n",
+ 	    FONTMAXBOUNDS(font,ascent),
+ 	    FONTMAXBOUNDS(font,descent),
+ 	    FONTMAXBOUNDS(font,characterWidth),
+ 	    FONTMAXBOUNDS(font,leftSideBearing),
+ 	    FONTMAXBOUNDS(font,rightSideBearing));
+ 
      while(nglyph--) {
  	top = -glyphs->yoff;
  	bot = top + glyphs->height;
***************
*** 305,310 ****
--- 328,336 ----
  	shift = skippix & 31;
  	extra = ((shift + glyphs->end - glyphs->start) > 32);
  
+ 	fprintf(stderr,"<[nglyph=%d][shift=%d][extra=%d]>",nglyph,shift,extra);
+ 	fflush(stderr);
+ 
  	for(i = top; i < bot; i++) {
  	    *pntr |= SHIFT_L(*bits, shift);
  	    if(extra)
***************
*** 316,339 ****
--- 342,375 ----
  	glyphs++;
      }
  
+     fprintf(stderr,"\n-2-\n");
+ 
      pntr = block + ((FONTMAXBOUNDS(font,ascent) + topLine) * pitch);
  
      Top = yInit + topLine;
      Bottom = yInit + botLine;
  
+     fprintf(stderr,"Top=%d Bottom=%d topLine=%d botLine=%d\n",Top,Bottom,topLine,botLine);
+ 
      while(nbox && (Top >= pbox->y2)) {
  	pbox++; nbox--;
      }
  
+     fprintf(stderr,"-3- nbox=%d\n",nbox);
+ 
+     fprintf(stderr,"loop: ");
      while(nbox && (Bottom > pbox->y1)) {
  	LeftEdge = max(Left, pbox->x1);
  	RightEdge = min(Right, pbox->x2);
+ 	fprintf(stderr,"<[nbox=%d][LEdge=%d][REdge=%d]>",nbox,LeftEdge,RightEdge);
+ 	fflush(stderr);
  
  	if(RightEdge > LeftEdge) {
  	    skippix = LeftEdge - Left;
  	    topLine = max(Top, pbox->y1);
  	    botLine = min(Bottom, pbox->y2);	
  	    height = botLine - topLine;
+ 	    fprintf(stderr,"([skippix=%d][topLine=%d][botLine=%d][height=%d])",skippix,topLine,botLine,height);
  
  	    if(height > 0) 
  	       (*infoRec->WriteBitmap)(pScrn, LeftEdge, topLine, 
***************
*** 345,350 ****
--- 381,387 ----
  
  	nbox--; pbox++;
      }
+     fprintf(stderr,"\n###\n");
  
      DEALLOCATE_LOCAL(block);
  }


X-tt-list メーリングリストの案内
Zurück zum Archiv-Index