On 31/07/2019 13:02, Andrew Stubbs wrote:
However, in a couple of cases there is an exposed-pipeline issue that needs to be resolved with an actual "nop", which we no longer have. The patch also takes care of adding these, where appropriate. (As it happens, the cmpswap instruction will now get both s_waitcnt and nop, which is unnecessary, but that's because I plan to add proper scheduling for all the s_waitcnt instructions in the near future, and I don't want this detail to get forgotten.)

I need to do the same for global_store_* instructions, so I've committed the attached.

Andrew

Global GCN instructions need nops too.

2019-09-05  Andrew Stubbs  <a...@codesourcery.com>

	gcc/
	* config/gcn/gcn.md (*movti_insn): Set delayeduse for global_store.
	(sync_compare_and_swap<mode>_insn): Likewise.

diff --git a/gcc/config/gcn/gcn.md b/gcc/config/gcn/gcn.md
index 926d0120930..a2f4800d318 100644
--- a/gcc/config/gcn/gcn.md
+++ b/gcc/config/gcn/gcn.md
@@ -652,7 +652,7 @@
   }
   [(set_attr "type" "mult,smem,smem,flat,flat,vmult,vmult,vmult,flat,flat,\
 		     ds,ds")
-   (set_attr "delayeduse" "*,*,yes,*,*,*,*,*,*,*,*,*")
+   (set_attr "delayeduse" "*,*,yes,*,*,*,*,*,yes,*,*,*")
    (set_attr "length" "*,12,12,12,12,*,*,*,12,12,12,12")])
 
 ;; }}}
@@ -1619,7 +1619,7 @@
   [(set_attr "type" "smem,flat,flat")
    (set_attr "length" "12")
    (set_attr "gcn_version" "gcn5,*,gcn5")
-   (set_attr "delayeduse" "*,yes,*")])
+   (set_attr "delayeduse" "*,yes,yes")])
 
 (define_insn "sync_compare_and_swap<mode>_lds_insn"
   [(set (match_operand:SIDI 0 "register_operand"    "= v")

Reply via email to