ProcessorScheduler.st
changeset 16841 9e5808800de0
parent 16624 ec0aed640724
child 16842 01a2d5d91c96
--- a/ProcessorScheduler.st	Tue Sep 16 13:11:38 2014 +0200
+++ b/ProcessorScheduler.st	Fri Sep 19 13:48:17 2014 +0200
@@ -27,7 +27,7 @@
 		UserSchedulingPriority UserInterruptPriority TimingPriority
 		HighestPriority SchedulingPriority MaxNumberOfProcesses
 		InvalidProcessSignal TimeSlicingPriorityLimit TimeSliceInterval
-		EventPollingInterval'
+		EventPollingInterval MaxProcessId'
 	poolDictionaries:''
 	category:'Kernel-Processes'
 !
@@ -280,8 +280,17 @@
         'Processor [error]: no process support - running event driven' errorPrintCR
     ].
 
-    "Modified: 23.9.1996 / 14:24:50 / stefan"
-    "Modified: 10.1.1997 / 18:03:03 / cg"
+%{
+#ifndef MAX_PROCESS_ID
+# warning "MAX_PROCESS_ID not defined!"
+# define MAX_PROCESS_ID _MAX_INT
+#endif
+    @global(ProcessorScheduler:MaxProcessId) = __MKSMALLINT(MAX_PROCESS_ID);    
+%}
+
+    "Modified: / 23-09-1996 / 14:24:50 / stefan"
+    "Modified: / 10-01-1997 / 18:03:03 / cg"
+    "Modified: / 19-09-2014 / 12:47:51 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
 !ProcessorScheduler class methodsFor:'instance creation'!
@@ -462,6 +471,14 @@
     MaxNumberOfProcesses := aNumber
 !
 
+maxProcessId
+    "Return a maximum allowed value of a Process id. "
+
+    ^ MaxProcessId
+
+    "Created: / 19-09-2014 / 12:47:16 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
 processDriven
     "turn on process driven mode"
 
@@ -3502,11 +3519,11 @@
 !ProcessorScheduler class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic/ProcessorScheduler.st,v 1.293 2014-06-24 17:08:02 stefan Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/ProcessorScheduler.st,v 1.294 2014-09-19 11:48:17 vrany Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libbasic/ProcessorScheduler.st,v 1.293 2014-06-24 17:08:02 stefan Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/ProcessorScheduler.st,v 1.294 2014-09-19 11:48:17 vrany Exp $'
 ! !