Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: PowerPC System Software /
Chapter 2 - Mixed Mode Manager / Mixed Mode Manager Reference
Constants


Routine Flags

The routineFlags field of a routine record contains a set of flags that specify informa-
tion about a routine. You can use constants to specify the desired routine flags. Currently, only 5 of the 16 bits in a routine flags word are defined. You should set all the other
bits to 0.

enum {
   kProcDescriptorIsAbsolute     = (RoutineFlagsType)0x00,
   kProcDescriptorIsRelative     = (RoutineFlagsType)0x01
};
Constant descriptions

kProcDescriptorIsAbsolute
The address of the routine's entry point specified in the procDescriptor field of a routine record is an absolute address.
kProcDescriptorIsRelative
The address of the routine's entry point specified in the procDescriptor field of a routine record is relative to the beginning of the routine descriptor. If the code is contained in a resource and its absolute location is not known until run time, you should set this flag.
enum {
   kFragmentIsPrepared           = (RoutineFlagsType)0x00,
   kFragmentNeedsPreparing       = (RoutineFlagsType)0x02
};
Constant descriptions

kFragmentIsPrepared
The fragment containing the code to be executed is already loaded into memory and prepared by the Code Fragment Manager.
kFragmentNeedsPreparing
The fragment containing the code to be executed needs to be loaded into memory and prepared by the Code Fragment Manager. If this flag is set, the kPowerPCISA and kProcDescriptorIsRelative flags should also be set.
enum {
   kUseCurrentISA                = (RoutineFlagsType)0x00,
   kUseNativeISA                 = (RoutineFlagsType)0x04
};
Constant descriptions

kUseCurrentISA
If possible, use the current instruction set architecture when executing a routine.
kUseNativeISA
Use the native instruction set architecture when executing a routine.
enum {
   kPassSelector                 = (RoutineFlagsType)0x00,
   kDontPassSelector             = (RoutineFlagsType)0x08
};
Constant descriptions

kPassSelector
Pass the routine selector to the target routine as a parameter.
kDontPassSelector
Do not pass the routine selector to the target routine as a parameter. You should not use this flag for 680x0 routines.
enum {
   kRoutineIsNotDispatchedDefaultRoutine
                                 = (RoutineFlagsType)0x00,
   kRoutineIsDispatchedDefaultRoutine
                                 = (RoutineFlagsType)0x10
};
Constant descriptions

kRoutineIsNotDispatchedDefaultRoutine
This routine is not the default routine for a set of routines that is dispatched using a routine selector.
kRoutineIsDispatchedDefaultRoutine
This routine is the default routine for a set of routines that is dispatched using a routine selector. If a set of routines is dispatched using a routine selector and the routine corresponding to a specified selector cannot be found, this default routine is called. This routine must be able to accept the same procedure information for all routines. If possible, it is passed the procedure information passed in a call to CallUniversalProc.

IMPORTANT

In general, you should use the constants kPassSelector and kRoutineIsNotDispatchedDefaultRoutine. The constants kDontPassSelector and kRoutineIsDispatchedDefaultRoutine are reserved for use with selector-based system software routines.

Previous Book Contents Book Index Next

© Apple Computer, Inc.
3 JUL 1996