@spatel, are you OK with this fix? If Constants are given to foldExtractExtract, this Builder call:
Value *NewExt = Builder.CreateExtractElement(Shuf, CheapExtIndex);
will end up with a Constant instead of an Instruction, causing a crash on the later cast.