alloc K * Size

This commit is contained in:
Vitor Santos Costa 2013-10-01 16:42:12 +01:00
parent 1ebd0f1a13
commit bf77381744
2 changed files with 4 additions and 1 deletions

View File

@ -3242,7 +3242,7 @@ YAP_Reset(void)
{
CACHE_REGS
int res = TRUE;
#ifndef THREADS
#if !defined(YAPOR) && !defined(THREADS)
int worker_id = 0;
#endif
BACKUP_MACHINE_REGS();

View File

@ -94,6 +94,9 @@ void Yap_init_yapor_global_local_memory(void) {
void Yap_init_yapor_stacks_memory(UInt TrailStackArea, UInt HeapStackArea, UInt GlobalLocalStackArea, int n_workers) {
long StacksArea;
HeapStackArea *= (K);
GlobalLocalStackArea *= (K);
TrailStackArea *= (K);
TrailStackArea = ADJUST_SIZE_TO_PAGE(TrailStackArea);
HeapStackArea = ADJUST_SIZE_TO_PAGE(HeapStackArea);
GlobalLocalStackArea = ADJUST_SIZE_TO_PAGE(GlobalLocalStackArea);