c/6348: internal error in allocate_dynamic_stack_space with STACK_SIZE_MODE non-default

Servatius.Brandt@fujitsu-siemens.com Servatius.Brandt@fujitsu-siemens.com
Thu Apr 18 03:46:00 GMT 2002


>Number:         6348
>Category:       c
>Synopsis:       internal error in allocate_dynamic_stack_space with STACK_SIZE_MODE non-default
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Apr 18 03:06:28 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Servatius.Brandt@fujitsu-siemens.com
>Release:        gcc-3.0.4
>Organization:
>Environment:
all ports providing an allocate_stack pattern with STACK_SIZE_MODE 
>Description:
There is an internal error in allocate_dynamic_stack_space()
in explow.c.  It appears when an allocate_stack pattern is provided in the machine description, so that
HAVE_allocate_stack gets #defined, and when STACK_SIZE_MODE
is different from Pmode.  Reason is that the size argument of
allocate_dynamic_stack_space() is converted to Pmode at the
beginning, so that the copy_to_mode_reg of size to a register
of mode STACK_SIZE_MODE fails.  A bug fix converting size to
STACK_SIZE_MODE and using copy_to_reg then is included. 
>How-To-Repeat:
Any port providing allocate_stack in the machine description
and using STACK_SIZE_MODE of a size different from Pmode.
>Fix:
See file attachment.
>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: application/octet-stream; name="explow.c.fix"; name="explow.c.fix"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="explow.c.fix"

KioqIGV4cGxvdy5jCVRodSBBcHIgMTggMTE6MzA6MjIgMjAwMgotLS0gZXhwbG93LmMubmV3CVRo
dSBBcHIgMTggMTE6MzE6MDUgMjAwMgoqKioqKioqKioqKioqKioKKioqIDE0MjYsMTQzMiAqKioq
CiAgCiAgICAgICAgcHJlZCA9IGluc25fZGF0YVsoaW50KSBDT0RFX0ZPUl9hbGxvY2F0ZV9zdGFj
a10ub3BlcmFuZFsxXS5wcmVkaWNhdGU7CiAgICAgICAgaWYgKHByZWQgJiYgISAoKCpwcmVkKSAo
c2l6ZSwgbW9kZSkpKQohIAlzaXplID0gY29weV90b19tb2RlX3JlZyAobW9kZSwgc2l6ZSk7CiAg
CiAgICAgICAgZW1pdF9pbnNuIChnZW5fYWxsb2NhdGVfc3RhY2sgKHRhcmdldCwgc2l6ZSkpOwog
ICAgICB9Ci0tLSAxNDI2LDE0MzIgLS0tLQogIAogICAgICAgIHByZWQgPSBpbnNuX2RhdGFbKGlu
dCkgQ09ERV9GT1JfYWxsb2NhdGVfc3RhY2tdLm9wZXJhbmRbMV0ucHJlZGljYXRlOwogICAgICAg
IGlmIChwcmVkICYmICEgKCgqcHJlZCkgKHNpemUsIG1vZGUpKSkKISAJc2l6ZSA9IGNvcHlfdG9f
cmVnIChjb252ZXJ0X3RvX21vZGUgKG1vZGUsIHNpemUsIDEpKTsKICAKICAgICAgICBlbWl0X2lu
c24gKGdlbl9hbGxvY2F0ZV9zdGFjayAodGFyZ2V0LCBzaXplKSk7CiAgICAgIH0K



More information about the Gcc-bugs mailing list