aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/export_windows_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/runtime/export_windows_test.go')
-rw-r--r--src/runtime/export_windows_test.go22
1 files changed, 5 insertions, 17 deletions
diff --git a/src/runtime/export_windows_test.go b/src/runtime/export_windows_test.go
index caaf2dae51..f44e24bbac 100644
--- a/src/runtime/export_windows_test.go
+++ b/src/runtime/export_windows_test.go
@@ -7,7 +7,7 @@
package runtime
import (
- "internal/runtime/sys"
+ "internal/runtime/syscall/windows"
"unsafe"
)
@@ -17,23 +17,11 @@ var (
)
func NumberOfProcessors() int32 {
- var info systeminfo
+ var info windows.SystemInfo
stdcall(_GetSystemInfo, uintptr(unsafe.Pointer(&info)))
- return int32(info.dwnumberofprocessors)
+ return int32(info.NumberOfProcessors)
}
-type ContextStub struct {
- context
-}
-
-func (c ContextStub) GetPC() uintptr {
- return c.ip()
-}
-
-func NewContextStub() *ContextStub {
- var ctx context
- ctx.set_ip(sys.GetCallerPC())
- ctx.set_sp(sys.GetCallerSP())
- ctx.set_fp(getcallerfp())
- return &ContextStub{ctx}
+func GetCallerFp() uintptr {
+ return getcallerfp()
}