cms-gem-daq-project / xhal

XHAL interface library
0 stars 10 forks source link

Propagating Andrew's improvements (address table pickling) #45

Closed mexanick closed 6 years ago

mexanick commented 6 years ago

Description

Implemented loading the address table from the pickled file if exist.

Types of changes

Motivation and Context

Pickling of the previously parsed address table significantly reduce the time required by reg_interface to start

How Has This Been Tested?

Tests at eagle60 completed successfully

Screenshots (if appropriate):

Checklist:

mexanick commented 6 years ago

It is. However the reg-utils repo is not ready for use yet and I plan to make a legacy release of xhal next week and want to have this improvement included. Then we will switch to the reg-utils. Apart from changes to the reg-utils repo we will have to make certain changes to gem_ops scripts as right now it takes this repo and its version of the reg_interface to rsync with the card, that's why I want to deliver a legacy version before switching to the new repo.

mexanick commented 6 years ago

@jsturdy @bdorney @evka85 @andrewpeck I have tested the updated code at the eagle60. Curren version works well. Please find below some notes (they will be added to the documentation as well).

  1. There's no lxml python module at the CTP7, so the pickle file has to be created at the host and copied to the CTP7. Pickle files are perfectly cross-platform, I've tested and no issues found.
  2. I have updated the scripts at eagle60 to the most recent ones, which improves the speed and stability of the code (there were about 1 year old scripts there!). The new set of scripts uses GEM_PATH env variable instead of hardcoded path the library and xml/pickle files. It is pointing to the write-protected area by default. So if you need to play with different versions of lib and/or xml/pickle files you need to make a test area and point the GEM_PATH there.
mexanick commented 6 years ago

oh, I forgot to mention: pickled file is created by parseXML method if it fails to locate the gem_amc_top.pickle. This method is called when one launches the reg_interface.py script.