runtime: minor code style improvements (followup to change 9778049)

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/9693044
This commit is contained in:
Dmitriy Vyukov 2013-06-02 01:45:26 +04:00
parent b40d98562f
commit 83d4cd758c
2 changed files with 2 additions and 2 deletions

View file

@ -520,7 +520,7 @@ runtime·persistentalloc(uintptr size, uintptr align)
{
byte *p;
if(align) {
if(align != 0) {
if(align&(align-1))
runtime·throw("persistentalloc: align is now a power of 2");
if(align > PageSize)

View file

@ -563,7 +563,7 @@ runtime·symtabinit(void)
// Initialize tables.
// Memory obtained from runtime·persistentalloc() is not scanned by GC,
// this is fine because all pointers either point into sections of the executable
// or also obtained from persistentmalloc().
// or also obtained from persistentalloc().
func = runtime·persistentalloc((nfunc+1)*sizeof func[0], 0);
func[nfunc].entry = (uint64)etext;
fname = runtime·persistentalloc(nfname*sizeof fname[0], 0);