[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PULL v2 05/13] target/rx: CPU definitions
From: |
Richard Henderson |
Subject: |
Re: [PULL v2 05/13] target/rx: CPU definitions |
Date: |
Fri, 20 Mar 2020 09:18:32 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 |
On 3/20/20 9:04 AM, Philippe Mathieu-Daudé wrote:
> Not related to this patch, but this line generates a warning with Clang:
>
> CC rx-softmmu/target/rx/cpu.o
> target/rx/cpu.c:158:33: warning: The result of the left shift is undefined
> because the left operand is negative
> address = physical = addr & TARGET_PAGE_MASK;
> ^~~~~~~~~~~~~~~~
> include/exec/cpu-all.h:234:45: note: expanded from macro 'TARGET_PAGE_MASK'
> #define TARGET_PAGE_MASK ((target_long)-1 << TARGET_PAGE_BITS)
> ~~~~~~~~~~~~~~~ ^
> 1 warning generated.
>From configure:
> # We use -fwrapv to tell the compiler that we require a C dialect where
> # left shift of signed integers is well defined and has the expected
> # 2s-complement style results. (Both clang and gcc agree that it
> # provides these semantics.)
Clang is *supposed* to be not generating those warnings.
r~
- [PULL v2 00/13] target: Add the Renesas RX architecture, Philippe Mathieu-Daudé, 2020/03/20
- [PULL v2 05/13] target/rx: CPU definitions, Philippe Mathieu-Daudé, 2020/03/20
- Re: [PULL v2 05/13] target/rx: CPU definitions, Philippe Mathieu-Daudé, 2020/03/20
- Re: [PULL v2 05/13] target/rx: CPU definitions,
Richard Henderson <=
- Re: [PULL v2 05/13] target/rx: CPU definitions, Peter Maydell, 2020/03/20
- Re: [PULL v2 05/13] target/rx: CPU definitions, Philippe Mathieu-Daudé, 2020/03/20
- Re: [PULL v2 05/13] target/rx: CPU definitions, Peter Maydell, 2020/03/20
- Re: [PULL v2 05/13] target/rx: CPU definitions, Philippe Mathieu-Daudé, 2020/03/21
- Re: [PULL v2 05/13] target/rx: CPU definitions, Philippe Mathieu-Daudé, 2020/03/21
Re: [PULL v2 00/13] target: Add the Renesas RX architecture, Peter Maydell, 2020/03/20