================
@@ -0,0 +1,91 @@
+// REQUIRES: lld
+
+// This test will make a type that will be compiled differently into two
+// different .dwo files in a type unit with the same type hash, but with
+// differing contents. I have discovered that the hash for the type unit is
+// simply based off of the typename and doesn't seem to differ when the 
contents
+// differ, so that will help us test foreign type units in the .debug_names
----------------
dwblaikie wrote:

Rather than the personal statement, could maybe just be explicit:

"Clang's type unit signature is based only on the mangled name of the type, 
regardless of the contents of the type"

(I can tell you that's how it works - that's how I implemented it - it is a 
violation of the DWARF spec (the spec says to use a content hash - though that 
content hash is of the semantic contents, not the syntactic content (eg: if the 
TU contained a type with a single int member, the spec-compliant hash would be 
the same whether it was the type DIE followed by the int DIE, or the other way 
around) - so it would still be the same despite some variations in layout, so 
the index entries still wouldn't be portable to all matched-hash definitions))

https://github.com/llvm/llvm-project/pull/87740
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to