optimization/743: -mpreferred-stack-boundary doesn't work in all cases on ix86

ronis@onsager.chem.mcgill.ca ronis@onsager.chem.mcgill.ca
Tue Nov 7 06:36:00 GMT 2000


>Number:         743
>Category:       optimization
>Synopsis:       -mpreferred-stack-boundary doesn't work in all cases on ix86
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Nov 07 06:36:00 PST 2000
>Closed-Date:
>Last-Modified:
>Originator:     David Ronis (for Steven Johnson)
>Release:        Current Snapshot
>Organization:
>Environment:
ix86-linux(2.2.17)-gnu(2.1.3)
>Description:
The attached code shows that code doesn't get aligned.  I've
compiled with various settings for -malign-functions
and -mpreferred-stack-boundary

This clearly isn't a release stopper, but perhaps a note
in the info page whould be in order.
>How-To-Repeat:
Compile with -malign-functions=3 -mpreferred-stack-boundary=3
-malign-jumps=3.    When I run, I get:

>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:
 >a.out
 one 1
 Abort
----gnatsweb-attachment----
Content-Type: application/octet-stream; name="stack2.c"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="stack2.c"

aW50IG9uZShpbnQgY291bnQpCnsKICAgICBkb3VibGUgZm9vYmFyOwogICAgIGlmICgoKChsb25n
KSAmZm9vYmFyKSAmIDB4N0wpKSB7CiAgICAgICAgICBwcmludGYoIm9uZSAlZFxuIiwgY291bnQp
OwogICAgICAgICAgYWJvcnQoKTsKICAgICB9CiAgICAgcmV0dXJuIDE7Cn0KCnZvaWQgYmxhaChp
bnQgZm9vKQp7CiAgICAgZG91YmxlIGZvb2JhcjsKICAgICBpZiAoKCgobG9uZykgJmZvb2Jhcikg
JiAweDdMKSkgewogICAgICAgICAgcHJpbnRmKCJibGFoXG4iKTsKICAgICAgICAgIGFib3J0KCk7
CiAgICAgfQp9CgppbnQgbWFpbih2b2lkKQp7CiAgICAgb25lKDEpOwogICAgIGJsYWgob25lKDIp
KTsKICAgICByZXR1cm4gMDsKfQoKCg==


More information about the Gcc-bugs mailing list