Does parallel make require guards against duplicate actions?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-hackers(at)postgreSQL(dot)org
Subject: Does parallel make require guards against duplicate actions?
Date: 2010-01-05 02:58:58
Message-ID: 5201.1262660338@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

The old Gen_fmgrtab.sh script used temporary file names that included
its process PID. It had this comment about that:

# We use the temporary files to avoid problems with concurrent runs
# (which can happen during parallel make).

The new implementation uses temp files that just have ".tmp" appended to
the target file name. If there is a risk that "make -j" will run the
same action twice in parallel, this isn't good enough. While it
wouldn't be too tough to add the PID to the scripts, I wonder whether
this comment is about a real problem or just a flight of fancy. It
doesn't seem to me that parallel make ought to be stupid enough to
do the same action twice. Anybody know?

regards, tom lane

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Takahiro Itagaki 2010-01-05 03:00:51 Re: Verifying variable names in pgbench
Previous Message Andrew Dunstan 2010-01-05 02:34:07 Re: pgsql: Get rid of the need for manual maintenance of the initial