4 Migrating from Simics 5 6 Target consoles
Simics Migration Guide  / 

5 Migrating from Simics 4.8

5.1 Introduction

This chapter describes how to port device models, components, and scripts to Simics 5 from Simics 4.8. For information about what is new in Simics 5, read the product release notes.

5.2 Running 4.8 Modules and Scripts in 5

The first step when migrating from an older version of Simics is to get all code and scripts to run using the legacy API support. You should follow the checklist from chapter 3, but you may skip the last two steps.

If there are warnings about deprecated functionality, start Simics with the -no-wdeprecated command line flag or set the sim→deprecation_level attribute to 0.

The following list shows the changes between 4.8 and 5 that may affect the migration process.

Once everything runs, Simics 5 is ready to be used instead of Simics 4.8.

5.3 Updating 4.8 Modules and Scripts to 5

Enabling old code and scripts to work with Simics 5 is the first step in the migration and all that is needed to start using the new Simics version. But it is also a good idea to start removing the use of features and API functions that have been deprecated in 4.8 and 5.

  1. Remove the -no-wdeprecated flag when running Simics, or set the sim→deprecation_level attribute to 1. Whenever deprecation warnings are encountered, use the table in chapter 8 to find out what has been deprecated in Simics 5 and what the recommended replacement is.
  2. Change the API in both C/C++ and Python modules to 5. Use the table in chapter 8 to find out what has been deprecated in Simics 5 and what the recommended replacement is.

5.4 Updating 4.8 devices to 5

Usage of the translate interface has changed compared to Simics 4.8. In particular, implementors of translate will need to handle large inquiry-type accesses. See the documentation for the translate interface for details.

Several DML 1.2 files have been removed from the standard library. Most of them are redundant and do nothing else than import another file. Devices need to update import statements accordingly:

4.8 5
import "i2c.dml" import "simics/devs/i2c.dml"
import "ieee-802-3.dml" import "simics/devs/ieee_802_3.dml"
import "interrupt.dml" import "simics/devs/interrupt.dml"
import "microwire.dml" import "simics/devs/microwire.dml"
import "mii.dml" import "simics/devs/mii.dml"
import "mips.dml" import "simics/arch/mips.dml"
import "nand-flash.dml" import "simics/devs/nand-flash.dml"
import "ppc.dml" import "simics/arch/ppc.dml"
import "recorder.dml" import "simics/simulator-iface/recorder.dml"
import "sata-interface.dml" import "simics/devs/sata-interface.dml"
import "serial-device.dml" import "simics/devs/serial-device.dml"
import "serial-peripheral-device.dml" import "simics/devs/serial-peripheral-device.dml"
import "usb.dml" import "simics/devs/usb.dml"
import "x86.dml" import "simics/arch/x86.dml"

5.5 Updating 4.8 components to 5

In Simics 5, component implementation has changed. For details about the new implementation, please refer to the Implementing Components section in the Model Builder User's Guide.

4 Migrating from Simics 5 6 Target consoles