<div dir="ltr">BTW, I also used bitcast to cast <nxi1> to i_n and then compare it with a n-bit data with all 1s to check equivalence. But it seemed that it was still slow.<div><br></div><div>Best,</div><div>Zhi</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jan 20, 2016 at 5:18 PM, zhi chen <span dir="ltr"><<a href="mailto:zchenhn@gmail.com" target="_blank">zchenhn@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi all,<div><br></div><div>What's is the most efficient way to check if a vectorType Value a <n x i1> only contains 1s in LLVM, where n is even? I tried to extract each element and then insert an ICmpInst with low efficiency because I didn't see a reduction operation. Is there any better way?</div><div><br></div><div>Best,</div><div>Zhi</div></div>
</blockquote></div><br></div>