Compressed Texture Upload

Does anybody know, if drivers analyse the contents of texture uploads and do certain optimizations for it?

I upload normal maps with glTexImage2D() and GL_COMPRESSED_RGBA_S3TC_DXT5_EXT as internal format, GL_RGBA/GL_UNSIGNED_BYTE as source.

Just for testing I left out the renormalization of fetched normals map texels in the fragment shader. It looks rather ugly (worse than I expected)!
I know that there are certain quality improving techniques for DXT5 compressed normalmaps if the compressor knows that the normals are re-normalized in the shader. Do drivers employ such heuristics if they “detect” normal map source data?

>>I know that there are certain quality improving techniques for DXT5 compressed normalmaps if the compressor knows that the normals are re-normalized in the shader.<<

I’ve never heard that before.

WRT DXT5 are you using the GreenAlpha of the normalmap + reconstructing the z component in the shader. That will give better quality than just renormalizing straight RGB data

Late comment, but do not expect the drivers to do a good job of compressing the texture for you. Always compress offline and upload the compressed data.