2020-01-22 12:07:55 +08:00
|
|
|
# RUN: llc -march=amdgcn -mcpu=polaris10 -run-pass si-insert-skips -amdgpu-skip-threshold-legacy=1 %s -o - | FileCheck %s
|
2017-01-25 06:18:39 +08:00
|
|
|
# https://bugs.freedesktop.org/show_bug.cgi?id=99019
|
|
|
|
--- |
|
|
|
|
define amdgpu_ps void @kill_uncond_branch() {
|
|
|
|
ret void
|
|
|
|
}
|
|
|
|
...
|
|
|
|
---
|
|
|
|
|
|
|
|
# CHECK-LABEL: name: kill_uncond_branch
|
|
|
|
|
|
|
|
# CHECK: bb.0:
|
2018-02-01 06:04:26 +08:00
|
|
|
# CHECK: S_CBRANCH_VCCNZ %bb.1, implicit $vcc
|
2017-01-25 06:18:39 +08:00
|
|
|
|
|
|
|
# CHECK: bb.1:
|
|
|
|
# CHECK: V_CMPX_LE_F32_e32
|
2018-02-01 06:04:26 +08:00
|
|
|
# CHECK-NEXT: S_CBRANCH_EXECNZ %bb.2, implicit $exec
|
2017-01-25 06:18:39 +08:00
|
|
|
|
|
|
|
# CHECK: bb.3:
|
|
|
|
# CHECK-NEXT: EXP_DONE
|
[AMDGPU] Add support for immediate operand for S_ENDPGM
Summary:
Add support for immediate operand in S_ENDPGM
Change-Id: I0c56a076a10980f719fb2a8f16407e9c301013f6
Reviewers: alexshap
Subscribers: qcolombet, arsenm, kzhuravl, jvesely, wdng, nhaehnle, yaxunl, tpr, t-tye, eraman, arphaman, Petar.Avramovic, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D59213
llvm-svn: 355902
2019-03-12 17:52:58 +08:00
|
|
|
# CHECK: S_ENDPGM 0
|
2017-01-25 06:18:39 +08:00
|
|
|
|
|
|
|
# CHECK: bb.2:
|
[AMDGPU] Add support for immediate operand for S_ENDPGM
Summary:
Add support for immediate operand in S_ENDPGM
Change-Id: I0c56a076a10980f719fb2a8f16407e9c301013f6
Reviewers: alexshap
Subscribers: qcolombet, arsenm, kzhuravl, jvesely, wdng, nhaehnle, yaxunl, tpr, t-tye, eraman, arphaman, Petar.Avramovic, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D59213
llvm-svn: 355902
2019-03-12 17:52:58 +08:00
|
|
|
# CHECK: S_ENDPGM 0
|
2017-01-25 06:18:39 +08:00
|
|
|
|
|
|
|
name: kill_uncond_branch
|
|
|
|
|
|
|
|
body: |
|
|
|
|
bb.0:
|
|
|
|
successors: %bb.1
|
2018-02-01 06:04:26 +08:00
|
|
|
S_CBRANCH_VCCNZ %bb.1, implicit $vcc
|
2017-01-25 06:18:39 +08:00
|
|
|
|
|
|
|
bb.1:
|
|
|
|
successors: %bb.2
|
2018-02-01 06:04:26 +08:00
|
|
|
$vgpr0 = V_MOV_B32_e32 0, implicit $exec
|
AMDGPU: Add implicit def of SCC to kill and indirect pseudos
Summary:
Kill instructions sometimes do use SCC in unusual circumstances, when
v_cmpx cannot be used due to the operands that are involved.
Additionally, even if SCC was never defined by the expansion, kill pseudos
could previously occur between an s_cmp and an s_cbranch_scc, which breaks
the SCC liveness tracking when the pseudo is expanded to split the basic
block. While it would be possible to explicitly mark the SCC as live-in for
the successor basic block, it's simpler to just mark the pseudo as using SCC,
so that such a sequence is never emitted by instruction selection in the
first place.
A similar issue affects indirect source/dest pseudos in principle, although
I haven't been able to come up with a test case where it actually matters
(this affects instruction selection, so a MIR test can't be used).
Fixes: dEQP-GLES3.functional.shaders.discard.dynamic_loop_always
Change-Id: Ica8d82ecff1a763b892a1112cf1b06c948863a4f
Reviewers: arsenm, rampitec
Subscribers: kzhuravl, wdng, yaxunl, dstuttard, tpr, t-tye, llvm-commits
Differential Revision: https://reviews.llvm.org/D47761
llvm-svn: 335223
2018-06-21 21:36:08 +08:00
|
|
|
SI_KILL_F32_COND_IMM_TERMINATOR $vgpr0, 0, 3, implicit-def $exec, implicit-def $vcc, implicit-def $scc, implicit $exec
|
2017-01-25 06:18:39 +08:00
|
|
|
S_BRANCH %bb.2
|
|
|
|
|
|
|
|
bb.2:
|
[AMDGPU] Add support for immediate operand for S_ENDPGM
Summary:
Add support for immediate operand in S_ENDPGM
Change-Id: I0c56a076a10980f719fb2a8f16407e9c301013f6
Reviewers: alexshap
Subscribers: qcolombet, arsenm, kzhuravl, jvesely, wdng, nhaehnle, yaxunl, tpr, t-tye, eraman, arphaman, Petar.Avramovic, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D59213
llvm-svn: 355902
2019-03-12 17:52:58 +08:00
|
|
|
S_ENDPGM 0
|