CodeConstruct / dbus-sensors

D-Bus configurable sensor scanning applications
Apache License 2.0
0 stars 3 forks source link

[bug] ubsan failed with difference compiler flag for io_uring #8

Open drakedog2008 opened 8 months ago

drakedog2008 commented 8 months ago

Currently, the dbus-sensor enables project wise io_uring flag:

https://gerrit.openbmc.org/c/openbmc/dbus-sensors/+/64039.

However, the nvmed disabled the io_uring due to https://gerrit.openbmc.org/c/openbmc/dbus-sensors/+/62299

Consequentially, it failed the ubsan:

/usr/local/include/boost/asio/detail/deadline_timer_service.hpp:272:30: runtime error: member call on address 0x617000000080 which does not point to an object of type 'io_uring_service'
0x617000000080: note: object is of type 'boost::asio::detail::select_reactor'
 00 00 00 00  e8 a7 39 5c 4e 56 00 00  00 00 00 00 00 00 00 00  52 70 95 5e 4e 56 00 00  a0 6d 95 5e
              ^~~~~~~~~~~~~~~~~~~~~~~
              vptr for 'boost::asio::detail::select_reactor'
drakedog2008 commented 8 months ago

After removing the io_uring flags from the utils library, ubsan is happen.

My 2 cents options are the io_uring flag points the boost::timer implementation to io_uring_service, but the main program creates the epoll instead of the io_uring.