facebookincubator / dynolog

Dynolog is a telemetry daemon for performance monitoring and tracing. It exports metrics from different components in the system like the linux kernel, CPU, disks, Intel PT, GPUs etc. Dynolog also integrates with pytorch and can trigger traces for distributed training applications.
MIT License
260 stars 38 forks source link

Call std::terminate instead of throwing from noexcept functions #226

Closed briancoutinho closed 7 months ago

briancoutinho commented 7 months ago

Summary: With -Werror,-Wexceptions the code like this one will generate a compile error like this one: error: 'tryPeekMsg' has a non-throwing exception specification but can still throw [-Werror,-Wexceptions]

After some internal discussion we decided to explicitly throw std::terminate() so intent is clear that this is a non recoverable error.

Differential Revision: D53891927

facebook-github-bot commented 7 months ago

This pull request was exported from Phabricator. Differential Revision: D53891927

facebook-github-bot commented 7 months ago

This pull request was exported from Phabricator. Differential Revision: D53891927

facebook-github-bot commented 7 months ago

This pull request has been merged in facebookincubator/dynolog@7be9dd1d7efce86c94142f60e086eabea6f5ae65.