metaonly module xdc.platform.ExeContext

Stock implementation of xdc.platform.IExeContext

This module is used by platforms to create execution contexts that must be returned by xdc.platform.IPlatform.getExeContext().
XDCscript usage meta-domain sourced in xdc/platform/ExeContext.xdc
var ExeContext = xdc.useModule('xdc.platform.ExeContext');
module-wide constants & types
        obj.id// unique id within the platform = String  ...
        obj.catalogName// name of catalog package = String  ...
        obj.deviceName// module name within catalog package = String  ...
        obj.revision// revision of specified device = String  ...
        obj.clockRate// clock rate in MHz of CPU on board = Float  ...
per-instance config parameters
    var params = new ExeContext.Params// Instance config-params object;
        params.board// The board-level attributes = IPlatform.Board undefined;
        params.clockRate// The clock rate in MHz of the CPU = Float undefined;
        params.id// The CPU's unique id within the platform = String undefined;
        params.revision// The revision of the CPU = String "";
per-instance creation
    var inst = ExeContext.create// Create an instance-object(IExeContext.Cpu cpu, IPlatform.Board board, params);
 
struct ExeContext.Cpu

CPU attributes necessary to create an execution context

XDCscript usage meta-domain
var obj = new ExeContext.Cpu;
 
    obj.id = String  ...
    // unique id within the platform
    obj.catalogName = String  ...
    // name of catalog package
    obj.deviceName = String  ...
    // module name within catalog package
    obj.revision = String  ...
    // revision of specified device
    obj.clockRate = Float  ...
    // clock rate in MHz of CPU on board
DETAILS
Attributes that uniquely identify the CPU responsible for executing an executable image.
Instance Config Parameters

XDCscript usage meta-domain
var params = new ExeContext.Params;
// Instance config-params object
    params.attrs = ICpuDataSheet.Instance undefined;
    // The CPU "data-sheet" attributes
    params.board = IPlatform.Board undefined;
    // The board-level attributes
    params.catalogName = String undefined;
    // The name of the package containing the module named by deviceName
    params.clockRate = Float undefined;
    // The clock rate in MHz of the CPU
    params.deviceName = String undefined;
    // The name of a CPU device within the catalog package catalogName
    params.id = String undefined;
    // The CPU's unique id within the platform
    params.memoryMap = IPlatform.Memory[string] undefined;
    // The memory map seen by executables at the time they are loaded
    params.revision = String "";
    // The revision of the CPU
config ExeContext.attrs  // instance

The CPU "data-sheet" attributes

XDCscript usage meta-domain
var params = new ExeContext.Params;
  ...
params.attrs = ICpuDataSheet.Instance undefined;
DETAILS
This "data sheet" allows one to get information about the CPU that runs the run the executable associated with this execution context.
Multi-CPU platforms provide multiple execution contexts; each context is associated with a single CPU on the platform.
READONLY
This parameter is set by the platform and is readonly for configuration scripts.
config ExeContext.board  // instance

The board-level attributes

XDCscript usage meta-domain
var params = new ExeContext.Params;
  ...
const params.board = IPlatform.Board computed value;
DETAILS
This parameter defines the static attributes of the board containing the CPU that runs the executable.
READONLY
This parameter is set by the platform and is readonly for configuration scripts.
config ExeContext.catalogName  // instance

The name of the package containing the module named by deviceName

XDCscript usage meta-domain
var params = new ExeContext.Params;
  ...
params.catalogName = String undefined;
DETAILS
This string names a package containing one or more modules that implements the xdc.platform.ICpuDataSheet interface.
READONLY
This parameter is set by the platform and is readonly for configuration scripts.
config ExeContext.clockRate  // instance

The clock rate in MHz of the CPU

XDCscript usage meta-domain
var params = new ExeContext.Params;
  ...
params.clockRate = Float undefined;
READONLY
This parameter is set by the platform and is readonly for configuration scripts.
config ExeContext.deviceName  // instance

The name of a CPU device within the catalog package catalogName

XDCscript usage meta-domain
var params = new ExeContext.Params;
  ...
params.deviceName = String undefined;
DETAILS
This string names a module in the catalog package, specified by catalogName, that represents the CPU that runs the executable; i.e., it implements the xdc.platform.ICpuDataSheet interface.
config ExeContext.id  // instance

The CPU's unique id within the platform

XDCscript usage meta-domain
var params = new ExeContext.Params;
  ...
params.id = String undefined;
DETAILS
This id is the string used to identify a specific CPU within the platform that provides this execution context.
READONLY
This parameter is set by the platform and is readonly for configuration scripts.
config ExeContext.memoryMap  // instance

The memory map seen by executables at the time they are loaded

XDCscript usage meta-domain
var params = new ExeContext.Params;
  ...
params.memoryMap = IPlatform.Memory[string] undefined;
READONLY
This parameter is set by the platform and is readonly for configuration scripts.
config ExeContext.revision  // instance

The revision of the CPU

XDCscript usage meta-domain
var params = new ExeContext.Params;
  ...
params.revision = String "";
READONLY
This parameter is set by the platform and is readonly for configuration scripts.
Instance Creation

XDCscript usage meta-domain
var params = new ExeContext.Params;
// Allocate instance config-params
params.config =   ...
// Assign individual configs
 
var inst = ExeContext.create(IExeContext.Cpu cpu, IPlatform.Board board, params);
// Create an instance-object
ARGUMENTS
cpu — an xdc.platform.IExeContext.Cpu structure that uniquely identifies a specific CPU
board — an xdc.platform.IPlatform.Board structure that uniquely identifies a specific board
DETAILS
An execution context is the "view" that an executable has of the CPU it is running on; e.g., the accessible memory map including platform specific memory or memory mapped registers.
generated on Tue, 24 Aug 2010 15:39:19 GMT