This patch adds support for the the LightWeight Profiling (LWP) instructions which are available on all AMD Bulldozer class CPUs (bdver1 to bdver4).
Details
- Reviewers
GGanesh craig.topper andreadb spatel - Commits
- rG99b925bdf388: [X86][LWP] Add llvm support for LWP instructions (reapplied).
rGb2e0464fde89: [X86][LWP] Add llvm support for LWP instructions.
rL302041: [X86][LWP] Add llvm support for LWP instructions (reapplied).
rL302028: [X86][LWP] Add llvm support for LWP instructions.
Diff Detail
- Repository
- rL LLVM
Event Timeline
test/CodeGen/X86/lwp-intrinsics-x86_64.ll | ||
---|---|---|
14 | That immediate seems way out of range of 32-bit value. Is that intentional? |
test/CodeGen/X86/lwp-intrinsics-x86_64.ll | ||
---|---|---|
14 | Yes, I was trying to check that it truncated correctly. Should I comment it? Add it as a separate test? |
test/CodeGen/X86/lwp-intrinsics-x86_64.ll | ||
---|---|---|
14 | OK, I'll strip them down. |
I noticed that according to X86GenInstrInfo.inc, the new LWPINS instructions don't have "UnmodeledSideEffects".
However, all the other LWP instructions have flag UnmodeledSideEffects set.
My understanding is that this is because LWPVAL/LLWPCB/SLWPCB are directly matched from x86 intrinsics with side effects, while LWPINS* are firstly lowered to X86ISD::LWPINS nodes.
Shouldn't we set hasSideEffects = 1 for the LWPINS variants too? After all, those instructions modify memory by pushing new events in the ring buffer. So, those can both read and write.
Can you split this refactor, please?