mirror of
https://github.com/flatcar/scripts.git
synced 2025-09-30 18:12:08 +02:00
stressapptest: upgraded package to upstream
Upgraded dev-util/stressapptest to version 1.0.4 on amd64, arm, x86 BUG=None TEST=Test commands are listed below: emerge-x86-generic dev-util/stressapptest emerge-daisy dev-util/stressapptest emerge-lumpy dev-util/stressapptest Change-Id: I1120f3f969f7a9c3eb30257667487464619dd332 Reviewed-on: https://gerrit.chromium.org/gerrit/40547 Reviewed-by: Mike Frysinger <vapier@chromium.org> Tested-by: Bruce Kuo <brucekuo@chromium.org> Commit-Queue: Bruce Kuo <brucekuo@chromium.org>
This commit is contained in:
parent
d7f374442f
commit
85e5076f26
@ -0,0 +1,43 @@
|
||||
http://code.google.com/p/stressapptest/issues/detail?id=26
|
||||
|
||||
--- a/src/os.cc
|
||||
+++ b/src/os.cc
|
||||
@@ -149,7 +149,16 @@ void OsLayer::GetFeatures() {
|
||||
// http://www.sandpile.org/ia32/cpuid.htm
|
||||
int ax, bx, cx, dx;
|
||||
__asm__ __volatile__ (
|
||||
- "cpuid": "=a" (ax), "=b" (bx), "=c" (cx), "=d" (dx) : "a" (1));
|
||||
+# if defined(STRESSAPPTEST_CPU_I686) && defined(__PIC__)
|
||||
+ "xchg %%ebx, %%esi;"
|
||||
+ "cpuid;"
|
||||
+ "xchg %%esi, %%ebx;"
|
||||
+ : "=S" (bx),
|
||||
+# else
|
||||
+ "cpuid;"
|
||||
+ : "=b" (bx),
|
||||
+# endif
|
||||
+ "=a" (ax), "=c" (cx), "=d" (dx) : "a" (1));
|
||||
has_clflush_ = (dx >> 19) & 1;
|
||||
has_sse2_ = (dx >> 26) & 1;
|
||||
|
||||
--- a/src/worker.cc
|
||||
+++ b/src/worker.cc
|
||||
@@ -85,7 +85,17 @@ namespace {
|
||||
inline int apicid(void) {
|
||||
int cpu;
|
||||
#if defined(STRESSAPPTEST_CPU_X86_64) || defined(STRESSAPPTEST_CPU_I686)
|
||||
- __asm __volatile("cpuid" : "=b" (cpu) : "a" (1) : "cx", "dx");
|
||||
+ __asm__ __volatile__ (
|
||||
+# if defined(STRESSAPPTEST_CPU_I686) && defined(__PIC__)
|
||||
+ "xchg %%ebx, %%esi;"
|
||||
+ "cpuid;"
|
||||
+ "xchg %%esi, %%ebx;"
|
||||
+ : "=S" (cpu)
|
||||
+# else
|
||||
+ "cpuid;"
|
||||
+ : "=b" (cpu)
|
||||
+# endif
|
||||
+ : "a" (1) : "cx", "dx");
|
||||
#elif defined(STRESSAPPTEST_CPU_ARMV7A)
|
||||
#warning "Unsupported CPU type ARMV7A: unable to determine core ID."
|
||||
cpu = 0;
|
@ -1,9 +1,11 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Copyright 1999-2013 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-util/stressapptest/stressapptest-1.0.4.ebuild,v 1.2 2012/11/27 06:54:01 vapier Exp $
|
||||
# $Header: /var/cvsroot/gentoo-x86/dev-util/stressapptest/stressapptest-1.0.4.ebuild,v 1.4 2013/01/05 04:35:30 vapier Exp $
|
||||
|
||||
EAPI="4"
|
||||
|
||||
inherit eutils
|
||||
|
||||
MY_P="${P}_autoconf"
|
||||
DESCRIPTION="Stressful Application Test"
|
||||
HOMEPAGE="http://code.google.com/p/stressapptest/"
|
||||
@ -11,7 +13,7 @@ SRC_URI="http://stressapptest.googlecode.com/files/${MY_P}.tar.gz"
|
||||
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="0"
|
||||
KEYWORDS="amd64 x86 arm"
|
||||
KEYWORDS="amd64 arm x86"
|
||||
IUSE="debug"
|
||||
|
||||
RDEPEND="dev-libs/libaio"
|
||||
@ -20,6 +22,7 @@ DEPEND="${RDEPEND}"
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
src_prepare() {
|
||||
epatch "${FILESDIR}"/${P}-cpuid-pic.patch
|
||||
sed -i \
|
||||
'/CXXFLAGS/s:-O3 -funroll-all-loops -funroll-loops::' \
|
||||
configure || die
|
||||
|
@ -4,9 +4,10 @@ DESCRIPTION=Stressful Application Test
|
||||
EAPI=4
|
||||
HOMEPAGE=http://code.google.com/p/stressapptest/
|
||||
IUSE=debug
|
||||
KEYWORDS=amd64 x86 arm
|
||||
KEYWORDS=amd64 ~arm ~x86
|
||||
LICENSE=Apache-2.0
|
||||
RDEPEND=dev-libs/libaio
|
||||
SLOT=0
|
||||
SRC_URI=http://stressapptest.googlecode.com/files/stressapptest-1.0.4_autoconf.tar.gz
|
||||
_md5_=9e3133bf4f780a1dac0d4e29ca889b7a
|
||||
_eclasses_=eutils 33ef77a15337022e05342d2c772a7a5a multilib 5f4ad6cf85e365e8f0c6050ddd21659e portability 0be430f759a631e692678ed796e09f5c toolchain-funcs 6526ac6fc9aedf391efb91fcd75ace68 user 9e552f935106ff0bc92af16da64b4b29
|
||||
_md5_=90f1ff23792866d05cec886262dc29da
|
||||
|
Loading…
x
Reference in New Issue
Block a user