cmake option to enable avx2 instruction support 

Creating a new pull request for enabling avx2 support in gcc and creating a C/CXX flag which can be used to statically compile avx2 instructions. 

I will delete these commits from #4200