IMO, when looking for a CJ to buy, Id would focus on certain year ranges rather than engines. For example, there are many differences between a 76 CJ-7 with a 6 cyl and a 86 CJ-7 with a 6 cyl. While both have a 258, there are different transmissions, t cases, axle widths, frame differences, interior and option differences, etc. But MAINLY look for a rust / dent free frame and body. An engine is just a component and can be swapped out for another one in an afternoon.....but if the body and frame are rusted and falling apart, you'll battle that for years and may not win (without going broke anyway).
To answer your question, the 6 is the most common and the most liked due to the touqe at low RPMs. There are two 4 cyl engines, a GM and an AMC. Both seem under powerd, but at least the axles are geared 4.10s. The only CJ V8 is a 304 and most will tell you if you'r going with a V8, go 360 or 401. I have both the 285 (6) and the 304 and like the 6 better for overall use. ...but my 304 is 31 years old, worn out and loud.....so I'm not speaking fairly.
1975 CJ-6 1983 CJ-8
1986 CJ-7 Laredo 1986 TJ-7 Trail Jeep
2003 Inca Gold TJ Rubicon