• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /freebsd-12-stable/contrib/llvm-project/compiler-rt/lib/fuzzer/

Lines Matching refs:Job

134     auto Job = new FuzzJob;
145 Job->DftTimeInSeconds = duration_cast<seconds>(Time2 - Time1).count();
148 Job->SeedListPath =
150 WriteToFile(Seeds, Job->SeedListPath);
151 Cmd.addFlag("seed_inputs", "@" + Job->SeedListPath);
153 Job->LogPath = DirPlusFile(TempDir, std::to_string(JobId) + ".log");
154 Job->CorpusDir = DirPlusFile(TempDir, "C" + std::to_string(JobId));
155 Job->FeaturesDir = DirPlusFile(TempDir, "F" + std::to_string(JobId));
156 Job->CFPath = DirPlusFile(TempDir, std::to_string(JobId) + ".merge");
157 Job->JobId = JobId;
160 Cmd.addArgument(Job->CorpusDir);
161 Cmd.addFlag("features_dir", Job->FeaturesDir);
163 for (auto &D : {Job->CorpusDir, Job->FeaturesDir}) {
168 Cmd.setOutputFile(Job->LogPath);
171 Job->Cmd = Cmd;
174 Printf("Job %zd/%p Created: %s\n", JobId, Job,
175 Job->Cmd.toString().c_str());
177 return Job;
180 void RunOneMergeJob(FuzzJob *Job) {
181 auto Stats = ParseFinalStatsFromLog(Job->LogPath);
187 GetSizedFilesFromDir(Job->CorpusDir, &TempFiles);
191 FeatureFile.replace(0, Job->CorpusDir.size(), Job->FeaturesDir);
203 // if (!FilesToAdd.empty() || Job->ExitCode != 0)
208 secondsSinceProcessStartUp(), Job->JobId, Job->DftTimeInSeconds);
215 &NewFeatures, Cov, &NewCov, Job->CFPath, false);
256 void Push(FuzzJob *Job) {
259 Qu.push(Job);
268 auto Job = Qu.front();
270 return Job;
275 while (auto Job = FuzzQ->Pop()) {
276 // Printf("WorkerThread: job %p\n", Job);
277 Job->ExitCode = ExecuteCommand(Job->Cmd);
278 MergeQ->Push(Job);
339 std::unique_ptr<FuzzJob> Job(MergeQ.Pop());
340 if (!Job)
342 ExitCode = Job->ExitCode;
350 Env.RunOneMergeJob(Job.get());
360 std::ifstream In(Job->LogPath);
369 FileToString(Job->LogPath).c_str());