Maybe Your DS4 analogue stick lost by submission earlier.
I mean he is already done and need to replace with a new one.
Deceased sticks behaves like that what You described.
Check it by connecting to USB port of Your PC and open it all below:
...then try to move stick watching readings... if they are randomly inaccurate then my answer reach the point.