prune-trace: use the first write pilot instead of any

In some cases the write-pilot is located at the upper boundary of the
experiment and thus is in a race situation with the experiment's end.
If the experiment's end occurs first, the campaign ends and complains
about missing data, otherwise everything is fine.
This patch circumvents this via using "the first" writing pilot; iff the
only write is located at the experiment's end, the race will still occur,
but cleverly written experiment code can, according to hsc, circumvent it.

Change-Id: I6a27a8c4770c04ea8dcaef8aa7bd85d18f43f0b5
This commit is contained in:
Michael Lenz
2014-01-17 13:41:28 +01:00
parent 0534b503a6
commit 4ccddeb137

View File

@ -35,6 +35,7 @@ bool BasicPruner::prune_all() {
" data_address, width, " << m_method_id << " "
"FROM trace "
"WHERE variant_id = " << row[0] << " AND accesstype = 'W' "
"ORDER BY instr2 ASC "
"LIMIT 1";
if (!db->query(ss.str().c_str())) return false;
ss.str("");