@@ -683,7 +683,11 @@ WARN_LOGFILE = LIBABIGAIL_OUTPUT/doc/api/doxygen-warnings.txt
# directories like "/usr/src/myproject". Separate the files or directories
# with spaces.
-INPUT = LIBABIGAIL_INPUT/src LIBABIGAIL_INPUT/include/
+INPUT = LIBABIGAIL_INPUT/src \
+ LIBABIGAIL_INPUT/include \
+ LIBABIGAIL_INPUT/tests/test-read-common.cc \
+ LIBABIGAIL_INPUT/tests/test-read-common.h
+
# This tag can be used to specify the character encoding of the source files
# that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is
@@ -25,6 +25,10 @@ runtestdifffilter \
runtestreaddwarf \
runtestcanonicalizetypes.sh
+if CTF_READER
+TESTS += runtestreadctf
+endif
+
# rather cheap tests
TESTS+= \
runtestabicompat \
@@ -72,7 +76,7 @@ runtestcanonicalizetypes.output.final.txt
noinst_PROGRAMS= $(TESTS) testirwalker testdiff2 printdifftree
noinst_SCRIPTS = mockfedabipkgdiff
-noinst_LTLIBRARIES = libtestutils.la libcatch.la
+noinst_LTLIBRARIES = libtestutils.la libtestreadcommon.la libcatch.la
libtestutils_la_SOURCES= \
test-utils.h \
@@ -82,15 +86,31 @@ libtestutils_la_CXXFLAGS= \
-DABIGAIL_SRC_DIR=\"${abs_top_srcdir}\" \
-DABIGAIL_BUILD_DIR=\"${abs_top_builddir}\"
+libtestreadcommon_la_SOURCES= \
+test-read-common.h \
+test-read-common.cc
+
+libtestreadcommon_la_CXXFLAGS= \
+-DABIGAIL_SRC_DIR=\"${abs_top_srcdir}\" \
+-DABIGAIL_BUILD_DIR=\"${abs_top_builddir}\"
+
libcatch_la_SOURCES = lib/catch.cc lib/catch.hpp
runtestreadwrite_SOURCES=test-read-write.cc
runtestreadwrite_LDADD=libtestutils.la $(top_builddir)/src/libabigail.la
runtestreaddwarf_SOURCES=test-read-dwarf.cc
-runtestreaddwarf_LDADD=libtestutils.la $(top_builddir)/src/libabigail.la
+runtestreaddwarf_LDADD=libtestreadcommon.la libtestutils.la \
+ $(top_builddir)/src/libabigail.la
runtestreaddwarf_LDFLAGS=-pthread
+if CTF_READER
+runtestreadctf_SOURCES=test-read-ctf.cc
+runtestreadctf_LDADD=libtestreadcommon.la libtestutils.la \
+ $(top_builddir)/src/libabigail.la
+runtestreadctf_LDFLAGS=-pthread
+endif
+
runtestannotate_SOURCES=test-annotate.cc
runtestannotate_LDADD=libtestutils.la $(top_builddir)/src/libabigail.la
@@ -457,6 +457,31 @@ test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt \
test-diff-dwarf/PR25058-liblttng-ctl.so \
test-diff-dwarf/PR25058-liblttng-ctl2.10.so \
\
+test-read-common/test3.c \
+test-read-common/test3.so \
+test-read-common/test3-alias-1.suppr \
+test-read-common/test3-alias-2.suppr \
+test-read-common/test3-alias-3.suppr \
+test-read-common/test3-alias-4.suppr \
+test-read-common/test4.c \
+test-read-common/test4.so \
+test-read-common/PR26261/Makefile \
+test-read-common/PR26261/PR26261-obja.c \
+test-read-common/PR26261/PR26261-objb.c \
+test-read-common/PR26261/PR26261-exe \
+test-read-common/PR26261/PR26261-main.c \
+test-read-common/PR26261/PR26261-obja.h \
+test-read-common/PR26261/PR26261-objb.h \
+test-read-common/test-PR26568-1.c \
+test-read-common/test-PR26568-2.c \
+test-read-common/test-PR26568-2.o \
+test-read-common/test-PR26568-1.o \
+test-read-common/PR27700/include-dir/priv.h \
+test-read-common/PR27700/include-dir/pub.h \
+test-read-common/PR27700/pub-incdir/inc.h \
+test-read-common/PR27700/test-PR27700.c \
+test-read-common/PR27700/test-PR27700.o \
+\
test-read-dwarf/test0 \
test-read-dwarf/test0.abi \
test-read-dwarf/test0.hash.abi \
@@ -471,20 +496,12 @@ test-read-dwarf/test2-1.cc \
test-read-dwarf/test2.so \
test-read-dwarf/test2.so.abi \
test-read-dwarf/test2.so.hash.abi \
-test-read-dwarf/test3.c \
-test-read-dwarf/test3.so \
test-read-dwarf/test3.so.abi \
test-read-dwarf/test3.so.hash.abi \
test-read-dwarf/test3-alias-1.so.hash.abi \
-test-read-dwarf/test3-alias-1.suppr \
test-read-dwarf/test3-alias-2.so.hash.abi \
-test-read-dwarf/test3-alias-2.suppr \
test-read-dwarf/test3-alias-3.so.hash.abi \
-test-read-dwarf/test3-alias-3.suppr \
test-read-dwarf/test3-alias-4.so.hash.abi \
-test-read-dwarf/test3-alias-4.suppr \
-test-read-dwarf/test4.c \
-test-read-dwarf/test4.so \
test-read-dwarf/test4.so.abi \
test-read-dwarf/test4.so.hash.abi \
test-read-dwarf/test5.cc \
@@ -552,18 +569,7 @@ test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi \
test-read-dwarf/test25-bogus-binary.elf \
test-read-dwarf/test26-bogus-binary.elf \
test-read-dwarf/test27-bogus-binary.elf \
-test-read-dwarf/PR26261/Makefile \
test-read-dwarf/PR26261/PR26261-exe.abi \
-test-read-dwarf/PR26261/PR26261-obja.c \
-test-read-dwarf/PR26261/PR26261-objb.c \
-test-read-dwarf/PR26261/PR26261-exe \
-test-read-dwarf/PR26261/PR26261-main.c \
-test-read-dwarf/PR26261/PR26261-obja.h \
-test-read-dwarf/PR26261/PR26261-objb.h \
-test-read-dwarf/test-PR26568-1.c \
-test-read-dwarf/test-PR26568-2.c \
-test-read-dwarf/test-PR26568-2.o \
-test-read-dwarf/test-PR26568-1.o \
test-read-dwarf/test-PR26568-1.o.abi \
test-read-dwarf/test-PR26568-2.o.abi \
test-read-dwarf/test-libandroid.so \
@@ -572,18 +578,77 @@ test-read-dwarf/test-suppressed-alias.c \
test-read-dwarf/test-suppressed-alias.o \
test-read-dwarf/test-suppressed-alias.o.abi \
test-read-dwarf/test-suppressed-alias.suppr \
-test-read-dwarf/PR27700/include-dir/priv.h \
-test-read-dwarf/PR27700/include-dir/pub.h \
-test-read-dwarf/PR27700/pub-incdir/inc.h \
test-read-dwarf/PR27700/test-PR27700.abi \
-test-read-dwarf/PR27700/test-PR27700.c \
-test-read-dwarf/PR27700/test-PR27700.o \
test-read-dwarf/test-libaaudio.so \
test-read-dwarf/test-libaaudio.so.abi \
test-read-dwarf/PR28584/PR28584-smv.cc \
test-read-dwarf/PR28584/PR28584-smv.clang.o \
test-read-dwarf/PR28584/PR28584-smv.clang.o.abi \
\
+test-read-ctf/test0 \
+test-read-ctf/test0.abi \
+test-read-ctf/test0.c \
+test-read-ctf/test0.hash.abi \
+test-read-ctf/test1.c \
+test-read-ctf/test1.so \
+test-read-ctf/test1.so.abi \
+test-read-ctf/test1.so.hash.abi \
+test-read-ctf/test2.c \
+test-read-ctf/test2.so \
+test-read-ctf/test2.so.abi \
+test-read-ctf/test2.so.hash.abi \
+test-read-ctf/test3.so.abi \
+test-read-ctf/test3.so.hash.abi \
+test-read-ctf/test4.so.abi \
+test-read-ctf/test4.so.hash.abi \
+test-read-ctf/test5.c \
+test-read-ctf/test5.o \
+test-read-ctf/test5.o.abi \
+test-read-ctf/test6.c \
+test-read-ctf/test6.o.abi \
+test-read-ctf/test7.c \
+test-read-ctf/test7.h \
+test-read-ctf/test7.o \
+test-read-ctf/test7.o.abi \
+test-read-ctf/test8.c \
+test-read-ctf/test8.o \
+test-read-ctf/test8.o.abi \
+test-read-ctf/test9.c \
+test-read-ctf/test9.o \
+test-read-ctf/test9.o.abi \
+test-read-ctf/test-alias.c \
+test-read-ctf/test-alias.o.abi \
+test-read-ctf/test-ambiguous-struct-A.c \
+test-read-ctf/test-ambiguous-struct-A.o \
+test-read-ctf/test-ambiguous-struct-A.o.hash.abi \
+test-read-ctf/test-ambiguous-struct-B.c \
+test-read-ctf/test-ambiguous-struct-B.o \
+test-read-ctf/test-ambiguous-struct-B.o.hash.abi \
+test-read-ctf/test-conflicting-type-syms-a.c \
+test-read-ctf/test-conflicting-type-syms-a.o \
+test-read-ctf/test-conflicting-type-syms-a.o.hash.abi \
+test-read-ctf/test-conflicting-type-syms-b.c \
+test-read-ctf/test-conflicting-type-syms-b.o \
+test-read-ctf/test-conflicting-type-syms-b.o.hash.abi \
+test-read-ctf/test-dynamic-array.c \
+test-read-ctf/test-dynamic-array.o \
+test-read-ctf/test-dynamic-array.o.abi \
+test-read-ctf/test-enum.c \
+test-read-ctf/test-enum-many.c \
+test-read-ctf/test-enum-many.o \
+test-read-ctf/test-enum-many.o.hash.abi \
+test-read-ctf/test-enum.o \
+test-read-ctf/test-enum.o.abi \
+test-read-ctf/test-enum-symbol.c \
+test-read-ctf/test-enum-symbol.o \
+test-read-ctf/test-enum-symbol.o.hash.abi \
+test-read-ctf/test-PR26568-1.o.abi \
+test-read-ctf/test-PR26568-2.o.abi \
+test-read-ctf/test-struct-iteration.c \
+test-read-ctf/test-struct-iteration.o.abi \
+test-read-ctf/PR27700/test-PR27700.abi \
+test-read-ctf/PR26261/PR26261-exe.abi \
+\
test-annotate/test0.abi \
test-annotate/test1.abi \
test-annotate/test2.so.abi \
@@ -16,9 +16,9 @@
<!-- foo__ -->
<elf-symbol name='foo__' type='func-type' binding='weak-binding' visibility='default-visibility' is-defined='yes'/>
</elf-function-symbols>
- <abi-instr address-size='64' path='test3.c' comp-dir-path='/home/skumari/Tasks/source_repo/dodji/libabigail/tests/data/test-read-dwarf' language='LANG_C89'>
+ <abi-instr address-size='64' path='test3.c' comp-dir-path='/home/byby/oracle/src/libabigail/tests/data/test-read-common' language='LANG_C89'>
<!-- void __foo() -->
- <function-decl name='__foo' mangled-name='__foo' filepath='/home/skumari/Tasks/source_repo/dodji/libabigail/tests/data/test-read-dwarf/test3.c' line='8' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='__foo'>
+ <function-decl name='__foo' mangled-name='__foo' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test3.c' line='23' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='__foo'>
<!-- void -->
<return type-id='type-id-1'/>
</function-decl>
@@ -6,7 +6,7 @@
<!-- cpy -->
<elf-symbol name='cpy' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
</elf-function-symbols>
- <abi-instr address-size='64' path='test4.c' comp-dir-path='/home/mark/src/tests' language='LANG_C89'>
+ <abi-instr address-size='64' path='test4.c' comp-dir-path='/home/byby/oracle/src/libabigail/tests/data/test-read-common' language='LANG_C99'>
<!-- char -->
<type-decl name='char' size-in-bits='8' id='type-id-1'/>
<!-- unsigned int -->
@@ -22,13 +22,13 @@
<!-- const char* restrict -->
<qualified-type-def type-id='type-id-6' restrict='yes' id='type-id-7'/>
<!-- char* cpy(char* restrict, const char* restrict, unsigned int) -->
- <function-decl name='cpy' mangled-name='cpy' filepath='/home/mark/src/tests/test4.c' line='2' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='cpy'>
+ <function-decl name='cpy' mangled-name='cpy' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test4.c' line='4' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='cpy'>
<!-- parameter of type 'char* restrict' -->
- <parameter type-id='type-id-4' name='s1' filepath='/home/mark/src/tests/test4.c' line='2' column='1'/>
+ <parameter type-id='type-id-4' name='s1' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test4.c' line='4' column='1'/>
<!-- parameter of type 'const char* restrict' -->
- <parameter type-id='type-id-7' name='s2' filepath='/home/mark/src/tests/test4.c' line='2' column='1'/>
+ <parameter type-id='type-id-7' name='s2' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test4.c' line='4' column='1'/>
<!-- parameter of type 'unsigned int' -->
- <parameter type-id='type-id-2' name='n' filepath='/home/mark/src/tests/test4.c' line='2' column='1'/>
+ <parameter type-id='type-id-2' name='n' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test4.c' line='4' column='1'/>
<!-- char* -->
<return type-id='type-id-3'/>
</function-decl>
similarity index 82%
rename from tests/data/test-read-dwarf/PR26261/Makefile
rename to tests/data/test-read-common/PR26261/Makefile
@@ -1,7 +1,7 @@
SRCS = PR26261-obja.c PR26261-objb.c PR26261-main.c
EXE = PR26261-exe
OBJS = $(SRCS:.c=.o)
-CFLAGS = -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?7jIve4A_klxmj&+cUgn
z4f`%N@zeNjE^OBfJzbRQ7nJ>y%AW!5CLDY{@pVn}n<vHK2=R?OBoJYbb8gp_(q40Q
Q`$tSygC6WR7Y`}^2NhnMHvj+t
literal 0
HcmV?d00001
similarity index 100%
rename from tests/data/test-read-dwarf/PR26261/PR26261-main.c
rename to tests/data/test-read-common/PR26261/PR26261-main.c
new file mode 100644
GIT binary patch
literal 4800
zcmbVPeN<G}5x)xv5@kh-fZtomF(9zOiXX*9R}olSLBy;=0xoZt2dvpIcNYb%2`WT4
zfCodV2sSZ#Y*HyotJJTUM2Qkl{XlILwN)g?ps60Q^;A4y?9AJHm-V^%Cv(p1o%!9F
zJ9FpVcjxVU$qQ4wBoe|%LS~aejiE3G49ZGDRFY5<Lewh99o5GBfhxzkK1cCmhq_m_
zaa|v=2Ue<kE0Z6qD%1KLR~+rnFV>uCqqa)Ny0a=r@mKB1UAT~{J^3yjdvR<}?x1R?
zQ|)pNPP96?OXX;HI#efjFu79QQJL1Is!YD?IM1-d=y#^=Kev3mP(mto4zAxokdS4R
z>tX9xKpp{%8y*Q947?mz4O|Fp0Hzi41rbS5AxH=c-jwO2uMg-lmkW_%GOqvwO~JV_
zg6Nc^KnDLYVKB;_xUgP4$V%WLzzM)*z$`e}zYy0S=8$GM2Vcx-s531@q#%>mQG)oG
z$3kGpX$;n35ik<&Arn{$JPa834(kYUq#(PIbT}wjA2yHcxRKNk6s#M>2w}DP#h`(d
z<qMEB2!61>Y)@Dp<^v)jtIYa*qBq$|fk|VrTQ&Al3$NicB3%K%lDWhfPmBs;oJw>>
zob?3{EgH<D1_i|?jaj=wOQ^sRBd0f!)mF}8;qx^*&R`(1MP?%(t1Z=*#+t31&cMgo
zth!i(Udw6qg`D0HQ*5!>tvqLpwevQ+EjFLCbAlKHV1A6wY&4opu^E|)>5A#`Y>dG;
za-Fa-d`d|BslfD-9l05^(v#*6AGiO&!);{o@|sDXSiH)8-b@%eQyCn&>w@1W8J{Oe
zuIH>@m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(*aTpFKbHMPm6oH9}5<fNP5V>#2Vh
zGo+)~{{-Nko*x<RbYSuE`Qf($^JmY`Q*89?rSWBS!=tFL*dNcN`0haeK>GeApyEb!
VITtb#Bv1ZvH2)5lrBe|5{~w{-$}a!_
literal 0
HcmV?d00001
similarity index 100%
rename from tests/data/test-read-dwarf/PR26261/PR26261-obja.c
rename to tests/data/test-read-common/PR26261/PR26261-obja.c
similarity index 100%
rename from tests/data/test-read-dwarf/PR26261/PR26261-obja.h
rename to tests/data/test-read-common/PR26261/PR26261-obja.h
new file mode 100644
GIT binary patch
literal 3592
zcmbtXeQZ-z6u+<A%3xb92t&rm3P||uCuA@QTBwd0V2+PrOh&rb?yW1ducdt*9by;^
zKLEi+l(>MA2q6+thcFrPRYEW#F``JAN+L0W8jVpy0)#*GocGS{9&a@ydb0b@Ilp^;
z=bm@JUbp^<h1DiOU|a<DDC_q)%GgVV{kB&%y{wdtVD&Yduh(pT?sn&jvwwY`Z{k5(
z2=^Gv2NN4+!PX7!O|oZ#rXkH>qNpw;D@7xZ8g-g6k1b1K794a4G>|FSSEibpJr!)=
zmpug9q2X#iH`rci1<+<dYlnvUsTOtI!Qkt}G6<d4Sh$IWWra1%{<xCxD{XPfFZvC>
z2Y{t>S=7y<9u}R>np3hr7Fa1VXG<(9IRkBhHfJm$1|yO)nFu-~;eZ$jhs1Eio{A@x
zgd|3tij-86&L&Y2Rnrb&lRX%VMq{$GZi%PTQ|ac~j;S3%wN{!)c8V(JetP$J=Q5eh
zXPHmWu>BjnJB5<?_(NUZ{JjO8jUN>Zi=6UqEU0yLAMS3x@w#`JyJOkv{Mnuw*P+DC
z_9NHJJl%&oF1v4(x#NYuZW!*mQ8qokWfSW%74L4WDy>#_jr!>~_G-g9Z`ES!)^Na_
zmn^R_vwdfa6~3^nYd}2{wx6+V^jdwhXTN{2a$K+QP1?4rrMGSQ!mp>E{_)C%%z;Jz
zZ<kpvx|(nOuw&^uYutXMVMoKFp%=%$(Q$0si<>{VzPx(n`d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se90Yu}#pQYy3%c)u)M%<Kx*kj-LVy$LDo|sY)x2zlj5+d97Tx
z1FrIUVjho0fvnL~_Q}IIzY}^?el|ig))0TH0p~of@%J6K^`UPQUyq?}j6DDtP8BUT
zhN$um@s0Ds>*sN2z`&eFejo8?@j%i>{t3V_)Jy$b?V<JK`vli-C^XLJc&@QAhm}5R
qedvJT?-Jx1`S{O<@$LYK{Y?B(=;*{ae^^s4elOL3LB~bY$o~g0^_1oS
literal 0
HcmV?d00001
similarity index 100%
rename from tests/data/test-read-dwarf/PR26261/PR26261-objb.c
rename to tests/data/test-read-common/PR26261/PR26261-objb.c
similarity index 100%
rename from tests/data/test-read-dwarf/PR26261/PR26261-objb.h
rename to tests/data/test-read-common/PR26261/PR26261-objb.h
new file mode 100644
GIT binary patch
literal 3560
zcmbtWeQZ-z6u+<C%Eq>C@-gOMu7G?D=+}@jQM9fyP(GaC*rGuD+P-#$_H}uE9UTc_
zjE{_unZ*z@lNkw2jS30F5QP}2Q3)u7M2swfz(V{W@ehHR2x!!EUeDd?TZxID?Dm}V
zyXSY#dH3CW-?lATQEw0g#zkOHu@R4>jJ4#A*e=a<u~IgXH7?up!?HbF@Aj<!{Lb|p
z0}pa?gLDpP9GC^iF&M9sJsUKYG=YhtxkkoH(EzOt<fBlK34II1jzth)jD_47j$+1U
ziZzqX$pu{r1F-TE(9_bm7CZxN7Yxixy=Zmw!Osx$7<AfV;Q$NED)YC93Jc1fR#ow+
z?X8l>=TX_3Iu>=ZXf+EaWKYbu(Z}p9v8ZJCwfoxbF-7!8Bzs)(+aqD0=nIF$aKxHu
zjjM_zM(wH;SL618sEV3t1u$Us$D+}gY;RayT~l4-<l2g<ZGP-WTPe^Vp##GGWZ#wZ
zsZ{E#)LEgwtl715p0RwW-uGc=-pqPoZi!U<=wMw(&h*YMQ<XO)UN}Ej9P$Q?w`+I2
zS(ek=`}oV-BR{Tlo7T4VJa4(wwS8rC@!1>RAw$07xZ}_(=W0XKyP66QjL#kDof&jE
zW^50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$VdiBQQ*F`JN&B)W4K@O+`EP&(#B0X
zl(z^U4;mrP=jW^rux#}kXw$w%e6Bd3`;8Ca-y}Z24|u$u-vATY`X8hX;UFURk6g~@
z{f7b5uPIU{(F=V6oea^(24F5*{X9JUAj!01SRc>6zJ3BQ%*p!%Q<EUo=X{Ry`doLw
zgvRHIDR7ARn>mp*599nE&ez2?;X{GUO{?Kw&g1$GnBn$t5Ez}r&&1Hy$G!&`E)~6Q
z4AG>E`1*C>{qwlbz`&e({>Q|x<$<L2{7(SKP#4W})j{u%?-P7~55eGkj%TZlIc`z?
rL3BXy{}SZt`T2n9?+$?2Svr3Yqmv=}^~0XB@q4NNuQRx4>iK^InN@{8
literal 0
HcmV?d00001
similarity index 100%
rename from tests/data/test-read-dwarf/PR27700/include-dir/priv.h
rename to tests/data/test-read-common/PR27700/include-dir/priv.h
similarity index 100%
rename from tests/data/test-read-dwarf/PR27700/include-dir/pub.h
rename to tests/data/test-read-common/PR27700/include-dir/pub.h
similarity index 100%
rename from tests/data/test-read-dwarf/PR27700/pub-incdir/inc.h
rename to tests/data/test-read-common/PR27700/pub-incdir/inc.h
similarity index 55%
rename from tests/data/test-read-dwarf/PR27700/test-PR27700.c
rename to tests/data/test-read-common/PR27700/test-PR27700.c
@@ -1,5 +1,7 @@
#include "include-dir/priv.h"
+/* gcc -I. -gctf -gdwarf -c -o test-PR27700.o test-PR27700.c */
+
void
foo(enum foo* c __attribute__((unused)))
{
new file mode 100644
GIT binary patch
literal 3552
zcmbtWeQZ-z6u)mR>!e%R7!KxUc-sVu($}sdYy%k^i~9(JkP!kTlJ&KHYa7<rrhS8s
zL?oCXm_?W17swyRKm7g!7r>984p<Nr6BYh|sL`k-A}j_>6cP-c^WHsexs;gbN$)%N
z{LcB^d+xpOp4TTI>+33#Bt{~!HkPvpWh_vV>$jWTc2>piXX|_RUh3KV#Er4dC$Ilt
zFQTAk>TqobjSWY^W<Yx$8e&b*a7yUcqdg58N+~qNE1}`Q4?wd)tAhqojIlB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ly}5Dsj6c>SkOsupHam4dJE3(&t`7V7x1UKoxcybpYL#du@L_)w_64L
zH*U8H_)Tv2a4qI3a~#hk|6G`o9*G-j5VVo9bd-9AmNA%u-xa0=(`lw)c~Mf@kg9~W
z;BaIhrVl0{!0fBRU`pG1hg(gldPD<W9%U$|Yea#0sEhD`Y2$Yb>K#+`grO;L^*w1r
z4Q=6eL?2d?sRUF-V}y^ZMF$2`YFy(B{GX}@__%lU9?)>@ypz3O+{V~^sRIMC{C5Za
ztME}kME(MZ!8`h2`HO%nj)~LK{ErGw!DLH_PlW=>AbWVAZkgGq5XKt8gLS1n8)0>J
z@=GuCaqt_B5b@#TZOTe`iaDX<PY$NcsN6%0T@Nl3qk(y7l)v=e9M$XzVQej+h4O!u
zzYz3)0`o^M@hSfpV1?#?na@vk3c^ewKG|XD6q^4lKL49M5a-7lMSPln7%-fl@`SD_
zSNQx-5x_O=AL*Tdn|vCW$0hj-Im&HP6h{0p;!^<Ew>bY10Vf{m{hTj^u?4s(1%!Cy
zdJ8&OSNU=YW^T?G_l5GOz~j)tF-87H&TpYWu0{SazzdyU29pAzbHekhfJS`63(bwZ
uF+TqVG(hnG4su2QeSnFz10WXV_mBQ3A%-IEALdkuKgRR_!er$hBL5%iFLg!$
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,22 @@
+/*
+ * gcc -c -std=c89 -mtune=generic -march=x86-64 crti.c
+ *
+ * NOTE: linking with _old_ crti.o exposes _init and _fini as
+ * global symbols, the newer versions don't.
+ *
+ * 0000000000000000 g F .init 0000000000000000 .hidden _init
+ * 0000000000000000 g F .fini 0000000000000000 .hidden _fini
+ *
+ * So this is a dummy c-runtime object.
+ *
+ */
+
+void __attribute__((visibility("default")))
+_init(void)
+{
+}
+
+void __attribute__((visibility("default")))
+_fini(void)
+{
+}
similarity index 61%
rename from tests/data/test-read-dwarf/test-PR26568-1.c
rename to tests/data/test-read-common/test-PR26568-1.c
@@ -1,3 +1,6 @@
+/* gcc -std=c89 -gctf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FtV$hDUL5BAK1d;kCd
literal 0
HcmV?d00001
similarity index 56%
rename from tests/data/test-read-dwarf/test-PR26568-2.c
rename to tests/data/test-read-common/test-PR26568-2.c
@@ -1,3 +1,6 @@
+/* gcc -std=c89 -gctf -g -mtune=generic -march=x86-64 -c \
+ * -o test-PR26568-2.o test-PR26568-2.c */
+
union A {
struct {
int x;
new file mode 100644
GIT binary patch
literal 3048
zcmbtVZERCz6n<~-S_<1r*<g+j^@@T_*0K#Zwi&QvUo9G3AVdekcDvnfi)%O9yHQXh
z13ze{5kyRgLyRIHh6s@#AR;!H0rM+H#VGtSA^V|0gP9r_KlGg2bGFN+#zar@_MG#a
z^StN0U$@WHK3r#$B*7wyC1TuTREUF)aocB@J~2&96|4M-VSnQ3YySS)Yv&9cE&oa9
z1cyCCwn_ekd;8i?#Mqn%Xd12&A6WBwGMW4|d0yI=|CsODLU~3*b#USPM=#0+`zJZd
zmb<t1?Ru_s;gO7kd+(lg&$^-HkUdy*bp6pS^LpzYuDZNGbCjKplWR`&)l_`FY$QK_
z;}2hjn+J{we{`;GxW-qwKQTS)@mcGY0&(^2%+9esUcaS}(w9DTo$<Nlj~bV{4riRn
z8%oTsoLEzzU1hs?W6tR}*4(jYc*nWm(k}y%Q*)=u@8-=oZ9ld)M}&7|HvS&H@?zyL
z2iEm|(JOwI&p%KqK5M$NIpoeBT(;rF!hzu_{eP?+c<adC%kwK&U%0ll^Mdp6qQT1>
z;&RuL%)V43ydOok^!1I}+}s=#lFQNh=Go1+3z5A|tX&CdcHtCW(2^wGaAl*yNnn6+
zr;X+jHn1lfo>4-w-zFxG1?4Qs?%cZ9E;(~;GVnUPB5g`XL>KkTS1HxSi<IILZ;`i1
zDJd!`E{37Z)8gG)v?HuVbhWcU@r3oBh_<**ivZXHt{QD=UmPzl^OW7Mc-m6!7@d4f
z{qQ>D1M>qOZ^3tu1PTM+E|5xk`d8$x)OU`=Vk0ApO{%I3?GNRhtlKn{H9GzJ2Zu%j
zy8^pLuh%AqDh`bf)((wU><%OXyMIdTt~mLQeQ=I1HyUVY+;U0E%6BE*LcI2J)vuzy
zy1G)C2TLjVmvumI888$Wb{N1AHX$VuW0A<`{-;tv+O$GQakn%xYl3q-1ZM$`17$A$
zRJq*G+p4o2DkPx)4}$Y%h~NH77lxBb2MgKg`qq#vOpnzRmc>MqH*U%zbKEgmvdA)d
zDKiIDj;SAGjTq9knC@v<QBqb~R_-bBwun$q1YlnCB(Tl<nT;F}#IalM4ChBde1c)6
ze)7m>+(Z5h(zruo*Bb2m2*-RpQ<l|aAa35JrwF&s!#S8QQw}P)V}@AsXA_S3*#D#C
z^FA@&M>xNC#`h3jN}BQa$bXQuwXQ-q?tyt9gg3S^tgAuLdNifm+0wPRF1)R(t_p83
z78Bm6)~R}1wO~(MQ%5A!1u?@`gTbiQdsA4As*yJBW=dyAL}Ln+U=!gc!*A&d<A+0d
zBVD@Yg;(Z@>1xXp<hMn7yxq|*_`K*Fsg~B>6pE^0jn?*m)J!1bp7D9|Ts|`Rd>F@E
zv)ly^V&*%5@eux`5i9>*$icVpU-`wrHRj|8MK#+=zd)LmB~27U0N<aF6G%7HqfC;I
z?++p7=M%mdbh`RiDgFv+R?KI=0gQC~ZM0DfIFYoK{}ABm`d8?2^E<-+@!c_>`)>t|
zN`W;l#|h+j$`NaB69m%LZ=m{dB4T~~mRaj}1BP>QpI{o|qQ{E+V-~K@`bh{He4dz+
zn~9Hcvv3;o`ypuX%}HQiBK~{}&OFwy65o<09M%g>3C!dCePH0ZP&tN$llazs;r==C
z6c{+Cm0wQ$a!w>|<sSz;-T9rT^W%Gh=jVpOe8$t&#!}r>|9f;ma$z9X%EvpAZmay*
d6bS#nrM%Qy*+xADMmqkF)c;v?GT7Gr{~OR-KGpyL
literal 0
HcmV?d00001
similarity index 100%
rename from tests/data/test-read-dwarf/test3-alias-1.suppr
rename to tests/data/test-read-common/test3-alias-1.suppr
similarity index 100%
rename from tests/data/test-read-dwarf/test3-alias-2.suppr
rename to tests/data/test-read-common/test3-alias-2.suppr
similarity index 100%
rename from tests/data/test-read-dwarf/test3-alias-3.suppr
rename to tests/data/test-read-common/test3-alias-3.suppr
similarity index 100%
rename from tests/data/test-read-dwarf/test3-alias-4.suppr
rename to tests/data/test-read-common/test3-alias-4.suppr
new file mode 100644
@@ -0,0 +1,26 @@
+/*
+ * Test file for creating multiple alias for a symbol
+ *
+ * NOTE: linking with _old_ crti.o exposes _init and _fini as
+ * global symbols, the newer versions don't.
+ *
+ * 0000000000000000 g F .init 0000000000000000 .hidden _init
+ * 0000000000000000 g F .fini 0000000000000000 .hidden _fini
+ *
+ * This test is looking for those symbols which are not experted.
+ * So it's linked with dummy crti.o to avoid false positives.
+ *
+ * gcc -std=c89 -shared -gctf -g -mtune=generic -march=x86-64 -fPIC \
+ * -nostartfiles -Wl,-soname=test3.so.1 -o test3.so test3.c crti.o
+ *
+ */
+
+void __foo(void);
+void foo(void) __attribute__((weak, alias("__foo")));
+void foo__(void) __attribute__((weak, alias("__foo")));
+void __foo__(void) __attribute__((alias("__foo")));
+
+void __foo(void)
+{
+
+}
new file mode 100755
GIT binary patch
literal 14824
zcmeHOPiz!b7=N?d(n4V={{&K!P7FjK?(DW;!yhZHrKQ9|um+<>GtTbLb~kos$nF$d
z5+f&4q9z<YcpxEB;?a{FOiVbNG<q;zlnWO<0491dv3|dq@7s>U6s*L=!~2rAzxTfP
zeeb>b%{Om$cfNUld}<<N7)m6oUQjD7rAD~p=3%jb?ugnzpF7m{(6(cx>!I40*+?a*
zdZRYx=tPy<N!$^c(Htx>zi>X2^$A>JwV;fP`PQMYzy>E0C<iUb^JU0vEq>iREY|p_
zbr#u9Q2buG8&v*{-#PXxn$f^X+{^O`hI5eaW%3J;kNY17OpBV9b^b#>g;s<^7ZqT9
zUaSZ4Aa+z$;2w6+p}>Ccw<>eFV<e1N^uzCJYq6(#rM3CiM-Orxw?AL_`MZ0$&+h+{
zqpnp2<35cU`GBw{$a*Si`pu-@O7>j|d-y@090zd=eJ){-<4Chtwq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zAr5J$ph{3BwOg8-v7M&l&A2UT*1f7Pb*EHnx)-H2TlZY4(;}q`wT<?ZOFs>PErz$<
z_I@q<w(P&WO^0U=v&#OC`@`?c%f9$u=ZYZW7LxRjv`X!x3ifvKzrz*5n{0^r5DADJ
zh};MARL9ujFZUBcSwDOr5>`=5spnWHVJDlNVEa8Qc1ZdkCq1qqnO~V~$e5g8*3VYz
zELAY3_{%;ah^r(n!n^43pKsj%H8biFoEJmJ<os3A<Jjf=wD&K0e~AxR<`sYJcM#mv
zVUj#fQQ&?P7ap#C9<V;q#qEX;MXeigWs2>4DLS|u<OL<ym7MFtRs7#z$I}=rCQ1K~
zsV}L6`3?3*e8wed`zduMb+BJz|EaihitQJyOCIMQeibVG(iIy+<`VpB75@*|AKzBu
zB7Sj{*p1sQvA@ZN_@aY2llYPA7x&qA?8OGSKNvM8Vmef1UQutMN}B%<96#TPA!E}2
EFPZjRv;Y7A
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,11 @@
+// gcc -shared -gctf -gdwarf-3 -mtune=generic -march=x86-64 -std=c99 -fPIC -o test4.so test4.c
+
+char *
+cpy (char * restrict s1, const char * restrict s2, unsigned int n)
+{
+ char *t1 = s1;
+ const char *t2 = s2;
+ while(n-- > 0)
+ *t1++ = *t2++;
+ return s1;
+}
new file mode 100755
GIT binary patch
literal 16560
zcmeHOeQX>@6`wu(>`R>ZoP>ms&}17WkW}^g>?E$!G|AbHopWQSX^5p18ZGO)weR43
z7v1e8c0@%*0L6*|=^uQkKotpuDv+Rnh#-HUG(m}w_`^j43MwK(4YFt@96n7!J$`Ry
z-g&*bE0rpNkan!wH}B&&Z|2SH?5ua@;{(HkA;S=y8pM9F$O)0qiWhp=f@D1+f~zSu
zOWVdp)jhemRx%ZB%7lD`DXV!u{h_V|Q`VDM7HJX~$&}YB{hDT(dT~wA#be4KzJDp5
z*ZvkXWn2hmgiB~#LgScT*7i&zs#tOKj+=g~dT!NrOr<Skj{`^k-frUX9n=2mwQp9}
z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' path='data/test-read-common/PR26261/PR26261-exe'>
+ <elf-function-symbols>
+ <elf-symbol name='__libc_csu_fini' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='__libc_csu_init' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='_start' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='fun_obja' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='fun_objb' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='main' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='wrapped_call' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <elf-variable-symbols>
+ <elf-symbol name='_IO_stdin_used' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-variable-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='char' size-in-bits='8' alignment-in-bits='8' id='type-id-1'/>
+ <class-decl name='SA' size-in-bits='192' alignment-in-bits='32' is-struct='yes' visibility='default' id='type-id-2'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='m1' type-id='type-id-3' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='m2' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='128'>
+ <var-decl name='m3' type-id='type-id-5' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <class-decl name='SB' size-in-bits='128' alignment-in-bits='32' is-struct='yes' visibility='default' id='type-id-6'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='m1' type-id='type-id-3' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='m2' type-id='type-id-7' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='type-id-3'/>
+ <typedef-decl name='fn_ptr_type_a2_t' type-id='type-id-8' id='type-id-5'/>
+ <typedef-decl name='fn_ptr_type_a_t' type-id='type-id-8' id='type-id-4'/>
+ <typedef-decl name='fn_ptr_type_b_t' type-id='type-id-9' id='type-id-7'/>
+ <pointer-type-def type-id='type-id-2' size-in-bits='64' alignment-in-bits='64' id='type-id-10'/>
+ <pointer-type-def type-id='type-id-6' size-in-bits='64' alignment-in-bits='64' id='type-id-11'/>
+ <pointer-type-def type-id='type-id-1' size-in-bits='64' alignment-in-bits='64' id='type-id-12'/>
+ <pointer-type-def type-id='type-id-12' size-in-bits='64' alignment-in-bits='64' id='type-id-13'/>
+ <pointer-type-def type-id='type-id-14' size-in-bits='64' alignment-in-bits='64' id='type-id-8'/>
+ <pointer-type-def type-id='type-id-15' size-in-bits='64' alignment-in-bits='64' id='type-id-9'/>
+ <function-type size-in-bits='64' alignment-in-bits='8' id='type-id-14'>
+ <parameter type-id='type-id-3'/>
+ <parameter type-id='type-id-3'/>
+ <return type-id='type-id-16'/>
+ </function-type>
+ <function-type size-in-bits='64' alignment-in-bits='8' id='type-id-15'>
+ <parameter type-id='type-id-3'/>
+ <parameter type-id='type-id-3'/>
+ <parameter type-id='type-id-1'/>
+ <return type-id='type-id-16'/>
+ </function-type>
+ <type-decl name='void' id='type-id-16'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,22 @@
+<abi-corpus version='2.1' path='data/test-read-common/PR27700/test-PR27700.o'>
+ <elf-function-symbols>
+ <elf-symbol name='foo' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='' is-anonymous='yes' size-in-bits='32' alignment-in-bits='32' id='811c9dc5'/>
+ <enum-decl name='foo' linkage-name='foo' id='022218d8'>
+ <underlying-type type-id='811c9dc5'/>
+ <enumerator name='foo_e0' value='0'/>
+ <enumerator name='foo_e1' value='1'/>
+ <enumerator name='foo_e2' value='2'/>
+ <enumerator name='foo_e3' value='3'/>
+ </enum-decl>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='f0981eeb'/>
+ <pointer-type-def type-id='022218d8' size-in-bits='64' alignment-in-bits='64' id='8750e847'/>
+ <function-decl name='foo' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <parameter type-id='8750e847'/>
+ <return type-id='48b5725f'/>
+ </function-decl>
+ <type-decl name='void' id='48b5725f'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,56 @@
+<abi-corpus version='2.1' path='data/test-read-common/test-PR26568-1.o'>
+ <elf-function-symbols>
+ <elf-symbol name='fun' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <class-decl name='A' size-in-bits='64' alignment-in-bits='64' is-struct='yes' visibility='default' id='type-id-1'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='' type-id='type-id-2' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='' type-id='type-id-3' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='x' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='' type-id='type-id-5' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='y' type-id='type-id-6' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <class-decl name='' size-in-bits='32' alignment-in-bits='32' is-struct='yes' is-anonymous='yes' visibility='default' id='type-id-3'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='x' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <class-decl name='' size-in-bits='64' alignment-in-bits='64' is-struct='yes' is-anonymous='yes' visibility='default' id='type-id-5'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='y' type-id='type-id-6' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='type-id-4'/>
+ <type-decl name='long int' size-in-bits='64' alignment-in-bits='64' id='type-id-6'/>
+ <union-decl name='' size-in-bits='64' is-anonymous='yes' visibility='default' id='type-id-2'>
+ <data-member access='public'>
+ <var-decl name='' type-id='type-id-3' visibility='default'/>
+ </data-member>
+ <data-member access='public'>
+ <var-decl name='x' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ <data-member access='public'>
+ <var-decl name='' type-id='type-id-5' visibility='default'/>
+ </data-member>
+ <data-member access='public'>
+ <var-decl name='y' type-id='type-id-6' visibility='default'/>
+ </data-member>
+ </union-decl>
+ <pointer-type-def type-id='type-id-1' size-in-bits='64' alignment-in-bits='64' id='type-id-7'/>
+ <function-decl name='fun' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <parameter type-id='type-id-7'/>
+ <return type-id='type-id-8'/>
+ </function-decl>
+ <type-decl name='void' id='type-id-8'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,39 @@
+<abi-corpus version='2.1' path='data/test-read-common/test-PR26568-2.o'>
+ <elf-function-symbols>
+ <elf-symbol name='fun' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <class-decl name='' size-in-bits='32' alignment-in-bits='32' is-struct='yes' is-anonymous='yes' visibility='default' id='type-id-1'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='x' type-id='type-id-2' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <class-decl name='' size-in-bits='64' alignment-in-bits='64' is-struct='yes' is-anonymous='yes' visibility='default' id='type-id-3'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='y' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='type-id-2'/>
+ <type-decl name='long int' size-in-bits='64' alignment-in-bits='64' id='type-id-4'/>
+ <union-decl name='A' size-in-bits='64' visibility='default' id='type-id-5'>
+ <data-member access='public'>
+ <var-decl name='' type-id='type-id-1' visibility='default'/>
+ </data-member>
+ <data-member access='public'>
+ <var-decl name='x' type-id='type-id-2' visibility='default'/>
+ </data-member>
+ <data-member access='public'>
+ <var-decl name='' type-id='type-id-3' visibility='default'/>
+ </data-member>
+ <data-member access='public'>
+ <var-decl name='y' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ </union-decl>
+ <pointer-type-def type-id='type-id-5' size-in-bits='64' alignment-in-bits='64' id='type-id-6'/>
+ <function-decl name='fun' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <parameter type-id='type-id-6'/>
+ <return type-id='type-id-7'/>
+ </function-decl>
+ <type-decl name='void' id='type-id-7'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,15 @@
+
+// function aliases
+
+void main_func(void);
+void alias_func(void) __attribute__((weak, alias("main_func")));
+
+void main_func(void)
+{
+
+}
+
+// variables aliases
+
+int main_var;
+extern int alias_var __attribute__((weak, alias("main_var")));
new file mode 100644
@@ -0,0 +1,19 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test-alias.o'>
+ <elf-function-symbols>
+ <elf-symbol name='alias_func' type='func-type' binding='weak-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='main_func' type='func-type' binding='global-binding' visibility='default-visibility' alias='alias_func,main_var,alias_var' is-defined='yes'/>
+ </elf-function-symbols>
+ <elf-variable-symbols>
+ <elf-symbol name='alias_var' size='4' type='object-type' binding='weak-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='main_var' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-variable-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='95e97e5e'/>
+ <function-decl name='main_func' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <return type-id='48b5725f'/>
+ </function-decl>
+ <var-decl name='alias_var' type-id='95e97e5e' mangled-name='alias_var' visibility='default'/>
+ <var-decl name='main_var' type-id='95e97e5e' mangled-name='main_var' visibility='default'/>
+ <type-decl name='void' id='48b5725f'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,8 @@
+struct A;
+struct B { struct A *a; };
+struct A { struct B b; long foo; long bar; struct B b2; };
+
+typedef struct A a_array[50];
+a_array *foo __attribute__((__used__));
+
+static struct A a __attribute ((__used__));
new file mode 100644
GIT binary patch
literal 1504
zcmbtU&2G~`5FVFMC`eU{IG`dV_e2ZWPI5si0=ZOB2_bGA5v*M|jfm~YUQ5jho`VD8
zQOX<e1n>;-0`PtIE{>MMg^|9UnQwmVnT_-A$@8Zxo+nm3c_h7OSrPw2Z^x|}%T>7|
zKfVoCY~-Oepf4M2KodUj1^584fbj>weWS_ICeP;sTeNQilmWn3fZp<<F9H<ivVROP
zejRvk>>JQ$0CO$@kX81KJBt1~pL>f|AL~4kYcv?=v&KLKK<=z|n&*1k_p$6tBD1oX
z_|rnmaal^DDoMtoI<_h5>7>Yx+OT@9s!A=|G$qkVnP*Y5NET69sdSb_b(Kc5X`+(p
zL``QwGp}`(sXWqIt?TGWY1Ntm$fF?D$DOBg<Tqtg2S{&H9qfmx$l<}kp1*VW;^nSC
z8i&Jh=#Piv(FpK&veS81P4leKYPM@f;+}ngGouXiduQaVc*f^W|0RqM<oi!Ihxh5>
zrhF5yns>0--e4EtJ+;EAgL8*d?FJ>R7r9mmw5~dRVlADWY6-b936r{(5Zl60<{VnW
zqSRT4A+a%)zBT@&Xu^3_Vl{eU-{C)WH!pr%PLJ5}t?TY}8v$}lpI@6Ax96XSTYnoV
z+~wcuW2c4h`1jzuJ(&{ofP8d<jw>VNkQ*|2NxquIyGtBRTW|H=61SYX#t-uxv2`}|
z3<keZH+{np?tA_I-I)gL=hiY58}bbu$Qr;M+j{=@P%Phh{rSn%Z}(Jdx$nOT*1bC>
Oem3>5+N%C=>wf{e$$~-v
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,36 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test-ambiguous-struct-A.o'>
+ <elf-variable-symbols>
+ <elf-symbol name='foo' size='8' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-variable-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <array-type-def dimensions='1' type-id='3ed987a4' size-in-bits='12800' alignment-in-bits='64' id='e022be37'>
+ <subrange length='50' type-id='7359adad' id='3c1860ce'/>
+ </array-type-def>
+ <class-decl name='A' size-in-bits='256' alignment-in-bits='64' is-struct='yes' visibility='default' id='3ed987a4'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='b' type-id='41d98c5d' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='foo' type-id='bd54fe1a' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='128'>
+ <var-decl name='bar' type-id='bd54fe1a' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='192'>
+ <var-decl name='b2' type-id='41d98c5d' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <class-decl name='B' size-in-bits='64' alignment-in-bits='64' is-struct='yes' visibility='default' id='41d98c5d'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='a' type-id='84d5ac12' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <type-decl name='long int' size-in-bits='64' alignment-in-bits='64' id='bd54fe1a'/>
+ <typedef-decl name='a_array' type-id='e022be37' id='1c12b755'/>
+ <type-decl name='unsigned long int' size-in-bits='64' alignment-in-bits='64' id='7359adad'/>
+ <pointer-type-def type-id='3ed987a4' size-in-bits='64' alignment-in-bits='64' id='84d5ac12'/>
+ <pointer-type-def type-id='1c12b755' size-in-bits='64' alignment-in-bits='64' id='55cd64e8'/>
+ <var-decl name='a' type-id='3ed987a4' mangled-name='a' visibility='default'/>
+ <var-decl name='foo' type-id='55cd64e8' mangled-name='foo' visibility='default'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,5 @@
+struct A;
+struct B { struct A *a; };
+struct A { struct B b; int foo; struct B b2; };
+
+static struct A a __attribute__((__used__));
new file mode 100644
GIT binary patch
literal 1344
zcmbtTO>fjN5S^3-3YGX$RiRdu!iiQ8XLpZ1ptKbfA;gUn;^3ri8?o7}Vn^zp=&9l-
zapa%y8_FMmH;LU?R^h^|US{Uao2+M&e0}}?%}NxJvxr{NkU5s<Vr7W4F3f0+?$fWI
zqwC7XAfXXr#;V05cmrsF8`dp2=KljWS^ETF<KA06HlM=Z2H04;24n!&9|9Ku^LGK*
z9qx^Lit`8E0S{=Oaw_MBPU@QSDM|d&v$|4gzRZ_t-N<65Qr#5ktjuLzp2~8Tv<qz-
zC9BjZZFG7pjqJh%<Z)7%lRlFb^ljbh1oE~p$$=<{jt&p^;+>-pA9v%)RE)(qo{p!J
z2@vn7^Mz{4O3jU&?c$L3%-x*mz>cCH%sGo}&U60DxIUt*-=Ss;MAU7pukcPg<H3>}
z&o7CDURFlt@TTegnTw1%Hzar=Byz1uU>Ug770*OsUK=Ga2o@rXFE&4&w_?%MnA|Mg
z|Np1&=fXn|?vn+%OT+y=LxDMdmwe0o#EZlJ=cw^}`?vn<J==Tmci`JgB;h@|p78~?
z6%>P%CeSc9X0d0Vtnh`$ap?M;-}5+Mdg%l{d4u*HIR5UsZ_Lwvv;E<@cvrr$EbQg_
sciaEgitoYmj$OaotK+R~aQ3F#1Jgy}SdYPm&yI!Lw*Pb2HC)2}KYuZ9CjbBd
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,23 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test-ambiguous-struct-B.o'>
+ <abi-instr address-size='64' language='LANG_C'>
+ <class-decl name='A' size-in-bits='192' alignment-in-bits='64' is-struct='yes' visibility='default' id='3ed987a4'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='b' type-id='41d98c5d' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='foo' type-id='95e97e5e' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='128'>
+ <var-decl name='b2' type-id='41d98c5d' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <class-decl name='B' size-in-bits='64' alignment-in-bits='64' is-struct='yes' visibility='default' id='41d98c5d'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='a' type-id='84d5ac12' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='95e97e5e'/>
+ <pointer-type-def type-id='3ed987a4' size-in-bits='64' alignment-in-bits='64' id='84d5ac12'/>
+ <var-decl name='a' type-id='3ed987a4' mangled-name='a' visibility='default'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,5 @@
+typedef long a_t;
+typedef long b_t;
+
+a_t *a;
+b_t ignore2;
new file mode 100644
GIT binary patch
literal 1360
zcmbtTOK#La5G@bG5P}pD!~zKxh7C!;_KcTVAWIR6gb*uOB4|4u$HJe9-I2x{a)lg&
zV{jAB02hFIc6X-Lnye`4xvE~(>**?wuim~to_HP^^XLt&Gs6;HPu6iVgb6*MZTj<T
zdQ*9}ZlNuXfrlDC`;Uz8j49&|;}PSr_TUhM*S|l5KH+qmJ=+2Jogp0KF{GX00%cR@
zeo-qDUlgSbK}B9St&Ax;Zz>t3ecDG&E3#5XU7JN^k&3j)MNtNq%TBdYRFRUM>Y`Jj
z#1IBdo(7pZ8?&sb&&ncGMV$w#U&^5Ct1b{>Ms#v?bm;G$eE78QFXC_>&i!~EFBS}c
zPp+1-Eh<?nQSR$I4?FNVxyxV~P00I+9T@X;zUf_<9(dHJ^!u;PA@&)&!#0tP?*je>
z13Y#MGoCPdaQlSoZBoc%E0MBS?dZ=<q~uCbi2YHRb{&PhJAO13rl+uOlni;=pi?6I
zrt`eM43}-gJ5v34r~i3AWifU#a}G(I+@$V)pK}2m{)e_Dc4Eb@{w3G2)7$j;9&EeW
zzb0R^ch5vA!Gmq)6rGe7+yicoX3LIs<133pX!OP(TAbZ_VH#|5L+?B0?lFdM(&}Al
zy?ZZrezdt-9P>l#zan9~&p@BiKLN=G-rYU;Eq&+#63g7NcDc4mA8Y+*ON-Fe{{z~E
BcuD{O
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,14 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test-conflicting-type-syms-a.o'>
+ <elf-variable-symbols>
+ <elf-symbol name='a' size='8' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='ignore2' size='8' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-variable-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='long int' size-in-bits='64' alignment-in-bits='64' id='bd54fe1a'/>
+ <typedef-decl name='a_t' type-id='bd54fe1a' id='40acc204'/>
+ <typedef-decl name='b_t' type-id='bd54fe1a' id='b3d2db81'/>
+ <pointer-type-def type-id='40acc204' size-in-bits='64' alignment-in-bits='64' id='c6fd4117'/>
+ <var-decl name='a' type-id='c6fd4117' mangled-name='a' visibility='default'/>
+ <var-decl name='ignore2' type-id='b3d2db81' mangled-name='ignore2' visibility='default'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,5 @@
+typedef long a_t;
+typedef long b_t;
+
+a_t b;
+b_t ignore1;
new file mode 100644
GIT binary patch
literal 1344
zcmbtTO>fjN5S^5zK#>qd9FWQ(^g>&Rv)SVwP^1cq5aPxWfs?w~h<vOPS86W6&*10q
zPx>3$6XF8%Hg-0$wkJk<o;S}kUi&Hg{q_4dTb@TYJbFdz%Bn;^w$?me(U|Vj4qabP
zhMlMD7P`wEcxd2re#`jAz`!lWBgSKsp@Bm;zrT(7n9Ci`97oU}tZ2`vsH@D+D^2pV
zrUalotLjEY6fWvgg-MrmVcp2IP+{AoVUZ^?$upT3!TGY)jgn=kRjb?ZRBE}R0gI<W
zs?Yi=t*f&lPjy~pf$o+nXuGlv5|I*}93Rj9gOd**5B+E+ref;Prn4ww_y_7@shYf0
zm6pXJt~_D*jN1$zVGq1t&}?|7-sHXQLB{@suKtcSaG$Zeat~GSJ@P&SI=n>KOn7#1
z^Xt}5lHez6nQ+!kpBI*Cb)iYXI}%CTl3?F>sY|?^L{)1g__aZ+W%||BS#>U!P0jx3
zuD{d&tb05RPqv*yVyCvH>+dt(fQIjG9Pzjqad-YX@4?fX=JEZHWANXIFFCtsVk^eN
z@uyG2>h?yw18q8V^ki-tUpTs*w|UO{mXBN2CUHaWJJ#+n@c$jh!pyt(a^H_OcNXXT
tH1l6jaNJ{{&(1%A$N}B;9{O)He}rNbMjn)1W}D{s&80pKojq~q{{dYmdA0xm
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,13 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test-conflicting-type-syms-b.o'>
+ <elf-variable-symbols>
+ <elf-symbol name='b' size='8' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='ignore1' size='8' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-variable-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='long int' size-in-bits='64' alignment-in-bits='64' id='bd54fe1a'/>
+ <typedef-decl name='a_t' type-id='bd54fe1a' id='40acc204'/>
+ <typedef-decl name='b_t' type-id='bd54fe1a' id='b3d2db81'/>
+ <var-decl name='b' type-id='40acc204' mangled-name='b' visibility='default'/>
+ <var-decl name='ignore1' type-id='b3d2db81' mangled-name='ignore1' visibility='default'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,13 @@
+// test dynamic arrays definitions
+// information was detected f field.
+
+struct S
+{
+ char *a;
+ char b[0];
+ char c[];
+};
+
+void use_struct_s(struct S *)
+{
+}
new file mode 100644
GIT binary patch
literal 1712
zcmbtU&1(}u6n~q>v}zk_ks?-PMZ^@{*(4|FK_bDnsCZC%Ea~iKnk?=|*qumL5W#~`
zPyLe$di8JcBzV<RZ~ES5Cf$zlq7UA_&)>Y+-^}j2$IrGamIYcYcnD{a&H{`U&iqc{
zc3=gTVQ=^7+wRfZ)8qY5KfhKhx~Z)lWvggOmy~`+`%(FK(9%epa9!6iq!@0Xc2F;%
z-c)`Kt=dhEaEQ^HtJ4N9p`z4itqyrpStCPr+DA$L$lKE*jUlnr{?->UxLBlSk9tAX
zOYnz01rA{n5A1QA1%p`h?I4!mfe){fpbz6r^fH-_ec8*v9VU@*z1+*)B;|f6+${Co
zFz~n+40sSa;}P}>9=TFvGIRS}^1^j6*>`+-IF0&w%%i|}c$)H@`2aiJ?v~xydA_%4
zx7w`9ns&R{ZnaSDhM0^*8bl(NJlrfuu<<>JSnNk)tdlY^mWuUVxT@aSdh-IT$*Q%n
zyts6XMLHl-lFRgXRA2p2>8{kav4P^h2(4R%AHU|67v|i+b!=QK<%?MaCWai7h;wWg
zBkbZiy#RCxX2P;OlH3D^j8E-Qds0j!Fd`qAmu0|^czh%gkq9hKq+rOMlS%HsQt==j
zvr(EL)iMW`ijXrg>>Z{&60?#2<7^<9xYM^&uhmh`j29K_^V5B|(4n0EVs!qgb_{Fc
z?_!<K^<VM#5o@kVBlZ0EM$rhNrSMGxmE?<RyjRMRtMS@ym2&0QQ{7Nb&gp%EIr<Tt
zyF(ajytyy)8}QVcCcdE(53pVq6Tgo|`c6CLCiK56{56%QpCDm1UgzmG&DjJwP{{)d
mQ0N}f8Jl?e0h(uzDL7I1+Z2?<r1c8c=HYcREMdtt@xK8~j*u|`
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,30 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test-dynamic-array.o'>
+ <elf-function-symbols>
+ <elf-symbol name='use_struct_s' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='char' size-in-bits='8' alignment-in-bits='8' id='type-id-1'/>
+ <array-type-def dimensions='1' type-id='type-id-1' size-in-bits='infinite' alignment-in-bits='8' id='type-id-2'>
+ <subrange length='infinite' type-id='type-id-3' id='type-id-4'/>
+ </array-type-def>
+ <class-decl name='S' size-in-bits='64' alignment-in-bits='64' is-struct='yes' visibility='default' id='type-id-5'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='a' type-id='type-id-6' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='b' type-id='type-id-2' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='c' type-id='type-id-2' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <type-decl name='unsigned long int' size-in-bits='64' alignment-in-bits='64' id='type-id-3'/>
+ <pointer-type-def type-id='type-id-5' size-in-bits='64' alignment-in-bits='64' id='type-id-7'/>
+ <pointer-type-def type-id='type-id-1' size-in-bits='64' alignment-in-bits='64' id='type-id-6'/>
+ <function-decl name='use_struct_s' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <parameter type-id='type-id-7'/>
+ <return type-id='type-id-8'/>
+ </function-decl>
+ <type-decl name='void' id='type-id-8'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,10 @@
+/* Looked up item by item. */
+enum e { ENUMSAMPLE_1 = 0, ENUMSAMPLE_2 = 1 };
+
+/* Looked up via both sorts of iterator in turn. */
+enum ie { IE_0 = -10, IE_1, IE_2, IE_3, IE_4, IE_5, IE_6, IE_7, IE_8, IE_9, IE_A, IE_B, IE_C, IE_D, IE_E, IE_F,
+ IE_10, IE_11, IE_12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+>|VHxzD`vb<W^w+m3e+R*W^<vY{9vba6UDtMl<
zur)}PGH+E`ZpC*j++E7^?c(L2KjuzZlhq0~#INy+{x9Uag9XotXk??ENISlt?HFTi
zeq;`t*;qg9#@Fw}0MDd<t>;)YX7@WN?t#WVIh18W%*2f2b2a9$hBN!O_!6w^{;fLq
zTcJ-c#=~}WYG?dHgTeURlc@7-<~bgXu3&xqy5jpmzxZ1EoDbGtVh6$Vp7X->Jck*q
g$F@l74}$ePpQ91Ke*Pc$+xln0`is%UXvf$80+<N)-T(jq
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,69 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test-enum-many.o'>
+ <elf-variable-symbols>
+ <elf-symbol name='bar' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='foo' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-variable-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='' is-anonymous='yes' size-in-bits='32' alignment-in-bits='32' id='811c9dc5'/>
+ <enum-decl name='e' linkage-name='e' id='a6c2eddf'>
+ <underlying-type type-id='811c9dc5'/>
+ <enumerator name='ENUMSAMPLE_1' value='0'/>
+ <enumerator name='ENUMSAMPLE_2' value='1'/>
+ </enum-decl>
+ <enum-decl name='ie' linkage-name='ie' id='1ee696ca'>
+ <underlying-type type-id='811c9dc5'/>
+ <enumerator name='IE_0' value='-10'/>
+ <enumerator name='IE_1' value='-9'/>
+ <enumerator name='IE_2' value='-8'/>
+ <enumerator name='IE_3' value='-7'/>
+ <enumerator name='IE_4' value='-6'/>
+ <enumerator name='IE_5' value='-5'/>
+ <enumerator name='IE_6' value='-4'/>
+ <enumerator name='IE_7' value='-3'/>
+ <enumerator name='IE_8' value='-2'/>
+ <enumerator name='IE_9' value='-1'/>
+ <enumerator name='IE_A' value='0'/>
+ <enumerator name='IE_B' value='1'/>
+ <enumerator name='IE_C' value='2'/>
+ <enumerator name='IE_D' value='3'/>
+ <enumerator name='IE_E' value='4'/>
+ <enumerator name='IE_F' value='5'/>
+ <enumerator name='IE_10' value='6'/>
+ <enumerator name='IE_11' value='7'/>
+ <enumerator name='IE_12' value='8'/>
+ <enumerator name='IE_13' value='9'/>
+ <enumerator name='IE_14' value='10'/>
+ <enumerator name='IE_15' value='11'/>
+ <enumerator name='IE_16' value='12'/>
+ <enumerator name='IE_17' value='13'/>
+ <enumerator name='IE_18' value='14'/>
+ <enumerator name='IE_19' value='15'/>
+ <enumerator name='IE_1A' value='16'/>
+ <enumerator name='IE_1B' value='17'/>
+ <enumerator name='IE_1C' value='18'/>
+ <enumerator name='IE_1D' value='19'/>
+ <enumerator name='IE_1E' value='20'/>
+ <enumerator name='IE_1F' value='21'/>
+ <enumerator name='IE_20' value='22'/>
+ <enumerator name='IE_21' value='23'/>
+ <enumerator name='IE_22' value='24'/>
+ <enumerator name='IE_23' value='25'/>
+ <enumerator name='IE_24' value='26'/>
+ <enumerator name='IE_25' value='27'/>
+ <enumerator name='IE_26' value='28'/>
+ <enumerator name='IE_27' value='29'/>
+ <enumerator name='IE_28' value='30'/>
+ <enumerator name='IE_29' value='31'/>
+ <enumerator name='IE_2A' value='32'/>
+ <enumerator name='IE_2B' value='33'/>
+ <enumerator name='IE_2C' value='34'/>
+ <enumerator name='IE_2D' value='35'/>
+ <enumerator name='IE_2E' value='36'/>
+ <enumerator name='IE_2F' value='37'/>
+ </enum-decl>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='95e97e5e'/>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='f0981eeb'/>
+ <var-decl name='foo' type-id='a6c2eddf' mangled-name='foo' visibility='default'/>
+ <var-decl name='bar' type-id='1ee696ca' mangled-name='bar' visibility='default'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1 @@
+enum {red1, green1, blue1} primary1;
new file mode 100644
GIT binary patch
literal 1312
zcmbtT&5qPC40e}c`4bXoIUpgV!i8Ny)9GB0_JAraum~Y;9Fa&mVWy%#qa>BKr+p0`
zhc|&&fD0!C_SWf?>~g}AWBc>xBzDu&7jItfL=kw2;2CTqj{<zy+4}jJo5Kyb4nMxm
z#>~N%0yFeUud?1k`yBNYmG+NW{aKd)9unWjyX@aYO9$+sqU;hUCeP?)1}md=lYy!_
zok7>wa@FW%Ts96irmUsuGf3BMty9&jK5dOGDxF$Wq*bY;Dp#_sl5S(2(XvjRw$7$Y
z>ExN4Ah=8l_i>1H)76RXYt>ew060E6I*j*^-@ZGDvxS(8dAyh}vJ5re*C!i|$Lq$)
z%Fo2#`!Ze~tFWi&3t?U&j(z_g4=v?q@cnm)-$CFu;1pTLy{W6@@5_&~0f7xUsn9wz
z*tPeZK5-yu8X%OlAaD}6v^DhwqG_EL*hpfXEIx6(YC5qoEq3pEf06&R_pqLNruQ(F
zd>TyraDERkN7!~U134eexizeRgbaGa|EeG7%sYkg6U4(kiJH@b@^dib8gett5H=qf
zgY%S$j|1G-dwYm^?@y`fBJcw4Ys9Xgjz2kXvgZ2mUNozz5G|~w{AaFz#pG+u^YwQp
hcsP4XedGH3%=3m}AL2i8{@YRV7Zcx)%)trk{{VTabvgh5
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,16 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test-enum-symbol.o'>
+ <elf-variable-symbols>
+ <elf-symbol name='primary1' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-variable-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='' is-anonymous='yes' size-in-bits='32' alignment-in-bits='32' id='811c9dc5'/>
+ <enum-decl name='' is-anonymous='yes' id='08f5ca17'>
+ <underlying-type type-id='811c9dc5'/>
+ <enumerator name='red1' value='0'/>
+ <enumerator name='green1' value='1'/>
+ <enumerator name='blue1' value='2'/>
+ </enum-decl>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='f0981eeb'/>
+ <var-decl name='primary1' type-id='08f5ca17' mangled-name='primary1' visibility='default'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,8 @@
+/* Looked up item by item. */
+enum e { ENUMSAMPLE_1 = 0, ENUMSAMPLE_2 = 1 };
+
+/* Looked up via both sorts of iterator in turn. */
+enum ie { IENUMSAMPLE_1 = -10, IENUMSAMPLE_2, IENUMSAMPLE_3 };
+
+enum e foo;
+enum ie bar;
new file mode 100644
GIT binary patch
literal 1440
zcmb_cO>fgc5FMA$77!9WAR!?n!-W>G9h+M#A)_i(MQw$IDh>#hwX;bqVmq=oQgcA?
zYxn{D0{#LwZtxf20NlcxWH)hFg%cx9-prf#*4fF&yUxLr6~`eH4n3k}XIP?dE6X~b
zl`&nR%k<-GYcWZe5?V*ic}=Gae2@Hyyny6qoFHFnWR7d*IdSNn7La)kK8N{R+z_qu
z%thWqLNn8PsDDnU(;eV1;6Cs-@C6WIJPt|f933A%e|-4tpmP#7n~26mo%IXZb+bZI
zCTahSwAn>xW)F!Cy|Sc4R1^%#Tn5P`nFM7e(xD9MDh-BNB9g2xvY|H~)vA&r50tD`
z9dv~fv(f|E^-|TFcd{7geoC~rySwdf?j0R(xnbnD{k9vmqcB9eoAPudt1Op=62q<e
zRf)`gE`op!`*c1rXTs4v@AO~6^A>%d+M25%HWr`G{CTX|(7bt;LE?LQ`Z{Jy<kyp2
zi3F&sISx#v<f$T`_d<SB*W_a-cqwzfDEURHq>qbvwG!zY-S>;JKdMTsLrwV2{D-)S
zGk6E9)>*ODo7UdvZ48(*-(#bTO<|$!zl%Blj{fH7Su+;<*5m`AeI}1$enIrCq193d
z4RdW4H{yd9-fwVR8o$Bq2G^8+Hi9O3j`k_IHRR$?M(e+5zx}@KeXz{-@)7Hre9aBw
m5|Sz7zriGed3*QF548U}H;u5b#lMI1{BO1YRm01r?f(OkDUBQe
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,24 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test-enum.o'>
+ <elf-variable-symbols>
+ <elf-symbol name='bar' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='foo' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-variable-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='' is-anonymous='yes' size-in-bits='32' alignment-in-bits='32' id='type-id-1'/>
+ <enum-decl name='e' linkage-name='e' id='type-id-2'>
+ <underlying-type type-id='type-id-1'/>
+ <enumerator name='ENUMSAMPLE_1' value='0'/>
+ <enumerator name='ENUMSAMPLE_2' value='1'/>
+ </enum-decl>
+ <enum-decl name='ie' linkage-name='ie' id='type-id-3'>
+ <underlying-type type-id='type-id-1'/>
+ <enumerator name='IENUMSAMPLE_1' value='-10'/>
+ <enumerator name='IENUMSAMPLE_2' value='-9'/>
+ <enumerator name='IENUMSAMPLE_3' value='-8'/>
+ </enum-decl>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='type-id-4'/>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='type-id-5'/>
+ <var-decl name='foo' type-id='type-id-2' mangled-name='foo' visibility='default'/>
+ <var-decl name='bar' type-id='type-id-3' mangled-name='bar' visibility='default'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,28 @@
+#include <unistd.h>
+
+struct foo_t
+{
+ int foo;
+ size_t bar;
+ const char *baz;
+ struct foo_t *self;
+ union
+ {
+ double should_not_appear;
+ char *nor_should_this;
+ } named;
+ struct
+ {
+ long unnamed_sub_member;
+ union
+ {
+ double one_more_level;
+ long yes_really_one_more;
+ };
+ };
+ struct {}; /* Empty ones */
+ union {};
+ int after_the_end;
+};
+
+struct foo_t used;
new file mode 100644
@@ -0,0 +1,96 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test-struct-iteration-ctf.o'>
+ <elf-variable-symbols>
+ <elf-symbol name='used' size='64' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-variable-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='char' size-in-bits='8' alignment-in-bits='8' id='type-id-1'/>
+ <class-decl name='' is-struct='yes' is-anonymous='yes' visibility='default' id='type-id-2'/>
+ <class-decl name='' size-in-bits='128' alignment-in-bits='64' is-struct='yes' is-anonymous='yes' visibility='default' id='type-id-3'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='unnamed_sub_member' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='' type-id='type-id-5' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='one_more_level' type-id='type-id-6' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='yes_really_one_more' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <class-decl name='foo_t' size-in-bits='512' alignment-in-bits='32' is-struct='yes' visibility='default' id='type-id-7'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='foo' type-id='type-id-8' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='bar' type-id='type-id-9' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='128'>
+ <var-decl name='baz' type-id='type-id-10' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='192'>
+ <var-decl name='self' type-id='type-id-11' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='256'>
+ <var-decl name='named' type-id='type-id-12' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='' type-id='type-id-3' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='unnamed_sub_member' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='' type-id='type-id-5' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='one_more_level' type-id='type-id-6' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='yes_really_one_more' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='' type-id='type-id-2' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='' type-id='type-id-13' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='448'>
+ <var-decl name='after_the_end' type-id='type-id-8' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <type-decl name='double' size-in-bits='64' alignment-in-bits='64' id='type-id-6'/>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='type-id-8'/>
+ <type-decl name='long int' size-in-bits='64' alignment-in-bits='64' id='type-id-4'/>
+ <type-decl name='short int' size-in-bits='16' alignment-in-bits='16' id='type-id-14'/>
+ <type-decl name='signed char' size-in-bits='8' alignment-in-bits='8' id='type-id-15'/>
+ <typedef-decl name='size_t' type-id='type-id-16' id='type-id-9'/>
+ <union-decl name='' size-in-bits='64' is-anonymous='yes' visibility='default' id='type-id-12'>
+ <data-member access='public'>
+ <var-decl name='should_not_appear' type-id='type-id-6' visibility='default'/>
+ </data-member>
+ <data-member access='public'>
+ <var-decl name='nor_should_this' type-id='type-id-17' visibility='default'/>
+ </data-member>
+ </union-decl>
+ <union-decl name='' is-anonymous='yes' visibility='default' id='type-id-13'/>
+ <union-decl name='' size-in-bits='64' is-anonymous='yes' visibility='default' id='type-id-5'>
+ <data-member access='public'>
+ <var-decl name='one_more_level' type-id='type-id-6' visibility='default'/>
+ </data-member>
+ <data-member access='public'>
+ <var-decl name='yes_really_one_more' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ </union-decl>
+ <type-decl name='unsigned char' size-in-bits='8' alignment-in-bits='8' id='type-id-18'/>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='type-id-19'/>
+ <type-decl name='unsigned long int' size-in-bits='64' alignment-in-bits='64' id='type-id-16'/>
+ <type-decl name='unsigned short int' size-in-bits='16' alignment-in-bits='16' id='type-id-20'/>
+ <pointer-type-def type-id='type-id-1' size-in-bits='64' alignment-in-bits='64' id='type-id-17'/>
+ <qualified-type-def type-id='type-id-1' const='yes' id='type-id-21'/>
+ <pointer-type-def type-id='type-id-21' size-in-bits='64' alignment-in-bits='64' id='type-id-10'/>
+ <pointer-type-def type-id='type-id-7' size-in-bits='64' alignment-in-bits='64' id='type-id-11'/>
+ <var-decl name='used' type-id='type-id-7' mangled-name='used' visibility='default'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100755
GIT binary patch
literal 16656
zcmeHOU2Ggz6~4Pp9MdFgCvDP@gl718$PXT`t<-YUkk0xi8LQ4u^8=|MovwG+-bMRk
zc4v!C6;Wgww4{MNLE$L~R3cFU4^Ty-5=mn<=|e@@hY|@@l~4<AO2I7@S*Y#uoqNw&
zuO}{4LgJ-!q?vQiIo~<=-gEEF&g|U#^`Viy(MUuIMb#cflGWj8l{qWbu}h1r>r*S0
zqc*Eesuh}LI2>&uZc4(lQDYF^#<&)6@;lG=^HB#9$qq5ZHY8kHNSyo@$l;>l^As2)
zTy+?k{FYOZWySpy{ybM8TyTy0EOG`}j%LCg_7mRhN4arq19$cqKjAmnZ<6~jek79L
zA@)1Oe!|bOpK!@1<%EtIjyDr^Ad&14Q<gq2aKaKDdd*K$xy>SpxU-1w){;`f#qU1&
zQ9C~@N!kx{eIJyUi`+lqEUK=2ZnSr2S3cdD&lRhaos)gNoxMBlO3Cig{igVY-FM)a
zZW2ucNi8YJwv>+aauDvr68WrM0=x}6YYDybJoF&tRs3Yx_X^2eQISj?=vDhhhWiJ+
z9=pfB6S(n0smM4Fk)qtbh`JS$<gvOj_c5}4g6o>Q$I&Gk6Kb2#e3QO8A7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 <elf-function-symbols>
+ <elf-symbol name='__libc_csu_fini' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='__libc_csu_init' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='_start' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='foo_1' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='main' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <elf-variable-symbols>
+ <elf-symbol name='_IO_stdin_used' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='status' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='test_array' size='40' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='test_const' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='test_float' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='test_pointer' size='8' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='test_restrict' size='8' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='test_volatile' size='2' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-variable-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='' is-anonymous='yes' size-in-bits='1' alignment-in-bits='8' id='type-id-1'/>
+ <type-decl name='char' size-in-bits='8' alignment-in-bits='8' id='type-id-2'/>
+ <class-decl name='S' size-in-bits='32' alignment-in-bits='32' is-struct='yes' visibility='default' id='type-id-3'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='m0' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <class-decl name='' size-in-bits='32' alignment-in-bits='8' is-struct='yes' is-anonymous='yes' visibility='default' id='type-id-5'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='status0' type-id='type-id-1' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='1'>
+ <var-decl name='status1' type-id='type-id-1' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <type-decl name='float' size-in-bits='32' alignment-in-bits='32' id='type-id-6'/>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='type-id-4'/>
+ <array-type-def dimensions='1' type-id='type-id-4' size-in-bits='320' alignment-in-bits='32' id='type-id-7'>
+ <subrange length='10' type-id='type-id-8' id='type-id-9'/>
+ </array-type-def>
+ <type-decl name='long int' size-in-bits='64' alignment-in-bits='64' id='type-id-10'/>
+ <type-decl name='short int' size-in-bits='16' alignment-in-bits='16' id='type-id-11'/>
+ <type-decl name='signed char' size-in-bits='8' alignment-in-bits='8' id='type-id-12'/>
+ <type-decl name='unsigned char' size-in-bits='8' alignment-in-bits='8' id='type-id-13'/>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='type-id-14'/>
+ <type-decl name='unsigned long int' size-in-bits='64' alignment-in-bits='64' id='type-id-8'/>
+ <type-decl name='unsigned short int' size-in-bits='16' alignment-in-bits='16' id='type-id-15'/>
+ <pointer-type-def type-id='type-id-3' size-in-bits='64' alignment-in-bits='64' id='type-id-16'/>
+ <pointer-type-def type-id='type-id-2' size-in-bits='64' alignment-in-bits='64' id='type-id-17'/>
+ <qualified-type-def type-id='type-id-3' const='yes' id='type-id-18'/>
+ <pointer-type-def type-id='type-id-10' size-in-bits='64' alignment-in-bits='64' id='type-id-19'/>
+ <qualified-type-def type-id='type-id-19' restrict='yes' id='type-id-20'/>
+ <qualified-type-def type-id='type-id-11' volatile='yes' id='type-id-21'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,32 @@
+
+#include <stdio.h>
+
+char* test_pointer = NULL;
+int test_array[10] = {0};
+volatile short test_volatile = 1;
+float test_float = 0.0;
+
+struct {
+ unsigned int status0 : 1;
+ unsigned int status1 : 1;
+} status;
+
+
+struct S
+{
+ int m0;
+};
+
+const struct S test_const;
+long* restrict test_restrict;
+
+int
+foo_1(struct S* s)
+{
+ return s->m0;
+}
+
+int main()
+{
+
+}
new file mode 100644
@@ -0,0 +1,54 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test0'>
+ <elf-function-symbols>
+ <elf-symbol name='__libc_csu_fini' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='__libc_csu_init' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='_start' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='foo_1' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='main' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <elf-variable-symbols>
+ <elf-symbol name='_IO_stdin_used' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='status' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='test_array' size='40' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='test_const' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='test_float' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='test_pointer' size='8' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='test_restrict' size='8' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='test_volatile' size='2' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-variable-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='' is-anonymous='yes' size-in-bits='1' alignment-in-bits='8' id='811c9dc5'/>
+ <type-decl name='char' size-in-bits='8' alignment-in-bits='8' id='a84c031d'/>
+ <class-decl name='S' size-in-bits='32' alignment-in-bits='32' is-struct='yes' visibility='default' id='50d9a3fa'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='m0' type-id='95e97e5e' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <class-decl name='' size-in-bits='32' alignment-in-bits='8' is-struct='yes' is-anonymous='yes' visibility='default' id='e7f43f72'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='status0' type-id='811c9dc5' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='1'>
+ <var-decl name='status1' type-id='811c9dc5' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <type-decl name='float' size-in-bits='32' alignment-in-bits='32' id='a6c45d85'/>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='95e97e5e'/>
+ <array-type-def dimensions='1' type-id='95e97e5e' size-in-bits='320' alignment-in-bits='32' id='b7bd1749'>
+ <subrange length='10' type-id='7359adad' id='487da03a'/>
+ </array-type-def>
+ <type-decl name='long int' size-in-bits='64' alignment-in-bits='64' id='bd54fe1a'/>
+ <type-decl name='short int' size-in-bits='16' alignment-in-bits='16' id='a2185560'/>
+ <type-decl name='signed char' size-in-bits='8' alignment-in-bits='8' id='28577a57'/>
+ <type-decl name='unsigned char' size-in-bits='8' alignment-in-bits='8' id='002ac4a6'/>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='f0981eeb'/>
+ <type-decl name='unsigned long int' size-in-bits='64' alignment-in-bits='64' id='7359adad'/>
+ <type-decl name='unsigned short int' size-in-bits='16' alignment-in-bits='16' id='8efea9e5'/>
+ <pointer-type-def type-id='50d9a3fa' size-in-bits='64' alignment-in-bits='64' id='fd01f598'/>
+ <pointer-type-def type-id='a84c031d' size-in-bits='64' alignment-in-bits='64' id='26a90f95'/>
+ <qualified-type-def type-id='50d9a3fa' const='yes' id='0fb3b55d'/>
+ <pointer-type-def type-id='bd54fe1a' size-in-bits='64' alignment-in-bits='64' id='3ccc2590'/>
+ <qualified-type-def type-id='3ccc2590' restrict='yes' id='af4b1b38'/>
+ <qualified-type-def type-id='a2185560' volatile='yes' id='ec67e496'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,25 @@
+enum opaque_enum;
+struct opaque_struct;
+
+typedef enum opaque_enum opaque_enum;
+typedef struct opaque_struct opaque_struct;
+
+void
+fn(opaque_struct *, opaque_enum *e);
+
+enum opaque_enum
+{
+ e0,
+ e1
+};
+
+struct opaque_struct
+{
+ opaque_enum m0;
+};
+
+void
+fn(opaque_struct * s, opaque_enum *e)
+{
+ s->m0 = *e;
+}
new file mode 100755
GIT binary patch
literal 15592
zcmeHOZEPGz8J@euiD?_#r38Y5+HI9eNtEoJT~Y#-nsXdGmtU{|dmTJ7DfeTVMD
z-0h`yMMY@<VMT%b;SV2DejpTy9|$2;{6cAi5+U)!MMAVlhzhmn1W34i8iaa0@9aG1
z_4Zs<2!W91wRYcmzh~Z=-I?>we0FMPI-N=>!VdMY+N6}q8NtB^sUf`MY7qDRYE<j)
z+!Vd7lr=(PH4>>vi~%VcI*C7LDnU%Su(eA^i~)|m_wct2NgTJ^1zFaO6tWL*#p@>C
zhQYK;Lrv^*#x7^<h_4!b;=#zRdhCs`^iK6WVDyN!E_jc_PU5{=VEWFPc-ysa&D4{a
z&D?=N5>MJGW!3{l4Wg&}$<U%FwD3(mpEn}SfA#67NcP22U#E{m{Pp7>*@iz2{(ZQT
zFb~Fi)$Qv1osnce6+CaT)~I`}&~JvGr@S+BvtB7^28)$e7&PZ*C##KmFy|MlK_u%h
z@ruj7w@|73)ygx0TBxgPrBHNR4fjEHdgjc@NpIX8caI@vO8=#Ck3i@rQDlF$M=S4<
ztQU-&<B{WM*3|#F8E@p@X88MZks<k{Upo=;rEeHpIGq?@`jD_5<4gY&He&qbn4pfu
zHUl;THUl;THUl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cGBTy@Wf
zBPyQ|CP;0|u@|?0%v6Z)QTcr*-};yj=2e~#wmoitZ9JlaM8E{8<mY2Q`+0e>0$z?#
I@1C^(7v)NDpa1{>
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,23 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test1.so'>
+ <elf-function-symbols>
+ <elf-symbol name='fn' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='' is-anonymous='yes' size-in-bits='32' alignment-in-bits='32' id='type-id-1'/>
+ <class-decl name='opaque_struct' size-in-bits='32' alignment-in-bits='32' is-struct='yes' visibility='default' id='type-id-2'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='m0' type-id='type-id-3' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <enum-decl name='opaque_enum' linkage-name='opaque_enum' id='type-id-4'>
+ <underlying-type type-id='type-id-1'/>
+ <enumerator name='e0' value='0'/>
+ <enumerator name='e1' value='1'/>
+ </enum-decl>
+ <typedef-decl name='opaque_enum' type-id='type-id-4' id='type-id-3'/>
+ <typedef-decl name='opaque_struct' type-id='type-id-2' id='type-id-5'/>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='type-id-6'/>
+ <pointer-type-def type-id='type-id-3' size-in-bits='64' alignment-in-bits='64' id='type-id-7'/>
+ <pointer-type-def type-id='type-id-5' size-in-bits='64' alignment-in-bits='64' id='type-id-8'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,23 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test1.so'>
+ <elf-function-symbols>
+ <elf-symbol name='fn' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='' is-anonymous='yes' size-in-bits='32' alignment-in-bits='32' id='811c9dc5'/>
+ <class-decl name='opaque_struct' size-in-bits='32' alignment-in-bits='32' is-struct='yes' visibility='default' id='6cde5052'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='m0' type-id='99fcd3a5' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <enum-decl name='opaque_enum' linkage-name='opaque_enum' id='55763a91'>
+ <underlying-type type-id='811c9dc5'/>
+ <enumerator name='e0' value='0'/>
+ <enumerator name='e1' value='1'/>
+ </enum-decl>
+ <typedef-decl name='opaque_enum' type-id='55763a91' id='99fcd3a5'/>
+ <typedef-decl name='opaque_struct' type-id='6cde5052' id='dae69ca1'/>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='f0981eeb'/>
+ <pointer-type-def type-id='99fcd3a5' size-in-bits='64' alignment-in-bits='64' id='0e0526e0'/>
+ <pointer-type-def type-id='dae69ca1' size-in-bits='64' alignment-in-bits='64' id='3f6e71d0'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,19 @@
+struct S0
+{
+ void* m0;
+};
+
+typedef const void* POINTER;
+
+struct S1
+{
+ POINTER m0;
+};
+
+void foo(struct S0* a __attribute__((unused)))
+{
+}
+
+void bar(struct S1* a __attribute__((unused)))
+{
+}
new file mode 100755
GIT binary patch
literal 15616
zcmeHOZD<_F8J;^^u@WaIxrtL(F3H9uV4HaFq{OLPLwu5a@;Q-YN0y->HJiP=mF~iw
zR_v}^Db%#oZLu(J{ilEW0r^!7{SiVS7z)LSi`_yBO8@i&N<v72XaZ5bS|x;R-gjo6
z(`s`Hp|qtxX3XyUJ@3pjvwI`&%y&zpBiT$wpllKkiZw}yqBayCfCuXih;F*?6n)Zn
z^P1^1+;MFL6}`%Zb96DQ<upB`8vzPCt7VlI2UD@+y-i=#B4{%12C@}w<xqHVJzdfH
zRy9RjmfSe5sN;${4)iJQ58AD&6~|wXYM<B6d$k`ZFnomKINuj7fNw(Q+o*p_x}Bit
z<|azCg)Yv?Jla9593S|x%vkWn<HmZ9**ruyBCKQ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J??~v;h?DMLc9sUI!%eV;ur|kd29w62&aplJWTc2F3aiRiyi`)*Ea1
z3rl-y%HL*^B_00*GID;5U%^t|pubRJ`;LA?@nd3mj$wSUF2^~-v_E9fpHXa2A|C6k
z12!qCz)wkQGW5S91J51g$9e|mEuYeWqu+?b_<Iz~E{MnZwpa3`q+-eY+70obPm?Jb
zFN)f?peUYmt!?)Q@%&4djK?}{hmMC|Ivz5w<Jbr7w~ESQZ4l47lI1E1tkdpo6XN%_
zHHtwz=!>KVpLE@OzmiHRV@i~<n0v|i<GMk!+Q@(R@wY$V0bKd{K;M(`R|b^yL@HrQ
U6x%k4_vJZDAzn&WN_;y0Q+>X1e*gdg
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,25 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test2.so'>
+ <elf-function-symbols>
+ <elf-symbol name='bar' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='foo' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <class-decl name='S0' size-in-bits='64' alignment-in-bits='64' is-struct='yes' visibility='default' id='type-id-1'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='m0' type-id='type-id-2' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <class-decl name='S1' size-in-bits='64' alignment-in-bits='64' is-struct='yes' visibility='default' id='type-id-3'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='m0' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <typedef-decl name='POINTER' type-id='type-id-5' id='type-id-4'/>
+ <pointer-type-def type-id='type-id-1' size-in-bits='64' alignment-in-bits='64' id='type-id-6'/>
+ <pointer-type-def type-id='type-id-3' size-in-bits='64' alignment-in-bits='64' id='type-id-7'/>
+ <qualified-type-def type-id='type-id-8' const='yes' id='type-id-9'/>
+ <pointer-type-def type-id='type-id-9' size-in-bits='64' alignment-in-bits='64' id='type-id-5'/>
+ <pointer-type-def type-id='type-id-8' size-in-bits='64' alignment-in-bits='64' id='type-id-2'/>
+ <type-decl name='void' id='type-id-8'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,25 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test2.so'>
+ <elf-function-symbols>
+ <elf-symbol name='bar' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='foo' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <class-decl name='S0' size-in-bits='64' alignment-in-bits='64' is-struct='yes' visibility='default' id='109cd6fe'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='m0' type-id='eaa32e2f' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <class-decl name='S1' size-in-bits='64' alignment-in-bits='64' is-struct='yes' visibility='default' id='119cd891'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='m0' type-id='8a34a235' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <typedef-decl name='POINTER' type-id='6e97a70c' id='8a34a235'/>
+ <pointer-type-def type-id='109cd6fe' size-in-bits='64' alignment-in-bits='64' id='842ea234'/>
+ <pointer-type-def type-id='119cd891' size-in-bits='64' alignment-in-bits='64' id='5e30a4f9'/>
+ <qualified-type-def type-id='48b5725f' const='yes' id='8581546e'/>
+ <pointer-type-def type-id='8581546e' size-in-bits='64' alignment-in-bits='64' id='6e97a70c'/>
+ <pointer-type-def type-id='48b5725f' size-in-bits='64' alignment-in-bits='64' id='eaa32e2f'/>
+ <type-decl name='void' id='48b5725f'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,12 @@
+<abi-corpus version='2.1' path='data/test-read-common/test3.so'>
+ <elf-function-symbols>
+ <elf-symbol name='__foo' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='__foo__' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='_fini' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='_init' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='foo' type='func-type' binding='weak-binding' visibility='default-visibility' alias='foo__,__foo__,__foo' is-defined='yes'/>
+ <elf-symbol name='foo__' type='func-type' binding='weak-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,12 @@
+<abi-corpus version='2.1' path='data/test-read-common/test3.so'>
+ <elf-function-symbols>
+ <elf-symbol name='__foo' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='__foo__' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='_fini' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='_init' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='foo' type='func-type' binding='weak-binding' visibility='default-visibility' alias='foo__,__foo__,__foo' is-defined='yes'/>
+ <elf-symbol name='foo__' type='func-type' binding='weak-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,14 @@
+<abi-corpus version='2.1' path='data/test-read-common/test4.so'>
+ <elf-function-symbols>
+ <elf-symbol name='cpy' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='char' size-in-bits='8' alignment-in-bits='8' id='type-id-1'/>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='type-id-2'/>
+ <pointer-type-def type-id='type-id-1' size-in-bits='64' alignment-in-bits='64' id='type-id-3'/>
+ <qualified-type-def type-id='type-id-3' restrict='yes' id='type-id-4'/>
+ <qualified-type-def type-id='type-id-1' const='yes' id='type-id-5'/>
+ <pointer-type-def type-id='type-id-5' size-in-bits='64' alignment-in-bits='64' id='type-id-6'/>
+ <qualified-type-def type-id='type-id-6' restrict='yes' id='type-id-7'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,14 @@
+<abi-corpus version='2.1' path='data/test-read-common/test4.so'>
+ <elf-function-symbols>
+ <elf-symbol name='cpy' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='char' size-in-bits='8' alignment-in-bits='8' id='a84c031d'/>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='f0981eeb'/>
+ <pointer-type-def type-id='a84c031d' size-in-bits='64' alignment-in-bits='64' id='26a90f95'/>
+ <qualified-type-def type-id='26a90f95' restrict='yes' id='266fe297'/>
+ <qualified-type-def type-id='a84c031d' const='yes' id='9b45d938'/>
+ <pointer-type-def type-id='9b45d938' size-in-bits='64' alignment-in-bits='64' id='80f4b756'/>
+ <qualified-type-def type-id='80f4b756' restrict='yes' id='9d26089a'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,41 @@
+// test function declaration passing const volatile modifier.
+long
+foo(char* c, const volatile long l);
+
+long
+foo(char* c, const volatile long l)
+{return *c + l;}
+
+// test function declaration passing variable arguments.
+void
+bar(const int c, ...)
+{}
+
+void
+baz(int c)
+{c = 0;}
+
+// test function declaration passing an enum type argument.
+enum E {e0, e1};
+
+void
+bar2(enum E e)
+{int c = e; ++c;}
+
+// test function declaration passing a typedef argument.
+typedef long long long_long;
+
+long_long
+baz2(int c)
+{c = 0; return c;}
+
+typedef const volatile unsigned long long useless_long_long;
+
+static useless_long_long
+this_should_not_be_seen_by_bidw()
+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_(DN)FX$}xsffR&>?wuoxvUMatipNKNwOx8XTe-2BnZ;y
zaSl51PbDfwHK5LZVO#uLyRsG8o2o};v*v{OQLV?GV2=#()RKOR;5=WATMEZD<y9S1
zUTGS))ckS`*WbGt!}a%GkKy`zcVf7%zp(v&GjLqUpfi#+t#!PHV+UR@5H|0VuwCC5
zHtrIJc9WMx*tprAjf;`;1E>6knpaz0d%e@fRSNpTmdkjx(ptx9s@GB_^FM@zSoR*D
z^C;!j<o75DoxV{zjS0^z9|fV`;UR+f(?jA<4rBF`yF?K57?`+zPl=Hpj&C%AkL>>>
zaIX1Z<Jteyw$l6eqs=wN_bG+x@5EHn$10&GG@zv3OUq}0Ydz}vL;Qnc@!IzS6#lfu
z(iFE;d^|5*e;r?i!u{j%2P*z&?Wklt-UUAG{FhWi4OAS@pKq3q*XKWNZ-(r0QIOuB
je^Cg<<GJRvQhlcSkM)gGyw-g0rpBxM-;4%BkH`NFTJliI
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,50 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test5.o'>
+ <elf-function-symbols>
+ <elf-symbol name='bar' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='bar2' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='baz' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='baz2' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ <elf-symbol name='foo' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='' is-anonymous='yes' size-in-bits='32' alignment-in-bits='32' id='type-id-1'/>
+ <type-decl name='char' size-in-bits='8' alignment-in-bits='8' id='type-id-2'/>
+ <enum-decl name='E' linkage-name='E' id='type-id-3'>
+ <underlying-type type-id='type-id-1'/>
+ <enumerator name='e0' value='0'/>
+ <enumerator name='e1' value='1'/>
+ </enum-decl>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='type-id-4'/>
+ <type-decl name='long int' size-in-bits='64' alignment-in-bits='64' id='type-id-5'/>
+ <type-decl name='long long int' size-in-bits='64' alignment-in-bits='64' id='type-id-6'/>
+ <type-decl name='long long unsigned int' size-in-bits='64' alignment-in-bits='64' id='type-id-7'/>
+ <typedef-decl name='long_long' type-id='type-id-6' id='type-id-8'/>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='type-id-9'/>
+ <pointer-type-def type-id='type-id-2' size-in-bits='64' alignment-in-bits='64' id='type-id-10'/>
+ <qualified-type-def type-id='type-id-4' const='yes' id='type-id-11'/>
+ <qualified-type-def type-id='type-id-5' const='yes' id='type-id-12'/>
+ <qualified-type-def type-id='type-id-12' volatile='yes' id='type-id-13'/>
+ <function-decl name='foo' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <parameter type-id='type-id-10'/>
+ <parameter type-id='type-id-13'/>
+ <return type-id='type-id-5'/>
+ </function-decl>
+ <function-decl name='baz2' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <parameter type-id='type-id-4'/>
+ <return type-id='type-id-8'/>
+ </function-decl>
+ <function-decl name='bar' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <parameter is-variadic='yes'/>
+ <return type-id='type-id-14'/>
+ </function-decl>
+ <function-decl name='bar2' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <parameter type-id='type-id-3'/>
+ <return type-id='type-id-14'/>
+ </function-decl>
+ <function-decl name='baz' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <parameter type-id='type-id-4'/>
+ <return type-id='type-id-14'/>
+ </function-decl>
+ <type-decl name='void' id='type-id-14'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,35 @@
+struct b0
+{
+ long long m0;
+ char m1;
+};
+
+struct b1
+{
+ double m0;
+ char m1;
+};
+
+struct s0;
+
+typedef int integer;
+typedef unsigned char byte;
+typedef integer (*mem_fun)(struct s0 *);
+
+struct s0
+{
+
+ struct b0 b0;
+ struct b1 b1;
+
+ integer m0;
+ byte m1;
+ mem_fun f;
+};
+
+integer
+fun(struct s0 *s0)
+{
+ s0->f = fun;
+ return s0->m0 + s0->m1;
+}
new file mode 100644
new file mode 100644
@@ -0,0 +1,8 @@
+#include "test7.h"
+
+void first_type_constructor(struct first_type *ft)
+{
+ ft->member0 = 0;
+ ft->member1 = 0;
+ ft->ctor = first_type_constructor;
+}
new file mode 100644
@@ -0,0 +1,24 @@
+#include <stdlib.h>
+
+typedef int integer;
+typedef unsigned char character;
+struct first_type;
+
+void
+first_type_constructor(struct first_type *ft);
+
+typedef void (*constructor)();
+
+struct first_type
+{
+ integer member0;
+ character member1;
+ constructor ctor;
+};
+
+struct second_type
+{
+ integer member0;
+ character member1;
+ constructor ctor;
+};
new file mode 100644
GIT binary patch
literal 2152
zcmbtV&ubG=5S~qA+F~1P6&34Y5s|hwo1}t@g07U>2%;bqd#Kdi&1<rl-Hp31+6dxJ
zEQ0jp*^7UGcMpY%y?F62@FeuAr`~jCGcVb!5kUuL-}lYWmziDieDT(ejHZDS4X#3u
zDJ#HUwuj9anvjQaSgve-t86~oue@5^-;M2rKABmdv$AWBka6q&&X2FzOzg+Uo&tPQ
zZBmLQUBw%mM?Hf03o2hIM?Mpk>?k?P(b0XJSdYUQ<{YmTQv3>Ys*5q1o6PBg6R4}q
z**{e8_iJIw|Ae`^-|G&arFw4|=kR>n!30U-pM{TO`3_G$^M{bV>sV&#PVZ5N08SGA
z(6Pf9o*z+l)N$0$s3z)RRGwR0`zZ2+<R^(V0>7rW{K&2OqN=;T1kyf3975I@bXhmX
zsaqjL^&ph}g}7$IO+{kbtJJN+twl|Qag60iM2`cv3QpihGHf|A2w~j~Be^EqO#z<p
zY!R0DEJMn_mP{+w15Xs~w%slUq2)A0F$$ex!?i8jtyylP&}w1}VR=O<A{iB{mb7A6
zKx4Jw$n}_AG#r4Xg@w!d^wRC+8NEDjl#G%-Uz#tMQT1uD(G;QU313=`na=C1<CG7e
zVgh79+oso5iN-vB2hgZiq&>Y0+Qx)7H8wo5h0asxBPGGI0N3*qFER_`xhe(_|ASE7
zEPVet$UUS!sDyJA@npgt_aZ+{g?@Z*{C(p+%{30<iLYl@bVl?Ekaoq0+Mcv*FmURf
zv#wAm8kQl&h6IDQ0EQh!VBiMu5qLCOF#JFY0|#1&q~$zhUh`W<GYoJ6vJFODM%35V
zL(3E0zW)hy%%_>EZ&#Hw8Fc5xT<ulGO(CHDo65ka$uGqT<}^pjRl8O8vusb!m{MGN
z43KpHIgFv2|C(RM+;mN9tNQQsE&2D@3!Gn~q=d}zh0Y~x1XV9}UQ5`Lq4&~1h@C1=
z#oj?MjGDS8tZ;t%UTXd-zlMNnrt@EN{v{R2XFA_T`=I@=4A}oD#;Sa^|3ST})i(Ek
mKm>*U63CR!r<xp!s3$u2*L$WIrRPU~DTDHxod4)A`M&@kYUQl}
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,42 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test7.o'>
+ <elf-function-symbols>
+ <elf-symbol name='first_type_constructor' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='char' size-in-bits='8' alignment-in-bits='8' id='type-id-1'/>
+ <class-decl name='first_type' size-in-bits='128' alignment-in-bits='32' is-struct='yes' visibility='default' id='type-id-2'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='member0' type-id='type-id-3' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='32'>
+ <var-decl name='member1' type-id='type-id-4' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='64'>
+ <var-decl name='ctor' type-id='type-id-5' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='type-id-6'/>
+ <type-decl name='long int' size-in-bits='64' alignment-in-bits='64' id='type-id-7'/>
+ <type-decl name='long long int' size-in-bits='64' alignment-in-bits='64' id='type-id-8'/>
+ <type-decl name='long long unsigned int' size-in-bits='64' alignment-in-bits='64' id='type-id-9'/>
+ <type-decl name='short int' size-in-bits='16' alignment-in-bits='16' id='type-id-10'/>
+ <type-decl name='signed char' size-in-bits='8' alignment-in-bits='8' id='type-id-11'/>
+ <typedef-decl name='character' type-id='type-id-12' id='type-id-4'/>
+ <typedef-decl name='constructor' type-id='type-id-13' id='type-id-5'/>
+ <typedef-decl name='integer' type-id='type-id-6' id='type-id-3'/>
+ <type-decl name='unsigned char' size-in-bits='8' alignment-in-bits='8' id='type-id-12'/>
+ <type-decl name='unsigned int' size-in-bits='32' alignment-in-bits='32' id='type-id-14'/>
+ <type-decl name='unsigned long int' size-in-bits='64' alignment-in-bits='64' id='type-id-15'/>
+ <type-decl name='unsigned short int' size-in-bits='16' alignment-in-bits='16' id='type-id-16'/>
+ <pointer-type-def type-id='type-id-2' size-in-bits='64' alignment-in-bits='64' id='type-id-17'/>
+ <pointer-type-def type-id='type-id-18' size-in-bits='64' alignment-in-bits='64' id='type-id-13'/>
+ <function-decl name='first_type_constructor' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <parameter type-id='type-id-17'/>
+ <return type-id='type-id-19'/>
+ </function-decl>
+ <function-type size-in-bits='64' alignment-in-bits='8' id='type-id-18'>
+ <return type-id='type-id-19'/>
+ </function-type>
+ <type-decl name='void' id='type-id-19'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,7 @@
+// Test generic pointer type passed as argument in function.
+// Compile this by doing gcc -gctf -Wall -c test8.cc
+
+void
+bar(void*)
+{
+}
new file mode 100644
GIT binary patch
literal 1496
zcmbtU!EVz)5S>j!TOg@Ig%DCXm=mcW>m(PV9#Bw3TLI#Llw$>JXWLk{<H+7t2@>Ll
z)LV}n`4kWz!if)n6E~P~cAaGvE-=!pXWq=4@y@RO?#c803S(e|!6R6D1_k&~S=#-=
z>_Z)DFg(2Yc6jmj=jG9tA786w(zRuFVO4P@-PGE{=Ma?$>!`XVnIueOw+LS=pmNzN
za?jIf1cAuFAE$}*gLyFb(@cc1^z$tA<0ue8bRwd-bvDgaCPm^anXB9%2_*`%h2W?a
zs^h}z@etr(Fxc~&2QP-ZUZ>03yzO<{-A)J9Ys%SFW>F$1O2oU1&3O1uS5T3F8)2Vl
zgGQM4%`9)~0DJQi*sQ^JY8#uE7`%fxDamzO9&a_?R|fU<eM}(#FG6*z@cq}S@R}K?
z6}*b}wuKkHC{9zM&C@JVJX%obV9L`Zfami>i2$D}TRg|cQgWt%(_n!Ic@7+hic6Z%
zw17`iB{|Nhl`9dRYX4+%#-~||GgWionT!RO<5$O-NF;UpZ`r{LG$V7POu@c3%KdAf
za&5Vb4q?vagJ*V<WxM=)7^Cz1SN;R!x;3et>HnD=OWfQJ#t3U$Ib_y!;(Z4<eDmDH
zxUucjhpWI9xla+>K>gzmq2JSd_r2V^9_X4bf2{fR1F^;BA7PNb$G)9}c0(7ut#SHM
z5!dhyPHo)YMER)uza|HT?h&1_%ct+nJ$r=8qV>XAF1l<9+(2s;zo}m;E;AQ~%l{23
CoNjCY
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,13 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test8.o'>
+ <elf-function-symbols>
+ <elf-symbol name='bar' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <pointer-type-def type-id='type-id-1' size-in-bits='64' alignment-in-bits='64' id='type-id-2'/>
+ <function-decl name='bar' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <parameter type-id='type-id-2'/>
+ <return type-id='type-id-1'/>
+ </function-decl>
+ <type-decl name='void' id='type-id-1'/>
+ </abi-instr>
+</abi-corpus>
new file mode 100644
@@ -0,0 +1,13 @@
+// test arrays type definitions
+struct S
+{
+ int a[5];
+ char *b[7];
+ double c[5][3];
+ int *(*d[10])[4];
+ char e[1];
+};
+
+int foo(struct S*)
+{
+}
new file mode 100644
GIT binary patch
literal 1864
zcmbtU&2G~`5FWQB4gCqBLI@}a!-ZBQc2X|T0}6_0D?l7TJyu{l+a$uVBYPt?h@YO2
zdh3w~;J{;4;w89o;sM~q4d&bIlC3Ec5}!2Q`TJ(PvtGZw|7df{amc`-yEL(km#925
z(VI$b(jqO;&i3Kg?ZekUj&?tN|1vXWl5QDAuV6#UT3&IFH>_7#d=|7kLv+Pu<udC4
z@?Dl=mRXinmILlE$LktPvqV(kwZ?MHh0pOi&B7>Yt^*!y^ld^LV+jjh7Wv$lmRT4j
zya(s%GE_lKLvgsJ3Zm}yabQl@Mma#`!DnhKulAqSe$#->iXpPDxbr#(d(fyX7)|Fa
zvW*&;g@)qdec{JG^jt5Z{&^M)6~yT&^%6;OnsnS@lJ`1^XuI$P6m^4)LTabOFcuV1
zn*{BpDf!*BFZ^&6j{GzWqFDHO7Wr{648mR~=*6|+AeWg4`o0vo%>8yC1Etp3*{(%$
zPg!@oh-j<T+HhC49`CHWjdic?)!p^_dZWSOu894C$a;N|$RNhCPd)~0kU4yK&apKh
z-tgE~8{?b{ATgYmPsrJ?I?D^Q<s%MWWgi5<py^(v`fjSVSlZ+S*na`)&d|4?r-i50
zxKBoK&`XwI^+E~;gZ*Qi3>Oau4$1luh`fB%mqEy@%*JciXj1G;@-SQS!aOIB=gN<?
zkAabwq*8c1qgpP5=!LdB$<P~QDUVf-$jd|=c%u7kFAMrY_5a@oE)Zsf3u2?Gjo<s%
zHgauTV*@_xVyN&#JIT_E{2LrIm(EI~f92m~Qn4oL7`}JnaQ@6~Xnq|e3nR^2vwToZ
zFSBk~K0Eb8p|6P<p0OXWf}c_`{iAji->dkohs;IIBLA~?+~$~#B7c{IxQ|UciS+}0
zpqI2CKP+$!-}q1K4N6t>pTl6xv%pp4n;$E3Yz#CXKTI3N`QZntQ|&Z*ubuG;@8tZ9
F`xjz3gGK-V
literal 0
HcmV?d00001
new file mode 100644
@@ -0,0 +1,57 @@
+<abi-corpus version='2.1' path='data/test-read-ctf/test9.o'>
+ <elf-function-symbols>
+ <elf-symbol name='foo' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
+ </elf-function-symbols>
+ <abi-instr address-size='64' language='LANG_C'>
+ <type-decl name='char' size-in-bits='8' alignment-in-bits='8' id='type-id-1'/>
+ <array-type-def dimensions='1' type-id='type-id-2' size-in-bits='448' alignment-in-bits='64' id='type-id-3'>
+ <subrange length='7' type-id='type-id-4' id='type-id-5'/>
+ </array-type-def>
+ <array-type-def dimensions='1' type-id='type-id-1' size-in-bits='infinite' alignment-in-bits='8' id='type-id-6'>
+ <subrange length='infinite' type-id='type-id-4' id='type-id-7'/>
+ </array-type-def>
+ <class-decl name='S' size-in-bits='2304' alignment-in-bits='32' is-struct='yes' visibility='default' id='type-id-8'>
+ <data-member access='public' layout-offset-in-bits='0'>
+ <var-decl name='a' type-id='type-id-9' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='192'>
+ <var-decl name='b' type-id='type-id-3' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='640'>
+ <var-decl name='c' type-id='type-id-10' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='1600'>
+ <var-decl name='d' type-id='type-id-11' visibility='default'/>
+ </data-member>
+ <data-member access='public' layout-offset-in-bits='2240'>
+ <var-decl name='e' type-id='type-id-6' visibility='default'/>
+ </data-member>
+ </class-decl>
+ <type-decl name='double' size-in-bits='64' alignment-in-bits='64' id='type-id-12'/>
+ <array-type-def dimensions='1' type-id='type-id-12' size-in-bits='320' alignment-in-bits='64' id='type-id-13'>
+ <subrange length='5' type-id='type-id-4' id='type-id-14'/>
+ </array-type-def>
+ <array-type-def dimensions='1' type-id='type-id-13' size-in-bits='960' alignment-in-bits='64' id='type-id-10'>
+ <subrange length='3' type-id='type-id-4' id='type-id-15'/>
+ </array-type-def>
+ <type-decl name='int' size-in-bits='32' alignment-in-bits='32' id='type-id-16'/>
+ <array-type-def dimensions='1' type-id='type-id-17' size-in-bits='256' alignment-in-bits='64' id='type-id-18'>
+ <subrange length='4' type-id='type-id-4' id='type-id-19'/>
+ </array-type-def>
+ <array-type-def dimensions='1' type-id='type-id-20' size-in-bits='640' alignment-in-bits='64' id='type-id-11'>
+ <subrange length='10' type-id='type-id-4' id='type-id-21'/>
+ </array-type-def>
+ <array-type-def dimensions='1' type-id='type-id-16' size-in-bits='160' alignment-in-bits='32' id='type-id-9'>
+ <subrange length='5' type-id='type-id-4' id='type-id-14'/>
+ </array-type-def>
+ <type-decl name='unsigned long int' size-in-bits='64' alignment-in-bits='64' id='type-id-4'/>
+ <pointer-type-def type-id='type-id-8' size-in-bits='64' alignment-in-bits='64' id='type-id-22'/>
+ <pointer-type-def type-id='type-id-1' size-in-bits='64' alignment-in-bits='64' id='type-id-2'/>
+ <pointer-type-def type-id='type-id-16' size-in-bits='64' alignment-in-bits='64' id='type-id-17'/>
+ <pointer-type-def type-id='type-id-18' size-in-bits='64' alignment-in-bits='64' id='type-id-20'/>
+ <function-decl name='foo' visibility='default' binding='global' size-in-bits='64' alignment-in-bits='8'>
+ <parameter type-id='type-id-22'/>
+ <return type-id='type-id-16'/>
+ </function-decl>
+ </abi-instr>
+</abi-corpus>
deleted file mode 100755
GIT binary patch
literal 0
HcmV?d00001
literal 10976
zcmeHNeQX@X6`$Sp$2pGAmk+=pK#q_IL*ujKd|*I<Jtr5|)Cp<g(57uzuYG6xQv1%m
z+k=FPlFER33ZaRF+Ng~xTD29bgo@Ovq@^lOLy1rkHK+xoQprMuCJ@xLq^a8i?(fac
zJMXP85LM;BjI{GU=6%hZx!pIrcYmULqpoR!n=Wn<lBzN#%j<=RE@cTJOwl3g&|f2#
ziW;!1aj~4KFosjgG{cZGV*pm+>d-w#hi*!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!AT(9h=W`YRpN#4kYAPM2
zcz9jj!kFJbpTDMPQfM5fN6pa8e+L78{n9y2IcR1@1zC^b*?>ORo6Sl;xZY|yC9D4i
zMz(nVTnDbWKz%xZk<B(-{>J((ekO4C&oBgpalhye<^O=6>C<QSW#`d9rS$*B8(S#^
zebMXhAdf`fSl}s~4GacIvGP3nuc!}NR|FISq*$l)gZcaWrJnyK0R<-gFfc`_*raaU
w<7(qx4KDpFj`t1U*XjPmYcCa5_nJD2zt4^oKS1JaQd$2GQBT1NC<I9HUo^gaj{pDw
@@ -1,12 +1,10 @@
-<abi-corpus version='2.1' path='data/test-read-dwarf/PR26261/PR26261-exe'>
+<abi-corpus version='2.1' path='data/test-read-common/PR26261/PR26261-exe'>
<elf-needed>
<dependency name='libc.so.6'/>
</elf-needed>
<elf-function-symbols>
<elf-symbol name='__libc_csu_fini' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
<elf-symbol name='__libc_csu_init' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
- <elf-symbol name='_fini' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
- <elf-symbol name='_init' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
<elf-symbol name='_start' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
<elf-symbol name='fun_obja' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
<elf-symbol name='fun_objb' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
@@ -16,18 +14,18 @@
<elf-variable-symbols>
<elf-symbol name='_IO_stdin_used' size='4' type='object-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
</elf-variable-symbols>
- <abi-instr address-size='64' path='PR26261-main.c' comp-dir-path='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261' language='LANG_C89'>
+ <abi-instr address-size='64' path='PR26261-main.c' comp-dir-path='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261' language='LANG_C11'>
<pointer-type-def type-id='type-id-1' size-in-bits='64' id='type-id-2'/>
<pointer-type-def type-id='type-id-2' size-in-bits='64' id='type-id-3'/>
- <function-decl name='wrapped_call' mangled-name='wrapped_call' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-main.c' line='18' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='wrapped_call'>
- <parameter type-id='type-id-4' name='fun' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-main.c' line='18' column='1'/>
- <parameter type-id='type-id-5' name='a' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-main.c' line='19' column='1'/>
- <parameter type-id='type-id-5' name='b' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-main.c' line='20' column='1'/>
+ <function-decl name='wrapped_call' mangled-name='wrapped_call' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-main.c' line='18' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='wrapped_call'>
+ <parameter type-id='type-id-4' name='fun' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-main.c' line='18' column='1'/>
+ <parameter type-id='type-id-5' name='a' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-main.c' line='19' column='1'/>
+ <parameter type-id='type-id-5' name='b' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-main.c' line='20' column='1'/>
<return type-id='type-id-6'/>
</function-decl>
- <function-decl name='main' mangled-name='main' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-main.c' line='27' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='main'>
- <parameter type-id='type-id-5' name='argc' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-main.c' line='27' column='1'/>
- <parameter type-id='type-id-3' name='argv' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-main.c' line='27' column='1'/>
+ <function-decl name='main' mangled-name='main' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-main.c' line='27' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='main'>
+ <parameter type-id='type-id-5' name='argc' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-main.c' line='27' column='1'/>
+ <parameter type-id='type-id-3' name='argv' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-main.c' line='27' column='1'/>
<return type-id='type-id-5'/>
</function-decl>
<function-type size-in-bits='64' id='type-id-7'>
@@ -36,44 +34,44 @@
<return type-id='type-id-6'/>
</function-type>
</abi-instr>
- <abi-instr address-size='64' path='PR26261-obja.c' comp-dir-path='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261' language='LANG_C89'>
+ <abi-instr address-size='64' path='PR26261-obja.c' comp-dir-path='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261' language='LANG_C11'>
<type-decl name='int' size-in-bits='32' id='type-id-5'/>
- <typedef-decl name='fn_ptr_type_a_t' type-id='type-id-4' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-obja.h' line='1' column='1' id='type-id-8'/>
- <typedef-decl name='fn_ptr_type_a2_t' type-id='type-id-4' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-obja.h' line='3' column='1' id='type-id-9'/>
- <class-decl name='SA' size-in-bits='192' is-struct='yes' visibility='default' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-obja.h' line='5' column='1' id='type-id-10'>
+ <typedef-decl name='fn_ptr_type_a_t' type-id='type-id-4' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-obja.h' line='1' column='1' id='type-id-8'/>
+ <typedef-decl name='fn_ptr_type_a2_t' type-id='type-id-4' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-obja.h' line='3' column='1' id='type-id-9'/>
+ <class-decl name='SA' size-in-bits='192' is-struct='yes' visibility='default' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-obja.h' line='5' column='1' id='type-id-10'>
<data-member access='public' layout-offset-in-bits='0'>
- <var-decl name='m1' type-id='type-id-5' visibility='default' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-obja.h' line='7' column='1'/>
+ <var-decl name='m1' type-id='type-id-5' visibility='default' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-obja.h' line='7' column='1'/>
</data-member>
<data-member access='public' layout-offset-in-bits='64'>
- <var-decl name='m2' type-id='type-id-8' visibility='default' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-obja.h' line='8' column='1'/>
+ <var-decl name='m2' type-id='type-id-8' visibility='default' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-obja.h' line='8' column='1'/>
</data-member>
<data-member access='public' layout-offset-in-bits='128'>
- <var-decl name='m3' type-id='type-id-9' visibility='default' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-obja.h' line='9' column='1'/>
+ <var-decl name='m3' type-id='type-id-9' visibility='default' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-obja.h' line='9' column='1'/>
</data-member>
</class-decl>
<pointer-type-def type-id='type-id-10' size-in-bits='64' id='type-id-11'/>
<pointer-type-def type-id='type-id-7' size-in-bits='64' id='type-id-4'/>
- <function-decl name='fun_obja' mangled-name='fun_obja' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-obja.c' line='4' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='fun_obja'>
- <parameter type-id='type-id-11' name='s' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-obja.c' line='4' column='1'/>
+ <function-decl name='fun_obja' mangled-name='fun_obja' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-obja.c' line='4' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='fun_obja'>
+ <parameter type-id='type-id-11' name='s' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-obja.c' line='4' column='1'/>
<return type-id='type-id-6'/>
</function-decl>
<type-decl name='void' id='type-id-6'/>
</abi-instr>
- <abi-instr address-size='64' path='PR26261-objb.c' comp-dir-path='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261' language='LANG_C89'>
+ <abi-instr address-size='64' path='PR26261-objb.c' comp-dir-path='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261' language='LANG_C11'>
<type-decl name='char' size-in-bits='8' id='type-id-1'/>
- <typedef-decl name='fn_ptr_type_b_t' type-id='type-id-12' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-objb.h' line='1' column='1' id='type-id-13'/>
- <class-decl name='SB' size-in-bits='128' is-struct='yes' visibility='default' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-objb.h' line='3' column='1' id='type-id-14'>
+ <typedef-decl name='fn_ptr_type_b_t' type-id='type-id-12' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-objb.h' line='1' column='1' id='type-id-13'/>
+ <class-decl name='SB' size-in-bits='128' is-struct='yes' visibility='default' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-objb.h' line='3' column='1' id='type-id-14'>
<data-member access='public' layout-offset-in-bits='0'>
- <var-decl name='m1' type-id='type-id-5' visibility='default' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-objb.h' line='5' column='1'/>
+ <var-decl name='m1' type-id='type-id-5' visibility='default' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-objb.h' line='5' column='1'/>
</data-member>
<data-member access='public' layout-offset-in-bits='64'>
- <var-decl name='m2' type-id='type-id-13' visibility='default' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-objb.h' line='6' column='1'/>
+ <var-decl name='m2' type-id='type-id-13' visibility='default' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-objb.h' line='6' column='1'/>
</data-member>
</class-decl>
<pointer-type-def type-id='type-id-14' size-in-bits='64' id='type-id-15'/>
<pointer-type-def type-id='type-id-16' size-in-bits='64' id='type-id-12'/>
- <function-decl name='fun_objb' mangled-name='fun_objb' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-objb.c' line='4' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='fun_objb'>
- <parameter type-id='type-id-15' name='s' filepath='/home/dodji/git/libabigail/patches/tests/data/test-read-dwarf/PR26261/PR26261-objb.c' line='4' column='1'/>
+ <function-decl name='fun_objb' mangled-name='fun_objb' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-objb.c' line='4' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='fun_objb'>
+ <parameter type-id='type-id-15' name='s' filepath='/home/byby/oracle/src/libabigail-upstream/tests/data/test-read-common/PR26261/PR26261-objb.c' line='4' column='1'/>
<return type-id='type-id-6'/>
</function-decl>
<function-type size-in-bits='64' id='type-id-16'>
@@ -1,15 +1,15 @@
-<abi-corpus version='2.1' path='data/test-read-dwarf/PR27700/test-PR27700.o'>
+<abi-corpus version='2.1' path='data/test-read-common/PR27700/test-PR27700.o'>
<elf-function-symbols>
<elf-symbol name='foo' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
</elf-function-symbols>
- <abi-instr address-size='64' path='test-PR27700.c' comp-dir-path='/home/dodji/git/libabigail/PR27700/tests/data/test-read-dwarf/PR27700' language='LANG_C11'>
+ <abi-instr address-size='64' path='tests/data/test-read-common/PR27700/test-PR27700.c' comp-dir-path='/home/byby/oracle/src/libabigail-upstream' language='LANG_C11'>
<type-decl name='unnamed-enum-underlying-type-32' is-anonymous='yes' size-in-bits='32' alignment-in-bits='32' id='9cac1fee'/>
- <enum-decl name='foo' filepath='include-dir/priv.h' line='1' column='1' id='022218d8'>
+ <enum-decl name='foo' filepath='tests/data/test-read-common/PR27700/include-dir/priv.h' line='1' column='1' id='022218d8'>
<underlying-type type-id='9cac1fee'/>
</enum-decl>
<pointer-type-def type-id='022218d8' size-in-bits='64' id='8750e847'/>
- <function-decl name='foo' mangled-name='foo' filepath='/home/dodji/git/libabigail/PR27700/tests/data/test-read-dwarf/PR27700/test-PR27700.c' line='4' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='foo'>
- <parameter type-id='8750e847' name='c' filepath='/home/dodji/git/libabigail/PR27700/tests/data/test-read-dwarf/PR27700/test-PR27700.c' line='4' column='1'/>
+ <function-decl name='foo' mangled-name='foo' filepath='tests/data/test-read-common/PR27700/test-PR27700.c' line='6' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='foo'>
+ <parameter type-id='8750e847' name='c' filepath='tests/data/test-read-common/PR27700/test-PR27700.c' line='6' column='1'/>
<return type-id='48b5725f'/>
</function-decl>
<type-decl name='void' id='48b5725f'/>
deleted file mode 100644
GIT binary patch
literal 0
HcmV?d00001
literal 3248
zcmb_e&2Jl35TCbe$1dAAAFfJ6in1V}DZ*<zg{A~0xCHVczM`N=Ac3s4_t{>s*VTGc
zLJ^`85>f>cL2!d365@u0#6N(zapR7-AaUhZi37~+&T}@e8x;Yg_|433X5P%3_py2Z
zxfeDJAwZFUH8|1~3h-^=NN&Vp1I|Dh_O@>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1KHn@0Hs*gkBu_l}x@(F9Ia+sSM35^3@%9O#Okb+YGc;Qn9
zhsmp(c$ZLHO6<er!X7(JdbaqE1am&26C^Veo?OKuIdMq*<Jg49g_L+h*vmrFxlL|7
z>Z<~$_~d!tOyE@auCPB6Qq7a>KPzHLlun4>JOMWaPCX|31bcL65IRkiVGzrn)IxV0
zf=zD-?B-|$cHs6MyX`g)y9b`%8KN)Jon|v|-<WYbf#Y}GSxVpYT}i<bV7G>Yfs60Z
z_J^Ts<Eyhqq0@R@ByxKPoxmBmqVfMJR*+A7EB8~Ts|#gvkAzLJ$?+5#gsCs;r1n%k
zeLCqLJSu-()JHKhWc{CJ(74wmL?3+mE3GF%)W3`WU*T7Q)4d`{-dX(Dh{iU~>YB*0
zBEWB>sOhA}?x9P?DEb!xu1%?trpCUEXj=chY)q7V>Yu(=YX5D-)SSfpOMneB5<`tW
zKwnz@&qaN?PgI}YwOao+Vw6+%iE1>S5s&dJ2?#0cOZhh9Y5YG0-+l=HuHY+Sz|{*W
z0%Tno|ApYsd^-@+1-~W(g_P@;@TaJx?cWb6`$zu<k}vm_`cZ3B?z*VICmN>jH~q_~
hd^(e~rQV~aa6A!<$*iuQ@}}|s5dD8MVaAHe{|}8}$8i7v
@@ -1,16 +1,16 @@
-<abi-corpus version='2.1' path='data/test-read-dwarf/test-PR26568-1.o'>
+<abi-corpus version='2.1' path='data/test-read-common/test-PR26568-1.o'>
<elf-function-symbols>
<elf-symbol name='fun' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
</elf-function-symbols>
- <abi-instr address-size='64' path='test-PR26568-1.c' comp-dir-path='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf' language='LANG_C89'>
+ <abi-instr address-size='64' path='tests/data/test-read-common/test-PR26568-1.c' comp-dir-path='/home/byby/oracle/src/libabigail-upstream' language='LANG_C11'>
<type-decl name='int' size-in-bits='32' id='type-id-1'/>
<type-decl name='long int' size-in-bits='64' id='type-id-2'/>
- <class-decl name='A' size-in-bits='64' is-struct='yes' visibility='default' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-1.c' line='1' column='1' id='type-id-3'>
+ <class-decl name='A' size-in-bits='64' is-struct='yes' visibility='default' filepath='tests/data/test-read-common/test-PR26568-1.c' line='4' column='1' id='type-id-3'>
<data-member access='public' layout-offset-in-bits='0'>
<var-decl name='' type-id='type-id-4' visibility='default'/>
</data-member>
</class-decl>
- <union-decl name='__anonymous_union__' size-in-bits='64' is-anonymous='yes' visibility='default' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-1.c' line='2' column='1' id='type-id-4'>
+ <union-decl name='__anonymous_union__' size-in-bits='64' is-anonymous='yes' visibility='default' filepath='tests/data/test-read-common/test-PR26568-1.c' line='5' column='1' id='type-id-4'>
<data-member access='public'>
<var-decl name='' type-id='type-id-5' visibility='default'/>
</data-member>
@@ -18,19 +18,19 @@
<var-decl name='' type-id='type-id-6' visibility='default'/>
</data-member>
</union-decl>
- <class-decl name='__anonymous_struct__' size-in-bits='32' is-struct='yes' is-anonymous='yes' visibility='default' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-1.c' line='3' column='1' id='type-id-5'>
+ <class-decl name='__anonymous_struct__' size-in-bits='32' is-struct='yes' is-anonymous='yes' visibility='default' filepath='tests/data/test-read-common/test-PR26568-1.c' line='6' column='1' id='type-id-5'>
<data-member access='public' layout-offset-in-bits='0'>
- <var-decl name='x' type-id='type-id-1' visibility='default' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-1.c' line='4' column='1'/>
+ <var-decl name='x' type-id='type-id-1' visibility='default' filepath='tests/data/test-read-common/test-PR26568-1.c' line='7' column='1'/>
</data-member>
</class-decl>
- <class-decl name='__anonymous_struct__1' size-in-bits='64' is-struct='yes' is-anonymous='yes' visibility='default' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-1.c' line='6' column='1' id='type-id-6'>
+ <class-decl name='__anonymous_struct__1' size-in-bits='64' is-struct='yes' is-anonymous='yes' visibility='default' filepath='tests/data/test-read-common/test-PR26568-1.c' line='9' column='1' id='type-id-6'>
<data-member access='public' layout-offset-in-bits='0'>
- <var-decl name='y' type-id='type-id-2' visibility='default' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-1.c' line='7' column='1'/>
+ <var-decl name='y' type-id='type-id-2' visibility='default' filepath='tests/data/test-read-common/test-PR26568-1.c' line='10' column='1'/>
</data-member>
</class-decl>
<pointer-type-def type-id='type-id-3' size-in-bits='64' id='type-id-7'/>
- <function-decl name='fun' mangled-name='fun' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-1.c' line='12' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='fun'>
- <parameter type-id='type-id-7' name='a' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-1.c' line='12' column='1'/>
+ <function-decl name='fun' mangled-name='fun' filepath='tests/data/test-read-common/test-PR26568-1.c' line='15' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='fun'>
+ <parameter type-id='type-id-7' name='a' filepath='tests/data/test-read-common/test-PR26568-1.c' line='15' column='1'/>
<return type-id='type-id-8'/>
</function-decl>
<type-decl name='void' id='type-id-8'/>
deleted file mode 100644
GIT binary patch
literal 0
HcmV?d00001
literal 2824
zcmbtVQHvW@6h3!mlT3CtF`KB}WqlaI(k^r++wE?Mm9433-4sh%7W$x2)=6@cj3$#Z
znXRc(6clk0L_rZnw9p4%efCN4q2P}YU-|=lEBK)2%-owy?oKJ_fw}kG@0{<PbMM?U
z^TCyCuW5{d6b6@Iwvs47Gdt58k=lR?l;KA6_+j(-?xW^sR~|ixaMGH;7`bd_LDyLG
zxODTk`)F8*j7AjuM1s?iF&?x9rZrI2C%|-4kh_ra{17yQW!}W4eg{~V6o8D8p(%SA
z490Gwma}QtBhcs``M?%QC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Q&A|-#?y3E
T_fK)t`1eHp_ovKQQThJ@<ln>C
@@ -1,11 +1,11 @@
-<abi-corpus version='2.1' path='data/test-read-dwarf/test-PR26568-2.o'>
+<abi-corpus version='2.1' path='data/test-read-common/test-PR26568-2.o'>
<elf-function-symbols>
<elf-symbol name='fun' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
</elf-function-symbols>
- <abi-instr address-size='64' path='test-PR26568-2.c' comp-dir-path='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf' language='LANG_C89'>
+ <abi-instr address-size='64' path='tests/data/test-read-common/test-PR26568-2.c' comp-dir-path='/home/byby/oracle/src/libabigail-upstream' language='LANG_C11'>
<type-decl name='int' size-in-bits='32' id='type-id-1'/>
<type-decl name='long int' size-in-bits='64' id='type-id-2'/>
- <union-decl name='A' size-in-bits='64' visibility='default' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-2.c' line='1' column='1' id='type-id-3'>
+ <union-decl name='A' size-in-bits='64' visibility='default' filepath='tests/data/test-read-common/test-PR26568-2.c' line='4' column='1' id='type-id-3'>
<data-member access='public'>
<var-decl name='' type-id='type-id-4' visibility='default'/>
</data-member>
@@ -13,19 +13,19 @@
<var-decl name='' type-id='type-id-5' visibility='default'/>
</data-member>
</union-decl>
- <class-decl name='__anonymous_struct__' size-in-bits='32' is-struct='yes' is-anonymous='yes' visibility='default' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-2.c' line='2' column='1' id='type-id-4'>
+ <class-decl name='__anonymous_struct__' size-in-bits='32' is-struct='yes' is-anonymous='yes' visibility='default' filepath='tests/data/test-read-common/test-PR26568-2.c' line='5' column='1' id='type-id-4'>
<data-member access='public' layout-offset-in-bits='0'>
- <var-decl name='x' type-id='type-id-1' visibility='default' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-2.c' line='3' column='1'/>
+ <var-decl name='x' type-id='type-id-1' visibility='default' filepath='tests/data/test-read-common/test-PR26568-2.c' line='6' column='1'/>
</data-member>
</class-decl>
- <class-decl name='__anonymous_struct__1' size-in-bits='64' is-struct='yes' is-anonymous='yes' visibility='default' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-2.c' line='5' column='1' id='type-id-5'>
+ <class-decl name='__anonymous_struct__1' size-in-bits='64' is-struct='yes' is-anonymous='yes' visibility='default' filepath='tests/data/test-read-common/test-PR26568-2.c' line='8' column='1' id='type-id-5'>
<data-member access='public' layout-offset-in-bits='0'>
- <var-decl name='y' type-id='type-id-2' visibility='default' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-2.c' line='6' column='1'/>
+ <var-decl name='y' type-id='type-id-2' visibility='default' filepath='tests/data/test-read-common/test-PR26568-2.c' line='9' column='1'/>
</data-member>
</class-decl>
<pointer-type-def type-id='type-id-3' size-in-bits='64' id='type-id-6'/>
- <function-decl name='fun' mangled-name='fun' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-2.c' line='10' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='fun'>
- <parameter type-id='type-id-6' name='a' filepath='/home/dodji/git/libabigail/fixes/tests/data/test-read-dwarf/test-PR26568-2.c' line='10' column='1'/>
+ <function-decl name='fun' mangled-name='fun' filepath='tests/data/test-read-common/test-PR26568-2.c' line='13' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='fun'>
+ <parameter type-id='type-id-6' name='a' filepath='tests/data/test-read-common/test-PR26568-2.c' line='13' column='1'/>
<return type-id='type-id-7'/>
</function-decl>
<type-decl name='void' id='type-id-7'/>
@@ -1,12 +1,12 @@
-<abi-corpus version='2.1' path='data/test-read-dwarf/test3.so' soname='test3.so.1'>
+<abi-corpus version='2.1' path='data/test-read-common/test3.so' soname='test3.so.1'>
<elf-needed>
<dependency name='libc.so.6'/>
</elf-needed>
<elf-function-symbols>
<elf-symbol name='__foo' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
</elf-function-symbols>
- <abi-instr address-size='64' path='test3.c' comp-dir-path='/home/skumari/Tasks/source_repo/dodji/libabigail/tests/data/test-read-dwarf' language='LANG_C89'>
- <function-decl name='__foo' mangled-name='__foo' filepath='/home/skumari/Tasks/source_repo/dodji/libabigail/tests/data/test-read-dwarf/test3.c' line='8' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='__foo'>
+ <abi-instr address-size='64' path='test3.c' comp-dir-path='/home/byby/oracle/src/libabigail/tests/data/test-read-common' language='LANG_C89'>
+ <function-decl name='__foo' mangled-name='__foo' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test3.c' line='23' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='__foo'>
<return type-id='48b5725f'/>
</function-decl>
<type-decl name='void' id='48b5725f'/>
@@ -1,4 +1,4 @@
-<abi-corpus version='2.1' path='data/test-read-dwarf/test3.so' soname='test3.so.1'>
+<abi-corpus version='2.1' path='data/test-read-common/test3.so' soname='test3.so.1'>
<elf-needed>
<dependency name='libc.so.6'/>
</elf-needed>
@@ -9,8 +9,8 @@
<elf-symbol name='foo' type='func-type' binding='weak-binding' visibility='default-visibility' is-defined='yes'/>
<elf-symbol name='foo__' type='func-type' binding='weak-binding' visibility='default-visibility' is-defined='yes'/>
</elf-function-symbols>
- <abi-instr address-size='64' path='test3.c' comp-dir-path='/home/skumari/Tasks/source_repo/dodji/libabigail/tests/data/test-read-dwarf' language='LANG_C89'>
- <function-decl name='__foo' mangled-name='__foo' filepath='/home/skumari/Tasks/source_repo/dodji/libabigail/tests/data/test-read-dwarf/test3.c' line='8' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='foo'>
+ <abi-instr address-size='64' path='test3.c' comp-dir-path='/home/byby/oracle/src/libabigail/tests/data/test-read-common' language='LANG_C89'>
+ <function-decl name='__foo' mangled-name='__foo' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test3.c' line='23' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='foo'>
<return type-id='48b5725f'/>
</function-decl>
<type-decl name='void' id='48b5725f'/>
@@ -1,12 +1,12 @@
-<abi-corpus version='2.1' path='data/test-read-dwarf/test3.so' soname='test3.so.1'>
+<abi-corpus version='2.1' path='data/test-read-common/test3.so' soname='test3.so.1'>
<elf-needed>
<dependency name='libc.so.6'/>
</elf-needed>
<elf-function-symbols>
<elf-symbol name='foo' type='func-type' binding='weak-binding' visibility='default-visibility' is-defined='yes'/>
</elf-function-symbols>
- <abi-instr address-size='64' path='test3.c' comp-dir-path='/home/skumari/Tasks/source_repo/dodji/libabigail/tests/data/test-read-dwarf' language='LANG_C89'>
- <function-decl name='__foo' mangled-name='__foo' filepath='/home/skumari/Tasks/source_repo/dodji/libabigail/tests/data/test-read-dwarf/test3.c' line='8' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='foo'>
+ <abi-instr address-size='64' path='test3.c' comp-dir-path='/home/byby/oracle/src/libabigail/tests/data/test-read-common' language='LANG_C89'>
+ <function-decl name='__foo' mangled-name='__foo' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test3.c' line='23' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='foo'>
<return type-id='48b5725f'/>
</function-decl>
<type-decl name='void' id='48b5725f'/>
@@ -1,4 +1,4 @@
-<abi-corpus version='2.1' path='data/test-read-dwarf/test3.so' soname='test3.so.1'>
+<abi-corpus version='2.1' path='data/test-read-common/test3.so' soname='test3.so.1'>
<elf-needed>
<dependency name='libc.so.6'/>
</elf-needed>
deleted file mode 100644
@@ -1,11 +0,0 @@
-// Test file for creating multiple alias for a symbol
-
-void __foo(void);
-void foo(void) __attribute__((weak, alias("__foo")));
-void foo__(void) __attribute__((weak, alias("__foo")));
-void __foo__(void) __attribute__((alias("__foo")));
-
-void __foo(void)
-{
-
-}
deleted file mode 100755
GIT binary patch
literal 0
HcmV?d00001
literal 8851
zcmeHMeQX>@6`#Aa<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O9JQ?P7JFU~SJR!(P4$28RLW8Eh}a{v=hzPhJY$bLH39COdPMlqM0!*e)4_3{?a
z*7{i8R4I;maI}A9KpVJl7PGqi38-$^1#L>t8<@sD`<V;<Bk;*U(;&S|+(W~UoarCd
z9vK{bY+y_q>pwF*fI1*)i@M$`D=ZSYZu;1tS>`EU%;pL;-XyP^4-U!{qcQTXKLPDa
NGxzm*6T@y2`@a>G9{B(O
@@ -1,4 +1,4 @@
-<abi-corpus version='2.1' path='data/test-read-dwarf/test3.so' soname='test3.so.1'>
+<abi-corpus version='2.1' path='data/test-read-common/test3.so' soname='test3.so.1'>
<elf-needed>
<dependency name='libc.so.6'/>
</elf-needed>
@@ -10,8 +10,8 @@
<elf-symbol name='foo' type='func-type' binding='weak-binding' visibility='default-visibility' is-defined='yes'/>
<elf-symbol name='foo__' type='func-type' binding='weak-binding' visibility='default-visibility' is-defined='yes'/>
</elf-function-symbols>
- <abi-instr address-size='64' path='test3.c' comp-dir-path='/home/skumari/Tasks/source_repo/dodji/libabigail/tests/data/test-read-dwarf' language='LANG_C89'>
- <function-decl name='__foo' mangled-name='__foo' filepath='/home/skumari/Tasks/source_repo/dodji/libabigail/tests/data/test-read-dwarf/test3.c' line='8' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='__foo'>
+ <abi-instr address-size='64' path='test3.c' comp-dir-path='/home/byby/oracle/src/libabigail/tests/data/test-read-common' language='LANG_C89'>
+ <function-decl name='__foo' mangled-name='__foo' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test3.c' line='23' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='__foo'>
<return type-id='type-id-1'/>
</function-decl>
<type-decl name='void' id='type-id-1'/>
@@ -1,4 +1,4 @@
-<abi-corpus version='2.1' path='data/test-read-dwarf/test3.so' soname='test3.so.1'>
+<abi-corpus version='2.1' path='data/test-read-common/test3.so' soname='test3.so.1'>
<elf-needed>
<dependency name='libc.so.6'/>
</elf-needed>
@@ -10,8 +10,8 @@
<elf-symbol name='foo' type='func-type' binding='weak-binding' visibility='default-visibility' is-defined='yes'/>
<elf-symbol name='foo__' type='func-type' binding='weak-binding' visibility='default-visibility' is-defined='yes'/>
</elf-function-symbols>
- <abi-instr address-size='64' path='test3.c' comp-dir-path='/home/skumari/Tasks/source_repo/dodji/libabigail/tests/data/test-read-dwarf' language='LANG_C89'>
- <function-decl name='__foo' mangled-name='__foo' filepath='/home/skumari/Tasks/source_repo/dodji/libabigail/tests/data/test-read-dwarf/test3.c' line='8' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='__foo'>
+ <abi-instr address-size='64' path='test3.c' comp-dir-path='/home/byby/oracle/src/libabigail/tests/data/test-read-common' language='LANG_C89'>
+ <function-decl name='__foo' mangled-name='__foo' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test3.c' line='23' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='__foo'>
<return type-id='48b5725f'/>
</function-decl>
<type-decl name='void' id='48b5725f'/>
deleted file mode 100644
@@ -1,14 +0,0 @@
-// Test file for restrict (needs to be compiled by a GCC that actually emits
-// DW_TAG_restrict_type. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59051
-//
-// gcc -gdwarf-3 -std=c99 -shared -nostartfiles -o test4.so test4.c
-
-char *
-cpy (char * restrict s1, const char * restrict s2, unsigned int n)
-{
- char *t1 = s1;
- const char *t2 = s2;
- while(n-- > 0)
- *t1++ = *t2++;
- return s1;
-}
deleted file mode 100755
GIT binary patch
literal 0
HcmV?d00001
literal 3364
zcmcImPiP!v6n`_b|JqG9o1{u1Dx+wdh?yj9NYj?oP0~#_x@}TzARc6#-JR?%W+!20
zViQq%s7hlABqHiTu!08#!HX0H4*_pIdGgf5UIIcd@mBN@-<$c~c6PF>i1@*L?|r}b
zdvCsZ-}k-wZe;T_vLpdF1ug)MGO~|kgkd`-6cia4hbZ>lkn*_EN2WtsUBqDtpn4p7
z2Zdz3F8eskU9?f#^?K@5Por@E#xLP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|MR+tvr8a0zw$iFAOANO(MCBL
zCQ_i?5f0A>Fj6^xER6sbq}~($;kfL_+|@Sze+d7dm?&h}|D87ecSWKpez1l8KSW~~
zBmN0-ftU<Bx8Qyvu<&=5h5vhP{P~^TXy>&FQXdHaFM}ZJ?8h*TdG9es@)z+VO$%ch
zu^xPQ|M2-af>^8f*E`UF?V>Llefa$iLkmU0*>W8SniZTepYLW|X`J6?{P2B@><U&M
zK5xzZ81VUN#^a6i(TsCef+)qO>>O?ih~$P$idV@(APyA}$qbnk=nNtL`bOaQgF^-c
zTH!Q93GbhES#5HmwI)2=`VnY#kEJ@@>K=Q#4Ni5b6~FNd)GxkvW%BauH0YP|b5oOf
ceQsvv)$BF>+T>I|t9#d7zU0!yHh9zh3+<yQu>b%7
@@ -1,11 +1,11 @@
-<abi-corpus version='2.1' path='data/test-read-dwarf/test4.so'>
+<abi-corpus version='2.1' path='data/test-read-common/test4.so'>
<elf-needed>
<dependency name='libc.so.6'/>
</elf-needed>
<elf-function-symbols>
<elf-symbol name='cpy' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
</elf-function-symbols>
- <abi-instr address-size='64' path='test4.c' comp-dir-path='/home/mark/src/tests' language='LANG_C89'>
+ <abi-instr address-size='64' path='test4.c' comp-dir-path='/home/byby/oracle/src/libabigail/tests/data/test-read-common' language='LANG_C99'>
<type-decl name='char' size-in-bits='8' id='type-id-1'/>
<type-decl name='unsigned int' size-in-bits='32' id='type-id-2'/>
<pointer-type-def type-id='type-id-1' size-in-bits='64' id='type-id-3'/>
@@ -13,10 +13,10 @@
<qualified-type-def type-id='type-id-1' const='yes' id='type-id-5'/>
<pointer-type-def type-id='type-id-5' size-in-bits='64' id='type-id-6'/>
<qualified-type-def type-id='type-id-6' restrict='yes' id='type-id-7'/>
- <function-decl name='cpy' mangled-name='cpy' filepath='/home/mark/src/tests/test4.c' line='2' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='cpy'>
- <parameter type-id='type-id-4' name='s1' filepath='/home/mark/src/tests/test4.c' line='2' column='1'/>
- <parameter type-id='type-id-7' name='s2' filepath='/home/mark/src/tests/test4.c' line='2' column='1'/>
- <parameter type-id='type-id-2' name='n' filepath='/home/mark/src/tests/test4.c' line='2' column='1'/>
+ <function-decl name='cpy' mangled-name='cpy' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test4.c' line='4' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='cpy'>
+ <parameter type-id='type-id-4' name='s1' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test4.c' line='4' column='1'/>
+ <parameter type-id='type-id-7' name='s2' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test4.c' line='4' column='1'/>
+ <parameter type-id='type-id-2' name='n' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test4.c' line='4' column='1'/>
<return type-id='type-id-3'/>
</function-decl>
</abi-instr>
@@ -1,11 +1,11 @@
-<abi-corpus version='2.1' path='data/test-read-dwarf/test4.so'>
+<abi-corpus version='2.1' path='data/test-read-common/test4.so'>
<elf-needed>
<dependency name='libc.so.6'/>
</elf-needed>
<elf-function-symbols>
<elf-symbol name='cpy' type='func-type' binding='global-binding' visibility='default-visibility' is-defined='yes'/>
</elf-function-symbols>
- <abi-instr address-size='64' path='test4.c' comp-dir-path='/home/mark/src/tests' language='LANG_C89'>
+ <abi-instr address-size='64' path='test4.c' comp-dir-path='/home/byby/oracle/src/libabigail/tests/data/test-read-common' language='LANG_C99'>
<type-decl name='char' size-in-bits='8' id='a84c031d'/>
<type-decl name='unsigned int' size-in-bits='32' id='f0981eeb'/>
<pointer-type-def type-id='a84c031d' size-in-bits='64' id='26a90f95'/>
@@ -13,10 +13,10 @@
<qualified-type-def type-id='a84c031d' const='yes' id='9b45d938'/>
<pointer-type-def type-id='9b45d938' size-in-bits='64' id='80f4b756'/>
<qualified-type-def type-id='80f4b756' restrict='yes' id='9d26089a'/>
- <function-decl name='cpy' mangled-name='cpy' filepath='/home/mark/src/tests/test4.c' line='2' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='cpy'>
- <parameter type-id='266fe297' name='s1' filepath='/home/mark/src/tests/test4.c' line='2' column='1'/>
- <parameter type-id='9d26089a' name='s2' filepath='/home/mark/src/tests/test4.c' line='2' column='1'/>
- <parameter type-id='f0981eeb' name='n' filepath='/home/mark/src/tests/test4.c' line='2' column='1'/>
+ <function-decl name='cpy' mangled-name='cpy' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test4.c' line='4' column='1' visibility='default' binding='global' size-in-bits='64' elf-symbol-id='cpy'>
+ <parameter type-id='266fe297' name='s1' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test4.c' line='4' column='1'/>
+ <parameter type-id='9d26089a' name='s2' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test4.c' line='4' column='1'/>
+ <parameter type-id='f0981eeb' name='n' filepath='/home/byby/oracle/src/libabigail/tests/data/test-read-common/test4.c' line='4' column='1'/>
<return type-id='26a90f95'/>
</function-decl>
</abi-instr>
@@ -42,12 +42,12 @@ InOutSpec in_out_specs[] =
"output/test-annotate/test2.so.abi"
},
{
- "data/test-read-dwarf/test3.so",
+ "data/test-read-common/test3.so",
"data/test-annotate/test3.so.abi",
"output/test-annotate/test3.so.abi"
},
{
- "data/test-read-dwarf/test4.so",
+ "data/test-read-common/test4.so",
"data/test-annotate/test4.so.abi",
"output/test-annotate/test4.so.abi"
},
new file mode 100644
@@ -0,0 +1,264 @@
+// -*- Mode: C++ -*-
+//
+
+/// @file
+///
+/// This file implements the common functionality for the tests in
+/// CTF and DWARF readers, it does the abstraction in the `act` test
+/// stage.
+
+#include <fstream>
+#include <cstring>
+#include "test-read-common.h"
+
+using std::ofstream;
+using std::cerr;
+using std::dynamic_pointer_cast;
+
+using abigail::tools_utils::emit_prefix;
+using abigail::tests::get_build_dir;
+using abigail::xml_writer::write_context_sptr;
+using abigail::xml_writer::create_write_context;
+using abigail::xml_writer::write_corpus;
+
+namespace abigail
+{
+namespace tests
+{
+namespace read_common
+{
+
+/// Constructor.
+///
+/// Task to be executed for each test entry in @ref
+/// abigail::tests::read_common::InOutSpec.
+///
+/// @param InOutSpec the set of tests.
+///
+/// @param a_out_abi_base the output base directory for abixml files.
+///
+/// @param a_in_elf_base the input base directory for object files.
+///
+/// @param a_in_elf_base the input base directory for expected
+/// abixml files.
+test_task::test_task(const InOutSpec &s,
+ string& a_out_abi_base,
+ string& a_in_elf_base,
+ string& a_in_abi_base)
+ : is_ok(true),
+ spec(s),
+ out_abi_base(a_out_abi_base),
+ in_elf_base(a_in_elf_base),
+ in_abi_base(a_in_abi_base)
+ {}
+
+/// Serialize the abixml @p out_abi_path file.
+///
+/// @param out_abi_path the abixml path file.
+///
+/// @param corp the ABI @ref abigail::ir::corpus.
+///
+/// @return true if abixml file was serialized successfully. Otherwise
+/// `error_message` is set with @p out_abi_path and false is returned.
+bool
+test_task::serialize_corpus(const string& out_abi_path,
+ corpus_sptr corp)
+{
+ ofstream of(out_abi_path.c_str(), std::ios_base::trunc);
+ if (!of.is_open())
+ {
+ error_message = string("failed to read ") + out_abi_path + "\n";
+ return false;
+ }
+
+ write_context_sptr write_ctxt
+ = create_write_context(corp->get_environment(), of);
+ set_type_id_style(*write_ctxt, spec.type_id_style);
+ is_ok = write_corpus(*write_ctxt, corp, /*indent=*/0);
+ of.close();
+
+ return is_ok;
+}
+
+/// Spawn `abidw --abidiff` tool appending @p extargs argument.
+///
+/// Thew input file object used by `abidw` will be specified by
+/// `in_elf_path'.
+///
+/// @param extargs the extra argument(s) passed to `abidw` tool.
+///
+/// @return true if `abidw` tool was executed correctly. Otherwise
+/// `error_message` shows the full path of the input file object and
+/// the full output path for the abixml file.
+bool
+test_task::run_abidw(const string& extargs)
+{
+ string abidw = string(get_build_dir()) + "/tools/abidw";
+ string drop_private_types;
+ if (!in_public_headers_path.empty())
+ drop_private_types += "--headers-dir " + in_public_headers_path +
+ " --drop-private-types";
+ string cmd = abidw + " " + drop_private_types + " --abidiff " + extargs +
+ in_elf_path;
+ if (system(cmd.c_str()))
+ {
+ error_message = string("ABIs differ:\n")
+ + in_elf_path
+ + "\nand:\n"
+ + out_abi_path
+ + "\n";
+
+ return false;
+ }
+
+ return true;
+}
+
+/// Spawn external `diff` command.
+///
+/// The files to be compared are: abixml generated by the input
+/// object file and the expected abixml file stored in `in_abi_path`.
+///
+/// @return true if `diff` command didn't find defences. Otherwise
+/// `error_message` shows the full path of the input file object and
+/// the full output path for the abixml file.
+bool
+test_task::run_diff()
+{
+ set_in_abi_path();
+ string cmd = "diff -u " + in_abi_path + " " + out_abi_path;
+ if (system(cmd.c_str()))
+ {
+ error_message = string("ABIs differ:\n")
+ + in_abi_path
+ + "\nand:\n"
+ + out_abi_path
+ + "\n";
+
+ return false;
+ }
+
+ return true;
+}
+
+/// Write the usage message to @p out stream object.
+///
+/// @param prog_name the program name.
+///
+/// @param out the stream object to which want to write.
+void
+display_usage(const string& prog_name, ostream& out)
+{
+ emit_prefix(prog_name, out)
+ << "usage: " << prog_name << " [options]\n"
+ << " where options can be: \n"
+ << " --help|-h display this message\n"
+ << " --no-parallel execute testsuite is a sigle thread\n"
+ ;
+}
+
+/// Parse and process test options.
+///
+/// @param argc the arguments number.
+///
+/// @param argv the pointer to the arguments.
+///
+/// @param opts the valid @ref options to be processed/parsed.
+///
+/// @return true if options was processed/parsed successfully. It returns
+/// false when help is requested or an invalid option is supplied.
+bool
+parse_command_line(int argc, char* argv[], options& opts)
+{
+ for (int i = 1; i < argc; ++i)
+ {
+ if (!strcmp(argv[i], "--no-parallel"))
+ opts.parallel = false;
+ else if (!strcmp(argv[i], "--help")
+ || !strcmp(argv[i], "--h"))
+ return false;
+ else
+ {
+ if (strlen(argv[i]) >= 2 && argv[i][0] == '-' && argv[i][1] == '-')
+ opts.wrong_option = argv[i];
+ return false;
+ }
+ }
+
+ return true;
+}
+
+/// The main entry point to execute the testsuite.
+///
+/// @param num_tests the number of tests to be executed.
+///
+/// @param specs the @ref abigail::tests::read_common::InOutSpec
+/// tests container.
+///
+/// @param opts the test execution @ref abigail::tests::read_common::options.
+///
+/// @param new_test the @ref create_new_test callback function to create
+/// a new test task object.
+///
+/// @return true if `all` tests were performed successfully. Otherwise
+/// false is returned.
+bool
+run_tests(const size_t num_tests, const InOutSpec* specs,
+ const options& opts, create_new_test new_test)
+{
+ size_t num_workers = (opts.parallel
+ ? std::min(abigail::workers::get_number_of_threads(),
+ num_tests)
+ : 1);
+
+ // Create a task queue. The max number of worker threads of the
+ // queue is the number of the concurrent threads supported by the
+ // processor of the machine this code runs on. But if
+ // --no-parallel was provided then the number of worker threads
+ // equals 1.
+ abigail::workers::queue task_queue(num_workers);
+ bool is_ok = true;
+
+ string out_abi_base = string(get_build_dir()) + "/tests/";
+ string in_elf_base = string(abigail::tests::get_src_dir()) + "/tests/";
+ string in_abi_base = in_elf_base;
+
+ for (const InOutSpec *s = specs; s->in_elf_path; ++s)
+ {
+ test_task_sptr t(new_test(s, out_abi_base,
+ in_elf_base,
+ in_abi_base));
+ ABG_ASSERT(task_queue.schedule_task(t));
+ }
+
+ // Wait for all worker threads to finish their job, and wind down.
+ task_queue.wait_for_workers_to_complete();
+
+ // Now walk the results and print whatever error messages need to be
+ // printed.
+
+ const vector<abigail::workers::task_sptr>& completed_tasks =
+ task_queue.get_completed_tasks();
+
+ ABG_ASSERT(completed_tasks.size() == num_tests);
+
+ for (vector<abigail::workers::task_sptr>::const_iterator ti =
+ completed_tasks.begin();
+ ti != completed_tasks.end();
+ ++ti)
+ {
+ test_task_sptr t = dynamic_pointer_cast<test_task>(*ti);
+ if (!t->is_ok)
+ {
+ is_ok = false;
+ if (!t->error_message.empty())
+ cerr << t->error_message << '\n';
+ }
+ }
+
+ return !is_ok;
+}
+
+}//end namespace read_common
+}//end namespace tests
+}//end namespace abigail
new file mode 100644
@@ -0,0 +1,179 @@
+// -*- Mode: C++ -*-
+//
+
+/// @file
+///
+/// This file declares the common functionality for tests in
+/// CTF and DWARF readers, it declares abstractions for `act` test
+/// stage.
+
+#ifndef __TEST_READ_COMMON_H__
+#define __TEST_READ_COMMON_H__
+
+#include <string>
+#include "abg-ir.h"
+#include "abg-corpus.h"
+#include "abg-workers.h"
+#include "abg-writer.h"
+#include "test-utils.h"
+#include "abg-tools-utils.h"
+
+using std::string;
+
+using abigail::xml_writer::type_id_style_kind;
+using abigail::ir::corpus_sptr;
+
+namespace abigail
+{
+namespace tests
+{
+namespace read_common
+{
+
+/// This is an aggregate that specifies where a test shall get its
+/// input from, and where it shall write its output to.
+struct InOutSpec
+{
+ const char* in_elf_path;
+ const char* in_suppr_spec_path;
+ const char* in_public_headers_path;
+ type_id_style_kind type_id_style;
+ const char* in_abi_path;
+ const char* out_abi_path;
+};// end struct InOutSpec
+
+/// The task that performs the tests.
+struct test_task : public abigail::workers::task
+{
+ bool is_ok;
+ InOutSpec spec;
+ string error_message;
+ string out_abi_base;
+ string in_elf_base;
+ string in_abi_base;
+
+ string in_elf_path;
+ string in_abi_path;
+ string in_suppr_spec_path;
+ string in_public_headers_path;
+ string out_abi_path;
+
+
+ /// A setter for `in_elf_path` field.
+ /// The `in_elf_path` is the full path for input object
+ /// in the tests container @ref
+ /// abigail::tests::read_common::InOutSpec.
+ void
+ set_in_elf_path()
+ {
+ in_elf_path = in_elf_base + spec.in_elf_path;
+ }
+
+ /// A setter for `in_suppr_spec_path` field.
+ /// The `in_suppr_spec_path` is the full path for suppression
+ /// entry in the tests container @ref
+ /// abigail::tests::read_common::InOutSpec.
+ void
+ set_in_suppr_spec_path()
+ {
+ if (spec.in_suppr_spec_path)
+ in_suppr_spec_path = in_elf_base + spec.in_suppr_spec_path;
+ else
+ in_suppr_spec_path.clear();
+ }
+
+ /// A setter for `in_public_headers_path` field.
+ /// The `in_public_headers_path` is the full path for headers
+ /// entry in the tests container @ref
+ /// abigail::tests::read_common::InOutSpec.
+ void
+ set_in_public_headers_path()
+ {
+ if (spec.in_public_headers_path)
+ in_public_headers_path = spec.in_public_headers_path;
+ if (!in_public_headers_path.empty())
+ in_public_headers_path = in_elf_base + spec.in_public_headers_path;
+ }
+
+ /// A setter for `out_abi_path` field.
+ /// The `out_abi_path` is the full path for output of abixml file.
+ /// @return true if `out_abi_path` is a valid directory.
+ bool
+ set_out_abi_path()
+ {
+ out_abi_path = out_abi_base + spec.out_abi_path;
+ if (!abigail::tools_utils::ensure_parent_dir_created(out_abi_path))
+ {
+ error_message =
+ string("Could not create parent directory for ") + out_abi_path;
+ return false;
+ }
+ return true;
+ }
+
+ /// A setter for `in_abi_path` field.
+ /// The `in_abi_path` is the full path for the expected abixml file.
+ void
+ set_in_abi_path()
+ {
+ in_abi_path = in_abi_base + spec.in_abi_path;
+ }
+
+ test_task(const InOutSpec &s,
+ string& a_out_abi_base,
+ string& a_in_elf_base,
+ string& a_in_abi_base);
+ bool
+ serialize_corpus(const string& out_abi_path,
+ corpus_sptr corp);
+ bool
+ run_abidw(const string& extargs = "");
+
+ bool
+ run_diff();
+
+ virtual
+ ~test_task()
+ {}
+}; // end struct test_task
+
+typedef shared_ptr<test_task> test_task_sptr;
+
+/// An abstraction for valid test options.
+struct options
+{
+ // saves a wrong option string passed to test-harness.
+ string wrong_option;
+ // parallel test execution.
+ bool parallel;
+
+ options()
+ : parallel(true)
+ {}
+
+ ~options()
+ {
+ }
+}; // end struct options
+
+void
+display_usage(const string& prog_name, ostream& out);
+
+bool
+parse_command_line(int argc, char* argv[], options& opts);
+
+/// A convenience typedef for a callback to create_new_test
+/// instances.
+typedef test_task* (*create_new_test)(const InOutSpec* s,
+ string& a_out_abi_base,
+ string& a_in_elf_base,
+ string& a_in_abi_base);
+bool
+run_tests(const size_t num_test, const InOutSpec* specs,
+ const options& opts, create_new_test new_test);
+
+}//end namespace read_common
+}//end namespace tests
+}//end namespace abigail
+
+#endif //__TEST_READ_COMMON_H__
new file mode 100644
@@ -0,0 +1,353 @@
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+// -*- Mode: C++ -*-
+//
+// Copyright (C) 2021 Oracle, Inc.
+//
+// Author: Guillermo E. Martinez
+
+/// @file
+///
+/// This file implement the CTF testsuite. It reads ELF binaries
+/// containing CTF, save them in XML corpus files and diff the
+/// corpus files against reference XML corpus files.
+
+#include <cstdlib>
+#include <fstream>
+#include <iostream>
+#include <memory>
+#include <string>
+#include <vector>
+#include "abg-ctf-reader.h"
+#include "test-read-common.h"
+
+using std::string;
+using std::cerr;
+
+using abigail::tests::read_common::InOutSpec;
+using abigail::tests::read_common::test_task;
+using abigail::tests::read_common::display_usage;
+using abigail::tests::read_common::options;
+
+using abigail::ctf_reader::read_context_sptr;
+using abigail::ctf_reader::create_read_context;
+using abigail::xml_writer::SEQUENCE_TYPE_ID_STYLE;
+using abigail::xml_writer::HASH_TYPE_ID_STYLE;
+using abigail::tools_utils::emit_prefix;
+
+static InOutSpec in_out_specs[] =
+{
+ {
+ "data/test-read-ctf/test0",
+ "",
+ "",
+ SEQUENCE_TYPE_ID_STYLE,
+ "data/test-read-ctf/test0.abi",
+ "output/test-read-ctf/test0.abi"
+ },
+ {
+ "data/test-read-ctf/test0",
+ "",
+ "",
+ HASH_TYPE_ID_STYLE,
+ "data/test-read-ctf/test0.hash.abi",
+ "output/test-read-ctf/test0.hash.abi"
+ },
+ {
+ "data/test-read-ctf/test1.so",
+ "",
+ "",
+ SEQUENCE_TYPE_ID_STYLE,
+ "data/test-read-ctf/test1.so.abi",
+ "output/test-read-ctf/test1.so.abi"
+ },
+ {
+ "data/test-read-ctf/test1.so",
+ "",
+ "",
+ HASH_TYPE_ID_STYLE,
+ "data/test-read-ctf/test1.so.hash.abi",
+ "output/test-read-ctf/test1.so.hash.abi"
+ },
+ {
+ "data/test-read-ctf/test2.so",
+ "",
+ "",
+ SEQUENCE_TYPE_ID_STYLE,
+ "data/test-read-ctf/test2.so.abi",
+ "output/test-read-ctf/test2.so.abi"
+ },
+ {
+ "data/test-read-ctf/test2.so",
+ "",
+ "",
+ HASH_TYPE_ID_STYLE,
+ "data/test-read-ctf/test2.so.hash.abi",
+ "output/test-read-ctf/test2.so.hash.abi"
+ },
+ {
+ "data/test-read-common/test3.so",
+ "",
+ "",
+ SEQUENCE_TYPE_ID_STYLE,
+ "data/test-read-ctf/test3.so.abi",
+ "output/test-read-ctf/test3.so.abi"
+ },
+ {
+ "data/test-read-common/test3.so",
+ "",
+ "",
+ HASH_TYPE_ID_STYLE,
+ "data/test-read-ctf/test3.so.hash.abi",
+ "output/test-read-ctf/test3.so.hash.abi"
+ },
+ {
+ "data/test-read-ctf/test-enum-many.o",
+ "",
+ "",
+ HASH_TYPE_ID_STYLE,
+ "data/test-read-ctf/test-enum-many.o.hash.abi",
+ "output/test-read-ctf/test-enum-many.o.hash.abi"
+ },
+ {
+ "data/test-read-ctf/test-ambiguous-struct-A.o",
+ "",
+ "",
+ HASH_TYPE_ID_STYLE,
+ "data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi",
+ "output/test-read-ctf/test-ambiguous-struct-A.o.hash.abi"
+ },
+ {
+ "data/test-read-ctf/test-ambiguous-struct-B.o",
+ "",
+ "",
+ HASH_TYPE_ID_STYLE,
+ "data/test-read-ctf/test-ambiguous-struct-B.o.hash.abi",
+ "output/test-read-ctf/test-ambiguous-struct-B.o.hash.abi"
+ },
+ {
+ "data/test-read-ctf/test-conflicting-type-syms-a.o",
+ "",
+ "",
+ HASH_TYPE_ID_STYLE,
+ "data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi",
+ "output/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi"
+ },
+ {
+ "data/test-read-ctf/test-conflicting-type-syms-b.o",
+ "",
+ "",
+ HASH_TYPE_ID_STYLE,
+ "data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi",
+ "output/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi"
+ },
+ {
+ "data/test-read-common/test4.so",
+ "",
+ "",
+ SEQUENCE_TYPE_ID_STYLE,
+ "data/test-read-ctf/test4.so.abi",
+ "output/test-read-ctf/test4.so.abi"
+ },
+ {
+ "data/test-read-common/test4.so",
+ "",
+ "",
+ HASH_TYPE_ID_STYLE,
+ "data/test-read-ctf/test4.so.hash.abi",
+ "output/test-read-ctf/test4.so.hash.abi"
+ },
+ {
+ "data/test-read-ctf/test5.o",
+ "",
+ "",
+ SEQUENCE_TYPE_ID_STYLE,
+ "data/test-read-ctf/test5.o.abi",
+ "output/test-read-ctf/test5.o.abi"
+ },
+ {
+ "data/test-read-ctf/test7.o",
+ "",
+ "",
+ SEQUENCE_TYPE_ID_STYLE,
+ "data/test-read-ctf/test7.o.abi",
+ "output/test-read-ctf/test7.o.abi"
+ },
+ {
+ "data/test-read-ctf/test8.o",
+ "",
+ "",
+ SEQUENCE_TYPE_ID_STYLE,
+ "data/test-read-ctf/test8.o.abi",
+ "output/test-read-ctf/test8.o.abi"
+ },
+ {
+ "data/test-read-ctf/test9.o",
+ "",
+ "",
+ SEQUENCE_TYPE_ID_STYLE,
+ "data/test-read-ctf/test9.o.abi",
+ "output/test-read-ctf/test9.o.abi"
+ },
+ {
+ "data/test-read-ctf/test-enum.o",
+ "",
+ "",
+ SEQUENCE_TYPE_ID_STYLE,
+ "data/test-read-ctf/test-enum.o.abi",
+ "output/test-read-ctf/test-enum.o.abi"
+ },
+ {
+ "data/test-read-ctf/test-enum-symbol.o",
+ "",
+ "",
+ HASH_TYPE_ID_STYLE,
+ "data/test-read-ctf/test-enum-symbol.o.hash.abi",
+ "output/test-read-ctf/test-enum-symbol.o.hash.abi"
+ },
+ {
+ "data/test-read-ctf/test-dynamic-array.o",
+ "",
+ "",
+ SEQUENCE_TYPE_ID_STYLE,
+ "data/test-read-ctf/test-dynamic-array.o.abi",
+ "output/test-read-ctf/test-dynamic-array.o.abi"
+ },
+ {
+ "data/test-read-common/PR27700/test-PR27700.o",
+ "",
+ "data/test-read-common/PR27700/pub-incdir",
+ HASH_TYPE_ID_STYLE,
+ "data/test-read-ctf/PR27700/test-PR27700.abi",
+ "output/test-read-ctf/PR27700/test-PR27700.abi",
+ },
+ // This should be the last entry.
+ {NULL, NULL, NULL, SEQUENCE_TYPE_ID_STYLE, NULL, NULL}
+};
+
+/// Task specialization to perform CTF tests.
+struct test_task_ctf : public test_task
+{
+ test_task_ctf(const InOutSpec &s,
+ string& a_out_abi_base,
+ string& a_in_elf_base,
+ string& a_in_abi_base);
+ virtual void
+ perform();
+
+ virtual
+ ~test_task_ctf()
+ {}
+}; // end struct test_task_ctf
+
+/// Constructor.
+///
+/// Task to be executed for each CTF test entry in @ref
+/// abigail::tests::read_common::InOutSpec.
+/// @param InOutSpec the array containing set of tests.
+///
+/// @param a_out_abi_base the output base directory for abixml files.
+///
+/// @param a_in_elf_base the input base directory for object files.
+///
+/// @param a_in_elf_base the input base directory for expected
+/// abixml files.
+test_task_ctf::test_task_ctf(const InOutSpec &s,
+ string& a_out_abi_base,
+ string& a_in_elf_base,
+ string& a_in_abi_base)
+ : test_task(s, a_out_abi_base, a_in_elf_base, a_in_abi_base)
+ {}
+
+/// The thread function to execute each CTF test entry in @ref
+/// abigail::tests::read_common::InOutSpec.
+///
+/// This reads the corpus into memory, saves it to disk, loads it
+/// again and compares the new in-memory representation against the
+void
+test_task_ctf::perform()
+{
+ abigail::ir::environment_sptr env;
+
+ set_in_elf_path();
+ set_in_suppr_spec_path();
+
+ env.reset(new abigail::ir::environment);
+ abigail::elf_reader::status status =
+ abigail::elf_reader::STATUS_UNKNOWN;
+ ABG_ASSERT(abigail::tools_utils::file_exists(in_elf_path));
+
+ read_context_sptr ctxt = create_read_context(in_elf_path,
+ env.get());
+ ABG_ASSERT(ctxt);
+
+ corpus_sptr corp = read_corpus(ctxt.get(), status);
+ // if there is no output and no input, assume that we do not care about the
+ // actual read result, just that it succeeded.
+ if (!spec.in_abi_path && !spec.out_abi_path)
+ {
+ // Phew! we made it here and we did not crash! yay!
+ return;
+ }
+ if (!corp)
+ {
+ error_message = string("failed to read ") + in_elf_path + "\n";
+ is_ok = false;
+ return;
+ }
+ corp->set_path(spec.in_elf_path);
+ // Do not take architecture names in comparison so that these
+ // test input binaries can come from whatever arch the
+ // programmer likes.
+ corp->set_architecture_name("");
+
+ if (!(is_ok = set_out_abi_path()))
+ return;
+
+ if (!(is_ok = serialize_corpus(out_abi_path, corp)))
+ return;
+
+ if (!(is_ok = run_abidw("--ctf ")))
+ return;
+
+ if (!(is_ok = run_diff()))
+ return;
+}
+
+/// Create a new CTF instance for task to be execute by the testsuite.
+///
+/// @param s the @ref abigail::tests::read_common::InOutSpec
+/// tests container.
+///
+/// @param a_out_abi_base the output base directory for abixml files.
+///
+/// @param a_in_elf_base the input base directory for object files.
+///
+/// @param a_in_abi_base the input base directory for abixml files.
+///
+/// @return abigail::tests::read_common::test_task instance.
+static test_task*
+new_task(const InOutSpec* s, string& a_out_abi_base,
+ string& a_in_elf_base, string& a_in_abi_base)
+{
+ return new test_task_ctf(*s, a_out_abi_base,
+ a_in_elf_base, a_in_abi_base);
+}
+
+int
+main(int argc, char *argv[])
+{
+ options opts;
+ if (!parse_command_line(argc, argv, opts))
+ {
+ if (!opts.wrong_option.empty())
+ emit_prefix(argv[0], cerr)
+ << "unrecognized option: " << opts.wrong_option << "\n";
+ display_usage(argv[0], cerr);
+ return 1;
+ }
+
+ // compute number of tests to be executed.
+ const size_t num_tests = sizeof(in_out_specs) / sizeof(InOutSpec) - 1;
+
+ return run_tests(num_tests, in_out_specs, opts, new_task);
+}
@@ -15,45 +15,27 @@
#include <memory>
#include <string>
#include <vector>
-#include "abg-ir.h"
+#include "test-read-common.h"
#include "abg-dwarf-reader.h"
-#include "abg-workers.h"
-#include "abg-writer.h"
-#include "abg-tools-utils.h"
-#include "test-utils.h"
using std::vector;
using std::string;
-using std::ofstream;
using std::cerr;
-using std::dynamic_pointer_cast;
-using abigail::tests::get_build_dir;
+
+using abigail::tests::read_common::InOutSpec;
+using abigail::tests::read_common::test_task;
+using abigail::tests::read_common::display_usage;
+using abigail::tests::read_common::options;
+
using abigail::dwarf_reader::read_corpus_from_elf;
using abigail::dwarf_reader::read_context;
using abigail::dwarf_reader::read_context_sptr;
using abigail::dwarf_reader::create_read_context;
using abigail::xml_writer::SEQUENCE_TYPE_ID_STYLE;
using abigail::xml_writer::HASH_TYPE_ID_STYLE;
-using abigail::xml_writer::create_write_context;
-using abigail::xml_writer::set_type_id_style;
-using abigail::xml_writer::type_id_style_kind;
-using abigail::xml_writer::write_context_sptr;
-using abigail::xml_writer::write_corpus;
-
-/// This is an aggregate that specifies where a test shall get its
-/// input from, and where it shall write its ouput to.
-struct InOutSpec
-{
- const char* in_elf_path;
- const char* in_suppr_spec_path;
- const char* in_public_headers_path;
- type_id_style_kind type_id_style;
- const char* in_abi_path;
- const char* out_abi_path;
-};// end struct InOutSpec
-
+using abigail::tools_utils::emit_prefix;
-InOutSpec in_out_specs[] =
+static InOutSpec in_out_specs[] =
{
{
"data/test-read-dwarf/test0",
@@ -104,7 +86,7 @@ InOutSpec in_out_specs[] =
"output/test-read-dwarf/test2.so.hash.abi"
},
{
- "data/test-read-dwarf/test3.so",
+ "data/test-read-common/test3.so",
"",
"",
SEQUENCE_TYPE_ID_STYLE,
@@ -112,7 +94,7 @@ InOutSpec in_out_specs[] =
"output/test-read-dwarf/test3.so.abi"
},
{
- "data/test-read-dwarf/test3.so",
+ "data/test-read-common/test3.so",
"",
"",
HASH_TYPE_ID_STYLE,
@@ -121,8 +103,8 @@ InOutSpec in_out_specs[] =
},
// suppress all except the main symbol of a group of aliases
{
- "data/test-read-dwarf/test3.so",
- "data/test-read-dwarf/test3-alias-1.suppr",
+ "data/test-read-common/test3.so",
+ "data/test-read-common/test3-alias-1.suppr",
"",
HASH_TYPE_ID_STYLE,
"data/test-read-dwarf/test3-alias-1.so.hash.abi",
@@ -130,8 +112,8 @@ InOutSpec in_out_specs[] =
},
// suppress the main symbol of a group of aliases
{
- "data/test-read-dwarf/test3.so",
- "data/test-read-dwarf/test3-alias-2.suppr",
+ "data/test-read-common/test3.so",
+ "data/test-read-common/test3-alias-2.suppr",
"",
HASH_TYPE_ID_STYLE,
"data/test-read-dwarf/test3-alias-2.so.hash.abi",
@@ -139,8 +121,8 @@ InOutSpec in_out_specs[] =
},
// suppress all except one non main symbol of a group of aliases
{
- "data/test-read-dwarf/test3.so",
- "data/test-read-dwarf/test3-alias-3.suppr",
+ "data/test-read-common/test3.so",
+ "data/test-read-common/test3-alias-3.suppr",
"",
HASH_TYPE_ID_STYLE,
"data/test-read-dwarf/test3-alias-3.so.hash.abi",
@@ -148,8 +130,8 @@ InOutSpec in_out_specs[] =
},
// suppress all symbols of a group of aliases
{
- "data/test-read-dwarf/test3.so",
- "data/test-read-dwarf/test3-alias-4.suppr",
+ "data/test-read-common/test3.so",
+ "data/test-read-common/test3-alias-4.suppr",
"",
HASH_TYPE_ID_STYLE,
"data/test-read-dwarf/test3-alias-4.so.hash.abi",
@@ -165,7 +147,7 @@ InOutSpec in_out_specs[] =
"output/test-read-dwarf/test-suppressed-alias.o.abi",
},
{
- "data/test-read-dwarf/test4.so",
+ "data/test-read-common/test4.so",
"",
"",
SEQUENCE_TYPE_ID_STYLE,
@@ -173,7 +155,7 @@ InOutSpec in_out_specs[] =
"output/test-read-dwarf/test4.so.abi"
},
{
- "data/test-read-dwarf/test4.so",
+ "data/test-read-common/test4.so",
"",
"",
HASH_TYPE_ID_STYLE,
@@ -449,7 +431,7 @@ InOutSpec in_out_specs[] =
NULL,
},
{
- "data/test-read-dwarf/PR26261/PR26261-exe",
+ "data/test-read-common/PR26261/PR26261-exe",
"",
"",
SEQUENCE_TYPE_ID_STYLE,
@@ -457,7 +439,7 @@ InOutSpec in_out_specs[] =
"output/test-read-dwarf/PR26261/PR26261-exe.abi",
},
{
- "data/test-read-dwarf/test-PR26568-1.o",
+ "data/test-read-common/test-PR26568-1.o",
"",
"",
SEQUENCE_TYPE_ID_STYLE,
@@ -465,7 +447,7 @@ InOutSpec in_out_specs[] =
"output/test-read-dwarf/test-PR26568-1.o.abi",
},
{
- "data/test-read-dwarf/test-PR26568-2.o",
+ "data/test-read-common/test-PR26568-2.o",
"",
"",
SEQUENCE_TYPE_ID_STYLE,
@@ -481,9 +463,9 @@ InOutSpec in_out_specs[] =
"output/test-read-dwarf/test-libandroid.so.abi",
},
{
- "data/test-read-dwarf/PR27700/test-PR27700.o",
+ "data/test-read-common/PR27700/test-PR27700.o",
"",
- "data/test-read-dwarf/PR27700/pub-incdir",
+ "data/test-read-common/PR27700/pub-incdir",
HASH_TYPE_ID_STYLE,
"data/test-read-dwarf/PR27700/test-PR27700.abi",
"output/test-read-dwarf/PR27700/test-PR27700.abi",
@@ -552,198 +534,138 @@ set_suppressions_from_headers(read_context& read_ctxt, const string& path)
}
}
-/// The task that peforms the tests.
-struct test_task : public abigail::workers::task
+/// Task specialization to perform DWARF tests.
+struct test_task_dwarf : public test_task
{
- bool is_ok;
- InOutSpec spec;
- string error_message;
- string out_abi_base;
- string in_elf_base;
- string in_abi_base;
+ test_task_dwarf(const InOutSpec &s,
+ string& a_out_abi_base,
+ string& a_in_elf_base,
+ string& a_in_abi_base);
+ virtual void
+ perform();
- test_task(const InOutSpec &s,
- string& a_out_abi_base,
- string& a_in_elf_base,
- string& a_in_abi_base)
- : is_ok(true),
- spec(s),
- out_abi_base(a_out_abi_base),
- in_elf_base(a_in_elf_base),
- in_abi_base(a_in_abi_base)
+ virtual
+ ~test_task_dwarf()
{}
+}; // end struct test_task_dwarf
- /// The actual test.
- ///
- /// This reads the corpus into memory, saves it to disk, loads it
- /// again and compares the new in-memory representation against the
- /// saved one.
- virtual void
- perform()
- {
- string in_elf_path, in_abi_path, in_suppr_spec_path, in_public_headers_path,
- out_abi_path;
- abigail::ir::environment_sptr env;
+/// Constructor.
+///
+/// Task to be executed for each DWARF test entry in @ref
+/// abigail::tests::read_common::InOutSpec.
+///
+/// @param InOutSpec the array containing set of tests.
+///
+/// @param a_out_abi_base the output base directory for abixml files.
+///
+/// @param a_in_elf_base the input base directory for object files.
+///
+/// @param a_in_elf_base the input base directory for expected
+/// abixml files.
+test_task_dwarf::test_task_dwarf(const InOutSpec &s,
+ string& a_out_abi_base,
+ string& a_in_elf_base,
+ string& a_in_abi_base)
+ : test_task(s, a_out_abi_base, a_in_elf_base, a_in_abi_base)
+ {}
- in_elf_path = in_elf_base + spec.in_elf_path;
- if (spec.in_suppr_spec_path)
- in_suppr_spec_path = in_elf_base + spec.in_suppr_spec_path;
- else
- in_suppr_spec_path.clear();
+/// The thread function to execute each DWARF test entry in @ref
+/// abigail::tests::read_common::InOutSpec.
+///
+/// This reads the corpus into memory, saves it to disk, loads it
+/// again and compares the new in-memory representation against the
+void
+test_task_dwarf::perform()
+{
+ abigail::ir::environment_sptr env;
- if (spec.in_public_headers_path)
- in_public_headers_path = spec.in_public_headers_path;
- if (!in_public_headers_path.empty())
- in_public_headers_path = in_elf_base + spec.in_public_headers_path;
+ set_in_elf_path();
+ set_in_suppr_spec_path();
+ set_in_public_headers_path();
- env.reset(new abigail::ir::environment);
- abigail::elf_reader::status status =
+ env.reset(new abigail::ir::environment);
+ abigail::elf_reader::status status =
abigail::elf_reader::STATUS_UNKNOWN;
- vector<char**> di_roots;
- ABG_ASSERT(abigail::tools_utils::file_exists(in_elf_path));
- read_context_sptr ctxt = create_read_context(in_elf_path,
- di_roots,
- env.get());
- ABG_ASSERT(ctxt);
- if (!in_suppr_spec_path.empty())
- set_suppressions(*ctxt, in_suppr_spec_path);
-
- if (!in_public_headers_path.empty())
- set_suppressions_from_headers(*ctxt, in_public_headers_path);
-
- abigail::corpus_sptr corp = read_corpus_from_elf(*ctxt, status);
- // if there is no output and no input, assume that we do not care about the
- // actual read result, just that it succeeded.
- if (!spec.in_abi_path && !spec.out_abi_path)
- {
- // Phew! we made it here and we did not crash! yay!
- return;
- }
- if (!corp)
- {
- error_message = string("failed to read ") + in_elf_path + "\n";
- is_ok = false;
- return;
- }
- corp->set_path(spec.in_elf_path);
- // Do not take architecture names in comparison so that these
- // test input binaries can come from whatever arch the
- // programmer likes.
- corp->set_architecture_name("");
+ vector<char**> di_roots;
+ ABG_ASSERT(abigail::tools_utils::file_exists(in_elf_path));
+ read_context_sptr ctxt = create_read_context(in_elf_path,
+ di_roots,
+ env.get());
+ ABG_ASSERT(ctxt);
+ if (!in_suppr_spec_path.empty())
+ set_suppressions(*ctxt, in_suppr_spec_path);
+
+ if (!in_public_headers_path.empty())
+ set_suppressions_from_headers(*ctxt, in_public_headers_path);
+
+ abigail::corpus_sptr corp = read_corpus_from_elf(*ctxt, status);
+ // if there is no output and no input, assume that we do not care about the
+ // actual read result, just that it succeeded.
+ if (!spec.in_abi_path && !spec.out_abi_path)
+ {
+ // Phew! we made it here and we did not crash! yay!
+ return;
+ }
+ if (!corp)
+ {
+ error_message = string("failed to read ") + in_elf_path + "\n";
+ is_ok = false;
+ return;
+ }
+ corp->set_path(spec.in_elf_path);
+ // Do not take architecture names in comparison so that these
+ // test input binaries can come from whatever arch the
+ // programmer likes.
+ corp->set_architecture_name("");
- out_abi_path = out_abi_base + spec.out_abi_path;
- if (!abigail::tools_utils::ensure_parent_dir_created(out_abi_path))
- {
- error_message =
- string("Could not create parent directory for ") + out_abi_path;
- is_ok = false;
- return;
- }
+ if (!(is_ok = set_out_abi_path()))
+ return;
- ofstream of(out_abi_path.c_str(), std::ios_base::trunc);
- if (!of.is_open())
- {
- error_message = string("failed to read ") + out_abi_path + "\n";
- is_ok = false;
- return;
- }
- write_context_sptr write_ctxt
- = create_write_context(corp->get_environment(), of);
- set_type_id_style(*write_ctxt, spec.type_id_style);
- is_ok = write_corpus(*write_ctxt, corp, /*indent=*/0);
- of.close();
+ if (!(is_ok = serialize_corpus(out_abi_path, corp)))
+ return;
- string abidw = string(get_build_dir()) + "/tools/abidw";
- string drop_private_types;
- if (!in_public_headers_path.empty())
- drop_private_types += "--headers-dir " + in_public_headers_path +
- " --drop-private-types";
- string cmd = abidw + " " + drop_private_types + " --abidiff " + in_elf_path;
- if (system(cmd.c_str()))
- {
- error_message = string("ABIs differ:\n")
- + in_elf_path
- + "\nand:\n"
- + out_abi_path
- + "\n";
- is_ok = false;
- }
+ if (!(is_ok = run_abidw()))
+ return;
- in_abi_path = in_abi_base + spec.in_abi_path;
- cmd = "diff -u " + in_abi_path + " " + out_abi_path;
- if (system(cmd.c_str()))
- is_ok = false;
- }
-}; // end struct test_task
+ if (!(is_ok = run_diff()))
+ return;
+}
-typedef shared_ptr<test_task> test_task_sptr;
+/// Create a new DWARF instance for task to be execute by the testsuite.
+///
+/// @param s the @ref abigail::tests::read_common::InOutSpec
+/// tests container.
+///
+/// @param a_out_abi_base the output base directory for abixml files.
+///
+/// @param a_in_elf_base the input base directory for object files.
+///
+/// @param a_in_abi_base the input base directory for abixml files.
+///
+/// @return abigail::tests::read_common::test_task instance.
+static test_task*
+new_task(const InOutSpec* s, string& a_out_abi_base,
+ string& a_in_elf_base, string& a_in_abi_base)
+{
+ return new test_task_dwarf(*s, a_out_abi_base,
+ a_in_elf_base, a_in_abi_base);
+}
int
main(int argc, char *argv[])
{
- bool no_parallel = false;
-
- if (argc == 2)
+ options opts;
+ if (!parse_command_line(argc, argv, opts))
{
- if (argv[1] == string("--no-parallel"))
- no_parallel = true;
- else
- {
- cerr << "unrecognized option\n";
- cerr << "usage: " << argv[0] << " [--no-parallel]\n" ;
- return 1;
- }
+ if (!opts.wrong_option.empty())
+ emit_prefix(argv[0], cerr)
+ << "unrecognized option: " << opts.wrong_option << "\n";
+ display_usage(argv[0], cerr);
+ return 1;
}
- /// Create a task queue. The max number of worker threads of the
- /// queue is the number of the concurrent threads supported by the
- /// processor of the machine this code runs on. But if
- /// --no-parallel was provided then the number of worker threads
- /// equals 1.
- const size_t num_tests = sizeof(in_out_specs) / sizeof (InOutSpec) - 1;
- size_t num_workers = (no_parallel
- ? 1
- : std::min(abigail::workers::get_number_of_threads(),
- num_tests));
- abigail::workers::queue task_queue(num_workers);
- bool is_ok = true;
-
- string out_abi_base = string(get_build_dir()) + "/tests/";
- string in_elf_base = string(abigail::tests::get_src_dir()) + "/tests/";
- string in_abi_base = in_elf_base;
-
- for (InOutSpec *s = in_out_specs; s->in_elf_path; ++s)
- {
- test_task_sptr t(new test_task(*s, out_abi_base,
- in_elf_base,
- in_abi_base));
- ABG_ASSERT(task_queue.schedule_task(t));
- }
-
- /// Wait for all worker threads to finish their job, and wind down.
- task_queue.wait_for_workers_to_complete();
-
- // Now walk the results and print whatever error messages need to be
- // printed.
-
- const vector<abigail::workers::task_sptr>& completed_tasks =
- task_queue.get_completed_tasks();
-
- ABG_ASSERT(completed_tasks.size() == num_tests);
-
- for (vector<abigail::workers::task_sptr>::const_iterator ti =
- completed_tasks.begin();
- ti != completed_tasks.end();
- ++ti)
- {
- test_task_sptr t = dynamic_pointer_cast<test_task>(*ti);
- if (!t->is_ok)
- {
- is_ok = false;
- if (!t->error_message.empty())
- cerr << t->error_message << '\n';
- }
- }
+ // compute number of tests to be executed.
+ const size_t num_tests = sizeof(in_out_specs) / sizeof(InOutSpec) - 1;
- return !is_ok;
+ return run_tests(num_tests, in_out_specs, opts, new_task);
}