# HG changeset patch # User Philipe Louchtch # Date 1403388153 -7200 # Node ID a4e5b5fb5e96372069a267686175357ed8bfa3d2 # Parent 5e2ee79f8d4acf02b0ee8e021766a6a228a14b96 Something has gone incredibly wrong, longjmp_helpers weren't included, as well as no longer being physically present on the disk; so it is rewritten. Hopefully it was exactly as it is now diff -r 5e2ee79f8d4a -r a4e5b5fb5e96 CoreController.c --- a/CoreController.c Fri May 30 19:51:48 2014 +0200 +++ b/CoreController.c Sun Jun 22 00:02:33 2014 +0200 @@ -18,7 +18,7 @@ #include #include "PR__structs__int.h" -#include "Services_Offered_by_PR/Longjmp__helpers.h" //TODO: Change path +#include "Services_Offered_by_PR/PR__longjmp_helpers.h" //TODO: Change path #include diff -r 5e2ee79f8d4a -r a4e5b5fb5e96 PR__SS.c --- a/PR__SS.c Fri May 30 19:51:48 2014 +0200 +++ b/PR__SS.c Sun Jun 22 00:02:33 2014 +0200 @@ -20,7 +20,7 @@ #include "Defines/PR_defs.h" #include "PR__structs__int.h" #include "Services_Offered_by_PR/Measurement_and_Stats/probes__int.h" -#include "Services_Offered_by_PR/Longjmp__helpers.h" +#include "Services_Offered_by_PR/PR__longjmp_helpers.h" //#define thdAttrs NULL diff -r 5e2ee79f8d4a -r a4e5b5fb5e96 PR__WL.c --- a/PR__WL.c Fri May 30 19:51:48 2014 +0200 +++ b/PR__WL.c Sun Jun 22 00:02:33 2014 +0200 @@ -15,7 +15,7 @@ #include "PR__structs__int.h" #include "Services_Offered_by_PR/Services_Language/PRServ_int.h" -#include "Services_Offered_by_PR/Longjmp__helpers.h" +#include "Services_Offered_by_PR/PR__longjmp_helpers.h" /* MEANING OF WL PI SS int diff -r 5e2ee79f8d4a -r a4e5b5fb5e96 PR__int.c --- a/PR__int.c Fri May 30 19:51:48 2014 +0200 +++ b/PR__int.c Sun Jun 22 00:02:33 2014 +0200 @@ -16,7 +16,7 @@ #include #include "PR__structs__int.h" #include "PR_defs__turn_on_and_off.h" -#include "Services_Offered_by_PR/Longjmp__helpers.h" +#include "Services_Offered_by_PR/PR__longjmp_helpers.h" //#include "Services_Offered_by_PR/Services_Language/PRServ__wrapper_library.h" //#include "Defines/PR_defs.h" #include diff -r 5e2ee79f8d4a -r a4e5b5fb5e96 Services_Offered_by_PR/PR__longjmp_helpers.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Services_Offered_by_PR/PR__longjmp_helpers.h Sun Jun 22 00:02:33 2014 +0200 @@ -0,0 +1,36 @@ +/* + * File: PR__longjmp_helpers.h + * Author: Philipe Louchtch - de Raadt + * + * Created on June 21, 2014, 11:32 PM + */ + +#ifndef PR__LONGJMP_HELPERS_H +#define PR__LONGJMP_HELPERS_H + +#include + +// Using the low 4 bits for retVal, the rest is for coreNum +// So valid retVal values are 0-15 + +#define Longjmp__decode_retVal(__toDecode, __coreNum, __retVal) \ +do { \ + __retVal = __toDecode & 15; \ + \ + /* If retVal is zero, the decoded coreNum will be 0, */ \ + /* so we need to test to prevent clobbering up coreNum */ \ + if (__retVal > 0) { \ + __coreNum = __toDecode >> 4; \ + } \ +} while(0) + +#define Longjmp__encode_retVal(__output, __coreNum, __retVal) \ +do { \ + assert(__retVal < 16 && "retVal must be smaller than 16!"); \ + __output = __coreNum << 4; \ + __output += __retVal; \ +} while(0) + + +#endif /* PR__LONGJMP_HELPERS_H */ + diff -r 5e2ee79f8d4a -r a4e5b5fb5e96 nb__PR__ML__wDKU__lib/nbproject/private/configurations.xml --- a/nb__PR__ML__wDKU__lib/nbproject/private/configurations.xml Fri May 30 19:51:48 2014 +0200 +++ b/nb__PR__ML__wDKU__lib/nbproject/private/configurations.xml Sun Jun 22 00:02:33 2014 +0200 @@ -81,6 +81,7 @@ + diff -r 5e2ee79f8d4a -r a4e5b5fb5e96 nb__PR__ML__wDKU__lib/nbproject/private/private.xml --- a/nb__PR__ML__wDKU__lib/nbproject/private/private.xml Fri May 30 19:51:48 2014 +0200 +++ b/nb__PR__ML__wDKU__lib/nbproject/private/private.xml Sun Jun 22 00:02:33 2014 +0200 @@ -9,19 +9,6 @@ - - file:/home/coolicer/Documents/Bach%20Proj/VReo_longjmp_test/library__proto-runtime/PR__SS.c - file:/home/coolicer/Documents/Bach%20Proj/VReo_longjmp_test/library__proto-runtime/PR__WL.c - file:/home/coolicer/Documents/Bach%20Proj/VReo_longjmp_test/library__proto-runtime/Services_Offered_by_PR/Services_Language/PRServ_Request_Handlers.c - file:/home/coolicer/Documents/Bach%20Proj/VReo_longjmp_test/library__proto-runtime/AnimationMaster.c - file:/home/coolicer/Documents/Bach%20Proj/VReo_longjmp_test/library__proto-runtime/CoreController.c - file:/home/coolicer/Documents/Bach%20Proj/VReo_longjmp_test/PR__include/PR__int.h - file:/home/coolicer/Documents/Bach%20Proj/VReo_longjmp_test/library__proto-runtime/Defines/MEAS__macros_to_be_moved_to_langs.h - file:/home/coolicer/Documents/Bach%20Proj/VReo_longjmp_test/library__proto-runtime/PR__PI.c - file:/home/coolicer/Documents/Bach%20Proj/VReo_longjmp_test/library__proto-runtime/PR.c - file:/home/coolicer/Documents/Bach%20Proj/VReo_longjmp_test/library__proto-runtime/PR__int.c - file:/home/coolicer/Documents/Bach%20Proj/VReo_longjmp_test/library__proto-runtime/PR__structs__int.h - file:/home/coolicer/Documents/Bach%20Proj/VReo_longjmp_test/PR__include/PR__structs__common.h - +