[PATCH] [asan-assembly-instrumentation] Added instrumentation for REP MOVS.
Evgeniy Stepanov
eugenis at google.com
Wed Jul 30 07:15:14 PDT 2014
================
Comment at: lib/Target/X86/AsmParser/X86AsmInstrumentation.cpp:181
@@ +180,3 @@
+ InstrumentMOVSImpl(AccessSize, Ctx, Out);
+ return;
+}
----------------
Don't really need a return here.
================
Comment at: lib/Target/X86/AsmParser/X86AsmInstrumentation.cpp:620
@@ -489,3 +619,3 @@
const MCInst &Inst, OperandVector &Operands, MCContext &Ctx,
const MCInstrInfo &MII, MCStreamer &Out) {}
----------------
Don't you need to emit the original instruction here?
================
Comment at: lib/Target/X86/AsmParser/X86AsmInstrumentation.cpp:117
@@ +116,3 @@
+ MCContext &Ctx, MCStreamer &Out) {
+ // Test (%SrcReg)
+ {
----------------
Yuri Gorshenin wrote:
> Evgeniy Stepanov wrote:
> > In memcpy() we check shadow for entire source and destination ranges. I guess it's not easy to do efficiently in asm, but at least leave a FIXME.
> >
> > Also, this code does push eax/ecx/edx/flags four times - once for each InstrumentMemOperand. Factor prologue/epilogue generation out of InstrumentMemOperand?
> >
> I've added FIXME comments for both issues. Would you mind if I'll resolve second issue in a next CL?
OK
http://reviews.llvm.org/D4719
More information about the llvm-commits
mailing list