qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [Bug 1321464] [NEW] qemu/block/qcow2.c:1942: possible perfo


From: dcb
Subject: [Qemu-devel] [Bug 1321464] [NEW] qemu/block/qcow2.c:1942: possible performance problem ?
Date: Tue, 20 May 2014 21:48:51 -0000

Public bug reported:

I just ran static analyser cppcheck over today (20140520) qemu source
code.

It said many things, including

[qemu/block/qcow2.c:1942] -> [qemu/block/qcow2.c:1943]: (performance) Buffer 
'pad_buf' is being writ
ten before its old content has been used.

Source code is

            memset(pad_buf, 0, s->cluster_size);
            memcpy(pad_buf, buf, nb_sectors * BDRV_SECTOR_SIZE);

Worth tuning ?

Similar problem here

[qemu/block/qcow.c:815] -> [qemu/block/qcow.c:816]: (performance) Buffer 
'pad_buf' is being written 
before its old content has been used.

and

[qemu/hw/i386/acpi-build.c:1265] -> [qemu/hw/i386/acpi-build.c:1267]: 
(performance) Buffer 'dsdt' is
 being written before its old content has been used.

** Affects: qemu
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1321464

Title:
  qemu/block/qcow2.c:1942: possible performance problem ?

Status in QEMU:
  New

Bug description:
  I just ran static analyser cppcheck over today (20140520) qemu source
  code.

  It said many things, including

  [qemu/block/qcow2.c:1942] -> [qemu/block/qcow2.c:1943]: (performance) Buffer 
'pad_buf' is being writ
  ten before its old content has been used.

  Source code is

              memset(pad_buf, 0, s->cluster_size);
              memcpy(pad_buf, buf, nb_sectors * BDRV_SECTOR_SIZE);

  Worth tuning ?

  Similar problem here

  [qemu/block/qcow.c:815] -> [qemu/block/qcow.c:816]: (performance) Buffer 
'pad_buf' is being written 
  before its old content has been used.

  and

  [qemu/hw/i386/acpi-build.c:1265] -> [qemu/hw/i386/acpi-build.c:1267]: 
(performance) Buffer 'dsdt' is
   being written before its old content has been used.

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1321464/+subscriptions



reply via email to

[Prev in Thread] Current Thread [Next in Thread]