-
Notifications
You must be signed in to change notification settings - Fork 10.4k
/
Copy pathGenArray.cpp
68 lines (57 loc) · 1.81 KB
/
GenArray.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
//===--- GenArray.cpp - Swift IR Generation for Array Types -----------===//
//
// This source file is part of the Swift.org open source project
//
// Copyright (c) 2014 - 2015 Apple Inc. and the Swift project authors
// Licensed under Apache License v2.0 with Runtime Library Exception
//
// See http://swift.org/LICENSE.txt for license information
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//
//===----------------------------------------------------------------------===//
//
// This file implements IR generation for array types in Swift. This
// includes creating the IR type as well as performing primitive array
// access operations.
//
//===----------------------------------------------------------------------===//
#include "swift/AST/Types.h"
#include "swift/AST/Decl.h"
#include "llvm/DerivedTypes.h"
#include "Address.h"
#include "GenType.h"
#include "IRGenModule.h"
#include "RValue.h"
using namespace swift;
using namespace irgen;
namespace {
class ArrayTypeInfo : public TypeInfo {
public:
ArrayTypeInfo() : TypeInfo(nullptr, Size(0), Alignment(0)) {}
RValueSchema getSchema() const {
// FIXME
return RValueSchema();
}
void getExplosionSchema(ExplosionSchema &schema) const {
// FIXME
}
RValue load(IRGenFunction &IGF, Address addr) const {
// FIXME
return RValue();
}
void store(IRGenFunction &CGF, const RValue &rvalue, Address addr) const {
// FIXME
}
void loadExplosion(IRGenFunction &IGF, Address addr, Explosion &explosion) const {
// FIXME
}
void storeExplosion(IRGenFunction &IGF, Explosion &explosion, Address addr) const {
// FIXME
}
};
}
const TypeInfo *
TypeConverter::convertArrayType(IRGenModule &IGM, ArrayType *T) {
// FIXME
return new ArrayTypeInfo();
}