[llvm] replace many GlobalValue->getValueType calls with more specific queries (PR #177039)

Nikita Popov via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 21 08:29:46 PST 2026


================
@@ -404,7 +404,7 @@ void WebAssemblyAsmPrinter::emitEndOfAsmFile(Module &M) {
     if (!G.hasInitializer() && G.hasExternalLinkage() &&
         !WebAssembly::isWasmVarAddressSpace(G.getAddressSpace()) &&
         G.getValueType()->isSized()) {
----------------
nikic wrote:

I think you are confusing unsized and scalable? Scalable types are sized. Unsized types are things like opaque struct types (`%S = type opaque`), and IIRC those can be used as types for external globals.

https://github.com/llvm/llvm-project/pull/177039


More information about the llvm-commits mailing list