So much nonsense being written here and in other forums. The situation is like this:
On a PS4 developer unit, you have 8G of ram divided into (numbers heavily rounded):
1G os
1.5G debug software
1G debug scratchpad
4.5G game (or 5.5G if using the debug scratchpad)
On a PS4 end user unit, you have:
1G os
5.5G game
1.5G unclear space (now os scratchpad space?) as there very likely isn't any debug software loaded
So on a PS4 end user unit, the ram limit is >= 5.5G for the game