This is an archive of the discontinued LLVM Phabricator instance.

[AMDGPU] gfx1010 wavefrontsize intrinsic folding
ClosedPublic

Authored by rampitec on Jun 12 2019, 7:47 AM.

Diff Detail

Event Timeline

rampitec created this revision.Jun 12 2019, 7:47 AM

I don't see codegen for this, so this looks like depending on an optimization pass for correctness

lib/Target/AMDGPU/AMDGPULibCalls.cpp
1392–1414

This doesn't really belong in this pass

test/CodeGen/AMDGPU/llvm.amdgcn.wavefrontsize.ll
7–8

Capitalized feature name is wrong? Also shouldn't be using opt -O3

I don't see codegen for this, so this looks like depending on an optimization pass for correctness

It is in the parent patch, inside ISelLowering. Optimization is only to fold it earlier.

arsenm added inline comments.Jun 12 2019, 8:26 AM
lib/Target/AMDGPU/AMDGPULibCalls.cpp
1392–1414

This might make more sense In AMDGPULowerIntrinsics?

rampitec marked an inline comment as done.Jun 12 2019, 8:31 AM
rampitec added inline comments.
lib/Target/AMDGPU/AMDGPULibCalls.cpp
1392–1414

The point is to give folding a chance as early as possible. It also belongs to libcalls because library is the primary user.

This revision is now accepted and ready to land.Jun 13 2019, 5:17 PM
This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptJun 17 2019, 10:57 AM