This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug rtl-optimization/33624] [4.3 Regression] ICE in speculate_insn, at haifa-sched.c:4053
- From: "rguenth at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 2 Oct 2007 11:48:34 -0000
- Subject: [Bug rtl-optimization/33624] [4.3 Regression] ICE in speculate_insn, at haifa-sched.c:4053
- References: <bug-33624-10053@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from rguenth at gcc dot gnu dot org 2007-10-02 11:48 -------
Reduced testcase:
typedef int GBool;
class GString { };
class XRef;
struct Ref { };
enum ObjType {
objBool, objInt, objReal, objString, objName, objNull,
objArray, objDict, objStream, objRef, objCmd, objError, objEOF,
objNone };
class Object {
public:
GBool isInt() { }
GBool isNum() { }
GBool isArray() { return type == objArray; }
int getInt() { }
double getNum() {
return type == objInt ? (double)intg :
real;
}
int arrayGetLength();
Object *arrayGet(int i, Object *obj);
ObjType type;
union {
int intg;
double real;
};
};
class Dict {
public:
Object *lookup(char *key, Object *obj);
};
typedef unsigned int CID;
struct GfxFontCIDWidthExcepV {
CID first;
CID last;
double height;
double vx, vy;
};
struct GfxFontCIDWidths {
GfxFontCIDWidthExcepV * excepsV;
int nExcepsV;
};
class GfxFont {
public:
GfxFont(char *tagA, Ref idA, GString *nameA);
};
class GfxCIDFont: public GfxFont {
GfxCIDFont(XRef *xref, char *tagA, Ref idA, GString *nameA, Dict
*fontDict);
GfxFontCIDWidths widths;
};
GfxCIDFont::GfxCIDFont(XRef *xref, char *tagA, Ref idA, GString *nameA,
Dict *fontDict): GfxFont(tagA, idA, nameA) {
Dict *desFontDict;
Object obj1, obj2, obj3, obj4, obj5, obj6;
int excepsSize, i, j, k, n;
if (desFontDict->lookup("W2", &obj1)->isArray()) {
while (i + 1 < obj1.arrayGetLength()) {
if (obj2.isInt() && obj3.isInt() && i + 4 < obj1.arrayGetLength()) {
if (obj1.arrayGet(i + 2, &obj4)->isNum() && obj1.arrayGet(i + 3,
&obj5)->isNum() && obj1.arrayGet(i + 4, &obj6)->isNum()) {
widths.excepsV[widths.nExcepsV].last = obj3.getInt();
widths.excepsV[widths.nExcepsV].height = obj4.getNum() * 0.001; } }
}
}
}
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33624