[PATCH] D28212: typeinfo: provide a partial implementation for Win32
Saleem Abdulrasool via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sun Jan 1 14:53:20 PST 2017
compnerd created this revision.
compnerd added reviewers: EricWF, mclow.lists, majnemer, rnk.
compnerd added subscribers: smeenai, kastiglione, cfe-commits.
compnerd set the repository for this revision to rL LLVM.
The RTTI structure is different on Windows when building under MS ABI.
Update the definition to reflect this. The structure itself contains an
area for caching the undecorated name (which is 0-initialized). The
decorated name has a bitfield followed by the linkage name. When
std::type_info::name is invoked for the first time, the runtime should
undecorate the name, cache it, and return the undecorated name. This
requires access to an implementation of `__unDName`. For now, return
the raw name.
This uses the fnv-1a hash to hash the name of the RTTI. We could use an alternate hash (murmur? city?), but, this was the quickest to throw together.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 3006 bytes
Desc: not available
More information about the cfe-commits