Anastasia marked an inline comment as done.
Anastasia added inline comments.
Comment at: test/CodeGenCXX/address-space-of-this.cpp:9
+//CHECK: call void @_ZN6MyTypeC1Ei(%struct.MyType* addrspacecast
(%struct.MyType addrspace(10)* @m to %struct.MyType*), i32 123)
+MyType
rjmccall added inline comments.
Comment at: test/CodeGenCXX/address-space-of-this.cpp:9
+//CHECK: call void @_ZN6MyTypeC1Ei(%struct.MyType* addrspacecast
(%struct.MyType addrspace(10)* @m to %struct.MyType*), i32 123)
+MyType __attribute__((address_space(10))) m = 123;
Anastasia marked an inline comment as done.
Anastasia added inline comments.
Comment at: test/CodeGenCXX/address-space-of-this.cpp:9
+//CHECK: call void @_ZN6MyTypeC1Ei(%struct.MyType* addrspacecast
(%struct.MyType addrspace(10)* @m to %struct.MyType*), i32 123)
+MyType
rjmccall added inline comments.
Comment at: test/CodeGenCXX/address-space-of-this.cpp:9
+//CHECK: call void @_ZN6MyTypeC1Ei(%struct.MyType* addrspacecast
(%struct.MyType addrspace(10)* @m to %struct.MyType*), i32 123)
+MyType __attribute__((address_space(10))) m = 123;
Anastasia marked an inline comment as done.
Anastasia added inline comments.
Comment at: test/CodeGenCXX/address-space-of-this.cpp:9
+//CHECK: call void @_ZN6MyTypeC1Ei(%struct.MyType* addrspacecast
(%struct.MyType addrspace(10)* @m to %struct.MyType*), i32 123)
+MyType
rjmccall added inline comments.
Comment at: test/CodeGenCXX/address-space-of-this.cpp:9
+//CHECK: call void @_ZN6MyTypeC1Ei(%struct.MyType* addrspacecast
(%struct.MyType addrspace(10)* @m to %struct.MyType*), i32 123)
+MyType __attribute__((address_space(10))) m = 123;
This revision was automatically updated to reflect the committed changes.
Closed by commit rC357682: [PR41276] Fixed incorrect generation of addr space
cast for this in C++. (authored by stulova, committed by ).
Herald added a project: clang.
Changed prior to commit:
rjmccall accepted this revision.
rjmccall added a comment.
This revision is now accepted and ready to land.
LGTM.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D59988/new/
https://reviews.llvm.org/D59988
___
cfe-commits mailing list
Anastasia updated this revision to Diff 193281.
Anastasia added a comment.
- Use `AggValueSlot` in the constructor call generation to store/retrieve
address space of 'this'.
- Fixed detecting the address space conversion while performing qualification
conversion.
CHANGES SINCE LAST ACTION
rjmccall added inline comments.
Comment at: lib/CodeGen/CGClass.cpp:2025
+ThisPtr =
+Builder.CreatePointerBitCastOrAddrSpaceCast(This.getPointer(),
NewType);
}
brunodf wrote:
> rjmccall wrote:
> > Anastasia wrote:
> > > I am a bit unsure if
brunodf added inline comments.
Comment at: lib/CodeGen/CGClass.cpp:2025
+ThisPtr =
+Builder.CreatePointerBitCastOrAddrSpaceCast(This.getPointer(),
NewType);
}
rjmccall wrote:
> Anastasia wrote:
> > I am a bit unsure if `performAddrSpaceCast`
rjmccall added inline comments.
Comment at: lib/CodeGen/CGClass.cpp:2025
+ThisPtr =
+Builder.CreatePointerBitCastOrAddrSpaceCast(This.getPointer(),
NewType);
}
Anastasia wrote:
> I am a bit unsure if `performAddrSpaceCast` should be used, but
Anastasia marked an inline comment as done.
Anastasia added inline comments.
Comment at: lib/CodeGen/CGClass.cpp:2025
+ThisPtr =
+Builder.CreatePointerBitCastOrAddrSpaceCast(This.getPointer(),
NewType);
}
I am a bit unsure if
Anastasia created this revision.
Anastasia added reviewers: rjmccall, brunodefraine.
Herald added a subscriber: ebevhan.
The example from the bugzilla triggered two issues:
1. In qualification conversion we are creating an address space conversion for
non-pointer and non-reference type.
2. We
14 matches
Mail list logo