================
@@ -176,9 +176,11 @@ bool CodeGenModule::TryEmitBaseDestructorAsAlias(const
CXXDestructorDecl *D) {
// requires explicit comdat support in the IL.
if (llvm::GlobalValue::isWeakForLinker(TargetLinkage))
return true;
- // Create the alias with no name.
- auto *Alias = llvm::GlobalAlias::create(AliasValueType, 0, Linkage, "",
- Aliasee, &getModule());
+
+ // Create the alias with no name, in the same address space as the aliasee.
+ auto *Alias = llvm::GlobalAlias::create(
+ AliasValueType, getDataLayout().getProgramAddressSpace(), Linkage, "",
----------------
arsenm wrote:
The implementation doesn't match the comment? Can you take the address space
from the alias instead of the datalayout
https://github.com/llvm/llvm-project/pull/236752
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits