DynamoRIO / DynamoRIO/dynamorio

Missing compiler warnings due to compiler flags getting lost for non-client, non-standalone targets in dirs with clients

Open
#6,040 1 comment 0 reactions 1 assignee Claimed by @lihasgupta View on GitHub
Bug-Assert Component-Tests
Dominant language
C
Stars
3.2k
Forks
629
Avg merge
2d 15h
Merged PRs (30d)
31

Description

**Describe the bug**

We are getting the following compiler warning in `invariant_checker_test.cpp` on 32-bit builds.

```
dynamorio/clients/drcachesim/tests/invariant_checker_test.cpp: In function ‘bool {anonymous}::check_duplicate_syscall_with_same_pc()’:
dynamorio/clients/drcachesim/tests/invariant_checker_test.cpp:594:29: warning: unsigned conversion from ‘long long int’ to ‘addr_t’ {aka ‘unsigned int’} changes value from ‘140528035158505’ to ‘1000200681’
[-Woverflow]
594 | constexpr addr_t ADDR = 0x7fcf3b9dd9e9;
| ^~~~~~~~~~~~~~
```

We can choose a smaller value within the unsigned int range for `constexpr addr_t ADDR `. That should fix this.

**To Reproduce**
- Compile DynamoRIO with tests for a 32-bit build.
- This compiler warning will be present.

**Expected behavior**
These should not be compiler warnings.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.