This is an archive of the discontinued LLVM Phabricator instance.

AMDGPU/SI: Add llvm.amdgcn.v.interp.p[12] intrinsics
ClosedPublic

Authored by tstellarAMD on Dec 11 2015, 7:38 PM.

Details

Summary

These are meant to be used instead of the llvm.SI.fs.interp intrinsic which
will be deprecated at some point.

Diff Detail

Repository
rL LLVM

Event Timeline

tstellarAMD retitled this revision from to AMDGPU/SI: Add llvm.amdgcn.v.interp.p[12] intrinsics.
tstellarAMD updated this object.
tstellarAMD added a reviewer: arsenm.
tstellarAMD added a subscriber: llvm-commits.
arsenm added inline comments.Dec 14 2015, 9:53 AM
include/llvm/IR/IntrinsicsAMDGPU.td
135 ↗(On Diff #42621)

I'm not sure this should have the v prefix

lib/Target/AMDGPU/AMDGPUIntrinsicExpander.cpp
1 ↗(On Diff #42621)

Why is this easier than handling the differences during intrinsic lowering?

test/CodeGen/AMDGPU/llvm.SI.fs.interp.ll
74–78 ↗(On Diff #42621)

Should be moved into file with new name

lib/Target/AMDGPU/AMDGPUIntrinsicExpander.cpp
1 ↗(On Diff #42621)

I would like to stop using the intrinsics like fs.interp which are more like library calls, so I don't want to add them to the public IntrinsicsAMDGPU.td file. Having an IR expansion pass here means I only need to handle the lower-level intrinsics in isSourceOfDivergence(), and I don't need to use AMGPUInstrinsicInfo to look up intrinsic names.

Keep old intrinsic and drop AMDGPUIntrinsicExpander pass

arsenm accepted this revision.Dec 14 2015, 8:31 PM
arsenm edited edge metadata.

LGTM

This revision is now accepted and ready to land.Dec 14 2015, 8:31 PM
This revision was automatically updated to reflect the committed changes.