Hello World in LLVM
ecksit.wordpress.com
ecksit.wordpress.com
$ cat >hello.s <<EOF
.text
.globl main
main:
leaq msg, %rdi
callq puts
ret
.data
msg: .asciz "hello world\n"
EOF
$ as -o hello.o hello.s; cc -o hello hello.o; ./hello
hello world