11592Srgrimes/* Copyright 2019-2020 Free Software Foundation, Inc.
21592Srgrimes
31592Srgrimes   This program is free software; you can redistribute it and/or modify
41592Srgrimes   it under the terms of the GNU General Public License as published by
51592Srgrimes   the Free Software Foundation; either version 3 of the License, or
61592Srgrimes   (at your option) any later version.
71592Srgrimes
81592Srgrimes   This program is distributed in the hope that it will be useful,
91592Srgrimes   but WITHOUT ANY WARRANTY; without even the implied warranty of
101592Srgrimes   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
111592Srgrimes   GNU General Public License for more details.
12262136Sbrueffer
131592Srgrimes   You should have received a copy of the GNU General Public License
141592Srgrimes   along with this program.  If not, see <http://www.gnu.org/licenses/>.
151592Srgrimes
161592Srgrimes   This file is part of the gdb testsuite.
171592Srgrimes
181592Srgrimes   Test that a breakpoint placed by line number in an assembler file
191592Srgrimes   will stop at the specified line.  Previously versions of GDB have
201592Srgrimes   incorrectly invoked the prologue analysis logic and skipped
211592Srgrimes   forward.  */
221592Srgrimes
231592Srgrimes	.text
241592Srgrimes	.global main
251592Srgrimesmain:
261592Srgrimes	nop
271592Srgrimestest:
281592Srgrimes	/* The next two instructions are required to look like an
2950476Speter	   x86-64 prologue so that GDB's prologue scanner will spot
301592Srgrimes	   them and skip forward.  */
31240506Seadler	push    %rbp		/* Break here.  */
321592Srgrimes	mov	%rsp, %rbp
3379529Sru	nop			/* Incorrect.  */
341592Srgrimes	nop
351592Srgrimes	nop
361592Srgrimes