I will have done this task when you arrive
This is not a very natural statement in English. You would probably say:
I will have done this task by the time you arrive
We can break this down into two things that happen:
- The task is completed
- You arrive
What the statement is saying is that 1. will happen before 2. happens. I will complete the task, and then you will arrive. This is usually the meaning of the future perfect:
They will have eaten their dinner when we get there
- They eat dinner
- We get there
They will have painted the house in time for Christmas
- They paint the house
- Christmas time comes
In these constructions, item 1. is always completed and finished before item 2. happens.