Skip to content

[AsmPrinter] Remove an unnecessary cast (NFC) #152085

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

kazutakahirata
Copy link
Contributor

getValue() already returns uint64_t.

getValue() already returns uint64_t.
@llvmbot
Copy link
Member

llvmbot commented Aug 5, 2025

@llvm/pr-subscribers-debuginfo

Author: Kazu Hirata (kazutakahirata)

Changes

getValue() already returns uint64_t.


Full diff: https://github.com/llvm/llvm-project/pull/152085.diff

1 Files Affected:

  • (modified) llvm/lib/CodeGen/AsmPrinter/DIEHash.cpp (+1-1)
diff --git a/llvm/lib/CodeGen/AsmPrinter/DIEHash.cpp b/llvm/lib/CodeGen/AsmPrinter/DIEHash.cpp
index 08ed78eb20a16..a7491a2d272fa 100644
--- a/llvm/lib/CodeGen/AsmPrinter/DIEHash.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/DIEHash.cpp
@@ -230,7 +230,7 @@ void DIEHash::hashBlockData(const DIE::const_value_range &Values) {
              "Base types referenced from DW_OP_convert should have a name");
       hashNestedType(C, Name);
     } else
-      Hash.update((uint64_t)V.getDIEInteger().getValue());
+      Hash.update(V.getDIEInteger().getValue());
 }
 
 // Hash the contents of a loclistptr class.

@kazutakahirata kazutakahirata merged commit 86ab5dc into llvm:main Aug 5, 2025
12 checks passed
@kazutakahirata kazutakahirata deleted the cleanup_20250804_cast_llvm_AsmPrinter branch August 5, 2025 14:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants