Speed limited by text file?

archel

Client
Регистрация
02.05.2011
Сообщения
175
Благодарностей
22
Баллы
18
Hi

I've got a simple offline template that has to take a line from a general file and then delete the line and do some regexp tasks with it.
Now, if I run 2, 10, or 40 threads simultaniously, it doesn't matter. The speed of executions stays the same.
I guess because only 1 template can edit a certain text file at a time.

There are some thousands of lines in the file, so it takes some time before all the executions are done.
But it could go a lot faster I guess if there is another method than taking/deleting the first line of a text file.
Thought about it but can't think of one that is workable enough.

Does anyone know a good solution for this?
Thanks in advance.
Steven
 

satyr85

Client
Регистрация
24.02.2012
Сообщения
43
Благодарностей
3
Баллы
8
Loops are working fine for me with such problems (speed is better). Simple add for example 50-100 lops of your task before template finish all tasks.
 
  • Спасибо
Реакции: archel

archel

Client
Регистрация
02.05.2011
Сообщения
175
Благодарностей
22
Баллы
18
This works indeed.
Thanks!
 

Кто просматривает тему: (Всего: 1, Пользователи: 0, Гости: 1)