diff --git a/bindings/python/ast.cpp b/bindings/python/ast.cpp index 2ddf3e6db..8ba2c6f48 100644 --- a/bindings/python/ast.cpp +++ b/bindings/python/ast.cpp @@ -427,14 +427,11 @@ void bind_proof_trace(py::module_ &m) { &llvm_pattern_matching_failure_event::get_function_name); py::class_< - llvm_tail_call_info_event, - std::shared_ptr>( + llvm_tail_call_info_event, std::shared_ptr>( proof_trace, "llvm_tail_call_info_event", step_event) .def_property_readonly( - "callern_name", - &llvm_tail_call_info_event::get_caller_name) - .def_property_readonly( - "is_tail", &llvm_tail_call_info_event::is_tail); + "callern_name", &llvm_tail_call_info_event::get_caller_name) + .def_property_readonly("is_tail", &llvm_tail_call_info_event::is_tail); py::class_>( proof_trace, "llvm_function_event", step_event) diff --git a/include/kllvm/binary/ProofTraceParser.h b/include/kllvm/binary/ProofTraceParser.h index 36b3c4178..3e7fa3e2e 100644 --- a/include/kllvm/binary/ProofTraceParser.h +++ b/include/kllvm/binary/ProofTraceParser.h @@ -681,8 +681,7 @@ class proof_trace_parser { case pattern_matching_failure_sentinel: return parse_pattern_matching_failure(buffer); - case tail_call_info_sentinel: - return parse_tail_call_info(buffer); + case tail_call_info_sentinel: return parse_tail_call_info(buffer); default: return nullptr; } diff --git a/include/kllvm/codegen/ProofEvent.h b/include/kllvm/codegen/ProofEvent.h index 1a5bcc7a8..ecb1cc5d8 100644 --- a/include/kllvm/codegen/ProofEvent.h +++ b/include/kllvm/codegen/ProofEvent.h @@ -180,8 +180,8 @@ class proof_event { * Emit a call to the `tail_call_info` API of the specified `proof_writer`. */ llvm::CallInst *emit_write_tail_call_info( - llvm::Value *proof_writer, std::string const &caller_name, - bool is_tail, llvm::BasicBlock *insert_at_end); + llvm::Value *proof_writer, std::string const &caller_name, bool is_tail, + llvm::BasicBlock *insert_at_end); /* * Emit a call to the `start_new_chunk` API of the specified `proof_writer`. diff --git a/lib/codegen/CreateTerm.cpp b/lib/codegen/CreateTerm.cpp index 2a6ba97e9..eb257d990 100644 --- a/lib/codegen/CreateTerm.cpp +++ b/lib/codegen/CreateTerm.cpp @@ -1286,18 +1286,16 @@ bool make_function( if (call->getCallingConv() == llvm::CallingConv::Tail && can_tail_call(call->getType())) { call->setTailCallKind(llvm::CallInst::TCK_MustTail); - current_block = - proof_event(definition, module) - .tail_call_info(name, true, call, current_block); + current_block = proof_event(definition, module) + .tail_call_info(name, true, call, current_block); } else { - current_block = - proof_event(definition, module) - .tail_call_info(name, false, nullptr, current_block); + current_block + = proof_event(definition, module) + .tail_call_info(name, false, nullptr, current_block); } } else { - current_block = - proof_event(definition, module) - .tail_call_info(name, false, nullptr, current_block); + current_block = proof_event(definition, module) + .tail_call_info(name, false, nullptr, current_block); } } auto *ret diff --git a/lib/codegen/ProofEvent.cpp b/lib/codegen/ProofEvent.cpp index 9d44a552a..b4f33c323 100644 --- a/lib/codegen/ProofEvent.cpp +++ b/lib/codegen/ProofEvent.cpp @@ -305,8 +305,8 @@ llvm::CallInst *proof_event::emit_write_pattern_matching_failure( } llvm::CallInst *proof_event::emit_write_tail_call_info( - llvm::Value *proof_writer, std::string const &caller_name, - bool is_tail, llvm::BasicBlock *insert_at_end) { + llvm::Value *proof_writer, std::string const &caller_name, bool is_tail, + llvm::BasicBlock *insert_at_end) { auto b = llvm::IRBuilder(insert_at_end); auto *void_ty = llvm::Type::getVoidTy(ctx_); @@ -319,8 +319,7 @@ llvm::CallInst *proof_event::emit_write_tail_call_info( auto *func = get_or_insert_function( module_, "write_tail_call_info_to_proof_trace", func_ty); - auto *var_caller_name - = b.CreateGlobalStringPtr(caller_name, "", 0, module_); + auto *var_caller_name = b.CreateGlobalStringPtr(caller_name, "", 0, module_); auto *var_is_tail = llvm::ConstantInt::get(i8_ty, is_tail); return b.CreateCall(func, {proof_writer, var_caller_name, var_is_tail}); } @@ -753,7 +752,7 @@ llvm::BasicBlock *proof_event::tail_call_info( return current_block; } - std::tuple prelude; + std::tuple prelude; if (is_tail) { assert(insert_before); prelude = event_prelude("tail_call_info", insert_before);