Hi Tim, Yes. As "(1). *FirstRealElt - (FirstRealElt - M.begin())" may be overflow, this patch implements in "(2). ExpectedElt - NumElts". I think you mean this patch is OK to be committed. Committed in http://llvm.org/viewvc/llvm-project?view=revision&revision=207485. Thanks, -Hao http://reviews.llvm.org/D3500