Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(8)

Issue 790643008: Condition itet ARM instruction in strcpy.c on thumb2 mode (Closed)

Created:
6 years ago by Derek Schuff
Modified:
6 years ago
Reviewers:
JF, Roland McGrath
CC:
native-client-reviews_googlegroups.com
Base URL:
https://chromium.googlesource.com/native_client/nacl-newlib.git@master
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Condition itet ARM instruction in strcpy.c on non-nacl Unlike nacl-gcc, nacl-clang defaults to unified syntax for the compiler's output. In pre-UAL syntax the it instruction is simply ignored; however in unified syntax the condition is checked against the conditions on the following instructions and an error is emitted if they do not match. Since this it instruction specifies the conditions of the three following instructions, they do not match when the sfi_breg expands to additional instructions, triggering the error when using nacl-clang. Also change the condition for selecting the strcmp implementation from __ARM_FEATURE_SIMD32 to __ARM_ARCH_PROFILE. The former is only defined by the compiler when it supports certain builtins (which clang does not support). But the builtins are not actually needed, only assembler support for the instructions. So _ARM_ARCH_PROFILE better indicates the needed support. R=jfb@chromium.org, mcgrathr@chromium.org BUG= https://code.google.com/p/nativeclient/issues/detail?id=4018 Committed: https://git.chromium.org/gitweb?p=native_client/nacl-newlib.git;a=commit;h=4e25c2883f51b43758f44ffcc6abb31b8680fb7c

Patch Set 1 #

Total comments: 2

Patch Set 2 : review, add ARM_ARCH_PROFILE #

Unified diffs Side-by-side diffs Delta from patch set Stats (+3 lines, -1 line) Patch
M newlib/libc/machine/arm/strcmp.S View 1 1 chunk +1 line, -1 line 0 comments Download
M newlib/libc/machine/arm/strcpy.c View 1 1 chunk +2 lines, -0 lines 0 comments Download

Messages

Total messages: 6 (0 generated)
Derek Schuff
6 years ago (2014-12-16 05:17:35 UTC) #1
JF
Typo in the description: "unfied" Also, the previous syntax is "pre-UAL syntax", not ARM. https://codereview.chromium.org/790643008/diff/1/newlib/libc/machine/arm/strcpy.c ...
6 years ago (2014-12-16 17:17:01 UTC) #2
Derek Schuff
https://codereview.chromium.org/790643008/diff/1/newlib/libc/machine/arm/strcpy.c File newlib/libc/machine/arm/strcpy.c (right): https://codereview.chromium.org/790643008/diff/1/newlib/libc/machine/arm/strcpy.c#newcode145 newlib/libc/machine/arm/strcpy.c:145: #ifdef __thumb2__ On 2014/12/16 17:17:00, JF wrote: > This ...
6 years ago (2014-12-16 18:44:34 UTC) #3
JF
lgtm
6 years ago (2014-12-16 18:50:36 UTC) #4
Roland McGrath
lgtm
6 years ago (2014-12-16 18:51:41 UTC) #5
Derek Schuff
6 years ago (2014-12-16 18:54:46 UTC) #6
Message was sent while issue was closed.
Committed patchset #2 (id:20001) manually as
4e25c2883f51b43758f44ffcc6abb31b8680fb7c (tree was closed).

Powered by Google App Engine
This is Rietveld 408576698