From patchwork Tue Apr 27 12:56:03 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gleb Natapov X-Patchwork-Id: 95411 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o3RCuCA9021866 for ; Tue, 27 Apr 2010 12:56:12 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753224Ab0D0M4I (ORCPT ); Tue, 27 Apr 2010 08:56:08 -0400 Received: from mx1.redhat.com ([209.132.183.28]:6393 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751254Ab0D0M4G (ORCPT ); Tue, 27 Apr 2010 08:56:06 -0400 Received: from int-mx03.intmail.prod.int.phx2.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o3RCu65s012973 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 27 Apr 2010 08:56:06 -0400 Received: from dhcp-1-237.tlv.redhat.com (dhcp-1-237.tlv.redhat.com [10.35.1.237]) by int-mx03.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o3RCu5T3010074; Tue, 27 Apr 2010 08:56:05 -0400 Received: by dhcp-1-237.tlv.redhat.com (Postfix, from userid 13519) id B455E1336CF; Tue, 27 Apr 2010 15:56:04 +0300 (IDT) From: Gleb Natapov To: avi@redhat.com, mtosatti@redhat.com Cc: kvm@vger.kernel.org Subject: [PATCH 1/2] Test cmps between two IO locations. Date: Tue, 27 Apr 2010 15:56:03 +0300 Message-Id: <1272372964-4159-1-git-send-email-gleb@redhat.com> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.16 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Tue, 27 Apr 2010 12:56:12 +0000 (UTC) diff --git a/kvm/user/test/x86/emulator.c b/kvm/user/test/x86/emulator.c index c6adbb5..db84c13 100644 --- a/kvm/user/test/x86/emulator.c +++ b/kvm/user/test/x86/emulator.c @@ -17,18 +17,11 @@ void report(const char *name, int result) } } -void test_cmps(void *mem) +void test_cmps_one(unsigned char *m1, unsigned char *m3) { - unsigned char *m1 = mem, *m2 = mem + 1024; - unsigned char m3[1024]; void *rsi, *rdi; long rcx, tmp; - for (int i = 0; i < 100; ++i) - m1[i] = m2[i] = m3[i] = i; - for (int i = 100; i < 200; ++i) - m1[i] = (m3[i] = m2[i] = i) + 1; - rsi = m1; rdi = m3; rcx = 30; asm volatile("xor %[tmp], %[tmp] \n\t" "repe/cmpsb" @@ -91,6 +84,19 @@ void test_cmps(void *mem) } +void test_cmps(void *mem) +{ + unsigned char *m1 = mem, *m2 = mem + 1024; + unsigned char m3[1024]; + + for (int i = 0; i < 100; ++i) + m1[i] = m2[i] = m3[i] = i; + for (int i = 100; i < 200; ++i) + m1[i] = (m3[i] = m2[i] = i) + 1; + test_cmps_one(m1, m3); + test_cmps_one(m1, m2); +} + void test_cr8(void) { unsigned long src, dst; diff --git a/roms/seabios b/roms/seabios index 8f469b9..0360e8e 160000 --- a/roms/seabios +++ b/roms/seabios @@ -1 +1 @@ -Subproject commit 8f469b9676127ba6bb52609d89ec774e61db0ee1 +Subproject commit 0360e8e69bb3a773ceb9d2b091b62c027bca862b