<div>I am compiling something without standard libraries, including no libc.</div><div><br></div><div>Somehow, this bitcode is being generated by plain array manipulation code:</div><div><div><br></div><div>  %12 = add i8 %11, -19</div>
<div>  %tmp35 = icmp sgt i32 %9, 1</div></div><div>  %smax36 = select i1 %tmp35, i32 %9, i32 1</div><div>  call void @llvm.memset.p0i8.i32(i8* getelementptr inbounds ([100 x i8]* @global_array_char, i32 0, i32 0), i8 %12, i32 %smax36, i32 1, i1 false)</div>
<div><br></div><div>(global_array_char is an array of length 100, which only partially gets used.)</div><div><br></div><div>This gets lowered by LLC to a library call to memset(), which cannot be satisfied.</div><div><br>
</div><div>Any advice?</div><div><br></div><div>Thanks,</div><div>David Meyer</div><div><br></div>