add stub routines stackalloc() and stackfree().

run oldstack on g0's stack, just like newstack does,
so that oldstack can free the old stack.

R=r
DELTA=53  (44 added, 0 deleted, 9 changed)
OCL=20404
CL=20433
This commit is contained in:
Russ Cox 2008-12-04 08:30:54 -08:00
parent c7bab46d0f
commit 79e1db2da1
5 changed files with 54 additions and 9 deletions

19
src/runtime/stack.c Normal file
View file

@ -0,0 +1,19 @@
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
#include "runtime.h"
// Stubs for stack management.
// In a separate file so they can be overridden during testing of gc.
void*
stackalloc(uint32 n)
{
return mal(n);
}
void
stackfree(void*)
{
}