[all-commits] [llvm/llvm-project] 075e16: [CIR] Correctly emit the size expr of a VLA with a...

Erich Keane via All-commits all-commits at lists.llvm.org
Thu May 28 14:24:05 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 075e16f74d7b265a22af73c4fcb5a6bd4b186543
      https://github.com/llvm/llvm-project/commit/075e16f74d7b265a22af73c4fcb5a6bd4b186543
  Author: Erich Keane <ekeane at nvidia.com>
  Date:   2026-05-28 (Thu, 28 May 2026)

  Changed paths:
    M clang/include/clang/CIR/Dialect/Builder/CIRBaseBuilder.h
    M clang/lib/CIR/CodeGen/CIRGenFunction.cpp
    M clang/test/CIR/CodeGen/vla.c

  Log Message:
  -----------
  [CIR] Correctly emit the size expr of a VLA with a 'bool' size. (#200066)

This came up in a test suite, the frontend considers 'bool' to be
integral enough to use as a bounds, so bool makes it through to the VLA
codegen. This patch adds a new cast function that takes a bool or int
type and casts it to an int (as this is a pretty useful task, that I
    believe I've seen before).



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list