Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 23 Oct 2002 15:59:01 -0700 (PDT)
From:      "Steven G. Kargl" <kargl@troutmask.apl.washington.edu>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   gnu/44426: Internal compiler error
Message-ID:  <200210232259.g9NMx1Xf002011@troutmask.apl.washington.edu>

next in thread | raw e-mail | index | archive | help

>Number:         44426
>Category:       gnu
>Synopsis:       Internal compiler error
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Oct 23 16:00:05 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Steven G. Kargl
>Release:        FreeBSD 5.0-CURRENT i386
>Organization:
apl-uw
>Environment:
System: FreeBSD troutmask.apl.washington.edu 5.0-CURRENT FreeBSD 5.0-CURRENT
#0: Wed Oct 23 13:47:34 PDT 2002 kargl@troutmask.apl.washington.edu:/usr/obj/usr/src/sys/TROUTMASK i386


>Description:

gcc dies with an internal compiler error.  I've files a bug report
with GCC, but with FreeBSD-5.0 around the corner I'll mention it
here, too.

troutmask:kargl[410] gcc -v -O2 -c b.c
Using built-in specs.
Configured with: FreeBSD/i386 system compiler
Thread model: posix
gcc version 3.2.1 [FreeBSD] 20021009 (prerelease)
/usr/libexec/cc1 -lang-c -v -D__GNUC__=3 -D__GNUC_MINOR__=2 -D__GNUC_PATCHLEVEL__=1 -D__GXX_ABI_VERSION=102 -D__FreeBSD__=5 -D__FreeBSD_cc_version=500004 -Dunix -D__KPRINTF_ATTRIBUTE__ -D__FreeBSD__=5 -D__FreeBSD_cc_version=500004 -D__unix__ -D__KPRINTF_ATTRIBUTE__ -D__unix -Asystem=unix -Asystem=bsd -Asystem=FreeBSD -D__OPTIMIZE__ -D__STDC_HOSTED__=1 -Acpu=i386 -Amachine=i386 -Di386 -D__i386 -D__i386__ -D__tune_i386__ -D__ELF__ -D_LONGLONG b.c -quiet -dumpbase b.c -O2 -version -o /var/tmp/cc4r9a8P.s
GNU CPP version 3.2.1 [FreeBSD] 20021009 (prerelease) (cpplib) (i386 FreeBSD/ELF)
GNU C version 3.2.1 [FreeBSD] 20021009 (prerelease) (i386-undermydesk-freebsd)
        compiled by GNU C version 3.2.1 [FreeBSD] 20021009 (prerelease).
ignoring duplicate directory "/usr/include"
#include "..." search starts here:
#include <...> search starts here:
 /usr/include
