the solution is just to finally build I-40 to I-5. That is a terrible corridor; I have driven it far too many times.
58 is an extraneous number in any case ... before 1964, the western segment of 58 was the continuation of state route 178, and the eastern was US-466. US-466 became state route 46 west of 99, so I cannot see why 178 was switched to 58 between Bakersfield and Santa Margarita, and 466 became 46 only halfway ... I'd have called the 58 alignment from Bakersfield to Barstow CA-46 (at least, until I-40 came along) and left 178 well enough alone!