* Another ppro bug
@ 1997-10-31 17:23 H.J. Lu
0 siblings, 0 replies; only message in thread
From: H.J. Lu @ 1997-10-31 17:23 UTC (permalink / raw)
To: egcs
On linux/PPro,
# cc -S -O -march=i686 foo.cc
foo.cc: In method `class PlotFile3D & PlotFile3D::space(const class Vec3D &, const class Vec3D &)':
foo.cc:45: Internal compiler error.
foo.cc:45: Please submit a full bug report to `egcs-bugs@cygnus.com'.
I think it may have something to do with fmov.
H.J.
----
class Vec3D
{
protected:
double n[3];
public:
double x() const;
double y() const;
double z() const;
};
const int umini = 0;
const int vmini = 0;
const int umaxi = 3120;
const int vmaxi = 3120;
const double margin = 0.9;
class PlotFile3D
{
protected:
Vec3D ul,vl,wl;
Vec3D ur,vr,wr;
double scale;
double uorig, vorig;
public:
PlotFile3D& space (const Vec3D& p0, const Vec3D& p1);
PlotFile3D& home();
};
PlotFile3D& PlotFile3D::space(const Vec3D& pt0, const Vec3D& pt1)
{
double umin = (pt0.x() * ul.x()) <? (pt0.x() * ur.x())
<? (pt1.x() * ul.x()) <? (pt1.x() * ur.x());
double umax = (pt0.x() * ul.x()) >? (pt0.x() * ur.x())
>? (pt1.x() * ul.x()) >? (pt1.x() * ur.x());
double vmin = (pt0.x() * vl.x()) <? (pt0.x() * vr.x())
<? (pt1.x() * vl.x()) <? (pt1.x() * vr.x());
double vmax = (pt0.x() * vl.x()) >? (pt0.x() * vr.x())
>? (pt1.x() * vl.x()) >? (pt1.x() * vr.x());
umin += (pt0.y() * ul.y()) <? (pt0.y() * ur.y())
<? (pt1.y() * ul.y()) <? (pt1.y() * ur.y());
umax += (pt0.y() * ul.y()) >? (pt0.y() * ur.y())
>? (pt1.y() * ul.y()) >? (pt1.y() * ur.y());
int pixwidth = umaxi - umini;
int pixheight = vmaxi - vmini;
uorig = 0.5 * (pixwidth - scale*(umin+umax));
vorig = 0.5 * (pixheight - scale*(vmin+vmax));
return home();
}
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1997-10-31 17:23 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-10-31 17:23 Another ppro bug H.J. Lu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).