Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-17 Thread Frederic Konrad
On 17/06/2015 20:23, Mark Burton wrote: On 17 Jun 2015, at 18:57, Dr. David Alan Gilbert wrote: * Alex Benn?e (alex.ben...@linaro.org) wrote: Hi, Shared Data Structures == Global TCG State We need to protect the entire code generation cycle including any

Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-17 Thread Mark Burton
> On 17 Jun 2015, at 18:57, Dr. David Alan Gilbert wrote: > > * Alex Benn?e (alex.ben...@linaro.org) wrote: >> Hi, > >> Shared Data Structures >> == >> >> Global TCG State >> >> >> We need to protect the entire code generation cycle including any post >> g

Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-17 Thread Dr. David Alan Gilbert
* Alex Benn?e (alex.ben...@linaro.org) wrote: > Hi, > Shared Data Structures > == > > Global TCG State > > > We need to protect the entire code generation cycle including any post > generation patching of the translated code. This also implies a shared > tran

Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-17 Thread Paolo Bonzini
On 17/06/2015 17:57, Alex Bennée wrote: > But would there be a risk is we make the BQL recursive? > > I had to do this because the iomem accesses either side of a virt-io > transaction would deadlock otherwise. The idea was to check if the BQL is taken, and if not take it in memory_region_disp

Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-17 Thread Alex Bennée
Paolo Bonzini writes: > On 12/06/2015 18:37, Alex Bennée wrote: >> Emulated hardware state >> --- >> >> Currently the hardware emulation has no protection against >> multiple-accesses. However guest systems accessing emulated hardware >> should be carrying out their own lock

Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-17 Thread Paolo Bonzini
On 12/06/2015 18:37, Alex Bennée wrote: > Emulated hardware state > --- > > Currently the hardware emulation has no protection against > multiple-accesses. However guest systems accessing emulated hardware > should be carrying out their own locking to prevent multiple CPUs >

Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-15 Thread Alex Bennée
Mark Burton writes: > I think we SHOUDL use the wiki - and keep it current. A lot of what you have > is in the wiki too, but I’d like to see the wiki updated. > We will add our stuff there too… Well I've added some pointer for now. Reading the wiki reminded me of the informal phone conference.

Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-15 Thread Alex Bennée
alvise rigo writes: > Hi Alex, > > Let me just add one comment. > >> >> Memory Barriers >> --- >> >> Barriers (sometimes known as fences) provide a mechanism for software >> to enforce a particular ordering of memory operations from the point >> of view of external observers (e.g. a

Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-15 Thread alvise rigo
Hi Alex, Let me just add one comment. On Fri, Jun 12, 2015 at 6:37 PM, Alex Bennée wrote: > Hi, > > One thing that Peter has been asking for is a design document for the > way we are going to approach multi-threaded TCG emulation. I started > with the information that was captured on the wiki an

Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-15 Thread Alex Bennée
Mark Burton writes: > I think we SHOUDL use the wiki - and keep it current. A lot of what you have > is in the wiki too, but I’d like to see the wiki updated. > We will add our stuff there too… I'll do a pass today and update it to point to lists, discussions and WIP trees. > > Cheers > Mark.

Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-15 Thread Mark Burton
I think we SHOUDL use the wiki - and keep it current. A lot of what you have is in the wiki too, but I’d like to see the wiki updated. We will add our stuff there too… Cheers Mark. > On 15 Jun 2015, at 12:06, Alex Bennée wrote: > > > Frederic Konrad writes: > >> On 12/06/2015 18:37, Alex

Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-15 Thread Alex Bennée
Frederic Konrad writes: > On 12/06/2015 18:37, Alex Bennée wrote: >> Hi, > > Hi Alex, > > I've completed some of the points below. We will also work on a design > decisions > document to add to this one. > > We probably want to merge that with what we did on the wiki? > http://wiki.qemu.org/Fea

Re: [Qemu-devel] RFC Multi-threaded TCG design document

2015-06-15 Thread Frederic Konrad
On 12/06/2015 18:37, Alex Bennée wrote: Hi, Hi Alex, I've completed some of the points below. We will also work on a design decisions document to add to this one. We probably want to merge that with what we did on the wiki? http://wiki.qemu.org/Features/tcg-multithread One thing that Pete

[Qemu-devel] RFC Multi-threaded TCG design document

2015-06-12 Thread Alex Bennée
Hi, One thing that Peter has been asking for is a design document for the way we are going to approach multi-threaded TCG emulation. I started with the information that was captured on the wiki and tried to build on that. It's almost certainly incomplete but I thought it would be worth posting for