How to find out which process triggered join_any in verilog
A good interactive debugging tool will let you set a breakpoint on the join_any or the statement that follows it. Then you will be able see which processes are still running. 

If you are looking for a programmatic way, one of many I can think of is pushing a unique ID on a queue and then popping the first one off the queue after the join_any will tell you which one finished first. 

int Qid[$];
fork 
  begin task1(); Qid.push_back(1); end
  begin task2(); Qid.push_back(2); end
  begin task3(); Qid.push_back(3); end
join_any
$display("task%0d finished first", Qid.pop_front() );