1// Copyright 2014 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// Export guts for testing. 6 7package runtime 8 9import "unsafe" 10 11var ( 12 TestingWER = &testingWER 13 OsYield = osyield 14 TimeBeginPeriodRetValue = &timeBeginPeriodRetValue 15) 16 17func NumberOfProcessors() int32 { 18 var info systeminfo 19 stdcall1(_GetSystemInfo, uintptr(unsafe.Pointer(&info))) 20 return int32(info.dwnumberofprocessors) 21} 22 23func LoadLibraryExStatus() (useEx, haveEx, haveFlags bool) { 24 return useLoadLibraryEx, _LoadLibraryExW != nil, _AddDllDirectory != nil 25} 26