[cfe-dev] [RFC] Fix Clang test case failure on ARM
陳韋任
chenwj at iis.sinica.edu.tw
Mon Apr 30 09:23:12 PDT 2012
Hi Eli,
> > Clang :: CodeGenCXX/virt-call-offsets.cpp
Below is the difference of x86 and arm output.
x86:
@x = global { i64, i64 } { i64 1, i64 0 }" align 8
arm:
@x = global { i32, i32 } { i32 0, i32 1 }, align 4
According to TNorthover on IRC, this could be x86 and ARM C++ ABI difference on
member function pointers (Sec. 3.2.1 in [1]), so both of them are correct. I am
not sure how to write the correct pattern for x86 and arm. The pattern below is
O.K. for x86 and arm, but I think this pattern doesn't guarantee the order (1, 0)
and (0, 1) for x86 and arm respectively, which means "{ i32 0, i32 0 }" pass, too.
// CHECK: @x = global { i{{[0-9]+}}, i{{[0-9]+}} } { i{{[0-9]+}} {{0|1}}, i{{[0-9]+}} {{1|0}} }
Any idea on how to make the pattern better? Thanks.
Regards,
chenwj
[1]
http://infocenter.arm.com/help/topic/com.arm.doc.ihi0041c/IHI0041C_cppabi.pdf
--
Wei-Ren Chen (陳韋任)
Computer Systems Lab, Institute of Information Science,
Academia Sinica, Taiwan (R.O.C.)
Tel:886-2-2788-3799 #1667
Homepage: http://people.cs.nctu.edu.tw/~chenwj
More information about the cfe-dev
mailing list