Removes the MCS-PDR lock holder optimization (XCC)
[akaros.git] / kern / include / ros / procinfo.h
index 36a380c..dff1a03 100644 (file)
@@ -29,7 +29,8 @@ struct vcore {
 #endif /* ROS_KERNEL */
        uint32_t                        pcoreid;
        bool                            valid;
-       bool                            preempt_served;
+       uint32_t                        nr_preempts_sent;       /* these two differ when a preempt*/
+       uint32_t                        nr_preempts_done;       /* is in flight. */
        uint64_t                        preempt_pending;
 };
 
@@ -43,9 +44,10 @@ typedef struct procinfo {
        pid_t ppid;
        size_t max_vcores;
        uint64_t tsc_freq;
-       void* heap_bottom;
+       uint64_t timing_overhead;
+       void *heap_bottom;
        /* for traditional forks, these two need to be memcpy'd over: */
-       charargp[PROCINFO_MAX_ARGP];
+       char *argp[PROCINFO_MAX_ARGP];
        char argbuf[PROCINFO_ARGBUF_SIZE];
        /* glibc relies on stuff above this point.  if you change it, you need to
         * rebuild glibc. */
@@ -69,7 +71,8 @@ procinfo_pack_args(procinfo_t* p, char* const* argv, char* const* envp)
                return -1;
 
        int pos = 0;
-       for(int i = 0; i < nargv; i++)
+       int i;
+       for(i = 0; i < nargv; i++)
        {
                int len = strlen(argv[i])+1;
                if(pos+len > PROCINFO_ARGBUF_SIZE)
@@ -80,7 +83,7 @@ procinfo_pack_args(procinfo_t* p, char* const* argv, char* const* envp)
        }
        p->argp[nargv] = 0;
 
-       for(int i = 0; i < nenvp; i++)
+       for(i = 0; i < nenvp; i++)
        {
                int len = strlen(envp[i])+1;
                if(pos+len > PROCINFO_ARGBUF_SIZE)