RFR: 8326983: Unused operands reported after JDK-8326135 [v2]

Vladimir Kozlov kvn at openjdk.org
Fri Mar 1 21:32:56 UTC 2024


On Fri, 1 Mar 2024 07:39:16 GMT, kuaiwei <duke at openjdk.org> wrote:

>> Remove all unused operands reported by adlc. I'm testing x86_64 and aarch64. So far no failure found in tier1.
>> I tried to clean unused operands for all platform. A special case is immLRot2 in arm, it's not used, but appeared in many todo comments. So I keep it.
>
> kuaiwei has updated the pull request incrementally with one additional commit since the last revision:
> 
>   clean for other architecture

FTR, I also bailout from adlc parser when we have unused operand to force build failure:

+++ b/src/hotspot/share/adlc/archDesc.cpp
@@ -773,8 +774,11 @@ bool ArchDesc::check_usage() {
       cnt++;
     }
   }
-  if (cnt) fprintf(stderr, "\n-------Warning: total %d unused operands\n", cnt);
-
+  if (cnt) {
+    fprintf(stderr, "\n-------Warning: total %d unused operands\n", cnt);
+    _semantic_errs++;
+    return false;
+  }
   return true;
 }


I don't think we need it in these changes but it helped me to catch the missing case.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/18075#issuecomment-1973947309


More information about the hotspot-compiler-dev mailing list