Suppress impossible code coverage issues

This commit is contained in:
Wilson Snyder
2020-05-15 22:34:29 -04:00
parent 2d11c2cbb3
commit 29bcbb0417
3 changed files with 7 additions and 7 deletions
+4 -4
View File
@@ -194,8 +194,8 @@ void VerilatedSave::flush() VL_MT_UNSAFE_ONE {
ssize_t got = ::write(m_fd, wp, remaining);
if (got > 0) {
wp += got;
} else if (got < 0) {
if (errno != EAGAIN && errno != EINTR) {
} else if (VL_UNCOVERABLE(got < 0)) {
if (VL_UNCOVERABLE(errno != EAGAIN && errno != EINTR)) {
// write failed, presume error (perhaps out of disk space)
std::string msg = std::string(__FUNCTION__) + ": " + strerror(errno);
VL_FATAL_MT("", 0, "", msg.c_str());
@@ -223,8 +223,8 @@ void VerilatedRestore::fill() VL_MT_UNSAFE_ONE {
ssize_t got = ::read(m_fd, m_endp, remaining);
if (got > 0) {
m_endp += got;
} else if (got < 0) {
if (errno != EAGAIN && errno != EINTR) {
} else if (VL_UNCOVERABLE(got < 0)) {
if (VL_UNCOVERABLE(errno != EAGAIN && errno != EINTR)) {
// write failed, presume error (perhaps out of disk space)
std::string msg = std::string(__FUNCTION__) + ": " + strerror(errno);
VL_FATAL_MT("", 0, "", msg.c_str());