PA PIE : more cleanup and fix