diff -r 7b3bde10b118 libgo/MERGE
--- a/libgo/MERGE	Wed Feb 08 14:33:09 2012 -0800
+++ b/libgo/MERGE	Thu Feb 09 00:00:42 2012 -0800
@@ -1,4 +1,4 @@
-1107a7d3cb07
+52ba9506bd99
 
 The first line of this file holds the Mercurial revision number of the
 last merge done from the master library sources.
diff -r 7b3bde10b118 libgo/Makefile.am
--- a/libgo/Makefile.am	Wed Feb 08 14:33:09 2012 -0800
+++ b/libgo/Makefile.am	Thu Feb 09 00:00:42 2012 -0800
@@ -226,6 +226,7 @@
 	$(exp_inotify_gox) \
 	exp/norm.gox \
 	exp/proxy.gox \
+	exp/signal.gox \
 	exp/terminal.gox \
 	exp/types.gox \
 	exp/utf8string.gox
@@ -257,13 +258,11 @@
 toolexeclibgoimagedir = $(toolexeclibgodir)/image
 
 toolexeclibgoimage_DATA = \
-	image/bmp.gox \
 	image/color.gox \
 	image/draw.gox \
 	image/gif.gox \
 	image/jpeg.gox \
-	image/png.gox \
-	image/tiff.gox
+	image/png.gox
 
 toolexeclibgoindexdir = $(toolexeclibgodir)/index
 
@@ -327,8 +326,7 @@
 
 toolexeclibgoos_DATA = \
 	os/exec.gox \
-	os/user.gox \
-	os/signal.gox
+	os/user.gox
 
 toolexeclibgopathdir = $(toolexeclibgodir)/path
 
@@ -949,7 +947,6 @@
 	go/crypto/cipher/cipher.go \
 	go/crypto/cipher/ctr.go \
 	go/crypto/cipher/io.go \
-	go/crypto/cipher/ocfb.go \
 	go/crypto/cipher/ofb.go
 go_crypto_des_files = \
 	go/crypto/des/block.go \
@@ -1107,6 +1104,8 @@
 	go/exp/proxy/per_host.go \
 	go/exp/proxy/proxy.go \
 	go/exp/proxy/socks5.go
+go_exp_signal_files = \
+	go/exp/signal/signal.go
 go_exp_terminal_files = \
 	go/exp/terminal/terminal.go \
 	go/exp/terminal/util.go
@@ -1179,9 +1178,6 @@
 	go/html/template/transition.go \
 	go/html/template/url.go
 
-go_image_bmp_files = \
-	go/image/bmp/reader.go
-
 go_image_color_files = \
 	go/image/color/color.go \
 	go/image/color/ycbcr.go
@@ -1203,12 +1199,6 @@
 	go/image/png/reader.go \
 	go/image/png/writer.go
 
-go_image_tiff_files = \
-	go/image/tiff/buffer.go \
-	go/image/tiff/compress.go \
-	go/image/tiff/consts.go \
-	go/image/tiff/reader.go
-
 go_index_suffixarray_files = \
 	go/index/suffixarray/qsufsort.go \
 	go/index/suffixarray/suffixarray.go
@@ -1317,9 +1307,6 @@
 	go/os/user/user.go \
 	go/os/user/lookup_unix.go
 
-go_os_signal_files = \
-	go/os/signal/signal.go
-
 go_path_filepath_files = \
 	go/path/filepath/match.go \
 	go/path/filepath/path.go \
@@ -1673,6 +1660,7 @@
 	exp/html.lo \
 	exp/norm.lo \
 	exp/proxy.lo \
+	exp/signal.lo \
 	exp/terminal.lo \
 	exp/types.lo \
 	exp/utf8string.lo \
@@ -1693,13 +1681,11 @@
 	net/http/httptest.lo \
 	net/http/httputil.lo \
 	net/http/pprof.lo \
-	image/bmp.lo \
 	image/color.lo \
 	image/draw.lo \
 	image/gif.lo \
 	image/jpeg.lo \
 	image/png.lo \
-	image/tiff.lo \
 	index/suffixarray.lo \
 	io/ioutil.lo \
 	log/syslog.lo \
@@ -1720,7 +1706,6 @@
 	old/template.lo \
 	$(os_lib_inotify_lo) \
 	os/user.lo \
