🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.help
Article #52437

Problem with emit_move_insn in 2.2.2

#52437
From: Michael Gersten
Date: Tue, 22 Sep 1992 17:18
65 lines
2740 bytes
Here's a question on emit_move_insn.

The code around line 1227 in expr.c says,
  else if (GET_MODE_SIZE (mode) >= UNITS_PER_WORD)
                                ^^

If the mode is the same size as UNITS_PER_WORD, then it goes into this routine,  
which ends with another emit_move_insn call.

On my system this is giving an infinite loop. Since it's still there, and no one  
else has complained, I'm assuming it's something else that is triggering this.

Any ideas?

From tm.h:
/* number of bits in an addressible storage unit */
#define BITS_PER_UNIT 16

/* Width in bits of a "word", which is the contents of a machine register. */
#define BITS_PER_WORD 16

/* Width of a word, in units (bytes).  */
#define UNITS_PER_WORD 1

From the backtrace:
#2842 0x38f8e in emit_move_insn (x=(rtx) 0x224254, y=(rtx) 0x218728) (expr.c  
line 1252)
#2843 0x38f8e in emit_move_insn (x=(rtx) 0x224254, y=(rtx) 0x218728) (expr.c  
line 1252)
#2844 0x3a3e2 in store_expr (exp=(tree) 0x21c208, target=(rtx) 0x224254,  
suggest_reg=0) (expr.c line 2203)
#2845 0x39e96 in expand_assignment (to=(tree) 0x224200, from=(tree) 0x21c208,  
want_value=0, suggest_reg=0) (expr.c line 2007)
#2846 0x3e78e in expand_expr (exp=(tree) 0x21c21c, target=(rtx) 0x0,  
tmode=VOIDmode, modifier=EXPAND_NORMAL) (expr.c line 4577)
#2847 0x328aa in expand_expr_stmt (exp=(tree) 0x21c21c) (stmt.c line 1227)
#2848 0x19d8a in c_expand_expr_stmt (expr=(tree) 0x21c21c) (c-common.c line 300)
#2849 0x50a2 in yyparse () (c-parse.y line 1303)
#2850 0x1c5d6 in compile_file (name=(char *) 0x3fffa9c "/usr/tmp/cc029189.i")  
(toplev.c line 1638)
#2851 0x1e888 in main (argc=7, argv=(char **) 0x3fffa2c, envp=(char **)  
0x3fffa4c) (toplev.c line 3055)

File is:
int a,b, c;

test()
{
        a = 1;
        b = 2;
        c = a;
        b = c;
}

Debugging output from my code is:
Debug: Leg addr: Mode is QI. Addr is

(symbol_ref:HI ("a"))
Accepted

(this is what is passed to GO_IF_LEGITIMATE_ADDRESS)
--
		Michael Gersten		michael@stb.info.com
HELLO! I'm a signature virus! Join in the fun and copy me into yours!
ex:.-1,. w $HOME/.signature
Technical Details
Message-ID: <m0mXDsf-0005QwC@stb.info.com>
Path: arc1-ca.pugleaf.net!sparky!uunet!convex!linac!pacific.mps.ohio-state.edu!cis.ohio-state.edu!stb.INfo.COM!michael

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 11318c,2ec4f512654ac078,start
X-Google-Attributes: gid11318c,public
X-Google-ArrivalTime: 1992-09-22 04:56:22 PST
Newsgroups: gnu.gcc.help
Path: arc1-ca.pugleaf.net!sparky!uunet!convex!linac!pacific.mps.ohio-state.edu!cis.ohio-state.edu!stb.INfo.COM!michael
From: michael@stb.INfo.COM (Michael Gersten)
Subject: Problem with emit_move_insn in 2.2.2
Message-ID: <m0mXDsf-0005QwC@stb.info.com>
Sender: daemon@cis.ohio-state.edu
Organization: GNUs Not Usenet
Distribution: gnu
Date: Tue, 22 Sep 1992 17:18:00 GMT
Lines: 65