Browse Source

Plan 9 from Bell Labs 2009-08-20

David du Colombier 14 years ago
parent
commit
8afce39a44
3 changed files with 10 additions and 1 deletions
  1. 8 1
      sys/man/2/exec
  2. 1 0
      sys/man/2/getpid
  3. 1 0
      sys/src/cmd/file.c

+ 8 - 1
sys/man/2/exec

@@ -31,7 +31,7 @@ struct Tos {
     vlong   pcycles;        /* process cycles (kernel + user) */
     ulong   pid;            /* process id */
     ulong   clock;          /* profiling clock */
-    /* top of stack */
+    /* top of stack is here */
 };
 .PP
 .B
@@ -141,6 +141,11 @@ When the new program begins, the global pointer
 is set to the address of a structure
 that holds information
 allowing accurate time keeping and clock reading in user space.
+These data are updated by the kernel during of the life of the process,
+including across
+.IR rfork s
+and
+.IR exec s.
 If there is a user-space accessible fast clock (a processor
 cycle counter),
 .B cyclefreq
@@ -150,6 +155,8 @@ will be set to its frequency in Hz.
 counts the number of cycles 
 this process has spent in kernel mode
 (kernel and user mode).
+.B Pid
+is the current process's id.
 .B Clock
 is the user-profiling clock (see
 .IR prof (1)).

+ 1 - 0
sys/man/2/getpid

@@ -32,6 +32,7 @@ and converts it to get the id of the parent of the current process.
 .B /sys/src/libc/9sys
 .SH SEE ALSO
 .IR intro (2),
+.IR exec (2),
 .IR cons (3),
 .IR proc (3)
 .SH DIAGNOSTICS

+ 1 - 0
sys/src/cmd/file.c

@@ -639,6 +639,7 @@ Fileoffmag longofftab[] = {
 	256*1024, 0xe7a5e4a9, 0xFFFFFFFF, "venti arenas partition\n", OCTET,
 	256*1024, 0xc75e5cd1, 0xFFFFFFFF, "venti index section\n", OCTET,
 	128*1024, 0x89ae7637, 0xFFFFFFFF, "fossil write buffer\n", OCTET,
+	4,	  0x31647542, 0xFFFFFFFF, "OS X finder properties\n", OCTET,
 };
 
 int