This section gives an example of using LLVM. Since we are currently
transitioning from llvm-gcc3 to llvm-gcc4, we include examples for both.
+
+
@@ -1540,7 +1551,7 @@ transitioning from llvm-gcc3 to llvm-gcc4, we include examples for both.
Use the llvm-dis utility to take a look at the LLVM assembly
code:
- % llvm-dis < hello.bc | less
+
% llvm-dis < hello.bc | less
Compile the program to native assembly using the LLC code
generator:
@@ -1595,9 +1606,9 @@ transitioning from llvm-gcc3 to llvm-gcc4, we include examples for both.
Run the program. To make sure the program ran, execute one of the
following commands:
-
+
% ./hello
-
+
or
% lli hello.bc
@@ -1605,7 +1616,7 @@ transitioning from llvm-gcc3 to llvm-gcc4, we include examples for both.
Use the llvm-dis utility to take a look at the LLVM assembly
code:
- % llvm-dis < hello.bc | less
+
% llvm-dis < hello.bc | less
Compile the program to native assembly using the LLC code
generator:
--
2.34.1