End of search list.
b.c: In function `ssqjac_':
b.c:202: unrecognizable insn:
(insn 641 736 650 (set (reg:SI 189)
        (ashift:SI (reg/v:SI 113)
            (const_int 1 [0x1]))) -1 (nil)
    (nil))
b.c:202: Internal compiler error in extract_insn, at recog.c:2150
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://www.gnu.org/software/gcc/bugs.html>; for instructions.

>How-To-Repeat:

Try to compile this code with "gcc -c -O2".  Sorry about the
the code, but it is the pre-processed output of a Fortran 95
subroutine.  I've tried to cut out the cruft.

typedef char   *Pointer;

typedef int     Integer;
typedef double  Double;

typedef struct {
	Integer        extent, mult, lower;
}               Triplet;

typedef struct {
	Pointer         addr;
	int             offset;
	Triplet         dim[1];
}               Dope1;

typedef struct {
	int             rank, offset;
	Triplet         dim[7];
}               BoundsInfo;

void 
ssqjac_(m_Dummy, n_Dummy, x_, fjac_, ldfjac_Dummy, nprob_Dummy)
	Integer        *m_Dummy;
	Integer        *n_Dummy;
	Double         *x_;
	Double         *fjac_;
	Integer        *ldfjac_Dummy;
	Integer        *nprob_Dummy;
{
	Integer         Tmp1;
	Integer         Tmp2;
	Integer         Tmp3;
	Integer         Tmp4;
	Integer         Tmp5;
	Integer         Tmp6;
	Integer         Tmp7;
	Double          Tmp8;
	Integer         Tmp9;
	Integer         Tmp10;
	Double          Tmp11;
	Integer         Tmp12;
	Integer         Tmp13;
	Integer         Tmp14;
	Integer         Tmp15;
	Double          Tmp16;
	Double          Tmp17;
	Integer         Tmp18;
	Integer         Tmp19;
	Double          Tmp20;
	Double          Tmp21;
	Double          Tmp22;
	Double          Tmp23;
	Integer         Tmp24;
	Integer         Tmp25;
	Integer         Tmp26;
	Integer         Tmp27;
	Integer         Tmp28;
	Integer         Tmp29;
	Integer         Tmp30;
	Integer         Tmp31;
	Integer         Tmp32;
	Integer         Tmp33;
	Integer         Tmp34;
	Double          Tmp35;
	Double          Tmp36;
	Double          Tmp37;
	Double          Tmp38;
	Double          Tmp39;
	char           *pTmp1;
	char           *pTmp2;
	Double         *pTmp3;
	char           *pTmp4;
	char           *pTmp5;
	Dope1           Section1;

	static Double   aConst1[11] = {4.00000000000000000e+00, 2.00000000000000000e+00, 1.00000000000000000e+00, 5.00000000000000000e-01, 2.50000000000000000e-01, 1.67000000000000010e-01, 1.25000000000000000e-01, 1.00000000000000006e-01, 8.32999999999999990e-02, 7.14000000000000051e-02, 6.25000000000000000e-02,};

	static Double   aConst2[11] = {4.00000000000000000e+00, 2.00000000000000000e+00, 1.00000000000000000e+00, 5.00000000000000000e-01, 2.50000000000000000e-01, 1.67000000000000010e-01, 1.25000000000000000e-01, 1.00000000000000006e-01, 8.32999999999999990e-02, 7.14000000000000051e-02, 6.25000000000000000e-02,};

	static Double   aConst3[11] = {4.00000000000000000e+00, 2.00000000000000000e+00, 1.00000000000000000e+00, 5.00000000000000000e-01, 2.50000000000000000e-01, 1.67000000000000010e-01, 1.25000000000000000e-01, 1.00000000000000006e-01, 8.32999999999999990e-02, 7.14000000000000051e-02, 6.25000000000000000e-02,};

	static Double   aConst4[11] = {4.00000000000000000e+00, 2.00000000000000000e+00, 1.00000000000000000e+00, 5.00000000000000000e-01, 2.50000000000000000e-01, 1.67000000000000010e-01, 1.25000000000000000e-01, 1.00000000000000006e-01, 8.32999999999999990e-02, 7.14000000000000051e-02, 6.25000000000000000e-02,};

	static Double   aConst5[11] = {4.00000000000000000e+00, 2.00000000000000000e+00, 1.00000000000000000e+00, 5.00000000000000000e-01, 2.50000000000000000e-01, 1.67000000000000010e-01, 1.25000000000000000e-01, 1.00000000000000006e-01, 8.32999999999999990e-02, 7.14000000000000051e-02, 6.25000000000000000e-02,};

	static Double   aConst6[11] = {4.00000000000000000e+00, 2.00000000000000000e+00, 1.00000000000000000e+00, 5.00000000000000000e-01, 2.50000000000000000e-01, 1.67000000000000010e-01, 1.25000000000000000e-01, 1.00000000000000006e-01, 8.32999999999999990e-02, 7.14000000000000051e-02, 6.25000000000000000e-02,};

	Integer         m_;
	Integer         n_;
	BoundsInfo      x_INFO;
	BoundsInfo      fjac_INFO;
	Integer         ldfjac_;
	Integer         nprob_;

	register Integer i_;
	register Integer j_;
	register Integer k_;

	auto Double     div_;
	auto Double     dx_;
	auto Double     prod_;
	auto Double     s2_;
	auto Double     temp_;
	auto Double     ti_;
	auto Double     tmp1_;
	auto Double     tmp2_;
	auto Double     tmp3_;
	auto Double     tmp4_;
	auto Double     tpi_;

	m_ = *m_Dummy;
	n_ = *n_Dummy;
	ldfjac_ = *ldfjac_Dummy;
	nprob_ = *nprob_Dummy;
	x_INFO.rank = 1;
	x_INFO.offset = 0;
	x_INFO.dim[0].lower = 1;
	Tmp1 = n_ - 1 + 1;

	if (Tmp1 < 0)
		Tmp1 = 0;

	x_INFO.dim[0].extent = Tmp1;
	x_INFO.dim[0].mult = 1;
	x_INFO.offset -= 1;
	fjac_INFO.rank = 2;
	fjac_INFO.offset = 0;
	fjac_INFO.dim[0].lower = 1;

	Tmp2 = ldfjac_ - 1 + 1;

	if (Tmp2 < 0)
		Tmp2 = 0;

	fjac_INFO.dim[0].extent = Tmp2;
	fjac_INFO.dim[0].mult = 1;
	fjac_INFO.offset -= 1;
	Tmp3 = 1 * Tmp2;
	fjac_INFO.dim[1].lower = 1;
	Tmp2 = n_ - 1 + 1;

	if (Tmp2 < 0)
		Tmp2 = 0;

	fjac_INFO.dim[1].extent = Tmp2;
	fjac_INFO.dim[1].mult = Tmp3;
	fjac_INFO.offset -= 1 * fjac_INFO.dim[1].mult;
	Tmp5 = fjac_INFO.dim[1].mult;
	Tmp4 = fjac_INFO.offset;

	switch (nprob_) {

	case 1:
		temp_ = 2.00000000000000000e+00 / m_;
		Tmp6 = n_;
		for (j_ = 1; j_ <= Tmp6; j_++) {

			Tmp7 = 8;
			Section1.addr = (Pointer) fjac_;
			Section1.offset = 0;
			Section1.addr += Tmp7 * (1 - 1);
			Section1.dim[0].mult = Tmp7;
			Section1.dim[0].extent = m_ - 1 + 1;

			if (Section1.dim[0].extent < 0)
				Section1.dim[0].extent = 0;

			Section1.offset = -(Section1.dim[0].mult);
			Section1.dim[0].lower = 1;
			Tmp7 *= fjac_INFO.dim[0].extent;
			Section1.addr += Tmp7 * (j_ - 1);
			Tmp8 = -(temp_);
			pTmp1 = Section1.addr;

			for (Tmp9 = 0; Tmp9 < Section1.dim[0].extent; Tmp9++) {
				*((Double *) pTmp1) = Tmp8;
				pTmp1 += Section1.dim[0].mult;
			}

			fjac_[j_ + Tmp5 * (j_) + Tmp4] = fjac_[j_ + Tmp5 * (j_) + Tmp4] + 1.00000000000000000e+00;
		}

		break;

	case 2:
		Tmp9 = n_;
		for (j_ = 1; j_ <= Tmp9; j_++) {
			Tmp10 = m_;
			for (i_ = 1; i_ <= Tmp10 - 1; i_ += 2) {
				fjac_[i_ + Tmp5 * (j_) + Tmp4] = (Double) ((i_ * j_));
				fjac_[(i_ + 1) + Tmp5 * (j_) + Tmp4] = (Double) (((i_ + 1) * j_));
			}
			if (i_ == Tmp10) {
				fjac_[i_ + Tmp5 * (j_) + Tmp4] = (Double) ((i_ * j_));
			}
			if (1 <= Tmp10)
				i_ = Tmp10 + 1;
		}
		break;

	}
}



>Fix:

Don't know ;-(



>Release-Note:
>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200210232259.g9NMx1Xf002011>