[opaque pointer types] Add an explicit pointee type to alias records in the IR
Since aliases actually use and verify their explicit type already, no further invalid testing is required here. The invalid.test:ALIAS-TYPE-MISMATCH case catches errors due to emitting a non-pointee type in the new format or a non-pointer type in the old format. llvm-svn: 247952
This commit is contained in:
@@ -756,7 +756,8 @@ static uint64_t WriteModuleInfo(const Module *M, const ValueEnumerator &VE,
|
||||
// Emit the alias information.
|
||||
for (const GlobalAlias &A : M->aliases()) {
|
||||
// ALIAS: [alias type, aliasee val#, linkage, visibility]
|
||||
Vals.push_back(VE.getTypeID(A.getType()));
|
||||
Vals.push_back(VE.getTypeID(A.getValueType()));
|
||||
Vals.push_back(A.getType()->getAddressSpace());
|
||||
Vals.push_back(VE.getValueID(A.getAliasee()));
|
||||
Vals.push_back(getEncodedLinkage(A));
|
||||
Vals.push_back(getEncodedVisibility(A));
|
||||
|
||||
Reference in New Issue
Block a user