Creating DSP/BIOS Objects Dynamically
2-16
2.4 Creating DSP/BIOS Objects Dynamically
For typical DSP applications, most objects should be created statically
because they are used throughout program execution. A number of default
objects are automatically defined in the configuration template. Creating
objects statically provides the following benefits:
❏
Reduced code size.
For a typical module, the XXX_create() and
XXX_delete() functions contain 50% of the code required to implement
the module. If you avoid using any calls to TSK_create() and
TSK_delete(), the underlying code for these functions is not included in
the application program. The same is true for other modules. By creating
objects statically, you can dramatically reduce the size of your application
program.
❏
Improved run-time performance.
In addition to saving code space,
avoiding dynamic creation of objects reduces the time your program
spends performing system setup.
Creating objects statically has the following limitations:
❏
Static objects are created whether or not they are needed. You may want
to create objects dynamically if they will be used only as a result of
infrequent run-time events.
❏
You cannot delete static objects at run-time using the XXX_delete
functions.
You can create many, but not all, DSP/BIOS objects by calling the function
XXX_create where XXX names a specific module. Some objects can only be
created statically. Each XXX_create function allocates memory for storing the
object’s internal state information, and returns a handle used to reference the
newly-created object when calling other functions provided by the XXX
module.
Summary of Contents for TMS320 Series
Page 1: ...TMS320 DSP BIOS v5 40 User s Guide Literature Number SPRU423G April 2009 ...
Page 16: ...xvi ...
Page 152: ...Tasks 4 48 Figure 4 12 Trace from Example 4 7 ...
Page 168: ...Semaphores 4 64 Figure 4 14 Trace Results from Example 4 11 ...
Page 202: ...5 20 ...
Page 287: ...Index 9 Index Void 1 11 W words data memory 3 15 of code 1 5 wrapper function 2 29 ...
Page 288: ...Index 10 Index ...