|
|
DescriptionFix win-clang build
In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. This value
could be larger than 255. clang-cl is complaining that "implicit
conversion from 'int' to 'unsigned char' changes value from 256 to 0"
when __COUNTER__ reaches 256.
To make binary smaller, we cast __COUNTER__ to unsigned char
instead of assigning it to int*.
TBR=thakis
Review-Url: https://codereview.chromium.org/2706143002
Cr-Commit-Position: refs/heads/master@{#451705}
Committed: https://chromium.googlesource.com/chromium/src/+/7d988be5bc1966437c64ea465b1144644003472f
Patch Set 1 #Patch Set 2 : Use static_csat #Messages
Total messages: 26 (16 generated)
The CQ bit was checked by shinyak@chromium.org to run a CQ dry run
The CQ bit was unchecked by shinyak@chromium.org
The CQ bit was checked by shinyak@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
shinyak@chromium.org changed reviewers: + scottmg@chromium.org, thakis@chromium.org
Try to fix build broken in https://codereview.chromium.org/2701253005/
Description was changed from ========== Fix win-clang build In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. Since this value should be larger than 255. clang-cl is complaining that "implicit conversion from 'int' to 'unsigned char' changes value from 256 to 0". So, let's use int* for this purpose. ========== to ========== Fix win-clang build In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. This value could be larger than 255. clang-cl is complaining that "implicit conversion from 'int' to 'unsigned char' changes value from 256 to 0" when __COUNTER__ reaches 256. So, let's use int* for this purpose. ==========
Description was changed from ========== Fix win-clang build In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. This value could be larger than 255. clang-cl is complaining that "implicit conversion from 'int' to 'unsigned char' changes value from 256 to 0" when __COUNTER__ reaches 256. So, let's use int* for this purpose. ========== to ========== Fix win-clang build In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. This value could be larger than 255. clang-cl is complaining that "implicit conversion from 'int' to 'unsigned char' changes value from 256 to 0" when __COUNTER__ reaches 256. So, let's use int* for this purpose. ==========
On 2017/02/21 02:29:26, shinyak wrote: > Try to fix build broken in https://codereview.chromium.org/2701253005/ Hi, sorry, I started the win_clang_rel trybot but then forgot to wait for it. Oops! I think it would be better cast __COUNTER__ to unsigned char (instead of storing the full range of value) so that a shorter form of mov is used. If you want to just revert my CL that's fine too, I can take a look and confirm if there's any difference in code size.
OK, I'll do cast.
The CQ bit was checked by shinyak@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Description was changed from ========== Fix win-clang build In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. This value could be larger than 255. clang-cl is complaining that "implicit conversion from 'int' to 'unsigned char' changes value from 256 to 0" when __COUNTER__ reaches 256. So, let's use int* for this purpose. ========== to ========== Fix win-clang build In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. This value could be larger than 255. clang-cl is complaining that "implicit conversion from 'int' to 'unsigned char' changes value from 256 to 0" when __COUNTER__ reaches 256. To make binary smaller, we use cast __COUNTER__ to unsigned char instead of assigning to int*. ==========
lgtm
Thanks for fixing this!
By the way, when casting __COUNTER__ to unsigned char, someone might be confused since the rvalue does not match the counter if __COUNTER >= 256. However, maybe we can use line number or something to know where this happened, so it won't be a problem. (right?)
Description was changed from ========== Fix win-clang build In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. This value could be larger than 255. clang-cl is complaining that "implicit conversion from 'int' to 'unsigned char' changes value from 256 to 0" when __COUNTER__ reaches 256. To make binary smaller, we use cast __COUNTER__ to unsigned char instead of assigning to int*. ========== to ========== Fix win-clang build In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. This value could be larger than 255. clang-cl is complaining that "implicit conversion from 'int' to 'unsigned char' changes value from 256 to 0" when __COUNTER__ reaches 256. To make binary smaller, we cast __COUNTER__ to unsigned char instead of assigning it to int*. ==========
Description was changed from ========== Fix win-clang build In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. This value could be larger than 255. clang-cl is complaining that "implicit conversion from 'int' to 'unsigned char' changes value from 256 to 0" when __COUNTER__ reaches 256. To make binary smaller, we cast __COUNTER__ to unsigned char instead of assigning it to int*. ========== to ========== Fix win-clang build In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. This value could be larger than 255. clang-cl is complaining that "implicit conversion from 'int' to 'unsigned char' changes value from 256 to 0" when __COUNTER__ reaches 256. To make binary smaller, we cast __COUNTER__ to unsigned char instead of assigning it to int*. TBR=thakis ==========
The CQ bit was unchecked by shinyak@chromium.org
The CQ bit was checked by shinyak@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Since this is a buildfix patch, I added TBR=thakis to commit
CQ is committing da patch. Bot data: {"patchset_id": 20001, "attempt_start_ts": 1487651101852060, "parent_rev": "3b2b2e23c656e16592fb6e2d4c75b5e4c353d061", "commit_rev": "7d988be5bc1966437c64ea465b1144644003472f"}
Message was sent while issue was closed.
Description was changed from ========== Fix win-clang build In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. This value could be larger than 255. clang-cl is complaining that "implicit conversion from 'int' to 'unsigned char' changes value from 256 to 0" when __COUNTER__ reaches 256. To make binary smaller, we cast __COUNTER__ to unsigned char instead of assigning it to int*. TBR=thakis ========== to ========== Fix win-clang build In base/logging.h, __COUNTER__ is used in IMMEDIATE_CRASH. This value could be larger than 255. clang-cl is complaining that "implicit conversion from 'int' to 'unsigned char' changes value from 256 to 0" when __COUNTER__ reaches 256. To make binary smaller, we cast __COUNTER__ to unsigned char instead of assigning it to int*. TBR=thakis Review-Url: https://codereview.chromium.org/2706143002 Cr-Commit-Position: refs/heads/master@{#451705} Committed: https://chromium.googlesource.com/chromium/src/+/7d988be5bc1966437c64ea465b11... ==========
Message was sent while issue was closed.
Committed patchset #2 (id:20001) as https://chromium.googlesource.com/chromium/src/+/7d988be5bc1966437c64ea465b11... |