Patchwork [gccgo] Add syscall.ARCH

login
register
mail settings
Submitter Ian Taylor
Date June 14, 2010, 5:26 a.m.
Message ID <mcrfx0qfalq.fsf@dhcp-172-17-9-151.mtv.corp.google.com>
Download mbox | patch
Permalink /patch/55468/
State New
Headers show

Comments

Ian Taylor - June 14, 2010, 5:26 a.m.
This patch is a quick patch to add syscall.ARCH, which is now provided
by the Go library.  Committed to gccgo branch.

Ian

Patch

diff -r 149b0703265f libgo/syscalls/syscall_linux_386.go
--- a/libgo/syscalls/syscall_linux_386.go	Sun Jun 13 22:23:02 2010 -0700
+++ b/libgo/syscalls/syscall_linux_386.go	Sun Jun 13 22:25:02 2010 -0700
@@ -6,6 +6,8 @@ 
 
 package syscall
 
+const ARCH = "386"
+
 func (r *PtraceRegs) PC() uint64 {
 	return uint64(uint32(r.Eip));
 }
diff -r 149b0703265f libgo/syscalls/syscall_linux_amd64.go
--- a/libgo/syscalls/syscall_linux_amd64.go	Sun Jun 13 22:23:02 2010 -0700
+++ b/libgo/syscalls/syscall_linux_amd64.go	Sun Jun 13 22:25:02 2010 -0700
@@ -6,6 +6,8 @@ 
 
 package syscall
 
+const ARCH = "amd64"
+
 func (r *PtraceRegs) PC() uint64 {
 	return r.Rip;
 }