~ubuntu-branches/ubuntu/saucy/golang/saucy

« back to all changes in this revision

Viewing changes to src/pkg/runtime/signal_linux_386.h

  • Committer: Package Import Robot
  • Author(s): Adam Conrad
  • Date: 2013-07-08 05:52:37 UTC
  • mfrom: (29.1.1 sid)
  • Revision ID: package-import@ubuntu.com-20130708055237-at01839e0hp8z3ni
Tags: 2:1.1-1ubuntu1
016-armhf-elf-header.patch: Use correct ELF header for armhf binaries.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
// Copyright 2013 The Go Authors.  All rights reserved.
 
2
// Use of this source code is governed by a BSD-style
 
3
// license that can be found in the LICENSE file.
 
4
 
 
5
#define SIG_REGS(ctxt) (*((Sigcontext*)&((Ucontext*)(ctxt))->uc_mcontext))
 
6
 
 
7
#define SIG_EAX(info, ctxt) (SIG_REGS(ctxt).eax)
 
8
#define SIG_EBX(info, ctxt) (SIG_REGS(ctxt).ebx)
 
9
#define SIG_ECX(info, ctxt) (SIG_REGS(ctxt).ecx)
 
10
#define SIG_EDX(info, ctxt) (SIG_REGS(ctxt).edx)
 
11
#define SIG_EDI(info, ctxt) (SIG_REGS(ctxt).edi)
 
12
#define SIG_ESI(info, ctxt) (SIG_REGS(ctxt).esi)
 
13
#define SIG_EBP(info, ctxt) (SIG_REGS(ctxt).ebp)
 
14
#define SIG_ESP(info, ctxt) (SIG_REGS(ctxt).esp)
 
15
#define SIG_EIP(info, ctxt) (SIG_REGS(ctxt).eip)
 
16
#define SIG_EFLAGS(info, ctxt) (SIG_REGS(ctxt).eflags)
 
17
 
 
18
#define SIG_CS(info, ctxt) (SIG_REGS(ctxt).cs)
 
19
#define SIG_FS(info, ctxt) (SIG_REGS(ctxt).fs)
 
20
#define SIG_GS(info, ctxt) (SIG_REGS(ctxt).gs)
 
21
 
 
22
#define SIG_CODE0(info, ctxt) ((info)->si_code)
 
23
#define SIG_CODE1(info, ctxt) (((uintptr*)(info))[2])
 
24