Re: clang generated code sometimes confuses fbt

2013-03-05 Thread Dimitry Andric
On 2013-03-05 13:02, Andriy Gapon wrote: on 04/03/2013 13:50 Dimitry Andric said the following: Actually, that way of fixing breaks it for gcc, so it should really be fixed in sort_iidescs() instead. See attached diff; I verified it works for both gcc-compiled and clang-compiled objects. Impo

Re: clang generated code sometimes confuses fbt

2013-03-05 Thread Andriy Gapon
on 04/03/2013 13:50 Dimitry Andric said the following: > Actually, that way of fixing breaks it for gcc, so it should really be > fixed in sort_iidescs() instead. See attached diff; I verified it works > for both gcc-compiled and clang-compiled objects. Impossible! It looks like the attached dif

Re: clang generated code sometimes confuses fbt

2013-03-04 Thread Dimitry Andric
On 2013-03-03 21:02, Dimitry Andric wrote: On 2013-03-03 17:36, Andriy Gapon wrote: on 03/03/2013 17:45 Dimitry Andric said the following: ... So to fix this inconsistency, we could either change dw_read() to use the full name instead of the basename, or change sort_iidescs() to use the basena

Re: clang generated code sometimes confuses fbt

2013-03-04 Thread Andriy Gapon
on 04/03/2013 09:57 Matt Burke said the following: > On 03/02/13 17:35, Andriy Gapon wrote: > >> To summarize: I would be glad of either clang generated code was >> "fbt-friendly" or if ctf information was generated for >> bpobj_iterate_impl. Either is perfect for me. > > Apologies if this is a s

Re: clang generated code sometimes confuses fbt

2013-03-04 Thread Dimitry Andric
On 2013-03-04 08:57, Matt Burke wrote: On 03/02/13 17:35, Andriy Gapon wrote: To summarize: I would be glad of either clang generated code was "fbt-friendly" or if ctf information was generated for bpobj_iterate_impl. Either is perfect for me. Apologies if this is a silly suggestion, but are y

Re: clang generated code sometimes confuses fbt

2013-03-03 Thread Matt Burke
On 03/02/13 17:35, Andriy Gapon wrote: > To summarize: I would be glad of either clang generated code was > "fbt-friendly" or if ctf information was generated for > bpobj_iterate_impl. Either is perfect for me. Apologies if this is a silly suggestion, but are you building with -O0? I've noticed b

Re: clang generated code sometimes confuses fbt

2013-03-03 Thread Dimitry Andric
On 2013-03-03 17:36, Andriy Gapon wrote: on 03/03/2013 17:45 Dimitry Andric said the following: Debug log of ctfconvert operating on a gcc-compiled bpobj.o: http://www.andric.com/freebsd/ctfconvert-bpobj-gcc.log The same, but on a clang-compiled bpobj.o: http://www.andric.com/freebsd/ct

Re: clang generated code sometimes confuses fbt

2013-03-03 Thread Andriy Gapon
on 03/03/2013 17:45 Dimitry Andric said the following: > Debug log of ctfconvert operating on a gcc-compiled bpobj.o: > > http://www.andric.com/freebsd/ctfconvert-bpobj-gcc.log > > The same, but on a clang-compiled bpobj.o: > > http://www.andric.com/freebsd/ctfconvert-bpobj-clang.log > > Th

Re: clang generated code sometimes confuses fbt

2013-03-03 Thread Andriy Gapon
on 02/03/2013 22:23 Dimitry Andric said the following: > > Have you verified that ctfconvert does the right thing, if you modify > the FILE symbol to have just the filename? No, I haven't. How can I test that? However my reading of the code makes me believe that that would help. -- Andriy Gapo

Re: clang generated code sometimes confuses fbt

2013-03-03 Thread Dimitry Andric
On 2013-03-02 21:23, Dimitry Andric wrote: On 2013-03-02 18:52, Andriy Gapon wrote: on 02/03/2013 19:35 Andriy Gapon said the following: Now, I am not quite sure why ctfconvert skips bpobj_iterate_impl in the clang-generated code. Seems like some sort of a bug in ctfconvert. It seems that gc

Re: clang generated code sometimes confuses fbt

2013-03-02 Thread Konstantin Belousov
On Sat, Mar 02, 2013 at 09:23:15PM +0100, Dimitry Andric wrote: > On 2013-03-02 18:52, Andriy Gapon wrote: > > on 02/03/2013 19:35 Andriy Gapon said the following: > >> Now, I am not quite sure why ctfconvert skips bpobj_iterate_impl in the > >> clang-generated code. Seems like some sort of a bug

Re: clang generated code sometimes confuses fbt

2013-03-02 Thread Dimitry Andric
On 2013-03-02 18:52, Andriy Gapon wrote: on 02/03/2013 19:35 Andriy Gapon said the following: Now, I am not quite sure why ctfconvert skips bpobj_iterate_impl in the clang-generated code. Seems like some sort of a bug in ctfconvert. It seems that gcc and clang put different names for symbol o

Re: clang generated code sometimes confuses fbt

2013-03-02 Thread Andriy Gapon
on 02/03/2013 19:35 Andriy Gapon said the following: > Now, I am not quite sure why ctfconvert skips bpobj_iterate_impl in the > clang-generated code. Seems like some sort of a bug in ctfconvert. It seems that gcc and clang put different names for symbol of type FILE: clang: readelf -a -W /usr/ob

clang generated code sometimes confuses fbt

2013-03-02 Thread Andriy Gapon
I observe the following problem. There are two tiny wrapper functions around a larger implementation function: int bpobj_iterate(bpobj_t *bpo, bpobj_itor_t func, void *arg, dmu_tx_t *tx) { return (bpobj_iterate_impl(bpo, func, arg, tx, B_TRUE)); } int bpobj_iterate_nofree(bpobj_t *bpo, bp