[committed] Use vars to name parallel parts in dwz_files_1

Tom de Vries tdevries@suse.de
Tue Mar 30 07:43:09 GMT 2021


Hi,

Use variables initial_parallel_p and finalize_multifile_parallel_p to name
parallel parts in dwz_files_1.

Committed to trunk.

Thanks,
- Tom

Use vars to name parallel parts in dwz_files_1

2021-03-29  Tom de Vries  <tdevries@suse.de>

	* dwz.c (dwz_files_1): Add variables initial_parallel_p and
	finalize_multifile_parallel_p.

---
 dwz.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/dwz.c b/dwz.c
index 3ad9c9e..037cb75 100644
--- a/dwz.c
+++ b/dwz.c
@@ -16537,8 +16537,8 @@ dwz_files_1 (int nr_files, char *files[], bool hardlink,
       workset[workset_size] = i;
       workset_size++;
     }
-
-  if (max_forks > 1 && multifile == NULL)
+  bool initial_parallel_p = max_forks > 1 && multifile == NULL;
+  if (initial_parallel_p)
     {
       pid_t pids[nr_files];
       int nr_forks = 0;
@@ -16641,7 +16641,8 @@ dwz_files_1 (int nr_files, char *files[], bool hardlink,
       workset_size++;
     }
 
-  if (max_forks > 1)
+  bool finalize_multifile_parallel_p = max_forks > 1;
+  if (finalize_multifile_parallel_p)
     {
       pid_t pids[nr_files];
       int nr_forks = 0;


More information about the Dwz mailing list