<div>Hi,</div><div>getMetadata(¡°dbg¡±) returns NULL for such a small program as follows:</div><div><br></div><div><br></div><div><div>int main(){</div><div><span class="Apple-tab-span" style="white-space:pre">        </span>char a[10], b[2];</div><div><span class="Apple-tab-span" style="white-space:pre">    </span>if(a[0] != 0 && a[1] != 0){</div><div><span class="Apple-tab-span" style="white-space:pre">          </span>strcpy(a, b);</div><div><span class="Apple-tab-span" style="white-space:pre">        </span>}</div><div><span class="Apple-tab-span" style="white-space:pre">    </span>return 0;</div><div>}</div></div><div><br></div><div>The compiling command is: <span style="line-height: 1.5;"> llvm-gcc --emit-llvm -g -c ./src.c</span></div><div><span style="line-height: 1.5;"><br></span></div><div><span style="line-height: 1.5;">I also tried the solutions I found through Google:</span></div><div><a href="http://stackoverflow.com/questions/14943447/llvm-line-number-of-an-instruction">http://stackoverflow.com/questions/14943447/llvm-line-number-of-an-instruction</a></div><div><a href="http://stackoverflow.com/questions/23089316/getmetadatadbg-returns-null-despite-producing-ir-with-clang-g-s-emit-llv" target="_blank" style="outline: none; cursor: pointer; color: rgb(10, 55, 97); font-family: 'lucida Grande', Verdana; line-height: 23px;">http://stack<wbr>overflow.com<wbr>/questions/2<wbr>3089316/getm<wbr>etadatadbg-r<wbr>eturns-null-<wbr>despite-prod<wbr>ucing-ir-wit<wbr>h-clang-g-s-<wbr>emit-llv</a></div><div><br></div><div>but neither of them works. </div><div><br></div><div>Does anyone have any idea about this?</div><div>Thanks,</div><div>Yongchao.</div><div></div>