Job longs for the grave in 3:19: “the small and the great are there, and the slave is free from his master.”
Yahweh has claimed Job as His “slave” twice in chapters 1 and 2, and now Job longs for death where that relationship can be severed. He longs for the place where a “slave” is free from his “lord.”
This can be taken as pure pain or anger or nihilism, but the word for “free” is the same word used in Exodus 21 and Deuteronomy 15 in regulations specifically designed to protect Hebrew slaves. They may serve for six years, but in the seventh year, they are to be freed. Job not only longs for freedom, he longs for the seventh year, the year of Sabbath, the year of release.
As becomes more explicit as the dialog goes on, Job longs for the grave not as a nihilistic end, a plunge into the void. Rather, Job longs for the grave because he fully expects to be raised up from it. Perhaps Job is not only looking for freedom but also for maturity and a standing before his master.