]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gold/testsuite/split_x32.sh
Update year range in copyright notice of binutils files
[thirdparty/binutils-gdb.git] / gold / testsuite / split_x32.sh
CommitLineData
4fc1b9d4
L
1#!/bin/sh
2
3# split_x32.sh -- test -fstack-split for x32
4
250d07de 5# Copyright (C) 2014-2021 Free Software Foundation, Inc.
4fc1b9d4
L
6# Written by Ian Lance Taylor <iant@google.com>.
7# Modified by H.J. Lu <hongjiu.lu@intel.com>.
8
9# This file is part of gold.
10
11# This program is free software; you can redistribute it and/or modify
12# it under the terms of the GNU General Public License as published by
13# the Free Software Foundation; either version 3 of the License, or
14# (at your option) any later version.
15
16# This program is distributed in the hope that it will be useful,
17# but WITHOUT ANY WARRANTY; without even the implied warranty of
18# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19# GNU General Public License for more details.
20
21# You should have received a copy of the GNU General Public License
22# along with this program; if not, write to the Free Software
23# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
24# MA 02110-1301, USA.
25
26match()
27{
28 if ! egrep "$1" "$2" >/dev/null 2>&1; then
29 echo 1>&2 "could not find '$1' in $2"
30 exit 1
31 fi
32}
33
34nomatch()
35{
36 if egrep "$1" "$2" >/dev/null 2>&1; then
37 echo 1>&2 "found unexpected '$1' in $2"
38 exit 1
39 fi
40}
41
42match 'cmp.*+%fs:[^,]*,%esp' split_x32_1.stdout
53752b85 43match 'call.*__morestack>?$' split_x32_1.stdout
4fc1b9d4
L
44match 'lea.*-0x200\(%rsp\),' split_x32_1.stdout
45
46match 'stc' split_x32_2.stdout
53752b85
L
47match 'call.*__morestack_non_split>?$' split_x32_2.stdout
48nomatch 'call.*__morestack>?$' split_x32_2.stdout
f5114272 49match 'lea.*-0x100200\(%rsp\),' split_x32_2.stdout
4fc1b9d4
L
50
51match 'failed to match' split_x32_3.stdout
52
53752b85 53match 'call.*__morestack>?$' split_x32_4.stdout
4fc1b9d4
L
54
55match 'cannot mix' split_x32_r.stdout