Re: parallel restore vs. windows

Поиск
Список
Период
Сортировка
От Andrew Chernow
Тема Re: parallel restore vs. windows
Дата
Msg-id 493DEE0B.1010202@esilo.com
обсуждение исходный текст
Ответ на Re: parallel restore vs. windows  (Andrew Dunstan <andrew@dunslane.net>)
Ответы Re: parallel restore vs. windows  (Andrew Chernow <ac@esilo.com>)
Re: parallel restore vs. windows  (Andrew Dunstan <andrew@dunslane.net>)
Список pgsql-hackers
Andrew Dunstan wrote:
> 
> 
> Andrew Chernow wrote:
>>
>>>> HANDLE h = (HANDLE)_beginthreadex(NULL, 0, thread_start, arg, 0, NULL);
>>>
>>> This didn't give me any more joy, unfortunately. But you're right, I 
>>> should be using it.
>>>
>>
>> Are these threads sharing memory, intentionally or by mistake?
> 
> 
> Things they write, and things they read but might not be stable, are not 
> supposed to be shared. If they are it's a mistake.
> 

Looks like the ArchiveHandle variable 'AH' and the TocEntry 'next_work_item' are 
not being deep copied at line 315 of your patch, where you prepare the 
RestoreArgs struct for the thread.  Every thread is accessing and possibly 
updating the members of these structs that need to be deep copied.

-- 
Andrew Chernow
eSilo, LLC
every bit counts
http://www.esilo.com/


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Andrew Dunstan
Дата:
Сообщение: Re: parallel restore vs. windows
Следующее
От: Andrew Chernow
Дата:
Сообщение: Re: parallel restore vs. windows