<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><blockquote type="cite" class="">You can imagine a community the size of LLVM's having to rely on<br class="">external libraries that may have the same goals today, but different<br class="">paths tomorrow. The end result is the same: a fork for the things that<br class="">matter to us, just like we've done with the standard library.<br class=""><br class="">All in all, your library looks really nice, and it does solve an<br class="">intersection of the problems we also solve, probably in very similar<br class="">ways, but that doesn't mean source code can be shared at that level.<br class="">There are other factors at play which have nothing to do with solving<br class="">problems.<br class=""></blockquote><div class=""><br class=""></div>I agree with you. And I never thought that sharing the same source code could be something that can be done.<div class=""><div class=""><br class=""></div><div class="">But sharing ideas, implementation tricks, algorithms (I am thinking about all the probing methods available in open addressing) might be helpful. That’s were we can share ideas. Scientific computing is more and more about computing on strings (think DNA), and data structures such as graphs which are not as simple as the good old days where BLAS workloads where the only ones.</div><div class=""><br class=""></div><div class="">To be honest, I’d like to get the best of ADT and understand the rationale behind some choices. In return, I might bring you some time to test new ideas and I can try to give ideas that could also be implemented in LLVM. For me, what is time consuming is not coding, but designing APIs that are both easy to use, difficult to misuse, and don’t lock performance. Getting the 3 of them right (or as close as you can) is really hard work.</div><div class="">Just to give, you an idea, here is how my hash map works if you want to do memoization</div><div class="">=====</div><div class="">B f(A x);</div><div class=""><br class=""></div><div class="">il::Map<A, B> map{};</div><div class=""><br class=""></div><div class="">B f_memoization(A x) {</div><div class="">  // If x is in the map, i is the slot where the key, value pair is</div><div class="">  // It it is not the case, it is the place where it should be inserted</div><div class="">  // All in all, this algo, hashes x and runs the hash table only one</div><div class="">  const int i = map.search(x);</div><div class="">  if (!map.found(x)) {</div><div class="">    map.insert(x, f(x), i);</div><div class="">  }</div><div class="">  return map.value(i);</div><div class="">}</div><div class="">=====</div><div class="">Doing the same with the STL is just painful. This example by the way comes from one of Chandler Carruth’s talk.</div><div class=""><br class=""></div><div class="">What I am looking for is sharing ideas, running some benchmarks, working on pros and cons of APIs on a performance point of view, etc. It anyone think that this could be helpful, it would be great.</div><div class=""><div class=""><br class=""><div class="">
<div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">François Fayard</div></div></div></div></div></div></body></html>