public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "dave at hiauly1 dot hia dot nrc dot ca" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/34483] wo_prof_two_strs.c:56: internal compiler error: in find_new_var_of_type, at ipa-struct-reorg.c:605
Date: Thu, 07 Feb 2008 15:34:00 -0000	[thread overview]
Message-ID: <20080207153355.32766.qmail@sourceware.org> (raw)
In-Reply-To: <bug-34483-276@http.gcc.gnu.org/bugzilla/>



------- Comment #68 from dave at hiauly1 dot hia dot nrc dot ca  2008-02-07 15:33 -------
Subject: Re:  wo_prof_two_strs.c:56: internal compiler error: in
find_new_var_of_type, at ipa-struct-reorg.c:605

> I looked into assembly you send and see the following difference:
> for original malloc there is additional instruction 
> 
> stwm %r4,64(%r30)
> 
> before malloc call, while for first artificial malloc (field a, I suppose)
> there is similar instruction
> 
> stw %r3,-60(%r30)
> 
> but for the second artificial malloc there isn't. ("Copy" instructions are to
> carry results of the malloc).
> 
> As I am not familiar with hp assembler, can you please explain what is the
> meaning of this instruction? Probably my suspicion is wrong.

The above two instructions are part of the prologue for main.  Both
instructions are stores.  In non leaf functions, the prologue always
creates a frame.  In the 32-bit runtime, this is always a multiple of
64 bytes.  Depending on the details of the prologue, the creation
of a new frame may be combined with a register store.  The above stwm
instruction saves register r4 at the stack pointer address contained
in r30 (conventionally the stack pointer register) and then 64 is
added to r30.  The stw insn saves r3 at the stack pointer address
minus 60.  r3 and r4 are both caller saves registers, so they have
to be saved in the frame when used and restored in the epilogue.

Prologue and epilogue handling occurs in every function with a frame,
so it is extremely well tested.

Dave


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34483


  parent reply	other threads:[~2008-02-07 15:34 UTC|newest]

Thread overview: 57+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-15 17:21 [Bug middle-end/34483] New: " danglin at gcc dot gnu dot org
2007-12-17 15:15 ` [Bug middle-end/34483] " olga at gcc dot gnu dot org
2007-12-24  2:08 ` dave at hiauly1 dot hia dot nrc dot ca
2007-12-28 14:58 ` rsandifo at gcc dot gnu dot org
2007-12-28 19:28 ` olga at gcc dot gnu dot org
2007-12-28 19:38 ` rsandifo at nildram dot co dot uk
2007-12-28 19:54 ` dave at hiauly1 dot hia dot nrc dot ca
2007-12-29  1:25 ` dave at hiauly1 dot hia dot nrc dot ca
2007-12-29 16:20 ` hjl at lucon dot org
2007-12-30 12:19 ` olga at gcc dot gnu dot org
2007-12-30 14:54 ` pinskia at gcc dot gnu dot org
2007-12-31 19:44 ` dominiq at lps dot ens dot fr
2008-01-02 13:24 ` rsandifo at nildram dot co dot uk
2008-01-02 15:16 ` dave at hiauly1 dot hia dot nrc dot ca
2008-01-02 17:26 ` dominiq at lps dot ens dot fr
2008-01-03  2:40 ` dave at hiauly1 dot hia dot nrc dot ca
2008-01-07 14:10 ` olga at gcc dot gnu dot org
2008-01-07 20:19 ` dominiq at lps dot ens dot fr
2008-01-08 16:11 ` dave at hiauly1 dot hia dot nrc dot ca
2008-01-15 14:55 ` olga at gcc dot gnu dot org
2008-01-15 20:50 ` dominiq at lps dot ens dot fr
2008-01-16  7:13 ` dave at hiauly1 dot hia dot nrc dot ca
2008-01-20 14:35 ` olga at gcc dot gnu dot org
2008-01-20 15:29 ` dominiq at lps dot ens dot fr
2008-01-20 18:10 ` olga at gcc dot gnu dot org
2008-01-20 19:27 ` dominiq at lps dot ens dot fr
2008-01-20 21:33 ` dominiq at lps dot ens dot fr
2008-01-21 14:10 ` olga at gcc dot gnu dot org
2008-01-21 14:27 ` dominiq at lps dot ens dot fr
2008-01-21 15:18 ` dominiq at lps dot ens dot fr
2008-01-21 19:10 ` olga at il dot ibm dot com
2008-01-21 19:56 ` dominiq at lps dot ens dot fr
2008-01-21 20:41 ` olga at il dot ibm dot com
2008-01-21 20:42 ` dominiq at lps dot ens dot fr
2008-01-21 20:55 ` olga at il dot ibm dot com
2008-01-21 21:43 ` dominiq at lps dot ens dot fr
2008-01-22 21:02 ` olga at il dot ibm dot com
2008-01-22 22:12 ` olga at il dot ibm dot com
2008-01-22 23:26 ` dominiq at lps dot ens dot fr
2008-01-22 23:42 ` olga at il dot ibm dot com
2008-01-22 23:50 ` dominiq at lps dot ens dot fr
2008-01-24 13:53 ` dominiq at lps dot ens dot fr
2008-01-24 16:43 ` dave at hiauly1 dot hia dot nrc dot ca
2008-01-25  0:34 ` danglin at gcc dot gnu dot org
2008-01-25  9:14 ` olga at il dot ibm dot com
2008-01-25 19:30 ` dave at hiauly1 dot hia dot nrc dot ca
2008-01-26 22:46 ` dave at hiauly1 dot hia dot nrc dot ca
2008-01-29 10:15 ` alond at il dot ibm dot com
2008-01-30 20:14 ` dave at hiauly1 dot hia dot nrc dot ca
2008-01-31 18:53 ` alond at il dot ibm dot com
2008-01-31 22:24 ` dave at hiauly1 dot hia dot nrc dot ca
2008-01-31 22:30 ` dave at hiauly1 dot hia dot nrc dot ca
2008-02-03 14:49 ` olga at gcc dot gnu dot org
2008-02-05  2:43 ` dave at hiauly1 dot hia dot nrc dot ca
2008-02-07 10:26 ` olga at gcc dot gnu dot org
2008-02-07 15:34 ` dave at hiauly1 dot hia dot nrc dot ca [this message]
2008-11-01 20:16 ` danglin at gcc dot gnu dot org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20080207153355.32766.qmail@sourceware.org \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).