Skip to content

Commit 89d4984

Browse files
borntraegerMartin Schwidefsky
authored andcommitted
[S390] Fix checkstack for s390
With -march=z990 and later gcc can use the long displacement facility insruction lay for stack register handling. This patch adopts checkstack to catch lay in addition to ahi and aghi. Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
1 parent 4a672cf commit 89d4984

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

scripts/checkstack.pl

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,10 @@
8181
$re = qr/.*st[dw]u.*r1,-($x{1,8})\(r1\)/o;
8282
} elsif ($arch =~ /^s390x?$/) {
8383
# 11160: a7 fb ff 60 aghi %r15,-160
84-
$re = qr/.*ag?hi.*\%r15,-(([0-9]{2}|[3-9])[0-9]{2})/o;
84+
# or
85+
# 100092: e3 f0 ff c8 ff 71 lay %r15,-56(%r15)
86+
$re = qr/.*(?:lay|ag?hi).*\%r15,-(([0-9]{2}|[3-9])[0-9]{2})
87+
(?:\(\%r15\))?$/ox;
8588
} elsif ($arch =~ /^sh64$/) {
8689
#XXX: we only check for the immediate case presently,
8790
# though we will want to check for the movi/sub

0 commit comments

Comments
 (0)