Maintain Traceability for Generated Identifiers

To verify your model, you can trace back and forth between generated identifiers and corresponding entities within the model. To maintain traceability, it is important that incremental revisions to a model have minimal impact on the identifier names that appear in generated code. There are two ways to minimally impact the identifier names:

  • Choose unique names for Simulink® objects (blocks, signals, states, and so on) as much as possible.

  • Use name mangling when conflicts cannot be avoided.

The position of the name-mangling text is specified by the placement of the $M token in the Identifier format control parameters. Mangle characters consist of alphanumeric characters that are unique to each object. For more information, see Control Name Mangling in Generated Identifiers.