Mercurial > cgi-bin > hgwebdir.cgi > VMS > VMS_Implementations > Vthread_impls > Vthread_MC_shared_impl
changeset 19:4977aea58ca0 DistibutedMalloc
Changed calls to VMS__malloc
author | Merten Sach <msach@mailbox.tu-berlin.de> |
---|---|
date | Fri, 16 Sep 2011 16:18:11 +0200 |
parents | bb2500771be8 |
children | dd40181fd8bb |
files | VPThread_Request_Handlers.c VPThread_lib.c |
diffstat | 2 files changed, 5 insertions(+), 24 deletions(-) [+] |
line diff
1.1 --- a/VPThread_Request_Handlers.c Wed Sep 07 18:08:29 2011 +0200 1.2 +++ b/VPThread_Request_Handlers.c Fri Sep 16 16:18:11 2011 +0200 1.3 @@ -184,12 +184,6 @@ 1.4 Meas_endCondSignal 1.5 } 1.6 1.7 - 1.8 - 1.9 -//============================================================================ 1.10 -// 1.11 -/* 1.12 - */ 1.13 void inline 1.14 handleMalloc(VPThdSemReq *semReq, VirtProcr *requestingPr,VPThdSemEnv *semEnv) 1.15 { void *ptr;
2.1 --- a/VPThread_lib.c Wed Sep 07 18:08:29 2011 +0200 2.2 +++ b/VPThread_lib.c Fri Sep 16 16:18:11 2011 +0200 2.3 @@ -224,7 +224,6 @@ 2.4 } 2.5 } 2.6 2.7 - 2.8 /*Frees any memory allocated by VPThread__init() then calls VMS__shutdown 2.9 */ 2.10 void 2.11 @@ -332,29 +331,17 @@ 2.12 2.13 void * 2.14 VPThread__malloc( size_t sizeToMalloc, VirtProcr *animPr ) 2.15 - { VPThdSemReq reqData; 2.16 - 2.17 - reqData.reqType = malloc_req; 2.18 - reqData.sizeToMalloc = sizeToMalloc; 2.19 - reqData.requestingPr = animPr; 2.20 - 2.21 - VMS__send_sem_request( &reqData, animPr ); 2.22 - 2.23 - return animPr->dataRetFromReq; 2.24 - } 2.25 +{ 2.26 + return VMS__malloc_in_lib(sizeToMalloc, animPr); 2.27 +} 2.28 2.29 2.30 /*Sends request to Master, which does the work of freeing 2.31 */ 2.32 void 2.33 VPThread__free( void *ptrToFree, VirtProcr *animPr ) 2.34 - { VPThdSemReq reqData; 2.35 - 2.36 - reqData.reqType = free_req; 2.37 - reqData.ptrToFree = ptrToFree; 2.38 - reqData.requestingPr = animPr; 2.39 - 2.40 - VMS__send_sem_request( &reqData, animPr ); 2.41 + { 2.42 + return VMS__free_in_lib(ptrToFree, animPr); 2.43 } 2.44 2.45