[PATCH] D23992: [OpenCL] Augment pipe built-ins with pipe packet size and alignment.

Anastasia Stulova via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 5 08:49:12 PDT 2016

Anastasia added inline comments.

Comment at: lib/CodeGen/CGOpenCLRuntime.cpp:97
@@ +96,3 @@
+  return llvm::ConstantInt::get(Int32Ty,
+                                TypeSizeInBits / 8, // Size in bytes.
+                                false);
Perhaps it's safer to use getTypeSizeInChars instead? Even though most of architectures should have an 8-bit byte, it will allow us to avoid having hard-coded numbers.


More information about the cfe-commits mailing list