]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
amdgcn: Remove dead code for fixed v0 register
authorJulian Brown <julian@codesourcery.com>
Wed, 25 Nov 2020 00:42:55 +0000 (16:42 -0800)
committerJulian Brown <julian@codesourcery.com>
Wed, 13 Jan 2021 01:05:47 +0000 (17:05 -0800)
This patch removes code to fix the v0 register in
gcn_conditional_register_usage that was missed out of the previous patch
removing the need for that:

  https://gcc.gnu.org/pipermail/gcc-patches/2019-November/534284.html

Backport from mainline:

2021-01-13  Julian Brown  <julian@codesourcery.com>

gcc/
* config/gcn/gcn.c (gcn_conditional_register_usage): Remove dead code
to fix v0 register.

(cherry picked from commit 7993fe1877a689463d8c71a0873e5cc8db080273)

gcc/config/gcn/gcn.c

index 2fcbf122e014078ef7e7ce204dc254758051f0ba..ee9f00558305b67d9b6d6fcd020592adf01b00c4 100644 (file)
@@ -2143,10 +2143,6 @@ gcn_conditional_register_usage (void)
     fixed_regs[cfun->machine->args.reg[WORK_ITEM_ID_Y_ARG]] = 1;
   if (cfun->machine->args.reg[WORK_ITEM_ID_Z_ARG] >= 0)
     fixed_regs[cfun->machine->args.reg[WORK_ITEM_ID_Z_ARG]] = 1;
-
-  if (TARGET_GCN5_PLUS)
-    /* v0 is always zero, for global nul-offsets.  */
-    fixed_regs[VGPR_REGNO (0)] = 1;
 }
 
 /* Determine if a load or store is valid, according to the register classes