Based on the posted pseudo code it seems that specific_loss would create the gradients for self.specifc_layer only (layer1 and previous layers are detached and no other layers are used to create output_s), while final_output might potentially use many more layers (thus also parameters).
If so, it could be easier for the model to drive final_loss down as its optimizer would potentially update many more parameters, but that’s just my guess.