In the service setLastInventoryCount, which updates lastInventoryCount for product facility records, it works on inventoryItemDetail changes on availableToPromiseDiff.
In parameter: InventoryItemId
So it should be updating productFacilities entertaining both productId and facilityId of same inventoryItemId.
Currently, it it unnecessary updating all the facilities inventory on a single inventory item update.
It can be major performance factor on a production system working highly on inventory updates.