[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stu
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid() |
Date: |
Tue, 12 Nov 2013 23:53:47 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130923 Thunderbird/17.0.9 |
Il 12/11/2013 19:54, Richard Henderson ha scritto:
> For what it's worth, I think BOTH of the patches that have been posted
> should be applied. That is, the patch that does (X || 1) -> (1 || X),
> and the patch that adds the stub.
>
> Frankly I'd have thought this was obvious
It's not that obvious to me.
If you add the stub, the patch that reorders operands is not necessary.
If you reorder operands, the stub is not necessary.
The patch that does (X || 1) -> (1 || X) is unnecessary as a
microoptimization, since this code basically runs once at startup. The
code is also a little bit less clear with the reordered operands, but
perhaps that's just me because I wrote the code that way. (Splitting
the if in two would also make sense, and would not affect clarity).
Why should both be applied?
Paolo
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), (continued)
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Peter Maydell, 2013/11/12
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Paolo Bonzini, 2013/11/12
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Peter Maydell, 2013/11/12
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Paolo Bonzini, 2013/11/12
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Peter Maydell, 2013/11/12
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Anthony Liguori, 2013/11/12
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Peter Maydell, 2013/11/12
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Richard Henderson, 2013/11/12
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Peter Maydell, 2013/11/12
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Stefan Weil, 2013/11/12
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(),
Paolo Bonzini <=
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Richard Henderson, 2013/11/12
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Paolo Bonzini, 2013/11/13
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Peter Maydell, 2013/11/13
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Gleb Natapov, 2013/11/13
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Peter Maydell, 2013/11/12
- Re: [Qemu-devel] [PATCH for-1.7] target-i386: Fix build by providing stub kvm_arch_get_supported_cpuid(), Peter Maydell, 2013/11/11