You can find a lot of information regarding this on the interwebs. Simply put... the user BEHIND the camera has more to say with how good a photo will be when it comes to a quality photo from either a Samsung S8 or an iPhone X.
When I was heavily into photography (Canon 40D and a Tamron 18-250mm lens) - it shocked me how pros would grab a super cheap P&S and produce stuff that looked 500x better than the most expensive DSLR. So now, I just use my phone and work on the thing behind the device.
Both are great - what matters more is the person behind it.
To answer your question - what I've read seems to indicate that Samsung is slightly passing Apple in rendering, speed, etc... It hops back and forth a lot --- I've looked at tons of comparisons and the ball goes in both courts for a lot of the shots - but it seems like the Samsung is doing really well in low light shots. My experience in the real world (with other samsung users (not scientific at all)) - still appears like they have a ways to go for all scenarios.