BYU would not have had the ball at the 1 yard line if a penalty were called. They'd have gotten 15 yards for PI - so at the 35, or 10 yards for holding - so at the 40.
It's rare that they call a PI to end a game in a free-for-all Hail Mary pass - but I believe they still should. Haven't watched that last play enough to have an opinion on it specifically.