DependableSystemsLab / LLFI

LLFI is an LLVM based fault injection tool, that injects faults into the LLVM IR of the application source code. The faults can be injected into specific program points, and the effect can be easily tracked back to the source code. Please refer to the paper below. NOTE: If you publish a paper using LLFI, please add it to PaperLLFI.bib
http://blogs.ubc.ca/karthik/2014/02/23/quantifying-the-accuracy-of-high-level-fault-injection-techniques/
Other
68 stars 35 forks source link

The unwind destination does not have a landingpad instruction! #90

Open Behroosh opened 8 years ago

Behroosh commented 8 years ago

I am working with "bfs" from the suggested test programs. I managed to instrument it when the target register is the destination register (dstreg). However, I get the following error message (in the instrumentation phase) when having source registers (allsrcreg) as target registers.

The unwind destination does not have a landingpad instruction! invoke void @_ZNSt5dequeIiSaIiEE9push_backERKi(%"class.std::deque"* %wavefront, i32* %5) to label %8 unwind label %73, !llfi_index !18 The unwind destination does not have a landingpad instruction! %14 = invoke zeroext i1 @_ZNKSt5dequeIiSaIiEE5emptyEv(%"class.std::deque"* %wavefront) to label %15 unwind label %73, !llfi_index !25 The unwind destination does not have a landingpad instruction! %18 = invoke i32* @_ZNSt5dequeIiSaIiEE5frontEv(%"class.std::deque"* %wavefront) to label %19 unwind label %73, !llfi_index !28 The unwind destination does not have a landingpad instruction! invoke void @_ZNSt5dequeIiSaIiEE9pop_frontEv(%"class.std::deque"* %wavefront) to label %21 unwind label %73, !llfi_index !31 The unwind destination does not have a landingpad instruction! invoke void @_ZNSt5dequeIiSaIiEE9push_backERKi(%"class.std::deque"* %wavefront, i32* %id) to label %68 unwind label %73, !llfiindex !81 LandingPadInst not the first non-PHI instruction in the block. %74 = landingpad { i8, i32 } personality i8_ bitcast (i32 (...)* @gxx_personalityv0 to i8) cleanup, !llfi_index !88 The unwind destination does not have a landingpad instruction! invoke void @ZNSt5dequeIiSaIiEED2Ev(%"class.std::deque" %wavefront) to label %87 unwind label %93, !llfiindex !93 LandingPadInst not the first non-PHI instruction in the block. %94 = landingpad { i8, i32 } personality i8_ bitcast (i32 (...)* @__gxx_personalityv0 to i8) catch i8_ null, !llfi_index !113 Broken module found, compilation aborted! 0 opt 0x00000000011f2942 llvm::sys::PrintStackTrace(_IO_FILE*) + 34 1 opt 0x00000000011f24f4 2 libpthread.so.0 0x00007f46bc78f340 3 libc.so.6 0x00007f46bbbd0cc9 gsignal + 57 4 libc.so.6 0x00007f46bbbd40d8 abort + 328 5 opt 0x0000000001117601 6 opt 0x0000000001120f42 7 opt 0x00000000010fb2cf llvm::FPPassManager::runOnFunction(llvm::Function&) + 623 8 opt 0x00000000010fb35b llvm::FPPassManager::runOnModule(llvm::Module&) + 43 9 opt 0x00000000010fd6c5 llvm::legacy::PassManagerImpl::run(llvm::Module&) + 709 10 opt 0x0000000000572264 main + 2452 11 libc.so.6 0x00007f46bbbbbec5 libc_start_main + 245 12 opt 0x000000000058d40d Stack dump:

  1. Program arguments: /ubc/ece/home/kp/grads/behsan/Workload/LLFI_Build/llvm/bin/opt -load /ubc/ece/home/kp/grads/behsan/Workload/LLFI_Build/LLFI2/bin/../llvm_passes/llfi-passes.so -profilingpass -insttype -excludeinst=ret -includeinst=all -regloc -allsrcreg -o /ubc/ece/home/kp/grads/behsan/Workload/LLFI_Build/SampleTest/bfs-allsrcreg/llfi/bfs-profiling.ll /ubc/ece/home/kp/grads/behsan/Workload/LLFI_Build/SampleTest/bfs-allsrcreg/llfi/bfs-llfi_index.ll -S
  2. Running pass 'Function Pass Manager' on module '/ubc/ece/home/kp/grads/behsan/Workload/LLFI_Build/SampleTest/bfs-allsrcreg/llfi/bfs-llfi_index.ll'.
  3. Running pass 'Module Verifier' on function '@_Z7BFS_CPUP4NodeP4EdgePiS3_i'

ERROR: there was an error during running the instrumentation pass, please follow the provided instructions for instrument.

Behroosh commented 8 years ago

I also used the latest version of LLFI and still got the same error message.

zezhang commented 7 years ago

Hey, I also have the same problem. Just want to ask did you fix up the problem yet?