diff mbox

[RFC,v5,5/6] configure: Use slow-path for atomic only when the softmmu is enabled

Message ID 1443083566-10994-6-git-send-email-a.rigo@virtualopensystems.com
State New
Headers show

Commit Message

Alvise Rigo Sept. 24, 2015, 8:32 a.m. UTC
Use the new slow path for atomic instruction translation when the
softmmu is enabled.

Suggested-by: Jani Kokkonen <jani.kokkonen@huawei.com>
Suggested-by: Claudio Fontana <claudio.fontana@huawei.com>
Signed-off-by: Alvise Rigo <a.rigo@virtualopensystems.com>
---
 configure | 11 +++++++++++
 1 file changed, 11 insertions(+)

Comments

Richard Henderson Sept. 30, 2015, 4:05 a.m. UTC | #1
On 09/24/2015 06:32 PM, Alvise Rigo wrote:
> Use the new slow path for atomic instruction translation when the
> softmmu is enabled.

Um... why?  TCG_USE_LDST_EXCL would appear to be 100% redundant with SOFTMMU.


r~
Alvise Rigo Sept. 30, 2015, 9:51 a.m. UTC | #2
On Wed, Sep 30, 2015 at 6:05 AM, Richard Henderson <rth@twiddle.net> wrote:
> On 09/24/2015 06:32 PM, Alvise Rigo wrote:
>>
>> Use the new slow path for atomic instruction translation when the
>> softmmu is enabled.
>
>
> Um... why?  TCG_USE_LDST_EXCL would appear to be 100% redundant with
> SOFTMMU.

Oops, modifying the previous version of the patch I didn't notice I
created a redundant variable.
I will remove it.

Regards,
alvise

>
>
> r~
diff mbox

Patch

diff --git a/configure b/configure
index cd219d8..5f72977 100755
--- a/configure
+++ b/configure
@@ -1391,6 +1391,13 @@  if test "$ARCH" = "unknown"; then
     fi
 fi
 
+# Use the slow-path for atomic instructions if the softmmu is enabled
+if test "$softmmu" = "yes"; then
+    tcg_use_ldst_excl="yes"
+else
+    tcg_use_ldst_excl="no"
+fi
+
 # Consult white-list to determine whether to enable werror
 # by default.  Only enable by default for git builds
 z_version=`cut -f3 -d. $source_path/VERSION`
@@ -4542,6 +4549,7 @@  echo "Install blobs     $blobs"
 echo "KVM support       $kvm"
 echo "RDMA support      $rdma"
 echo "TCG interpreter   $tcg_interpreter"
+echo "use ld/st excl    $tcg_use_ldst_excl"
 echo "fdt support       $fdt"
 echo "preadv support    $preadv"
 echo "fdatasync         $fdatasync"
@@ -4920,6 +4928,9 @@  fi
 if test "$tcg_interpreter" = "yes" ; then
   echo "CONFIG_TCG_INTERPRETER=y" >> $config_host_mak
 fi
+if test "$tcg_use_ldst_excl" = "yes" ; then
+  echo "CONFIG_TCG_USE_LDST_EXCL=y" >> $config_host_mak
+fi
 if test "$fdatasync" = "yes" ; then
   echo "CONFIG_FDATASYNC=y" >> $config_host_mak
 fi