Re: [Qemu-devel] [RFC 0/5] scripts/dump-guest-memory.py: Add multi-arch support

2016-01-20 Thread Laszlo Ersek
On 01/20/16 14:50, Markus Armbruster wrote: > Paolo Bonzini writes: > >> On 20/01/2016 11:03, Janosch Frank wrote: >>> >>> In python 3: >>> 1/2 == 0.5 >>> 1//2 == 0 >>> but a // b == floor(a/b), i.e. a cast is made. >>> >>> Anyway, I got rid of the import with: >>> -(-len_desc // 4) >> >> I would

Re: [Qemu-devel] [RFC 0/5] scripts/dump-guest-memory.py: Add multi-arch support

2016-01-20 Thread Markus Armbruster
Paolo Bonzini writes: > On 20/01/2016 11:03, Janosch Frank wrote: >> >> In python 3: >> 1/2 == 0.5 >> 1//2 == 0 >> but a // b == floor(a/b), i.e. a cast is made. >> >> Anyway, I got rid of the import with: >> -(-len_desc // 4) > > I would change that to either: > > def ceil_div(a, b) >

Re: [Qemu-devel] [RFC 0/5] scripts/dump-guest-memory.py: Add multi-arch support

2016-01-20 Thread Paolo Bonzini
On 20/01/2016 11:03, Janosch Frank wrote: > > In python 3: > 1/2 == 0.5 > 1//2 == 0 > but a // b == floor(a/b), i.e. a cast is made. > > Anyway, I got rid of the import with: > -(-len_desc // 4) I would change that to either: def ceil_div(a, b) return -(-a // b) ... ceil

Re: [Qemu-devel] [RFC 0/5] scripts/dump-guest-memory.py: Add multi-arch support

2016-01-20 Thread Janosch Frank
On 01/18/2016 06:57 PM, Laszlo Ersek wrote: > On 01/18/16 17:31, Andrew Jones wrote: >> On Thu, Jan 14, 2016 at 05:24:23PM +0100, Laszlo Ersek wrote: >>> On 01/14/16 09:48, Janosch Frank wrote: The dump guest memory script for extracting a Linux core from a qemu core is currently limited

Re: [Qemu-devel] [RFC 0/5] scripts/dump-guest-memory.py: Add multi-arch support

2016-01-18 Thread Laszlo Ersek
On 01/18/16 17:31, Andrew Jones wrote: > On Thu, Jan 14, 2016 at 05:24:23PM +0100, Laszlo Ersek wrote: >> On 01/14/16 09:48, Janosch Frank wrote: >>> The dump guest memory script for extracting a Linux core from a qemu >>> core is currently limited to amd64 and python 2. >>> >>> With this series we

Re: [Qemu-devel] [RFC 0/5] scripts/dump-guest-memory.py: Add multi-arch support

2016-01-18 Thread Andrew Jones
On Thu, Jan 14, 2016 at 05:24:23PM +0100, Laszlo Ersek wrote: > On 01/14/16 09:48, Janosch Frank wrote: > > The dump guest memory script for extracting a Linux core from a qemu > > core is currently limited to amd64 and python 2. > > > > With this series we add support for python 3 (while maintain

Re: [Qemu-devel] [RFC 0/5] scripts/dump-guest-memory.py: Add multi-arch support

2016-01-14 Thread Laszlo Ersek
On 01/14/16 09:48, Janosch Frank wrote: > The dump guest memory script for extracting a Linux core from a qemu > core is currently limited to amd64 and python 2. > > With this series we add support for python 3 (while maintaining python > 2 support) and add the possibility to extract dumps from VM

[Qemu-devel] [RFC 0/5] scripts/dump-guest-memory.py: Add multi-arch support

2016-01-14 Thread Janosch Frank
The dump guest memory script for extracting a Linux core from a qemu core is currently limited to amd64 and python 2. With this series we add support for python 3 (while maintaining python 2 support) and add the possibility to extract dumps from VMs with the most common architectures. This was te