[clang] [llvm] [WIP] ABI Lowering Library (PR #140112)

Nikita Popov via cfe-commits cfe-commits at lists.llvm.org
Fri May 30 02:43:47 PDT 2025


================
@@ -0,0 +1,260 @@
+#ifndef LLVM_ABI_TYPES_H
+#define LLVM_ABI_TYPES_H
+
+#include "llvm/ADT/APFloat.h"
+#include "llvm/ADT/ArrayRef.h"
+#include "llvm/Support/Alignment.h"
+#include "llvm/Support/Allocator.h"
+#include "llvm/Support/TypeSize.h"
+#include <cstdint>
+#include <llvm/IR/CallingConv.h>
+
+namespace llvm {
+namespace abi {
+
+enum class TypeKind {
+  Void,
+  Integer,
+  Float,
+  Pointer,
+  Array,
+  Vector,
+  Struct,
+  Union,
+};
+
+class Type {
+protected:
+  TypeKind Kind;
+  TypeSize SizeInBits;
+  Align AlignInBits;
----------------
nikic wrote:

Are you sure this one is InBits? That would be pretty unusual, because memory can't be bit-addressed anyway.

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


More information about the cfe-commits mailing list