Genesis 46 enumerates the family members of Jacob that went down to Egypt with him. Among these descendants are Judah's grandsons by his son Perez: Hezron and Hamul. The peculiarity of this circumstance is demonstrated by a consideration of the following events;
Judah goes down from his brothers after Joseph's sell and marries. He fathers Er, Onan and Shelah. Er marries Tamar is killed for unspecified wickedness. Onan marries her afterwards is killed by God for refusing to impregnate her. Judah delays to give her his third son, so Tamar pretends to be prostitute and tricks Judah into getting her pregnant with Perez and Zerah. Perez presumably grows up and has his two sons before the family heads off to Egypt.
The issue with this narrative is fact that, based on several times markers, it must've all taken place in 22 years.¹ This has caused some to suggest that Er and Onan were extremely young when they married, resulting in the absurdity of Divine intervention to kill children for sin(I may be misunderstanding, but Chizkuni, when commenting on Genesis 38:1, appears to say that the Seder Olam proposes this).
Why is such a proposal necessary when Genesis 46:27 adds Joseph's sons, who were in Egypt years before Jacob made the trip down there, to the number of those who "went to Egypt?" Why can't Hezron and Hamul have been born in Egypt sometime later?
¹ Joseph was 17 when he was sold & 39(= 30 at his elevation to Vizier + 7 years of plenty + 2 years of Famine before his family arrived) when his family arrived in Egypt.