search for: b_vtable

Displaying 2 results from an estimated 2 matches for "b_vtable".

Did you mean: a_vtable
2016 Feb 29
0
[cfe-dev] RFC: A new ABI for virtual calls, and a change to the virtual call representation in the IR
...; } > > typedef void (A::*mfp)(); > > mfp getmfp() { > return &A::g; > } > > void callmfp(A *a, mfp m) { > (a->*m)(); > } > > In IR: > > @A_vtable = {i8*, i8*, i32, i32} {0, @A::rtti, @A::f - (@A_vtable + 16), > @A::g - (@A_vtable + 16)} > @B_vtable = {i8*, i8*, i32} {0, @B::rtti, @B::h - (@B_vtable + 16)} > @C_vtable0 = {i8*, i8*, i32, i32, i32} {0, @C::rtti, @C::f - (@C_vtable0 + > 16), @C::g - (@C_vtable0 + 16), @C::h - (@C_vtable0 + 16)} > @C_vtable1 = {i8*, i8*, i32} {-8, @C::rtti, @C::h - (@C_vtable1 + 16)} > > define void...
2016 Feb 29
10
RFC: A new ABI for virtual calls, and a change to the virtual call representation in the IR
...h(); }; void fcall(A *a) { a->f(); } void gcall(A *a) { a->g(); } typedef void (A::*mfp)(); mfp getmfp() { return &A::g; } void callmfp(A *a, mfp m) { (a->*m)(); } In IR: @A_vtable = {i8*, i8*, i32, i32} {0, @A::rtti, @A::f - (@A_vtable + 16), @A::g - (@A_vtable + 16)} @B_vtable = {i8*, i8*, i32} {0, @B::rtti, @B::h - (@B_vtable + 16)} @C_vtable0 = {i8*, i8*, i32, i32, i32} {0, @C::rtti, @C::f - (@C_vtable0 + 16), @C::g - (@C_vtable0 + 16), @C::h - (@C_vtable0 + 16)} @C_vtable1 = {i8*, i8*, i32} {-8, @C::rtti, @C::h - (@C_vtable1 + 16)} define void @fcall(%A* %a) { %slo...