remote_gdb.hh revision 5569:baeee670d4ce
16502Snate@binkert.org/*
26502Snate@binkert.org * Copyright (c) 2002-2005 The Regents of The University of Michigan
36502Snate@binkert.org * All rights reserved.
46502Snate@binkert.org *
56502Snate@binkert.org * Redistribution and use in source and binary forms, with or without
66502Snate@binkert.org * modification, are permitted provided that the following conditions are
76502Snate@binkert.org * met: redistributions of source code must retain the above copyright
86502Snate@binkert.org * notice, this list of conditions and the following disclaimer;
96502Snate@binkert.org * redistributions in binary form must reproduce the above copyright
106502Snate@binkert.org * notice, this list of conditions and the following disclaimer in the
116502Snate@binkert.org * documentation and/or other materials provided with the distribution;
126502Snate@binkert.org * neither the name of the copyright holders nor the names of its
136502Snate@binkert.org * contributors may be used to endorse or promote products derived from
146502Snate@binkert.org * this software without specific prior written permission.
156502Snate@binkert.org *
166502Snate@binkert.org * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
176502Snate@binkert.org * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
186502Snate@binkert.org * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
196502Snate@binkert.org * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
206502Snate@binkert.org * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
216502Snate@binkert.org * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
226502Snate@binkert.org * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
236502Snate@binkert.org * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
246502Snate@binkert.org * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
256502Snate@binkert.org * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
266502Snate@binkert.org * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2712563Sgabeblack@google.com *
2812563Sgabeblack@google.com * Authors: Nathan Binkert
2913712Sandreas.sandberg@arm.com */
3013712Sandreas.sandberg@arm.com
3113712Sandreas.sandberg@arm.com#ifndef __ARCH_ALPHA_REMOTE_GDB_HH__
3213712Sandreas.sandberg@arm.com#define __ARCH_ALPHA_REMOTE_GDB_HH__
3313712Sandreas.sandberg@arm.com
346502Snate@binkert.org#include <map>
356502Snate@binkert.org
366502Snate@binkert.org#include "arch/alpha/types.hh"
376502Snate@binkert.org#include "arch/alpha/kgdb.h"
386502Snate@binkert.org#include "base/remote_gdb.hh"
396502Snate@binkert.org#include "cpu/pc_event.hh"
406502Snate@binkert.org#include "base/pollevent.hh"
416502Snate@binkert.org#include "base/socket.hh"
426502Snate@binkert.org
436502Snate@binkert.orgclass System;
446502Snate@binkert.orgclass ThreadContext;
456502Snate@binkert.orgclass PhysicalMemory;
466502Snate@binkert.org
476502Snate@binkert.orgnamespace AlphaISA {
486502Snate@binkert.org
496502Snate@binkert.orgclass RemoteGDB : public BaseRemoteGDB
506502Snate@binkert.org{
516502Snate@binkert.org  protected:
526502Snate@binkert.org    Addr notTakenBkpt;
536502Snate@binkert.org    Addr takenBkpt;
546502Snate@binkert.org
556502Snate@binkert.org  protected:
566502Snate@binkert.org    void getregs();
576502Snate@binkert.org    void setregs();
586502Snate@binkert.org
596502Snate@binkert.org    void clearSingleStep();
606502Snate@binkert.org    void setSingleStep();
616502Snate@binkert.org
626502Snate@binkert.org    // Machine memory
636502Snate@binkert.org    bool acc(Addr addr, size_t len);
646999Snate@binkert.org    bool write(Addr addr, size_t size, const char *data);
656999Snate@binkert.org
666999Snate@binkert.org  public:
676502Snate@binkert.org    RemoteGDB(System *system, ThreadContext *context);
686502Snate@binkert.org};
696502Snate@binkert.org
706999Snate@binkert.org} // namespace AlphaISA
716999Snate@binkert.org
726502Snate@binkert.org#endif // __ARCH_ALPHA_REMOTE_GDB_HH__
7313712Sandreas.sandberg@arm.com