From bf484aa2163d5b88b09e1732975bc430d69bcf4d Mon Sep 17 00:00:00 2001 From: Paul Sokolovsky Date: Tue, 19 Feb 2013 08:36:52 +0200 Subject: [PATCH] Correct if-then-else LLVM asm example. As was present vividly breaks LLVM IR constraints on SSA and basic-blocks: same var being assigned twice, no control transfer at the end of basic block. Compare with the original: http://www.mdevan.org/llvm-py/kaleidoscope/PythonLangImpl5.html --- docs/source/doc/kaleidoscope/PythonLangImpl5.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/source/doc/kaleidoscope/PythonLangImpl5.rst b/docs/source/doc/kaleidoscope/PythonLangImpl5.rst index 5a096da..33edba2 100644 --- a/docs/source/doc/kaleidoscope/PythonLangImpl5.rst +++ b/docs/source/doc/kaleidoscope/PythonLangImpl5.rst @@ -217,7 +217,8 @@ Kaleidoscope looks something like this: br i1 %ifcond, label %then, label %else then: ; preds = %entry - %calltmp1 = call double @bar() + %calltmp = call double @foo() + br label %ifcont else: ; preds = %entry %calltmp1 = call double @bar()