-	os/signal.lo \
 	path/filepath.lo \
 	regexp/syntax.lo \
 	net/rpc/jsonrpc.lo \
@@ -2607,6 +2592,16 @@
 	@$(CHECK)
 .PHONY: exp/proxy/check
 
+@go_include@ exp/signal.lo.dep
+exp/signal.lo.dep: $(go_exp_signal_files)
+	$(BUILDDEPS)
+exp/signal.lo: $(go_exp_signal_files)
+	$(BUILDPACKAGE)
+exp/signal/check: $(CHECK_DEPS)
+	@$(MKDIR_P) exp/signal
+	@$(CHECK)
+.PHONY: exp/signal/check
+
 @go_include@ exp/terminal.lo.dep
 exp/terminal.lo.dep: $(go_exp_terminal_files)
 	$(BUILDDEPS)
@@ -2776,16 +2771,6 @@
 	@$(CHECK)
 .PHONY: hash/fnv/check
 
-@go_include@ image/bmp.lo.dep
-image/bmp.lo.dep: $(go_image_bmp_files)
-	$(BUILDDEPS)
-image/bmp.lo: $(go_image_bmp_files)
-	$(BUILDPACKAGE)
-image/bmp/check: $(CHECK_DEPS)
-	@$(MKDIR_P) image/bmp
-	@$(CHECK)
-.PHONY: image/bmp/check
-
 @go_include@ image/color.lo.dep
 image/color.lo.dep: $(go_image_color_files)
 	$(BUILDDEPS)
@@ -2836,16 +2821,6 @@
 	@$(CHECK)
 .PHONY: image/png/check
 
-@go_include@ image/tiff.lo.dep
-image/tiff.lo.dep: $(go_image_tiff_files)
-	$(BUILDDEPS)
-image/tiff.lo: $(go_image_tiff_files)
-	$(BUILDPACKAGE)
-image/tiff/check: $(CHECK_DEPS)
-	@$(MKDIR_P) image/tiff
-	@$(CHECK)
-.PHONY: image/tiff/check
-
 @go_include@ index/suffixarray.lo.dep
 index/suffixarray.lo.dep: $(go_index_suffixarray_files)
 	$(BUILDDEPS)
@@ -3088,16 +3063,6 @@
 	@$(CHECK)
 .PHONY: os/user/check
 
-@go_include@ os/signal.lo.dep
-os/signal.lo.dep: $(go_os_signal_files)
-	$(BUILDDEPS)
-os/signal.lo: $(go_os_signal_files)
-	$(BUILDPACKAGE)
-os/signal/check: $(CHECK_DEPS)
-	@$(MKDIR_P) os/signal
-	@$(CHECK)
-.PHONY: os/signal/check
-
 @go_include@ path/filepath.lo.dep
 path/filepath.lo.dep: $(go_path_filepath_files)
 	$(BUILDDEPS)
@@ -3412,6 +3377,8 @@
 	$(BUILDGOX)
 exp/proxy.gox: exp/proxy.lo
 	$(BUILDGOX)
+exp/signal.gox: exp/signal.lo
+	$(BUILDGOX)
 exp/terminal.gox: exp/terminal.lo
 	$(BUILDGOX)
 exp/types.gox: exp/types.lo
@@ -3446,8 +3413,6 @@
 hash/fnv.gox: hash/fnv.lo
 	$(BUILDGOX)
 
-image/bmp.gox: image/bmp.lo
-	$(BUILDGOX)
 image/color.gox: image/color.lo
 	$(BUILDGOX)
 image/draw.gox: image/draw.lo
@@ -3458,8 +3423,6 @@
 	$(BUILDGOX)
 image/png.gox: image/png.lo
 	$(BUILDGOX)
-image/tiff.gox: image/tiff.lo
-	$(BUILDGOX)
 
 index/suffixarray.gox: index/suffixarray.lo
 	$(BUILDGOX)
@@ -3518,8 +3481,6 @@
 	$(BUILDGOX)
 os/user.gox: os/user.lo
 	$(BUILDGOX)
-os/signal.gox: os/signal.lo
-	$(BUILDGOX)
 
 path/filepath.gox: path/filepath.lo
 	$(BUILDGOX)
