Chosen Solution
I’ve had this Mid 2011 27” iMac sitting for almost a year. Didn’t use it because it was quite slow. No issues as far as I know. Yesterday I’ve replaced the HDD with an SSD and suddenly the screen starts flickering with these black and white bars when booting. When booted everything seems fine. Occasionally some parts of the interface (always black/gray) areas start flickering or have grey lines in them. Did I ruin some display cable or is the GPU failing? Which would be coincidental. I’ve made video: https://media0.giphy.com/media/Vb6C360o1…
I think you have a loose connection on the LVDS cable on your logic board. A common issue is damaging the connector but pulling a bit hard on the cable when you disconnect the display assembly. You may only have to fix the catches on the side of the connector