Matt Stupple
2006-Sep-13 08:17 UTC
[dtrace-discuss] dbx warnings/errors when using USDT in C++
(This is snv_40 with Sun Studio 11) After adding some USDT probes to my code (thanks for the forum help with getting that working!) I now find that I am unable to debug using dbx - if I try to load up my test harness binary in dbx I get this: $ dbx test_fw_tools Reading test_fw_tools dbx: Detected a Cfront (CC.2.0.x) compiled file "ilds/onnv_40/usr/src/lib/libdtrace/sparc;/ws/onnv-tools/SUNWspro/SOS10/prod/bin/cc -xO3 -xarch=v8 -xspace -W0,-Lt -W2,-Rcond_elim -Xa -xildoff -errtags=yes -errwarn=%all -erroff=E_EMPTY_TRANSLATION_UNIT -erroff=E_STATEMENT_NOT_REACHED -xc99=%none -Wd,-xsafe=unboundsym -v -K PIC -DTEXT_DOMAIN=''"SUNW_OST_OSLIB"'' -D_TS_ERRNO -I/export/builds/onnv_40/proto/root_sparc/usr/include -I../common -I. -c -o drti.o ../common/drti.c" - this stab format is unsupported dbx: warning: object initialization interrupted - no program loaded With a simpler testcase (attached) dbx just gives me a warning, but I wonder if this is as a result of the same underlying problem? $ dbx bar Reading bar dbx: warning: ".index.stab" section error in "/export/home/matt/dev/playpen/dtrace/bar", stab #94 and beyond have been ignored This may be stating the obvious, but it seems that the object file generated by ''dtrace -G'' is causing the problem - if I remove the trick (see earlier USDT/C++ thread) used to force this object to be linked into my final binary then dbx no longer has any problems loading my binary... Matt. This message posted from opensolaris.org -------------- next part -------------- A non-text attachment was scrubbed... Name: dbx_problems.tar.gz Type: application/x-gzip Size: 654 bytes Desc: not available URL: <http://mail.opensolaris.org/pipermail/dtrace-discuss/attachments/20060913/ffdb314a/attachment.bin>