@@ -3637,6 +3598,7 @@
 	$(exp_inotify_check) \
 	exp/norm/check \
 	exp/proxy/check \
+	exp/signal/check \
 	exp/terminal/check \
 	exp/utf8string/check \
 	html/template/check \
@@ -3656,7 +3618,6 @@
 	image/draw/check \
 	image/jpeg/check \
 	image/png/check \
-	image/tiff/check \
 	index/suffixarray/check \
 	io/ioutil/check \
 	log/syslog/check \
@@ -3679,7 +3640,6 @@
 	old/template/check \
 	os/exec/check \
 	os/user/check \
-	os/signal/check \
 	path/filepath/check \
 	regexp/syntax/check \
 	sync/atomic/check \
diff -r 7b3bde10b118 libgo/runtime/malloc.h
--- a/libgo/runtime/malloc.h	Wed Feb 08 14:33:09 2012 -0800
+++ b/libgo/runtime/malloc.h	Thu Feb 09 00:00:42 2012 -0800
@@ -235,7 +235,7 @@
 };
 
 extern MStats mstats
-  __asm__ ("libgo_runtime.runtime.MemStats");
+  __asm__ ("libgo_runtime.runtime.VmemStats");
 
 
 // Size classes.  Computed and initialized by InitSizes.
diff -r 7b3bde10b118 libgo/runtime/mgc0.c
--- a/libgo/runtime/mgc0.c	Wed Feb 08 14:33:09 2012 -0800
+++ b/libgo/runtime/mgc0.c	Thu Feb 09 00:00:42 2012 -0800
@@ -1061,11 +1061,11 @@
 		runtime_gc(1);
 }
 
-void runtime_UpdateMemStats(void)
-  __asm__("libgo_runtime.runtime.UpdateMemStats");
+void runtime_ReadMemStats(MStats *)
+  __asm__("libgo_runtime.runtime.ReadMemStats");
 
 void
-runtime_UpdateMemStats(void)
+runtime_ReadMemStats(MStats *stats)
 {
 	M *m;
 
@@ -1078,6 +1078,7 @@
 	m->gcing = 1;
 	runtime_stoptheworld();
 	cachestats();
+	*stats = mstats;
 	m->gcing = 0;
 	runtime_semrelease(&gcsema);
 	runtime_starttheworld(false);
diff -r 7b3bde10b118 libgo/runtime/proc.c
--- a/libgo/runtime/proc.c	Wed Feb 08 14:33:09 2012 -0800
+++ b/libgo/runtime/proc.c	Thu Feb 09 00:00:42 2012 -0800
@@ -525,7 +525,7 @@
 	runtime_atomicstorep((void**)&runtime_allm, m);
 
 	m->id = runtime_sched.mcount++;
-	m->fastrand = 0x49f6428aUL + m->id;
+	m->fastrand = 0x49f6428aUL + m->id + runtime_cputicks();
 
 	if(m->mcache == nil)
 		m->mcache = runtime_allocmcache();
diff -r 7b3bde10b118 libgo/runtime/runtime.c
--- a/libgo/runtime/runtime.c	Wed Feb 08 14:33:09 2012 -0800
+++ b/libgo/runtime/runtime.c	Thu Feb 09 00:00:42 2012 -0800
@@ -184,6 +184,19 @@
 	return x;
 }
 
+int64
+runtime_cputicks(void)
+{
+#if defined(__386__) || defined(__x86_64__)
+  uint32 low, high;
+  asm("rdtsc" : "=a" (low), "=d" (high));
+  return (int64)(((uint64)high << 32) | (uint64)low);
+#else
+  // FIXME: implement for other processors.
+  return 0;
+#endif
+}
+
 struct funcline_go_return
 {
   String retfile;
diff -r 7b3bde10b118 libgo/runtime/runtime.h
--- a/libgo/runtime/runtime.h	Wed Feb 08 14:33:09 2012 -0800
+++ b/libgo/runtime/runtime.h	Thu Feb 09 00:00:42 2012 -0800
@@ -286,6 +286,7 @@
 void	siginit(void);
 bool	__go_sigsend(int32 sig);
 int64	runtime_nanotime(void);
+int64	runtime_cputicks(void);
 
 void	runtime_stoptheworld(void);
 void	runtime_starttheworld(bool);
