An Iranian tanker has left Gibraltar after being held there since July, despite US pressure to detain it further.