Jump to content

PIB: Difference between revisions

From EDM2
Ak120 (talk | contribs)
mNo edit summary
Ak120 (talk | contribs)
mNo edit summary
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
== PIB ==
Process Information Block.
Process Information Block.  


=== Type ===  
== Type ==
  [[ULONG]]  pib_ulpid
  [[ULONG]]  pib_ulpid
  ULONG  pib_ulppid
  ULONG  pib_ulppid
Line 11: Line 10:
  ULONG  pib_ultype
  ULONG  pib_ultype


==== C Declaration Method ====
=== C Declaration Method ===
typedef struct
typedef struct


=== Fields ===
== Fields ==
;pib_ulpid:Process identifier.
;pib_ulpid:Process identifier.
;pib_ulppid:Parent process identifier.  
;pib_ulppid:Parent process identifier.  
Line 20: Line 19:
;pib_pchcmd:Command line pointer.
;pib_pchcmd:Command line pointer.
:This is the address of the ASCIIZ argument strings passed to the program. This string represents command parameters.
:This is the address of the ASCIIZ argument strings passed to the program. This string represents command parameters.
:The convention used by CMD.EXE is that the first of these strings is the program name (as entered from the command prompt or found in a batch file), and the second string consists of the parameters for the program. The second ASCIIZ string is followed by an additional byte of zeros. A value of zero for the address of pib_pchcmd means that no arguments are to be passed to the program.  
:The convention used by CMD.EXE is that the first of these strings is the program name (as entered from the command prompt or found in a batch file), and the second string consists of the parameters for the program. The second ASCIIZ string is followed by an additional byte of zeros. A value of zero for the address of pib_pchcmd means that no arguments are to be passed to the program.
;pib_pchenv:Environment pointer.
;pib_pchenv:Environment pointer.
:These strings represent environment variables and their current values. An environment string has the following form:
:These strings represent environment variables and their current values. An environment string has the following form:
Line 29: Line 28:
;pib_ultype:Process' type code.
;pib_ultype:Process' type code.
:The following process' type codes are available:
:The following process' type codes are available:
::0   Full screen protect-mode session  
::0 Full screen protect-mode session  
::1   Requires real mode. Dos emulation.  
::1 Requires real mode. Dos emulation.  
::2   VIO windowable protect-mode session  
::2 VIO windowable protect-mode session  
::3   Presentation Manager protect-mode session
::3 Presentation Manager protect-mode session
::4   Detached protect-mode process.
::4 Detached protect-mode process.


=== Comment ===
=== Comment ===

Latest revision as of 00:24, 9 February 2020

Process Information Block.

Type

ULONG  pib_ulpid
ULONG  pib_ulppid
ULONG  pib_hmte
PCHAR  pib_pchcmd
PCHAR  pib_pchenv
ULONG  pib_flstatus
ULONG  pib_ultype

C Declaration Method

typedef struct

Fields

pib_ulpid
Process identifier.
pib_ulppid
Parent process identifier.
pib_hmte
Module handle of executable program.
pib_pchcmd
Command line pointer.
This is the address of the ASCIIZ argument strings passed to the program. This string represents command parameters.
The convention used by CMD.EXE is that the first of these strings is the program name (as entered from the command prompt or found in a batch file), and the second string consists of the parameters for the program. The second ASCIIZ string is followed by an additional byte of zeros. A value of zero for the address of pib_pchcmd means that no arguments are to be passed to the program.
pib_pchenv
Environment pointer.
These strings represent environment variables and their current values. An environment string has the following form:
variable=value
The last ASCIIZ environment string must be followed by an additional byte of zeros.
pib_flstatus
Process' status bits.
A value of 1 in this bit flag indicates that the current process is in exit list processing.
pib_ultype
Process' type code.
The following process' type codes are available:
0 Full screen protect-mode session
1 Requires real mode. Dos emulation.
2 VIO windowable protect-mode session
3 Presentation Manager protect-mode session
4 Detached protect-mode process.

Comment

An application that has been loaded into memory and prepared for execution is called a process. A process is the code, data, and other resources of an application, such as file handles, semaphores, pipes, queues, and so on. The operating system considers every application it loads to be a process.

Information about a process is kept in a read/write area of the process address space, called the Process Information Block.