hi Derek,
thanks for your explanation, I have downloaded the toolchain source and build almost everyone ok.(except when it searches for the .git in native_client directory, I deleted .git sometime),
But, I think I have downloaded what I need !, I only need llvm-clang x86_64 compiler and newlib library and some relative libs.
BUT, after I compiled it, I have two doubts:
(1) As I only need clang-llvm-x86_64-nacl compiler (not pexe, i need nexe), So I tried to compile one hello world .c with the newly build clang compiler.
But I don't know where the compiler is. So I scaned all the directories in out directory, the following ones may be what I want.
binutils_x86_x86_64_linux_install
compiler_rt_bc_x86_64_bc_install
core_sdk_libs_x86_64_install
driver_x86_64_linux_install
libcxx_x86_64_bc_install
libcxx_x86_64_install
libcxx_x86_64_linux_install
libgcc_eh_x86_64_install
libs_support_translator_x86_64_install
libs_support_x86_64_bc_install
libs_support_x86_64_install
llvm_x86_64_linux_install
newlib_x86_64_bc_install
newlib_x86_64_install
I use compiler in llvm_x86_64_linux_install/bin/x86_64-nacl-clang, But when I compile .c with it, I find it needs come basic .o file such as crt1.o, crtbeginT.o and so on.
Although I find all the .o files in above directories with 'find .. -name xxx', and I copied them to my builddir then compile ok .
but this is somewhat informal, I think there should have some scripts or some option for one to auto collect all the basic files for one to compile !!
Can you kindly figure it out ?
(2) What I want to do is to modify the core code generation part. for example, I would like to add one instruction before every load/store instruction.
Can you kindly figure the llvm code part which I should focus on ?
I have searched llvm/clang for string 'nacl/NACL', BUT, i didn't find any key parts.
NOW, I want to deep into this, try to expanding mem space larger than 4G !
Thanks !
在 2015年8月25日星期二 UTC+8上午12:44:39,Derek Schuff写道: