Skip to content

Commit

Permalink
Version 4.1.0.13 (cherry-pick)
Browse files Browse the repository at this point in the history
Merged 9e99a60

Fix run-time ARMv6 detection.

BUG=v8:3844
LOG=N
[email protected]

Review URL: https://codereview.chromium.org/866393002

Cr-Commit-Position: refs/branch-heads/4.1@{crosswalk-project#14}
Cr-Branched-From: 2e08d2a-refs/heads/candidates@{#25353}
  • Loading branch information
bmeurer committed Jan 23, 2015
1 parent 0214eb0 commit bfe7179
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
11 changes: 10 additions & 1 deletion src/base/cpu.cc
Original file line number Diff line number Diff line change
Expand Up @@ -438,7 +438,7 @@ CPU::CPU()
//
// See http://code.google.com/p/android/issues/detail?id=10812
//
// We try to correct this by looking at the 'elf_format'
// We try to correct this by looking at the 'elf_platform'
// field reported by the 'Processor' field, which is of the
// form of "(v7l)" for an ARMv7-based CPU, and "(v6l)" for
// an ARMv6-one. For example, the Raspberry Pi is one popular
Expand All @@ -450,6 +450,15 @@ CPU::CPU()
}
delete[] processor;
}

// elf_platform moved to the model name field in Linux v3.8.
if (architecture_ == 7) {
char* processor = cpu_info.ExtractField("model name");
if (HasListItem(processor, "(v6l)")) {
architecture_ = 6;
}
delete[] processor;
}
}

// Try to extract the list of CPU features from ELF hwcaps.
Expand Down
2 changes: 1 addition & 1 deletion src/version.cc
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
#define MAJOR_VERSION 4
#define MINOR_VERSION 1
#define BUILD_NUMBER 0
#define PATCH_LEVEL 12
#define PATCH_LEVEL 13
// Use 1 for candidates and 0 otherwise.
// (Boolean macro values are not supported by all preprocessors.)
#define IS_CANDIDATE_VERSION 0
Expand Down

0 comments on commit bfe7179

Please sign in to comment.