Heming Cui
2010-Oct-25 19:39 UTC
[LLVMdev] Is it possible to map an LLVM instruction to x86 assembly instructions?
Dear folks, If I want to setup a mapping between an LLVM instruction and the x86 assembly instructions it generates, is this possible? Or, an equavalent question is, when LLVM is emitting assebmly instructions, will it transform a set of LLVM instructions to a set of assembly instructions, or transform each LLVM instruction to assembly instructions independently? -- Regards, Heming Cui -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20101025/13cf27a0/attachment.html>
Eli Friedman
2010-Oct-25 20:54 UTC
[LLVMdev] Is it possible to map an LLVM instruction to x86 assembly instructions?
On Mon, Oct 25, 2010 at 12:39 PM, Heming Cui <hc2428 at columbia.edu> wrote:> Dear folks, > If I want to setup a mapping between an LLVM instruction and the x86 > assembly instructions it generates, is this possible? > Or, an equavalent question is, when LLVM is emitting assebmly > instructions, will it transform a set of LLVM instructions to a set of > assembly instructions, or transform each LLVM instruction to assembly > instructions independently?Essentially, it's from a set to a set; if you're compiling without optimizations, the correlation will likely be close, but not exact. With optimizations, the end result might not be particularly close. You can come up with an approximation using debug information, though. -Eli
Jianzhou Zhao
2010-Oct-25 21:42 UTC
[LLVMdev] Is it possible to map an LLVM instruction to x86 assembly instructions?
On Mon, Oct 25, 2010 at 4:54 PM, Eli Friedman <eli.friedman at gmail.com> wrote:> On Mon, Oct 25, 2010 at 12:39 PM, Heming Cui <hc2428 at columbia.edu> wrote: >> Dear folks, >> If I want to setup a mapping between an LLVM instruction and the x86 >> assembly instructions it generates, is this possible? >> Or, an equavalent question is, when LLVM is emitting assebmly >> instructions, will it transform a set of LLVM instructions to a set of >> assembly instructions, or transform each LLVM instruction to assembly >> instructions independently? > > Essentially, it's from a set to a set; if you're compiling without > optimizations, the correlation will likely be close, but not exact. > With optimizations, the end result might not be particularly close. > You can come up with an approximation using debug information, though.Does the pass 'X86DAGToDAGISel' added by 'X86TargetMachine::addInstSelector' define such mappings? although it maps DAG to X86 code.> > -Eli > > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev >-- Jianzhou
Maybe Matching Threads
- [LLVMdev] Is it possible to map an LLVM instruction to x86 assembly instructions?
- [LLVMdev] How to add extern function declaratioin to llvm bc?
- [LLVMdev] Can Interpreter handle clone() call (with CLONE_VM flag)?
- [LLVMdev] DataStructure Analysis ds-aa can not stop when passing mysqld
- [LLVMdev] Given Filename and line number, how to get its basicblock?