perl plugin: Added debugging output to display the ithread behavior.